diff options
author | Eric Botcazou <ebotcazou@libertysurf.fr> | 2002-11-11 06:38:22 +0100 |
---|---|---|
committer | Mark Mitchell <mmitchel@gcc.gnu.org> | 2002-11-11 05:38:22 +0000 |
commit | 45ed7228db8501bfe840fe8b5adce1b01c9eefa2 (patch) | |
tree | 40da459ba25373c9a9c3df50aa7ee84d2b280291 /gcc/recog.c | |
parent | 5aad4daaba1a304a06dacb53793f71138b6bdcd7 (diff) | |
download | gcc-45ed7228db8501bfe840fe8b5adce1b01c9eefa2.zip gcc-45ed7228db8501bfe840fe8b5adce1b01c9eefa2.tar.gz gcc-45ed7228db8501bfe840fe8b5adce1b01c9eefa2.tar.bz2 |
re PR c/8439 (empty struct causes crash)
PR c/8439
* recog.c (validate_replace_rtx_1) [PLUS]: Simplify only
if there is something new to be simplified.
From-SVN: r59005
Diffstat (limited to 'gcc/recog.c')
-rw-r--r-- | gcc/recog.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/recog.c b/gcc/recog.c index b40867b..649f366 100644 --- a/gcc/recog.c +++ b/gcc/recog.c @@ -522,10 +522,10 @@ validate_replace_rtx_1 (loc, from, to, object) { case PLUS: /* If we have a PLUS whose second operand is now a CONST_INT, use - plus_constant to try to simplify it. + simplify_gen_binary to try to simplify it. ??? We may want later to remove this, once simplification is separated from this function. */ - if (GET_CODE (XEXP (x, 1)) == CONST_INT) + if (GET_CODE (XEXP (x, 1)) == CONST_INT && XEXP (x, 1) == to) validate_change (object, loc, simplify_gen_binary (PLUS, GET_MODE (x), XEXP (x, 0), XEXP (x, 1)), 1); |