aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Gingold <gingold@adacore.com>2012-05-15 07:57:57 +0000
committerTristan Gingold <gingold@gcc.gnu.org>2012-05-15 07:57:57 +0000
commit094aaeabfdbe5db85c21d072eb1c2175621fb369 (patch)
tree417e78a57215314a4b814c7a300f93c061c4d9bf
parentf65e3801ce5cc7be12b40ce8827718d158643a72 (diff)
downloadgcc-094aaeabfdbe5db85c21d072eb1c2175621fb369.zip
gcc-094aaeabfdbe5db85c21d072eb1c2175621fb369.tar.gz
gcc-094aaeabfdbe5db85c21d072eb1c2175621fb369.tar.bz2
ira-color.c (move_spill_restore): Add a guard.
2012-05-15 Tristan Gingold <gingold@adacore.com> * ira-color.c (move_spill_restore): Add a guard. From-SVN: r187500
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/ira-color.c5
2 files changed, 7 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 608a68a..9b7d499 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,9 @@
2012-05-15 Tristan Gingold <gingold@adacore.com>
+ * ira-color.c (move_spill_restore): Add a guard.
+
+2012-05-15 Tristan Gingold <gingold@adacore.com>
+
* config/ia64/ia64.c (ia64_emit_probe_stack_range): Adjust calls to
plus_constant.
diff --git a/gcc/ira-color.c b/gcc/ira-color.c
index 45f5244..300c3b8 100644
--- a/gcc/ira-color.c
+++ b/gcc/ira-color.c
@@ -2941,8 +2941,9 @@ move_spill_restore (void)
copies and the reload pass can spill the allocno set
by copy although the allocno will not get memory
slot. */
- || ira_reg_equiv_invariant_p[regno]
- || ira_reg_equiv_const[regno] != NULL_RTX
+ || (regno < ira_reg_equiv_len
+ && (ira_reg_equiv_invariant_p[regno]
+ || ira_reg_equiv_const[regno] != NULL_RTX))
|| !bitmap_bit_p (loop_node->border_allocnos, ALLOCNO_NUM (a)))
continue;
mode = ALLOCNO_MODE (a);