aboutsummaryrefslogtreecommitdiff
path: root/gcc/fold-const.c
diff options
context:
space:
mode:
authorGeoffrey Keating <geoffk@redhat.com>2001-04-20 01:34:01 +0000
committerGeoffrey Keating <geoffk@gcc.gnu.org>2001-04-20 01:34:01 +0000
commitdea8be3e9fea111391e7710c41cff0ce6c8b6b05 (patch)
tree19b2a9a746f4b586cf438b98b93f447c15c2265b /gcc/fold-const.c
parentfe6adb3e8da9d209fab4b4420f3ef260ece06e46 (diff)
downloadgcc-dea8be3e9fea111391e7710c41cff0ce6c8b6b05.zip
gcc-dea8be3e9fea111391e7710c41cff0ce6c8b6b05.tar.gz
gcc-dea8be3e9fea111391e7710c41cff0ce6c8b6b05.tar.bz2
fold-const.c (fold): Use first_rtl_op rather than TREE_CODE_LENGTH when...
* fold-const.c (fold): Use first_rtl_op rather than TREE_CODE_LENGTH when looping over parameters of a tree. Correct strange grouping in test for evaluated SAVE_EXPR. From-SVN: r41437
Diffstat (limited to 'gcc/fold-const.c')
-rw-r--r--gcc/fold-const.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/fold-const.c b/gcc/fold-const.c
index a595b6e..1ee585d 100644
--- a/gcc/fold-const.c
+++ b/gcc/fold-const.c
@@ -4864,7 +4864,7 @@ fold (expr)
/* Don't try to process an RTL_EXPR since its operands aren't trees.
Likewise for a SAVE_EXPR that's already been evaluated. */
- if (code == RTL_EXPR || (code == SAVE_EXPR && SAVE_EXPR_RTL (t)) != 0)
+ if (code == RTL_EXPR || (code == SAVE_EXPR && SAVE_EXPR_RTL (t) != 0))
return t;
/* Return right away if a constant. */
@@ -4903,7 +4903,7 @@ fold (expr)
}
else if (IS_EXPR_CODE_CLASS (kind) || kind == 'r')
{
- register int len = TREE_CODE_LENGTH (code);
+ register int len = first_rtl_op (code);
register int i;
for (i = 0; i < len; i++)
{