On 10/15/19 4:56 AM, Segher Boessenkool wrote: > On Tue, Oct 15, 2019 at 05:15:07PM +0800, Jiufu Guo wrote: >> And another issue: Behavior is still inconsistent between "-mno-vsx >> -flto" and "-mno-vsx" for user code. Previous patch makes it consistent >> between "-mvsx -flto" and "-mvsx". > >> $GCC_BUILD/gcc/xgcc -B$GCC_BUILD/gcc novsx.c -O2 -mno-vsx >> /home/guojiufu/temp/novsx.c: In function 'main': >> /home/guojiufu/temp/novsx.c:6:1: error: inlining failed in call to >> 'always_inline' 'foo': target specific option mismatch > > So what should we do about this? There are arguments for *both* > behaviours, and apparently with LTO we do not know which flags are > explicit?
I'd say this is user error, telling the compiler it has to inline the callee function, but then using incompatible options on the caller and the callee, so that it cannot. I think the error message is the correct thing here. Peter