* regclass.c: Revert my Jan 4 change to loop cost computation.

From-SVN: r31210
This commit is contained in:
Jeffrey A Law 2000-01-04 18:46:46 +00:00 committed by Jeff Law
parent 6461530210
commit 399b9016a7
2 changed files with 8 additions and 8 deletions

View File

@ -1,3 +1,7 @@
Tue Jan 4 11:44:13 2000 Jeffrey A Law (law@cygnus.com)
* regclass.c: Revert my Jan 4 change to loop cost computation.
Tue Jan 4 19:22:39 MET 2000 Jan Hubicka <hubicka@freesoft.cz> Tue Jan 4 19:22:39 MET 2000 Jan Hubicka <hubicka@freesoft.cz>
* regclass.c (regclass): Do not obey REG_N_REFS in non-optimizing * regclass.c (regclass): Do not obey REG_N_REFS in non-optimizing

View File

@ -1100,17 +1100,13 @@ regclass (f, nregs, dump)
basic_block bb = BASIC_BLOCK (index); basic_block bb = BASIC_BLOCK (index);
/* Show that an insn inside a loop is likely to be executed three /* Show that an insn inside a loop is likely to be executed three
times more than insns outside a loop. This is much more times more than insns outside a loop. This is much more aggressive
aggressive than the assumptions made elsewhere and is being than the assumptions made elsewhere and is being tried as an
tried as an experiment. experiment. */
Note that a block's loop depth starts at zero, not one! We
must not subract one from the loop depth as that could give
a negative shift count below. */
if (optimize_size) if (optimize_size)
loop_cost = 1; loop_cost = 1;
else else
loop_cost = 1 << (2 * MIN (bb->loop_depth, 5)); loop_cost = 1 << (2 * MIN (bb->loop_depth - 1, 5));
for (insn = bb->head; ; insn = NEXT_INSN (insn)) for (insn = bb->head; ; insn = NEXT_INSN (insn))
{ {
insn = scan_one_insn (insn, pass); insn = scan_one_insn (insn, pass);