summaryrefslogtreecommitdiff
path: root/gcc/sched-rgn.c
diff options
context:
space:
mode:
authorabel <abel@138bc75d-0d04-0410-961f-82ee72b054a4>2014-02-24 05:57:02 +0000
committerabel <abel@138bc75d-0d04-0410-961f-82ee72b054a4>2014-02-24 05:57:02 +0000
commit91096e87f33c945b931481d37bd2094a05fd9b78 (patch)
tree4e4b38d31417de3db52142b6f3e4e5a802536d6d /gcc/sched-rgn.c
parent2a9110cb500e6754c28864a6dfaed185b367516c (diff)
downloadgcc-91096e87f33c945b931481d37bd2094a05fd9b78.tar.gz
gcc/
2014-02-24 Andrey Belevantsev <abel@ispras.ru> PR rtl-optimization/60268 * sched-rgn.c (haifa_find_rgns): Move the nr_regions_initial variable initialization to ... (sched_rgn_init): ... here. (schedule_region): Check for SCHED_PRESSURE_NONE earlier. testsuite/ 2014-02-24 Andrey Belevantsev <abel@ispras.ru> PR rtl-optimization/60268 * gcc.c-torture/compile/pr60268.c: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208066 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/sched-rgn.c')
-rw-r--r--gcc/sched-rgn.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/sched-rgn.c b/gcc/sched-rgn.c
index 0573b6a6e8f..dc6fa16a19e 100644
--- a/gcc/sched-rgn.c
+++ b/gcc/sched-rgn.c
@@ -1067,7 +1067,6 @@ haifa_find_rgns (void)
BLOCK_TO_BB (bb->index) = 0;
}
- nr_regions_initial = nr_regions;
free (max_hdr);
free (degree);
free (stack);
@@ -2997,10 +2996,10 @@ schedule_region (int rgn)
/* Do not support register pressure sensitive scheduling for the new regions
as we don't update the liveness info for them. */
- if (rgn >= nr_regions_initial)
+ if (sched_pressure != SCHED_PRESSURE_NONE
+ && rgn >= nr_regions_initial)
{
- if (sched_pressure != SCHED_PRESSURE_NONE)
- free_global_sched_pressure_data ();
+ free_global_sched_pressure_data ();
sched_pressure = SCHED_PRESSURE_NONE;
}
@@ -3166,6 +3165,7 @@ sched_rgn_init (bool single_blocks_p)
RGN_BLOCKS (nr_regions) = (RGN_BLOCKS (nr_regions - 1) +
RGN_NR_BLOCKS (nr_regions - 1));
+ nr_regions_initial = nr_regions;
}
/* Free data structures for region scheduling. */