Commit 8050766e by Tom de Vries Committed by Tom de Vries

Fix gcc_assert in expand_omp_for_static_chunk

2015-09-03  Tom de Vries  <tom@codesourcery.com>

	PR tree-optimization/65637
	* omp-low.c (expand_omp_for_static_chunk): Fix gcc_assert for the case
	that head is NULL.

	* gcc.dg/autopar/pr46099-2.c: New test.

From-SVN: r227436
parent 8cba6b95
2015-09-03 Tom de Vries <tom@codesourcery.com> 2015-09-03 Tom de Vries <tom@codesourcery.com>
PR tree-optimization/65637
* omp-low.c (expand_omp_for_static_chunk): Fix gcc_assert for the case
that head is NULL.
2015-09-03 Tom de Vries <tom@codesourcery.com>
* omp-low.c (expand_omp_for_static_chunk): Handle simple latch bb. * omp-low.c (expand_omp_for_static_chunk): Handle simple latch bb.
2015-09-03 Tom de Vries <tom@codesourcery.com> 2015-09-03 Tom de Vries <tom@codesourcery.com>
......
...@@ -7326,7 +7326,7 @@ expand_omp_for_static_chunk (struct omp_region *region, ...@@ -7326,7 +7326,7 @@ expand_omp_for_static_chunk (struct omp_region *region,
locus = redirect_edge_var_map_location (vm); locus = redirect_edge_var_map_location (vm);
add_phi_arg (nphi, redirect_edge_var_map_def (vm), re, locus); add_phi_arg (nphi, redirect_edge_var_map_def (vm), re, locus);
} }
gcc_assert (gsi_end_p (psi) && i == head->length ()); gcc_assert (gsi_end_p (psi) && (head == NULL || i == head->length ()));
redirect_edge_var_map_clear (re); redirect_edge_var_map_clear (re);
while (1) while (1)
{ {
......
2015-09-03 Tom de Vries <tom@codesourcery.com>
PR tree-optimization/65637
* gcc.dg/autopar/pr46099-2.c: New test.
2015-09-03 Naveen H.S <Naveen.Hurugalawadi@caviumnetworks.com> 2015-09-03 Naveen H.S <Naveen.Hurugalawadi@caviumnetworks.com>
PR middle-end/67351 PR middle-end/67351
......
/* PR tree-optimization/46099. */
/* { dg-do compile } */
/* { dg-options "-ftree-parallelize-loops=2 -fcompare-debug -O --param parloops-chunk-size=100" } */
#include "pr46099.c"
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