aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Kenner <kenner@gcc.gnu.org>1996-04-16 06:21:39 -0400
committerRichard Kenner <kenner@gcc.gnu.org>1996-04-16 06:21:39 -0400
commitb35cd3c16c6bcbeddfac00f6c2cfc8b83b14a372 (patch)
tree82b49be23ab82c6c92a10003d393c5a297e7da13
parent21b2a157ce0498394301452f8744bd782078825d (diff)
downloadgcc-b35cd3c16c6bcbeddfac00f6c2cfc8b83b14a372.zip
gcc-b35cd3c16c6bcbeddfac00f6c2cfc8b83b14a372.tar.gz
gcc-b35cd3c16c6bcbeddfac00f6c2cfc8b83b14a372.tar.bz2
(expand_assignment): Don't pre-evaluate RHS if a CALL_EXPR with a
variable-size return. From-SVN: r11804
-rw-r--r--gcc/expr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/expr.c b/gcc/expr.c
index e29b404..512a083 100644
--- a/gcc/expr.c
+++ b/gcc/expr.c
@@ -2803,6 +2803,7 @@ expand_assignment (to, from, want_value, suggest_reg)
Handling this in the normal way is safe because no computation is done
before the call. */
if (TREE_CODE (from) == CALL_EXPR && ! aggregate_value_p (from)
+ && TREE_CODE (TYPE_SIZE (TREE_TYPE (from))) == INTEGER_CST
&& ! (TREE_CODE (to) == VAR_DECL && GET_CODE (DECL_RTL (to)) == REG))
{
rtx value;