summaryrefslogtreecommitdiffstats
path: root/contrib/gcc/function.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/gcc/function.c')
-rw-r--r--contrib/gcc/function.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/contrib/gcc/function.c b/contrib/gcc/function.c
index 60afafa..a4033a9 100644
--- a/contrib/gcc/function.c
+++ b/contrib/gcc/function.c
@@ -1428,7 +1428,16 @@ free_temps_for_rtl_expr (t)
for (p = temp_slots; p; p = p->next)
if (p->rtl_expr == t)
- p->in_use = 0;
+ {
+ /* If this slot is below the current TEMP_SLOT_LEVEL, then it
+ needs to be preserved. This can happen if a temporary in
+ the RTL_EXPR was addressed; preserve_temp_slots will move
+ the temporary into a higher level. */
+ if (temp_slot_level <= p->level)
+ p->in_use = 0;
+ else
+ p->rtl_expr = NULL_TREE;
+ }
combine_temp_slots ();
}
OpenPOWER on IntegriCloud