4 ms·
I liked this this reply farther in to the thread: "inlines, when used properly, are _not_ larger than not inlining" http://lkml.indiana.edu/hypermail/linux/ke
by nkurz 16y ago
I liked this this reply farther in to the thread: "inlines, when used properly, are _not_ larger than not inlining"
http://lkml.indiana.edu/hypermail/linux/kernel/0206.1/0843.html http://lkml.indiana.edu/hypermail/linux/kernel/0206.1/0843.h...
My usual rule is to not inline anything that calls a full fledged function, and to only explicitly inline things that are truly on high performance paths. Basically, trust that the compiler will inline or not inline the rest as appropriate. But this is another interesting metric to consider.
- Locke1689 16y agoMy usual rule is to not inline anything that calls a full fledged function, and to only explicitly inline things that are truly on high performance paths. Basically, trust that the compiler will inline or not inline the rest as appropriate. But this is another interesting metric to consider. That's pretty much correct. Keep in mind, though, that inline has different consequences in a header file. There are good and bad reasons for that kind of usage.