diff options
author | Jakub Jelinek <jakub@redhat.com> | 2025-09-04 18:52:47 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2025-09-04 18:52:47 +0200 |
commit | e2e01a893c1770e23ec1a573403688198c321b0e (patch) | |
tree | 97076a6bd82847509f7eace1a6029aa9e49ec0a2 /gcc | |
parent | 79d9ff28c2da0fde4aae0c034d7d39ef27558c14 (diff) | |
download | gcc-e2e01a893c1770e23ec1a573403688198c321b0e.zip gcc-e2e01a893c1770e23ec1a573403688198c321b0e.tar.gz gcc-e2e01a893c1770e23ec1a573403688198c321b0e.tar.bz2 |
aarch64: Adjust aarch64/spaceship_1.C testcase for recent changes [PR121732]
In r16-3414 libstdc++ changed ABI for (still experimental C++20) and uses
unordered value -128 instead of 2. Generally the change improved code
generation on all targets tested, see
https://gcc.gnu.org/pipermail/gcc-patches/2025-August/693534.html
for details.
In r16-3474 I've adjusted the middle-end and backends to use that value.
This apparently broke the spaceship_1.C test on aarch64 which scans the
exact function bodies which are now different.
The following patch adjusts the full body patterns to match. On these
2 routines, the generated code is 1 insn longer than in the past, so if
you have ideas how to change the code generation for the common case of
-1, 0, 1, -128 value, maybe it could be improved.
2025-09-04 Jakub Jelinek <jakub@redhat.com>
PR testsuite/121732
PR target/117013
* g++.target/aarch64/spaceship_1.C: Adjust expected fn bodies
for _Z8ss_floatff and _Z9ss_doubledd.
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/g++.target/aarch64/spaceship_1.C | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/gcc/testsuite/g++.target/aarch64/spaceship_1.C b/gcc/testsuite/g++.target/aarch64/spaceship_1.C index e6daf62..2dfc972 100644 --- a/gcc/testsuite/g++.target/aarch64/spaceship_1.C +++ b/gcc/testsuite/g++.target/aarch64/spaceship_1.C @@ -34,8 +34,9 @@ ** _Z8ss_floatff: ** fcmpe s0, s1 ** csinv (w[0-9]+), wzr, wzr, pl -** cset (w[0-9]+), vs -** csinc w0, \1, \2, ls +** mov (w[0-9]+), -129 +** csel (w[0-9]+), \2, wzr, vs +** csinc w0, \1, \3, ls ** ret */ SPACESHIP_FN(float); @@ -53,8 +54,9 @@ SPACESHIP_FN_NN(float); ** _Z9ss_doubledd: ** fcmpe d0, d1 ** csinv (w[0-9]+), wzr, wzr, pl -** cset (w[0-9]+), vs -** csinc w0, \1, \2, ls +** mov (w[0-9]+), -129 +** csel (w[0-9]+), \2, wzr, vs +** csinc w0, \1, \3, ls ** ret */ SPACESHIP_FN(double); |