diff options
author | sayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-09-25 02:12:13 +0000 |
---|---|---|
committer | sayle <sayle@138bc75d-0d04-0410-961f-82ee72b054a4> | 2003-09-25 02:12:13 +0000 |
commit | c777ce3ace58f73ecdaf3db81962181e7006e888 (patch) | |
tree | 52363c3d5dcb35f61f5f341073d7fbfb2fe58e6b /gcc | |
parent | c17b85eafa482aa4b14b5c81bac7a471e41393c7 (diff) | |
download | ppe42-gcc-c777ce3ace58f73ecdaf3db81962181e7006e888.tar.gz ppe42-gcc-c777ce3ace58f73ecdaf3db81962181e7006e888.zip |
PR bootstrap/12358
* fold-const.c (tree_swap_operands_p): Only reorder operands when
one of the operands is constant.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@71749 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/fold-const.c | 10 |
2 files changed, 6 insertions, 10 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index b869d0b9d93..72e1dd5aad8 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2003-09-24 Roger Sayle <roger@eyesopen.com> + + PR bootstrap/12358 + * fold-const.c (tree_swap_operands_p): Only reorder operands when + one of the operands is constant. + 2003-09-24 Ziemowit Laski <zlaski@apple.com> MERGE OF objc-improvements-branch into MAINLINE: diff --git a/gcc/fold-const.c b/gcc/fold-const.c index 24f6b02ec70..96d46263df2 100644 --- a/gcc/fold-const.c +++ b/gcc/fold-const.c @@ -5007,16 +5007,6 @@ tree_swap_operands_p (tree arg0, tree arg1) if (TREE_CONSTANT (arg0)) return 1; - if (DECL_P (arg1)) - return 0; - if (DECL_P (arg0)) - return 1; - - if (TREE_CODE (arg1) == SAVE_EXPR) - return 0; - if (TREE_CODE (arg0) == SAVE_EXPR) - return 1; - return 0; } |