summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c
diff options
context:
space:
mode:
authorDavid Alan Gilbert <david.gilbert@linaro.org>2011-10-14 14:39:32 +0000
committerRichard Sandiford <rsandifo@gcc.gnu.org>2011-10-14 14:39:32 +0000
commite11a4c8086c3e6fadeb25950bffca82be527ed8b (patch)
tree1eac349fa79439900ee2821fb4b51a27644f2739 /gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c
parent41aac0de5b574d74a08d92d7dbddb1735fcff694 (diff)
downloadgcc-e11a4c8086c3e6fadeb25950bffca82be527ed8b.tar.gz
di-longlong64-sync-1.c: New test.
gcc/testsuite/ 2011-10-14 David Alan Gilbert <david.gilbert@linaro.org> * gcc.dg/di-longlong64-sync-1.c: New test. * gcc.dg/di-sync-multithread.c: New test. * gcc.target/arm/di-longlong64-sync-withhelpers.c: New test. * gcc.target/arm/di-longlong64-sync-withldrexd.c: New test. * lib/target-supports.exp: (arm_arch_*_ok): Series of effective-target tests for v5, v6, v6k, and v7-a, and add-options helpers. (check_effective_target_arm_arm_ok): New helper. (check_effective_target_sync_longlong): New helper. From-SVN: r179983
Diffstat (limited to 'gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c')
-rw-r--r--gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c b/gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c
new file mode 100644
index 00000000000..dab69405ef4
--- /dev/null
+++ b/gcc/testsuite/gcc.target/arm/di-longlong64-sync-withldrexd.c
@@ -0,0 +1,17 @@
+/* { dg-do compile } */
+/* { dg-require-effective-target arm_arm_ok } */
+/* { dg-options "-marm -std=gnu99" } */
+/* { dg-require-effective-target arm_arch_v6k_ok } */
+/* { dg-add-options arm_arch_v6k } */
+/* { dg-message "note: '__sync_fetch_and_nand' changed semantics in GCC 4.4" "" { target *-*-* } 0 } */
+/* { dg-message "note: '__sync_nand_and_fetch' changed semantics in GCC 4.4" "" { target *-*-* } 0 } */
+/* { dg-message "file included" "In file included" { target *-*-* } 0 } */
+
+#include "../../gcc.dg/di-longlong64-sync-1.c"
+
+/* We should be using ldrexd, strexd and no helpers or shorter ldrex. */
+/* { dg-final { scan-assembler-times "\tldrexd" 46 } } */
+/* { dg-final { scan-assembler-times "\tstrexd" 46 } } */
+/* { dg-final { scan-assembler-not "__sync_" } } */
+/* { dg-final { scan-assembler-not "ldrex\t" } } */
+/* { dg-final { scan-assembler-not "strex\t" } } */