[Bug c++/54988] fpmath=sse target pragma causes inlining failure because of target specific option mismatch

thiago at kde dot org gcc-bugzilla@gcc.gnu.org
Mon Oct 22 14:43:00 GMT 2012


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

--- Comment #3 from Thiago Macieira <thiago at kde dot org> 2012-10-22 14:43:11 UTC ---
This might be as I pointed out in
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54231:

(Node "Function attributes"):

     On the 386/x86_64 and PowerPC backends, the inliner will not
     inline a function that has different target options than the
     caller, unless the callee has a subset of the target options of
     the caller.  For example a function declared with `target("sse3")'
     can inline a function with `target("sse2")', since `-msse3'
     implies `-msse2'.

My guess was that we were forcing the inlining (via always_inline) of a
function that has different target options.

But I guess that doesn't explain why it happens only in C++ and only in
optimising mode. Does always_inline inline on -O0 too?



More information about the Gcc-bugs mailing list