aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorMatthew Hiller <hiller@redhat.com>2000-11-10 05:22:48 +0000
committerJeff Law <law@gcc.gnu.org>2000-11-09 22:22:48 -0700
commit881a89697e1604663cb76e32abab1c2419fbcbc8 (patch)
tree7ccf4fbc00fbaeb0537f2ab265f08e7f21e66c0f /gcc
parent13507bd80dc47454cca3220f14dca27710e15c8f (diff)
downloadgcc-881a89697e1604663cb76e32abab1c2419fbcbc8.zip
gcc-881a89697e1604663cb76e32abab1c2419fbcbc8.tar.gz
gcc-881a89697e1604663cb76e32abab1c2419fbcbc8.tar.bz2
reload1.c (reload_combine): Fixed calculation of first_index_reg, last_index_reg.
* reload1.c (reload_combine): Fixed calculation of first_index_reg, last_index_reg. From-SVN: r37360
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/reload1.c6
2 files changed, 8 insertions, 3 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 8c6ed0e..15ccecb 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2000-11-09 Matthew Hiller <hiller@redhat.com>
+
+ * reload1.c (reload_combine): Fixed calculation of
+ first_index_reg, last_index_reg.
+
2000-11-09 Mark Mitchell <mark@codesourcery.com>
* c-dump.c (dequeue_and_dump): Dump function bodies.
diff --git a/gcc/reload1.c b/gcc/reload1.c
index 151529a..5219e8a 100644
--- a/gcc/reload1.c
+++ b/gcc/reload1.c
@@ -8363,7 +8363,7 @@ static void
reload_combine ()
{
rtx insn, set;
- int first_index_reg = 1, last_index_reg = 0;
+ int first_index_reg = -1, last_index_reg;
int i;
unsigned int r;
int last_label_ruid;
@@ -8381,14 +8381,14 @@ reload_combine ()
for (r = 0; r < FIRST_PSEUDO_REGISTER; r++)
if (TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], r))
{
- if (! first_index_reg)
+ if (first_index_reg == -1)
first_index_reg = r;
last_index_reg = r;
}
/* If no index register is available, we can quit now. */
- if (first_index_reg > last_index_reg)
+ if (first_index_reg == -1)
return;
/* Set up LABEL_LIVE and EVER_LIVE_AT_START. The register lifetime