diff options
author | Jakub Jelinek <jakub@redhat.com> | 2011-04-13 17:50:02 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2011-04-13 17:50:02 +0200 |
commit | 20790697dd24387ffbf4f97e46774edfcb0a7142 (patch) | |
tree | 0c13f4d4a47b9ebcbcd30c9e09f47ca6a8b0b2b1 /libgomp/testsuite | |
parent | 9c76a19e8f83e9e9a154d1779115b5061687c97b (diff) | |
download | gcc-20790697dd24387ffbf4f97e46774edfcb0a7142.zip gcc-20790697dd24387ffbf4f97e46774edfcb0a7142.tar.gz gcc-20790697dd24387ffbf4f97e46774edfcb0a7142.tar.bz2 |
re PR middle-end/48591 (OpenMP ICE with atomics on __float128 in 32-bit only i686 cc1)
PR middle-end/48591
* omp-low.c (expand_omp_atomic_fetch_op): Return false if decl is
NULL.
(expand_omp_atomic_pipeline): Return false if cmpxchg is NULL.
* gcc.dg/gomp/pr48591.c: New test.
* testsuite/libgomp.c/pr48591.c: New test.
From-SVN: r172379
Diffstat (limited to 'libgomp/testsuite')
-rw-r--r-- | libgomp/testsuite/libgomp.c/pr48591.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/libgomp/testsuite/libgomp.c/pr48591.c b/libgomp/testsuite/libgomp.c/pr48591.c new file mode 100644 index 0000000..18dfd7f --- /dev/null +++ b/libgomp/testsuite/libgomp.c/pr48591.c @@ -0,0 +1,22 @@ +/* PR middle-end/48591 */ +/* { dg-do run { target i?86-*-linux* x86_64-*-linux* ia64-*-linux* } } */ +/* { dg-options "-fopenmp" } */ + +extern void abort (void); + +int +main () +{ + __float128 f = 0.0; + int i; + #pragma omp parallel for reduction(+:f) + for (i = 0; i < 128; i++) + f += 0.5Q; + if (f != 64.0Q) + abort (); + #pragma omp atomic + f += 8.5Q; + if (f != 72.5Q) + abort (); + return 0; +} |