summaryrefslogtreecommitdiff
path: root/gcc/reload.c
diff options
context:
space:
mode:
authorwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>1997-02-05 00:29:03 +0000
committerwilson <wilson@138bc75d-0d04-0410-961f-82ee72b054a4>1997-02-05 00:29:03 +0000
commit0ea7d6cd4827cc17403abda7d72dde690a0f765d (patch)
tree988a8dd5e9a17c784e388086a48ff94033a55f1d /gcc/reload.c
parentda8cdbc4e6cf6d91e166f309c612174a44f1be21 (diff)
downloadgcc-0ea7d6cd4827cc17403abda7d72dde690a0f765d.tar.gz
(find_reloads_address_1, case POST_INC): Don't use
ADDR_TYPE here. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@13608 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/reload.c')
-rw-r--r--gcc/reload.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/gcc/reload.c b/gcc/reload.c
index f1b79234c27..a15e41211c7 100644
--- a/gcc/reload.c
+++ b/gcc/reload.c
@@ -4855,9 +4855,12 @@ find_reloads_address_1 (mode, x, context, loc, opnum, type, ind_levels)
if (reg_equiv_address[regno] != 0)
{
rtx tem = make_memloc (XEXP (x, 0), regno);
- /* First reload the memory location's address. */
+ /* First reload the memory location's address.
+ We can't use ADDR_TYPE (type) here, because we need to
+ write back the value after reading it, hence we actually
+ need two registers. */
find_reloads_address (GET_MODE (tem), 0, XEXP (tem, 0),
- &XEXP (tem, 0), opnum, ADDR_TYPE (type),
+ &XEXP (tem, 0), opnum, type,
ind_levels);
/* Put this inside a new increment-expression. */
x = gen_rtx (GET_CODE (x), GET_MODE (x), tem);
@@ -4924,9 +4927,12 @@ find_reloads_address_1 (mode, x, context, loc, opnum, type, ind_levels)
Note that this is actually conservative: it would be slightly
more efficient to use the value of SPILL_INDIRECT_LEVELS from
reload1.c here. */
+ /* We can't use ADDR_TYPE (type) here, because we need to
+ write back the value after reading it, hence we actually
+ need two registers. */
find_reloads_address (GET_MODE (x), &XEXP (x, 0),
XEXP (XEXP (x, 0), 0), &XEXP (XEXP (x, 0), 0),
- opnum, ADDR_TYPE (type), ind_levels);
+ opnum, type, ind_levels);
reloadnum = push_reload (x, NULL_RTX, loc, NULL_PTR,
(context