On 2026-07-20 15:51, Richard Earnshaw (foss) wrote:
On 14/07/2026 19:30, Torbjörn SVENSSON wrote:
Ok for trunk, releases/gcc-16 and releases/gcc-15?
Do I need to pick this for GCC14 and GCC13 too in order to close the ticket?
Kind regards,
Torbjörn
--
On MVE or NEON capable targers and thumb1 targets, I see these:
XPASS: gcc.dg/Wstringop-overflow-47.c pr97027 (test for warnings, line 72)
XPASS: gcc.dg/Wstringop-overflow-47.c pr97027 (test for warnings, line 77)
XPASS: gcc.dg/Wstringop-overflow-47.c pr97027 note (test for warnings, line 68)
gcc/testsuite/ChangeLog:
PR target/124364
* gcc.dg/Wstringop-overflow-47.c: Remove xfail.
Signed-off-by: Torbjörn SVENSSON <[email protected]>
---
gcc/testsuite/gcc.dg/Wstringop-overflow-47.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/gcc/testsuite/gcc.dg/Wstringop-overflow-47.c
b/gcc/testsuite/gcc.dg/Wstringop-overflow-47.c
index 6fb64ae96e2..c243b26390d 100644
--- a/gcc/testsuite/gcc.dg/Wstringop-overflow-47.c
+++ b/gcc/testsuite/gcc.dg/Wstringop-overflow-47.c
@@ -65,15 +65,15 @@ void warn_i16_64 (int16_t i)
like x86_64 it's a series of BIT_FIELD_REFs. The overflow by
the former is detected but the latter is not yet. */
- extern char warn_a64[64]; // { dg-message "at offset (1|128) into destination object 'warn_a64' of size (63|64)" "pr97027 note" { xfail { ! { aarch64-*-* } } } }
+ extern char warn_a64[64]; // { dg-message "at offset (1|128) into destination object
'warn_a64' of size (63|64)" "pr97027 note" { xfail { ! { aarch64-*-* || { arm_neon
|| { arm_mve || arm_thumb1 } } } } } }
I think it's ok to write:
{ arm_neon || arm_mve || arm_thumb1 }
Rather than
{ arm_neon || { arm_mve || arm_thumb1 } }
since all the boolean operations are the same. It's only if you mix || and &&
that you need explicit nesting.
If you really wanted to avoid ambiguity, though, it might be better to write
{ aarch64*-*-* || { arm*-*-* && { arm_neon || arm_mve || arm_thumb1 } } }
since this makes it completely clear that these operators apply to the arm*
targets, not aarch64.
I don't think we can.
ERROR: gcc.dg/Wstringop-overflow-47.c: syntax error in target selector "target arm_neon || arm_mve || arm_thumb1" for
" dg-message 68 "at ...64)" "pr97027 note" { xfail { ! { aarch64-*-* || { arm*-*-* && {
arm_neon || arm_mve || arm_thumb1 } } } } } "
This is the expression that I decided to push:
{ aarch64-*-* || { arm*-*-* && { arm_neon || { arm_mve || arm_thumb1 } } } }
Otherwise, OK.
Pushed as r17-2562-g11f59ab65c277a, r16-9315-gd9c29beefdc584 and
r15-11399-gaf341ce9bd4923.
Kind regards,
Torbjörn
R.
void *p = warn_a64 + 1;
I16_64 *q = (I16_64*)p;
- *q = (I16_64){ i }; // { dg-warning "writing (1 byte|64 bytes) into a region of
size (0|63)" "pr97027" { xfail { ! { aarch64-*-* } } } }
+ *q = (I16_64){ i }; // { dg-warning "writing (1 byte|64 bytes) into a region of
size (0|63)" "pr97027" { xfail { ! { aarch64-*-* || { arm_neon || { arm_mve ||
arm_thumb1 } } } } } }
char a64[64];
p = a64 + 1;
q = (I16_64*)p;
- *q = (I16_64){ i }; // { dg-warning "writing (1 byte|64 bytes) into a region of
size (0|63)" "pr97027" { xfail { ! { aarch64-*-* } } } }
+ *q = (I16_64){ i }; // { dg-warning "writing (1 byte|64 bytes) into a region of
size (0|63)" "pr97027" { xfail { ! { aarch64-*-* || { arm_neon || { arm_mve ||
arm_thumb1 } } } } } }
sink (p);
}