There is an amazing discussion about compiler optimizations going on right now at the lkml. It all began with Ingo Molnar's patches to improve .text size with GCC 4 compilers. Really quite informative to see both the pros and cons of using the inline keyword of the C compilers.

Oh, by the way, while the discussion reached the consensus that using inline in abundance is a problem, it reminded me that people should use static for functions that are meant to be used only in the compilation unit where they appear. This way, GCC is even able reduce the size of the generated binaries (not exactly sure if this would impact the running size of the binaries---I still have to investigate that).

I was so tired today that I slept for about 16h. I needed that.

blog comments powered by Disqus