tree-cfg.c (gimple_duplicate_sese_region): Fix ordering of set_loop_copy and initialize_original_copy_tables.

2014-02-06  Richard Biener  <rguenther@suse.de>

	* tree-cfg.c (gimple_duplicate_sese_region): Fix ordering of
	set_loop_copy and initialize_original_copy_tables.

From-SVN: r207532
This commit is contained in:
Richard Biener 2014-02-06 09:41:44 +00:00 committed by Richard Biener
parent 179d29415e
commit d50f7b84e3
2 changed files with 12 additions and 5 deletions

View File

@ -1,3 +1,8 @@
2014-02-06 Richard Biener <rguenther@suse.de>
* tree-cfg.c (gimple_duplicate_sese_region): Fix ordering of
set_loop_copy and initialize_original_copy_tables.
2014-02-06 Alex Velenko <Alex.Velenko@arm.com>
* config/aarch64/aarch64-simd.md

View File

@ -5879,14 +5879,11 @@ gimple_duplicate_sese_region (edge entry, edge exit,
return false;
}
set_loop_copy (loop, loop);
/* In case the function is used for loop header copying (which is the primary
use), ensure that EXIT and its copy will be new latch and entry edges. */
if (loop->header == entry->dest)
{
copying_header = true;
set_loop_copy (loop, loop_outer (loop));
if (!dominated_by_p (CDI_DOMINATORS, loop->latch, exit->src))
return false;
@ -5897,14 +5894,19 @@ gimple_duplicate_sese_region (edge entry, edge exit,
return false;
}
initialize_original_copy_tables ();
if (copying_header)
set_loop_copy (loop, loop_outer (loop));
else
set_loop_copy (loop, loop);
if (!region_copy)
{
region_copy = XNEWVEC (basic_block, n_region);
free_region_copy = true;
}
initialize_original_copy_tables ();
/* Record blocks outside the region that are dominated by something
inside. */
if (update_dominance)