https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70010
--- Comment #7 from Jiu Fu Guo <guojiufu at gcc dot gnu.org> --- Author: guojiufu Date: Wed Oct 16 13:35:41 2019 New Revision: 277065 URL: https://gcc.gnu.org/viewcvs?rev=277065&root=gcc&view=rev Log: In PR70010, a function is marked with target(no-vsx) to disable VSX code generation. To avoid VSX code generation, this function should not be inlined into VSX function. To fix the bug, in the current logic when checking whether the caller's ISA flags supports the callee's ISA flags, we just need to add a test that enforces that the caller's ISA flags match exactly the callee's flags, for those flags that were explicitly set in the callee. If caller without target attribute then using options from command line. gcc/ 2019-10-16 Peter Bergner <berg...@linux.ibm.com> Jiufu Guo <guoji...@linux.ibm.com> PR target/70010 * config/rs6000/rs6000.c (rs6000_can_inline_p): Prohibit inlining if the callee explicitly disables some isa_flags the caller is using. gcc.testsuite/ 2019-10-16 Peter Bergner <berg...@linux.ibm.com> Jiufu Guo <guoji...@linux.ibm.com> PR target/70010 * gcc.target/powerpc/pr70010.c: New test. * gcc.target/powerpc/pr70010-1.c: New test. * gcc.target/powerpc/pr70010-2.c: New test. * gcc.target/powerpc/pr70010-3.c: New test. * gcc.target/powerpc/pr70010-4.c: New test. Added: trunk/gcc/testsuite/gcc.target/powerpc/pr70010-1.c trunk/gcc/testsuite/gcc.target/powerpc/pr70010-2.c trunk/gcc/testsuite/gcc.target/powerpc/pr70010-3.c trunk/gcc/testsuite/gcc.target/powerpc/pr70010-4.c trunk/gcc/testsuite/gcc.target/powerpc/pr70010.c Modified: trunk/gcc/ChangeLog trunk/gcc/config/rs6000/rs6000.c trunk/gcc/testsuite/ChangeLog