aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Wilson <wilson@gcc.gnu.org>1995-05-01 16:26:28 -0700
committerJim Wilson <wilson@gcc.gnu.org>1995-05-01 16:26:28 -0700
commit4c7a0be934b1cf59a0bfff3a41ced8f901cedc18 (patch)
treef292c2a72d8269c12ef92188c67f50c5652f6b87
parenta58942422c0b4b60efa76fd7261961c1d4ea612a (diff)
downloadgcc-4c7a0be934b1cf59a0bfff3a41ced8f901cedc18.zip
gcc-4c7a0be934b1cf59a0bfff3a41ced8f901cedc18.tar.gz
gcc-4c7a0be934b1cf59a0bfff3a41ced8f901cedc18.tar.bz2
(expand_expr, case SAVE_EXPR): Handle the case where
mode is VOIDmode. From-SVN: r9556
-rw-r--r--gcc/expr.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/expr.c b/gcc/expr.c
index e940ccb..9ebbda9 100644
--- a/gcc/expr.c
+++ b/gcc/expr.c
@@ -4310,6 +4310,8 @@ expand_expr (exp, target, tmode, modifier)
= assign_stack_temp (mode, int_size_in_bytes (type), 0);
MEM_IN_STRUCT_P (temp) = AGGREGATE_TYPE_P (type);
}
+ else if (mode == VOIDmode)
+ temp = const0_rtx;
else
temp = gen_reg_rtx (promote_mode (type, mode, &unsignedp, 0));
@@ -4331,7 +4333,10 @@ expand_expr (exp, target, tmode, modifier)
SUBREG_PROMOTED_UNSIGNED_P (temp) = unsignedp;
}
- store_expr (TREE_OPERAND (exp, 0), temp, 0);
+ if (temp == const0_rtx)
+ expand_expr (TREE_OPERAND (exp, 0), const0_rtx, VOIDmode, 0);
+ else
+ store_expr (TREE_OPERAND (exp, 0), temp, 0);
}
/* If the mode of SAVE_EXPR_RTL does not match that of the expression, it