Assembly vs C

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
User avatar
bewing
Member
Member
Posts: 1401
Joined: Wed Feb 07, 2007 1:45 pm
Location: Eugene, OR, US

Re: Assembly vs C

Post by bewing »

You are being overly pedantic. And you missed my main point. We are already assuming the algorithms are basically identical, and we are assuming the specific case of how GCC compiles code (and not just some random theoretical compiler). But the main point is that the code itself has very little to do with it. The speed of the code is mostly governed by the number of memory accesses that it does, and that the OS has to do to execute the code. Reduce that, and the speed increases a lot. I know from direct observation that you can beat GCC by a factor of two by doing that one thing.
Post Reply