aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorAlexandre Oliva <oliva@adacore.com>2024-11-07 02:47:15 -0300
committerAlexandre Oliva <oliva@gnu.org>2024-11-07 02:47:15 -0300
commit8e6a25b01becf449d54154b7e83de5f4955cba37 (patch)
treedc42737152449e01a35b551559b0e1bbb3c7de99 /gcc
parent2ec80c60d4f10dcdbc9fad5d35297bfa432d14aa (diff)
downloadgcc-8e6a25b01becf449d54154b7e83de5f4955cba37.zip
gcc-8e6a25b01becf449d54154b7e83de5f4955cba37.tar.gz
gcc-8e6a25b01becf449d54154b7e83de5f4955cba37.tar.bz2
allow vuses in ifcombine blocks
Disallowing vuses in blocks for ifcombine is too strict, and it prevents usefully moving fold_truth_andor into ifcombine. That tree-level folder has long ifcombined loads, absent other relevant side effects. for gcc/ChangeLog * tree-ssa-ifcombine.c (bb_no_side_effects_p): Allow vuses, but not vdefs.
Diffstat (limited to 'gcc')
-rw-r--r--gcc/tree-ssa-ifcombine.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/tree-ssa-ifcombine.cc b/gcc/tree-ssa-ifcombine.cc
index 3970292..57b7e4b 100644
--- a/gcc/tree-ssa-ifcombine.cc
+++ b/gcc/tree-ssa-ifcombine.cc
@@ -130,7 +130,7 @@ bb_no_side_effects_p (basic_block bb)
enum tree_code rhs_code;
if (gimple_has_side_effects (stmt)
|| gimple_could_trap_p (stmt)
- || gimple_vuse (stmt)
+ || gimple_vdef (stmt)
/* We need to rewrite stmts with undefined overflow to use
unsigned arithmetic but cannot do so for signed division. */
|| ((ass = dyn_cast <gassign *> (stmt))