Commit 2ee10f81 by Jakub Jelinek Committed by Jakub Jelinek

re PR middle-end/67517 (ICE in gimplify_scan_omp_clauses)

	PR middle-end/67517
	* gimplify.c (gimplify_scan_omp_clauses): Instead of
	asserting that decl is not specified in octx->variables,
	break out of the loop if it is.

	* c-c++-common/gomp/pr67517.c: New test.

From-SVN: r227608
parent 499c20bb
2015-09-10 Jakub Jelinek <jakub@redhat.com>
PR middle-end/67517
* gimplify.c (gimplify_scan_omp_clauses): Instead of
asserting that decl is not specified in octx->variables,
break out of the loop if it is.
PR c++/67514
* gimplify.c (gimplify_omp_for): For loop SIMD construct, if
iterator is not explicitly determined, but is defined inside
......
......@@ -6214,9 +6214,12 @@ gimplify_scan_omp_clauses (tree *list_p, gimple_seq *pre_p,
}
else
break;
gcc_checking_assert (splay_tree_lookup (octx->variables,
(splay_tree_key)
decl) == NULL);
if (splay_tree_lookup (octx->variables,
(splay_tree_key) decl) != NULL)
{
octx = NULL;
break;
}
flags = GOVD_SEEN;
if (!OMP_CLAUSE_LINEAR_NO_COPYIN (c))
flags |= GOVD_FIRSTPRIVATE;
......
2015-09-10 Jakub Jelinek <jakub@redhat.com>
PR middle-end/67517
* c-c++-common/gomp/pr67517.c: New test.
PR c++/67514
* g++.dg/gomp/pr67514.C: New test.
......
/* PR middle-end/67517 */
/* { dg-do compile } */
/* { dg-options "-fopenmp" } */
int
foo (int x, int y, int z)
{
int i;
#pragma omp parallel for simd linear (y : x & 15) linear (x : 16) linear (z : x & 15)
for (i = 0; i < 256; ++i)
x += 16, y += x & 15, z += x & 15;
return x + y + z;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment