aboutsummaryrefslogtreecommitdiff
path: root/gcc/fold-const.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@gcc.gnu.org>2001-02-14 08:57:49 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2001-02-14 08:57:49 +0100
commitfe375cf108993c9afcef778e4b2def2ddf43160e (patch)
tree1998ac8deccf251adebd1cb63da29b3285bdd37f /gcc/fold-const.c
parentceeaadbb7808485164e3079e4bf60fa07a3ad66d (diff)
downloadgcc-fe375cf108993c9afcef778e4b2def2ddf43160e.zip
gcc-fe375cf108993c9afcef778e4b2def2ddf43160e.tar.gz
gcc-fe375cf108993c9afcef778e4b2def2ddf43160e.tar.bz2
stor-layout.c (is_pending_size, [...]): New functions.
* stor-layout.c (is_pending_size, put_pending_size): New functions. (variable_size): Call put_pending_size. * tree.h (is_pending_size, put_pending_size): Add prototypes. * fold-const.c (extract_muldiv): If SAVE_EXPR is on the pending sizes list, put newly created SAVE_EXPR there as well. * gcc.c-torture/execute/20010209-1.c: New test. * config/ia64/ia64.c (last_group): Only 2 entries are needed. (errata_find_address_regs): load_group has only 2 entries. (errata_emit_nops): Likewise. shladd is not problematic. Clear last_group if nop was emitted. (fixup_errata): load_group has only 2 entries. Optimize. From-SVN: r39663
Diffstat (limited to 'gcc/fold-const.c')
-rw-r--r--gcc/fold-const.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/fold-const.c b/gcc/fold-const.c
index 3cb1869..3975ae4 100644
--- a/gcc/fold-const.c
+++ b/gcc/fold-const.c
@@ -4449,7 +4449,14 @@ extract_muldiv (t, c, code, wide_type)
if (SAVE_EXPR_RTL (t) == 0 && ! TREE_SIDE_EFFECTS (TREE_OPERAND (t, 0))
&& 0 != (t1 = extract_muldiv (TREE_OPERAND (t, 0), c, code,
wide_type)))
- return save_expr (t1);
+ {
+ t1 = save_expr (t1);
+ if (SAVE_EXPR_PERSISTENT_P (t) && TREE_CODE (t1) == SAVE_EXPR)
+ SAVE_EXPR_PERSISTENT_P (t1) = 1;
+ if (is_pending_size (t))
+ put_pending_size (t1);
+ return t1;
+ }
break;
case LSHIFT_EXPR: case RSHIFT_EXPR: