[Bug c++/59394] Unused code generated

gjl at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sun Dec 22 16:43:00 GMT 2013


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59394

--- Comment #3 from Georg-Johann Lay <gjl at gcc dot gnu.org> ---
Some more notes:

If you don't want that small functions are being inlined, consider
-fno-inline-small-functions.

If a function is being inlined then it's body is still implemented except in
the case where GCC can prove the body is never needed, for example if the
function is static.

If you implement two functions that result in the same code, GCC won't reuse
the code for you.  If you have redundant code, it is up to you to reuse it.



More information about the Gcc-bugs mailing list