diff options
author | Diego Novillo <dnovillo@gcc.gnu.org> | 2005-01-08 13:31:39 -0500 |
---|---|---|
committer | Diego Novillo <dnovillo@gcc.gnu.org> | 2005-01-08 13:31:39 -0500 |
commit | e79b60a72c50b9d1ba1e196048cb6c4329556cba (patch) | |
tree | 0414cc3da4abf709fe841647da112fa2d898af87 /gcc/tree-ssa-dse.c | |
parent | 1dba11822e73daaaf1afc31ab17d616d85c217e3 (diff) | |
download | gcc-e79b60a72c50b9d1ba1e196048cb6c4329556cba.zip gcc-e79b60a72c50b9d1ba1e196048cb6c4329556cba.tar.gz gcc-e79b60a72c50b9d1ba1e196048cb6c4329556cba.tar.bz2 |
[multiple changes]
2005-01-08 Jeff Law <law@redhat.com>
Diego Novillo <dnovillo@redhat.com>
* tree-nrv.c (tree_nrv): Ignore volatile return values.
* tree-ssa-dse.c (dse_optimize_stmt): Do not optimize
statements with volatile operands.
* tree-ssa-operands.c (add_stmt_operand): Do add volatile
operands after marking a statement with has_volatile_ops.
testsuite/ChangeLog:
2005-01-08 Diego Novillo <dnovillo@redhat.com>
* gcc.dg/pr18241-1.c: New test.
* gcc.dg/pr18241-2.c: New test.
* gcc.dg/pr18241-3.c: New test.
* gcc.dg/pr18241-4.c: New test.
* gcc.dg/pr18241-5.c: New test.
From-SVN: r93088
Diffstat (limited to 'gcc/tree-ssa-dse.c')
-rw-r--r-- | gcc/tree-ssa-dse.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/tree-ssa-dse.c b/gcc/tree-ssa-dse.c index 93ceaeb..86622e9 100644 --- a/gcc/tree-ssa-dse.c +++ b/gcc/tree-ssa-dse.c @@ -259,6 +259,10 @@ dse_optimize_stmt (struct dom_walk_data *walk_data, not also a function call, then record it into our table. */ if (get_call_expr_in (stmt)) return; + + if (ann->has_volatile_ops) + return; + if (TREE_CODE (stmt) == MODIFY_EXPR) { dataflow_t df = get_immediate_uses (stmt); |