From bcd8d8b3e7da966d8bc00fe397208f5532bdfddf Mon Sep 17 00:00:00 2001 From: jakub Date: Fri, 13 Nov 2009 18:42:32 +0000 Subject: PR middle-end/42029 * gimplify.c (gimplify_omp_atomic): Set DECL_GIMPLE_REG_P on tmp_load if needed. * libgomp.c/pr42029.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/gcc-4_4-branch@154162 138bc75d-0d04-0410-961f-82ee72b054a4 --- libgomp/ChangeLog | 5 +++++ libgomp/testsuite/libgomp.c/pr42029.c | 19 +++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 libgomp/testsuite/libgomp.c/pr42029.c (limited to 'libgomp') diff --git a/libgomp/ChangeLog b/libgomp/ChangeLog index 82b705fbc9a..62588c6413c 100644 --- a/libgomp/ChangeLog +++ b/libgomp/ChangeLog @@ -1,3 +1,8 @@ +2009-11-13 Jakub Jelinek + + PR middle-end/42029 + * libgomp.c/pr42029.c: New test. + 2009-10-15 Release Manager * GCC 4.4.2 released. diff --git a/libgomp/testsuite/libgomp.c/pr42029.c b/libgomp/testsuite/libgomp.c/pr42029.c new file mode 100644 index 00000000000..ea7ac2c0986 --- /dev/null +++ b/libgomp/testsuite/libgomp.c/pr42029.c @@ -0,0 +1,19 @@ +/* PR middle-end/42029 */ +/* { dg-do run } */ + +extern void abort (void); + +int +main () +{ + int i; + _Complex int c = 0; + +#pragma omp parallel for private(i) reduction(+:c) + for (i = 0; i < 8; ++i) + c += 1; + + if (c != 8) + abort (); + return 0; +} -- cgit v1.2.1