diff options
author | Ian Lance Taylor <iant@google.com> | 2007-05-25 19:04:26 +0000 |
---|---|---|
committer | Kenneth Zadeck <zadeck@naturalbridge.com> | 2007-05-25 19:04:26 +0000 |
commit | 2bff76832bc84f6fabe568333cea158c977a8564 (patch) | |
tree | 99e21743b0e36510b655f9e533b55b4704f79981 | |
parent | 639c6be65fd2f33d9f4ea6f3bec18a89e1cfd025 (diff) |
2007-05-25 Ian Lance Taylor <iant@google.com>
* reload1.c (mark_home_live_1): New static function, broken out of
mark_home_live.
(mark_home_live): Call mark_home_live_1.
(scan_paradoxical_subregs): Call mark_home_live_1.
git-svn-id: https://gcc.gnu.org/svn/gcc/branches/dataflow-branch@125065 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r-- | gcc/ChangeLog.dataflow | 7 | ||||
-rw-r--r-- | gcc/reload1.c | 27 |
2 files changed, 27 insertions, 7 deletions
diff --git a/gcc/ChangeLog.dataflow b/gcc/ChangeLog.dataflow index fe8a0ae41a4..ea617a4ccac 100644 --- a/gcc/ChangeLog.dataflow +++ b/gcc/ChangeLog.dataflow @@ -1,3 +1,10 @@ +2007-05-25 Ian Lance Taylor <iant@google.com> + + * reload1.c (mark_home_live_1): New static function, broken out of + mark_home_live. + (mark_home_live): Call mark_home_live_1. + (scan_paradoxical_subregs): Call mark_home_live_1. + 2007-05-24 Andrew Pinski <andrew_pinski@playstation.sony.com> * config/spu/spu.md (smulsi3_highpart): Unshare the rtl chain. diff --git a/gcc/reload1.c b/gcc/reload1.c index 25bedbf1b80..bc79dd4d052 100644 --- a/gcc/reload1.c +++ b/gcc/reload1.c @@ -2141,21 +2141,31 @@ alter_reg (int i, int from_reg) } } -/* Mark the slots in regs_ever_live for the hard regs - used by pseudo-reg number REGNO. */ +/* Mark the slots in regs_ever_live for the hard regs used by + pseudo-reg number REGNO, accessed in MODE. */ -void -mark_home_live (int regno) +static void +mark_home_live_1 (int regno, enum machine_mode mode) { int i, lim; i = reg_renumber[regno]; if (i < 0) return; - lim = i + hard_regno_nregs[i][PSEUDO_REGNO_MODE (regno)]; + lim = i + hard_regno_nregs[i][mode]; while (i < lim) df_set_regs_ever_live(i++, true); } + +/* Mark the slots in regs_ever_live for the hard regs + used by pseudo-reg number REGNO. */ + +void +mark_home_live (int regno) +{ + if (reg_renumber[regno] >= 0) + mark_home_live_1 (regno, PSEUDO_REGNO_MODE (regno)); +} /* This function handles the tracking of elimination offsets around branches. @@ -3905,8 +3915,11 @@ scan_paradoxical_subregs (rtx x) if (REG_P (SUBREG_REG (x)) && (GET_MODE_SIZE (GET_MODE (x)) > reg_max_ref_width[REGNO (SUBREG_REG (x))])) - reg_max_ref_width[REGNO (SUBREG_REG (x))] - = GET_MODE_SIZE (GET_MODE (x)); + { + reg_max_ref_width[REGNO (SUBREG_REG (x))] + = GET_MODE_SIZE (GET_MODE (x)); + mark_home_live_1 (REGNO (SUBREG_REG (x)), GET_MODE (x)); + } return; default: |