Olivier Hainque <hain...@adacore.com> writes: >> On 16 Dec 2019, at 11:19, Richard Sandiford <richard.sandif...@arm.com> >> wrote: > >>> * gcc.target/aarch64/aapcs64/aapcs64.exp: Guard tests using >>> abitest.S by check_weak_available. >> >> OK, thanks. > > Great, thanks for your prompt feedback Richard! > > As a side question, we have quite a few failures or aarch64 > specific tests caused by the use of -fpic or -fPIC in dg-options, > also not supported by the VxWorks compilers in kernel mode. > > We have local patches adding > > dg-require-effective-target fpic > > directives to these. > > Is that the correct thing to do ?
Yeah. Adding that to tests that use -fpic or -fPIC is OK/preapproved. Personally, I don't think people can be expected to remember to use this whenever they add a new -fpic or -fPIC test, so it's probably going to be a constant fight to get clean results without PIC support. Maybe we should have a programmatic fix. E.g. we could override dg-options in gcc-dg.exp and make it do the equivalent of: { dg-require-effective-target fpic } whenever -fpic or -fPIC is used. We override it in a few test harnesses already (e.g. mips.exp, which does something more complicated) so it wouldn't be entirely new ground. Thanks, Richard