-
- Downloads
aarch64: Allow compiler to define ls64 builtins [PR110132]
This patch refactors the ls64 builtins to allow the compiler to define them directly instead of having wrapper functions in arm_acle.h. This should be not only easier to maintain, but it makes two important correctness fixes: - It fixes PR110132, where the builtins ended up getting declared with invisible bindings in the C FE, so the FE ended up synthesizing incompatible implicit definitions for these builtins. - It allows the builtins to be used with LTO, which didn't work previously. We also take the opportunity to add test coverage from C++ for these builtins. gcc/ChangeLog: PR target/110132 * config/aarch64/aarch64-builtins.cc (aarch64_general_simulate_builtin): New. Use it ... (aarch64_init_ls64_builtins): ... here. Switch to declaring public ACLE names for builtins. (aarch64_general_init_builtins): Ensure we invoke the arm_acle.h setup if in_lto_p, just like we do for SVE. * config/aarch64/arm_acle.h: (__arm_ld64b): Delete. (__arm_st64b): Delete. (__arm_st64bv): Delete. (__arm_st64bv0): Delete. gcc/testsuite/ChangeLog: PR target/110132 * lib/target-supports.exp (check_effective_target_aarch64_asm_FUNC_ok): Extend to ls64. * g++.target/aarch64/acle/acle.exp: New. * g++.target/aarch64/acle/ls64.C: New test. * g++.target/aarch64/acle/ls64_lto.C: New test. * gcc.target/aarch64/acle/ls64_lto.c: New test. * gcc.target/aarch64/acle/pr110132.c: New test. (cherry picked from commit 9963029a)
Showing
- gcc/config/aarch64/aarch64-builtins.cc 19 additions, 5 deletionsgcc/config/aarch64/aarch64-builtins.cc
- gcc/config/aarch64/arm_acle.h 0 additions, 33 deletionsgcc/config/aarch64/arm_acle.h
- gcc/testsuite/g++.target/aarch64/acle/acle.exp 35 additions, 0 deletionsgcc/testsuite/g++.target/aarch64/acle/acle.exp
- gcc/testsuite/g++.target/aarch64/acle/ls64.C 10 additions, 0 deletionsgcc/testsuite/g++.target/aarch64/acle/ls64.C
- gcc/testsuite/g++.target/aarch64/acle/ls64_lto.C 10 additions, 0 deletionsgcc/testsuite/g++.target/aarch64/acle/ls64_lto.C
- gcc/testsuite/gcc.target/aarch64/acle/ls64_lto.c 10 additions, 0 deletionsgcc/testsuite/gcc.target/aarch64/acle/ls64_lto.c
- gcc/testsuite/gcc.target/aarch64/acle/pr110132.c 15 additions, 0 deletionsgcc/testsuite/gcc.target/aarch64/acle/pr110132.c
- gcc/testsuite/lib/target-supports.exp 1 addition, 1 deletiongcc/testsuite/lib/target-supports.exp
Loading
Please register or sign in to comment