diff options
author | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-10-24 18:58:15 +0000 |
---|---|---|
committer | law <law@138bc75d-0d04-0410-961f-82ee72b054a4> | 2001-10-24 18:58:15 +0000 |
commit | 36958752554e6522753ccbebd80e12c0bb03d08d (patch) | |
tree | 4e5e4d6b88785120d6f5705ef1ec0f1df947d36e /gcc/ssa-ccp.c | |
parent | 66d9e37d46f85c8050dfd67430ded16a6c2ce74c (diff) | |
download | gcc-36958752554e6522753ccbebd80e12c0bb03d08d.tar.gz |
* ssa-ccp.c (ssa_ccp_substitute_constants): Don't do anything if
the node was already a set to a constant.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@46468 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ssa-ccp.c')
-rw-r--r-- | gcc/ssa-ccp.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/gcc/ssa-ccp.c b/gcc/ssa-ccp.c index 047b29d82b2..c2f1b78cae1 100644 --- a/gcc/ssa-ccp.c +++ b/gcc/ssa-ccp.c @@ -866,8 +866,13 @@ ssa_ccp_substitute_constants () /* Do not try to simplify PHI nodes down to a constant load. That will be done later as we translate out of SSA. Also, doing that here could violate the rule that all PHI nodes - are consecutive at the start of the basic block. */ - if (! PHI_NODE_P (def)) + are consecutive at the start of the basic block. + + Don't do anything to nodes that were already sets to + constants. */ + if (! PHI_NODE_P (def) + && ! ((GET_CODE (def) == INSN + && GET_CODE (SET_SRC (set)) == CONST_INT))) { if (rtl_dump_file) fprintf (rtl_dump_file, |