https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111366

--- Comment #10 from Kewen Lin <linkw at gcc dot gnu.org> ---
(In reply to Jan Wassenberg from comment #5)
> Thanks for reporting this. One might think this is caused by -mcpu=power9
> clashing with our #pragma target altivec,vsx,power8-vector.
> 
> However, what makes this seem like an actual bug is that -flto=auto is
> additionally required to trigger the bug.

This reminds me there is one bug in the current function rs6000_can_inline_p,
see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102059#c17

-flto=auto makes the callee have a constructed DECL_FUNCTION_SPECIFIC_TARGET,
so callee_tree is not NULL, it would further check ISA flags. Without it, the
current implementation doesn't adopt the default option node and just ignore it
unexpectedly. Filed PR111380.

Reply via email to