mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-28 01:14:27 +08:00
Correctly count substitutions if eliminations are going on.
From-SVN: r42198
This commit is contained in:
parent
2e2ed7d22d
commit
5d7ef82a5d
@ -3,6 +3,9 @@
|
||||
* stmt.c (expand_asm_operands): For inout operands, make sure
|
||||
the substitution of '=' for '+' makes it into the rtl.
|
||||
|
||||
* reload1.c (delete_output_reload): Call eliminate_regs on substed.
|
||||
(reload_as_needed): Call update_eliminable_offsets a bit later.
|
||||
|
||||
2001-05-17 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
|
||||
|
||||
* gcc.texi (gccbug): Refer to the web pages for detailed information
|
||||
|
@ -3874,9 +3874,6 @@ reload_as_needed (live_known)
|
||||
spill_reg_order);
|
||||
}
|
||||
|
||||
if (num_eliminable && chain->need_elim)
|
||||
update_eliminable_offsets ();
|
||||
|
||||
if (n_reloads > 0)
|
||||
{
|
||||
rtx next = NEXT_INSN (insn);
|
||||
@ -3923,6 +3920,10 @@ reload_as_needed (live_known)
|
||||
NOTE_LINE_NUMBER (p) = NOTE_INSN_DELETED;
|
||||
}
|
||||
}
|
||||
|
||||
if (num_eliminable && chain->need_elim)
|
||||
update_eliminable_offsets ();
|
||||
|
||||
/* Any previously reloaded spilled pseudo reg, stored in this insn,
|
||||
is no longer validly lying around to save a future reload.
|
||||
Note that this does not detect pseudos that were reloaded
|
||||
@ -7599,7 +7600,9 @@ delete_output_reload (insn, j, last_reload_reg)
|
||||
}
|
||||
n_occurrences = count_occurrences (PATTERN (insn), reg, 0);
|
||||
if (substed)
|
||||
n_occurrences += count_occurrences (PATTERN (insn), substed, 0);
|
||||
n_occurrences += count_occurrences (PATTERN (insn),
|
||||
eliminate_regs (substed, 0,
|
||||
NULL_RTX), 0);
|
||||
if (n_occurrences > n_inherited)
|
||||
return;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user