diff options
author | Dan Albert <danalbert@google.com> | 2016-02-24 13:48:45 -0800 |
---|---|---|
committer | Dan Albert <danalbert@google.com> | 2016-02-24 13:51:18 -0800 |
commit | b9de1157289455b0ca26daff519d4a0ddcd1fa13 (patch) | |
tree | 4c56cc0a34b91f17033a40a455f26652304f7b8d /gcc-4.8.1/gcc/testsuite/gcc.dg/ia64-sync-3.c | |
parent | 098157a754787181cfa10e71325832448ddcea98 (diff) | |
download | toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.tar.gz toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.tar.bz2 toolchain_gcc-b9de1157289455b0ca26daff519d4a0ddcd1fa13.zip |
Update 4.8.1 to 4.8.3.
My previous drop was the wrong version. The platform mingw is
currently using 4.8.3, not 4.8.1 (not sure how I got that wrong).
From ftp://ftp.gnu.org/gnu/gcc/gcc-4.8.3/gcc-4.8.3.tar.bz2.
Bug: http://b/26523949
Change-Id: Id85f1bdcbbaf78c7d0b5a69e74c798a08f341c35
Diffstat (limited to 'gcc-4.8.1/gcc/testsuite/gcc.dg/ia64-sync-3.c')
-rw-r--r-- | gcc-4.8.1/gcc/testsuite/gcc.dg/ia64-sync-3.c | 80 |
1 files changed, 0 insertions, 80 deletions
diff --git a/gcc-4.8.1/gcc/testsuite/gcc.dg/ia64-sync-3.c b/gcc-4.8.1/gcc/testsuite/gcc.dg/ia64-sync-3.c deleted file mode 100644 index 621e90277..000000000 --- a/gcc-4.8.1/gcc/testsuite/gcc.dg/ia64-sync-3.c +++ /dev/null @@ -1,80 +0,0 @@ -/* { dg-do run } */ -/* { dg-require-effective-target sync_int_long } */ -/* { dg-options } */ -/* { dg-options "-march=i486" { target { { i?86-*-* x86_64-*-* } && ia32 } } } */ -/* { dg-options "-mcpu=v9" { target sparc*-*-* } } */ - -/* Test basic functionality of the intrinsics. */ - -__extension__ typedef __SIZE_TYPE__ size_t; - -extern void abort (void); -extern void *memcpy (void *, const void *, size_t); - -static int AI[4]; -static int init_si[4] = { -30,-30,-50,-50 }; -static int test_si[4] = { -115,-115,25,25 }; - -static void -do_si (void) -{ - if (__sync_val_compare_and_swap(AI+0, -30, -115) != -30) - abort (); - if (__sync_val_compare_and_swap(AI+0, -30, -115) != -115) - abort (); - if (__sync_bool_compare_and_swap(AI+1, -30, -115) != 1) - abort (); - if (__sync_bool_compare_and_swap(AI+1, -30, -115) != 0) - abort (); - - if (__sync_val_compare_and_swap(AI+2, AI[2], 25) != -50) - abort (); - if (__sync_val_compare_and_swap(AI+2, AI[2], 25) != 25) - abort (); - if (__sync_bool_compare_and_swap(AI+3, AI[3], 25) != 1) - abort (); - if (__sync_bool_compare_and_swap(AI+3, AI[3], 25) != 1) - abort (); -} - -static long AL[4]; -static long init_di[4] = { -30,-30,-50,-50 }; -static long test_di[4] = { -115,-115,25,25 }; - -static void -do_di (void) -{ - if (__sync_val_compare_and_swap(AL+0, -30, -115) != -30) - abort (); - if (__sync_val_compare_and_swap(AL+0, -30, -115) != -115) - abort (); - if (__sync_bool_compare_and_swap(AL+1, -30, -115) != 1) - abort (); - if (__sync_bool_compare_and_swap(AL+1, -30, -115) != 0) - abort (); - - if (__sync_val_compare_and_swap(AL+2, AL[2], 25) != -50) - abort (); - if (__sync_val_compare_and_swap(AL+2, AL[2], 25) != 25) - abort (); - if (__sync_bool_compare_and_swap(AL+3, AL[3], 25) != 1) - abort (); - if (__sync_bool_compare_and_swap(AL+3, AL[3], 25) != 1) - abort (); -} - -int main() -{ - memcpy(AI, init_si, sizeof(init_si)); - memcpy(AL, init_di, sizeof(init_di)); - - do_si (); - do_di (); - - if (memcmp (AI, test_si, sizeof(test_si))) - abort (); - if (memcmp (AL, test_di, sizeof(test_di))) - abort (); - - return 0; -} |