diff options
author | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-01-27 15:49:34 +0000 |
---|---|---|
committer | rguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-01-27 15:49:34 +0000 |
commit | 541c6dbbc2c32da227173e364f7a773963b492a9 (patch) | |
tree | 0c04ec091ef10bd60dd9a1ebcd58d05b54dbc651 /gcc/ipa-pure-const.c | |
parent | 25b3bbad6624357c1ac6a31e0be6fca37182fb78 (diff) | |
download | gcc-541c6dbbc2c32da227173e364f7a773963b492a9.tar.gz |
2012-01-27 Richard Guenther <rguenther@suse.de>
* ipa-pure-const.c (check_stmt): Clobbers do not make a
function non-const/pure.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@183632 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ipa-pure-const.c')
-rw-r--r-- | gcc/ipa-pure-const.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ipa-pure-const.c b/gcc/ipa-pure-const.c index 82e24cf5a01..e8b21f9fc6b 100644 --- a/gcc/ipa-pure-const.c +++ b/gcc/ipa-pure-const.c @@ -652,7 +652,8 @@ check_stmt (gimple_stmt_iterator *gsip, funct_state local, bool ipa) print_gimple_stmt (dump_file, stmt, 0, 0); } - if (gimple_has_volatile_ops (stmt)) + if (gimple_has_volatile_ops (stmt) + && !gimple_clobber_p (stmt)) { local->pure_const_state = IPA_NEITHER; if (dump_file) |