aboutsummaryrefslogtreecommitdiff
path: root/gcc/emit-rtl.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/emit-rtl.c')
-rw-r--r--gcc/emit-rtl.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c
index 99f052d..a724608 100644
--- a/gcc/emit-rtl.c
+++ b/gcc/emit-rtl.c
@@ -2626,8 +2626,10 @@ unshare_all_rtl_1 (rtx_insn *insn)
This special care is necessary when the stack slot MEM does not
actually appear in the insn chain. If it does appear, its address
is unshared from all else at that point. */
- stack_slot_list = safe_as_a <rtx_expr_list *> (
- copy_rtx_if_shared (stack_slot_list));
+ unsigned int i;
+ rtx temp;
+ FOR_EACH_VEC_SAFE_ELT (stack_slot_list, i, temp)
+ (*stack_slot_list)[i] = copy_rtx_if_shared (temp);
}
/* Go through all the RTL insn bodies and copy any invalid shared
@@ -2656,7 +2658,10 @@ unshare_all_rtl_again (rtx_insn *insn)
for (decl = DECL_ARGUMENTS (cfun->decl); decl; decl = DECL_CHAIN (decl))
set_used_flags (DECL_RTL (decl));
- reset_used_flags (stack_slot_list);
+ rtx temp;
+ unsigned int i;
+ FOR_EACH_VEC_SAFE_ELT (stack_slot_list, i, temp)
+ reset_used_flags (temp);
unshare_all_rtl_1 (insn);
}