]> git.ipfire.org Git - people/ms/gcc.git/commit
aarch64: Prevent FPR register asms for +nofp
authorRichard Sandiford <richard.sandiford@arm.com>
Wed, 7 Sep 2022 09:52:03 +0000 (10:52 +0100)
committerRichard Sandiford <richard.sandiford@arm.com>
Wed, 7 Sep 2022 09:52:03 +0000 (10:52 +0100)
commitf58d5545d6b39cb6534dae105931e92ea9389d1f
tree51675784eddc2624dee0e47122acfb37e1ecdc68
parent0067ba052b976431c49d6a86f2c9ede9938efcdf
aarch64: Prevent FPR register asms for +nofp

+nofp disabled the automatic allocation of FPRs, but it didn't stop
users from explicitly putting register variables in FPRs.  We'd then
either report an ICE or generate unsupported instructions.

It's still possible (and deliberately redundant) to specify FPRs in
clobber lists.

gcc/
* config/aarch64/aarch64.cc (aarch64_conditional_register_usage):
Disallow use of FPRs in register asms for !TARGET_FLOAT.

gcc/testsuite/
* gcc.target/aarch64/nofp_2.c: New test.
gcc/config/aarch64/aarch64.cc
gcc/testsuite/gcc.target/aarch64/nofp_2.c [new file with mode: 0644]