On 5/20/20 9:46 AM, Segher Boessenkool wrote:
So, which spec are those 4 lines above from?
From -with-specs=<blah> in the configure command. We use that
capability extensively for VxWorks.
We have as DRIVER_SELF_SPECS (see rs6000.h)
#define DRIVER_SELF_SPECS \
"%{mdejagnu-cpu=*: %<mcpu=* -mcpu=%*}", \
"%{mdejagnu-tune=*: %<mtune=* -mtune=%*}", \
"%{mdejagnu-*: %<mdejagnu-*}", \
SUBTARGET_DRIVER_SELF_SPECS
so -mdejagnu-cpu= is translated to -mcpu= very early. But yours is
still done earlier?
Interesting. I've been testing on a modified gcc-9, and I don't have
the DRIVER_SELF_SPECS for rs6000.h. Possibly this problem will be
solved by backporting this macro? I can't yet run the fsf-testsuite
for vxworks on gcc-11 until many more vxworks specific hunks have been
ported.
It can of course be fixed by adding
%{mdejagnu-cpu=604:%{!maltivec:%{!mno-altivec:-mno-altivec}}}
%{mdejagnu-cpu=604:%{!mvsx:%{!mno-vsx:-mno-vsx}}}
%{!mdejagnu-cpu=*:%{!maltivec:%{!mno-altivec:-mno-altivec}}}
%{!mdejagnu-cpu=*:%{!mvsx:%{!mno-vsx:-mno-vsx}}}
to your specs, but that is band-aid on top of band-aid.
Indeed
Why do you want
to add -mno-altivec -mno-vsx whenever possible, anyway?
Clearly these aren't supported in the VxWorks kernel and adding them
helps with getting a cleaner testsuite result. If you're asking beyond
those reasons, I'll have to dig a bit more to give an answer.