]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
testsuite: Require atomic operations for c2y-if-decls-*
authorDimitar Dimitrov <dimitar@dinux.eu>
Sun, 27 Oct 2024 07:49:49 +0000 (09:49 +0200)
committerDimitar Dimitrov <dimitar@dinux.eu>
Mon, 11 Nov 2024 18:53:45 +0000 (20:53 +0200)
Since some of the c2y-if-decls tests use _Atomic, add a
requirement for target to support atomic operations on
int and long types.

This fixes spurious test link failures on pru-unknown-elf,
which lacks atomic ops.  The tests still pass on x86_64-linux-gnu.

gcc/testsuite/ChangeLog:

* gcc.dg/c2y-if-decls-1.c: Require target that supports atomic
operations on int and long types.
* gcc.dg/c2y-if-decls-11.c: Ditto.
* gcc.dg/c2y-if-decls-4.c: Ditto.
* gcc.dg/c2y-if-decls-8.c: Ditto.

Signed-off-by: Dimitar Dimitrov <dimitar@dinux.eu>
gcc/testsuite/gcc.dg/c2y-if-decls-1.c
gcc/testsuite/gcc.dg/c2y-if-decls-11.c
gcc/testsuite/gcc.dg/c2y-if-decls-4.c
gcc/testsuite/gcc.dg/c2y-if-decls-8.c

index ab9b3f207003c8bf2b2562e6e0c440f415d4d67b..f4e8e5d2f882684d18e9018ec3ab1025830b98e5 100644 (file)
@@ -1,6 +1,7 @@
 /* N3356 - if declarations.  */
 /* PR c/117019 */
 /* { dg-do run } */
+/* { dg-require-effective-target sync_int_long } */
 /* { dg-options "-std=c2y -Wc23-c2y-compat" } */
 /* Test C2Y if declarations.  Valid usages.  */
 
index 5ac962507c9e12ed0b4197b125e557045bdbbd9b..065e74c530af69701f8a513ed6b4bd682b06ea25 100644 (file)
@@ -1,6 +1,7 @@
 /* N3356 - if declarations.  */
 /* PR c/117019 */
 /* { dg-do run } */
+/* { dg-require-effective-target sync_int_long } */
 /* { dg-options "-std=c2y -pedantic-errors" } */
 /* Test C2Y if declarations.  Valid usages.  */
 
index 6df4bb09a9e24a235b722554287fd7cc80a7323c..1648f6583bd2ed5f5284097fdd35e3c873f80030 100644 (file)
@@ -1,6 +1,7 @@
 /* N3356 - if declarations.  */
 /* PR c/117019 */
 /* { dg-do run } */
+/* { dg-require-effective-target sync_int_long } */
 /* { dg-options "-std=c2y -Wc23-c2y-compat" } */
 /* Test C2Y if declarations.  Valid usages.  */
 
index bd3c5cc4403ca94c2f2dc02cc5d5d40ad9cdd537..432b3da77f82c4c7ac02b7982f565343fe5c9b80 100644 (file)
@@ -1,6 +1,7 @@
 /* N3356 - if declarations.  */
 /* PR c/117019 */
 /* { dg-do run } */
+/* { dg-require-effective-target sync_int_long } */
 /* { dg-options "-std=c2y -pedantic-errors" } */
 /* Test C2Y if declarations.  Valid usages.  */