This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
Hi, The problem here is that after DECL_DISREGARD_INLINE_LIMITS was added, we don't copy the value from the merged function decl for template decls. This fixes that obvious forgotten problem. This is a regression because we now merge the attributes but the middle-end decides that it cannot inline a function any more at -O0 even though it should be. OK? Bootstrapped and tested on i686-apple-darwin8.11.1 without any regressions. I added 4 tests to make sure that the we don't regress again and we actually do the correct thing for always_inline. Thanks, Andrew Pinski * decl.c (duplicate_decls): Merge DECL_DISREGARD_INLINE_LIMITS for template decls' function decl. * g++.dg/ext/always_inline-1.C: New test. * g++.dg/ext/always_inline-2.C: New test. * g++.dg/ext/always_inline-3.C: New test. * g++.dg/ext/always_inline-4.C: New test.
Attachment:
fixPRinline.diff.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |