Commit ea1637e9 by J"orn Rennecke Committed by Joern Rennecke

global.c (prune_preferences): Move some invariants out of the inner loop.

	* global.c (prune_preferences): Move some invariants out of the
	inner loop.

From-SVN: r28691
parent 7bc69973
Thu Aug 12 23:51:04 1999 J"orn Rennecke <amylaar@cygnus.co.uk>
* global.c (prune_preferences): Move some invariants out of the
inner loop.
Thu Aug 12 15:30:29 1999 Jesse Perry (jap@unx.dec.com) Thu Aug 12 15:30:29 1999 Jesse Perry (jap@unx.dec.com)
* configure.in (alpha*-dec-osf*): Add osf5. * configure.in (alpha*-dec-osf*): Add osf5.
......
...@@ -864,7 +864,7 @@ prune_preferences () ...@@ -864,7 +864,7 @@ prune_preferences ()
for (i = max_allocno - 1; i >= 0; i--) for (i = max_allocno - 1; i >= 0; i--)
{ {
HARD_REG_SET temp; HARD_REG_SET temp, temp2;
allocno = allocno_order[i]; allocno = allocno_order[i];
COPY_HARD_REG_SET (temp, hard_reg_conflicts[allocno]); COPY_HARD_REG_SET (temp, hard_reg_conflicts[allocno]);
...@@ -882,25 +882,27 @@ prune_preferences () ...@@ -882,25 +882,27 @@ prune_preferences ()
AND_COMPL_HARD_REG_SET (hard_reg_copy_preferences[allocno], temp); AND_COMPL_HARD_REG_SET (hard_reg_copy_preferences[allocno], temp);
AND_COMPL_HARD_REG_SET (hard_reg_full_preferences[allocno], temp); AND_COMPL_HARD_REG_SET (hard_reg_full_preferences[allocno], temp);
CLEAR_HARD_REG_SET (regs_someone_prefers[allocno]);
/* Merge in the preferences of lower-priority registers (they have /* Merge in the preferences of lower-priority registers (they have
already been pruned). If we also prefer some of those registers, already been pruned). If we also prefer some of those registers,
don't exclude them unless we are of a smaller size (in which case don't exclude them unless we are of a smaller size (in which case
we want to give the lower-priority allocno the first chance for we want to give the lower-priority allocno the first chance for
these registers). */ these registers). */
CLEAR_HARD_REG_SET (temp);
CLEAR_HARD_REG_SET (temp2);
for (j = i + 1; j < max_allocno; j++) for (j = i + 1; j < max_allocno; j++)
if (CONFLICTP (allocno, allocno_order[j]) if (CONFLICTP (allocno, allocno_order[j])
|| CONFLICTP (allocno_order[j], allocno)) || CONFLICTP (allocno_order[j], allocno))
{ {
COPY_HARD_REG_SET (temp,
hard_reg_full_preferences[allocno_order[j]]);
if (allocno_size[allocno_order[j]] <= allocno_size[allocno]) if (allocno_size[allocno_order[j]] <= allocno_size[allocno])
AND_COMPL_HARD_REG_SET (temp, IOR_HARD_REG_SET (temp,
hard_reg_full_preferences[allocno]); hard_reg_full_preferences[allocno_order[j]]);
else
IOR_HARD_REG_SET (regs_someone_prefers[allocno], temp); IOR_HARD_REG_SET (temp2,
hard_reg_full_preferences[allocno_order[j]]);
} }
AND_COMPL_HARD_REG_SET (temp, hard_reg_full_preferences[allocno]);
IOR_HARD_REG_SET (temp, temp2);
COPY_HARD_REG_SET (regs_someone_prefers[allocno], temp);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment