diff options
author | Jakub Jelinek <jakub@gcc.gnu.org> | 2019-01-28 23:34:32 +0100 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2019-01-28 23:34:32 +0100 |
commit | 52bfbb69e7e888d8692597e649e9cedc7436083c (patch) | |
tree | 597e518b85e9597fc31a0ee247b3ee49b7c876d0 /libgomp | |
parent | be3a87e7b5ff3d284a7663519826f2613dc46f69 (diff) | |
download | gcc-52bfbb69e7e888d8692597e649e9cedc7436083c.zip gcc-52bfbb69e7e888d8692597e649e9cedc7436083c.tar.gz gcc-52bfbb69e7e888d8692597e649e9cedc7436083c.tar.bz2 |
re PR middle-end/89002 (ICE in scan_omp_1_op, at omp-low.c:3166)
PR middle-end/89002
* gimplify.c (gimplify_omp_for): When adding OMP_CLAUSE_*_GIMPLE_SEQ
for lastprivate/linear IV, push gimplify context around gimplify_assign
and, if it needed any temporaries, pop it into a gimple bind around the
sequence.
* testsuite/libgomp.c/pr89002.c: New test.
From-SVN: r268346
Diffstat (limited to 'libgomp')
-rw-r--r-- | libgomp/testsuite/libgomp.c/pr89002.c | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/libgomp/testsuite/libgomp.c/pr89002.c b/libgomp/testsuite/libgomp.c/pr89002.c index b66fada..6d1b164 100644 --- a/libgomp/testsuite/libgomp.c/pr89002.c +++ b/libgomp/testsuite/libgomp.c/pr89002.c @@ -41,46 +41,3 @@ main () abort (); return 0; } -/* PR middle-end/89002 */ - -extern void abort (void); - -int -foo (int x) -{ - int a; - int *p = &a; - -#pragma omp taskloop lastprivate (a) - for (a = 0; a < x; ++a) - ; - return *p; -} - -int -bar (int x) -{ - int a; - int *p = &a; - -#pragma omp parallel -#pragma omp single -#pragma omp taskloop lastprivate (a) - for (a = 0; a < x; ++a) - ; - return *p; -} - -int -main () -{ -#pragma omp parallel -#pragma omp single - { - if (foo (4) != 4) - abort (); - } - if (bar (6) != 6) - abort (); - return 0; -} |