PR tree-optimization/58775 PR tree-optimization/58791 * tree-ssa-reassoc.c (reassoc_stmt_dominates_stmt_p): New function. (insert_stmt_after): Rewritten, don't move the stmt, but really insert it. (get_stmt_uid_with_default): Remove. (build_and_add_sum): Use insert_stmt_after and reassoc_stmt_dominates_stmt_p. Fix up uid if bb contains only labels. (update_range_test): Set uid on stmts added by force_gimple_operand_gsi. Don't immediately modify statements in inter-bb optimization, just update oe->op values. (optimize_range_tests): Return bool whether any changed have been made. (update_ops): New function. (struct inter_bb_range_test_entry): New type. (maybe_optimize_range_tests): Perform statement changes here. (not_dominated_by, appears_later_in_bb, get_def_stmt, ensure_ops_are_available): Remove. (find_insert_point): Rewritten. (rewrite_expr_tree): Remove MOVED argument, add CHANGED argument, return LHS of the (new resp. old) stmt. Don't call ensure_ops_are_available, don't reuse SSA_NAMEs, recurse first instead of last, move new stmt at the right place. (linearize_expr, repropagate_negates): Don't reuse SSA_NAMEs. (negate_value): Likewise. Set uids. (break_up_subtract_bb): Initialize uids. (reassociate_bb): Adjust rewrite_expr_tree caller. (do_reassoc): Don't call renumber_gimple_stmt_uids. * gcc.dg/guality/pr58791-1.c: New test. * gcc.dg/guality/pr58791-2.c: New test. * gcc.dg/guality/pr58791-3.c: New test. * gcc.dg/guality/pr58791-4.c: New test. * gcc.dg/guality/pr58791-5.c: New test. * gcc.c-torture/compile/pr58775.c: New test. * gcc.dg/tree-ssa/reassoc-28.c: Don't scan reassoc1 dump. From-SVN: r203979
Name |
Last commit
|
Last update |
---|---|---|
INSTALL | Loading commit data... | |
boehm-gc | Loading commit data... | |
config | Loading commit data... | |
contrib | Loading commit data... | |
fixincludes | Loading commit data... | |
gcc | Loading commit data... | |
gnattools | Loading commit data... | |
include | Loading commit data... | |
intl | Loading commit data... | |
libada | Loading commit data... | |
libatomic | Loading commit data... | |
libbacktrace | Loading commit data... | |
libcpp | Loading commit data... | |
libdecnumber | Loading commit data... | |
libffi | Loading commit data... | |
libgcc | Loading commit data... | |
libgfortran | Loading commit data... | |
libgo | Loading commit data... | |
libgomp | Loading commit data... | |
libiberty | Loading commit data... | |
libitm | Loading commit data... | |
libjava | Loading commit data... | |
libmudflap | Loading commit data... | |
libobjc | Loading commit data... | |
libquadmath | Loading commit data... | |
libsanitizer | Loading commit data... | |
libssp | Loading commit data... | |
libstdc++-v3 | Loading commit data... | |
libvtv | Loading commit data... | |
lto-plugin | Loading commit data... | |
maintainer-scripts | Loading commit data... | |
zlib | Loading commit data... | |
.dir-locals.el | Loading commit data... | |
.gitignore | Loading commit data... | |
ABOUT-NLS | Loading commit data... | |
COPYING | Loading commit data... | |
COPYING.LIB | Loading commit data... | |
COPYING.RUNTIME | Loading commit data... | |
COPYING3 | Loading commit data... | |
COPYING3.LIB | Loading commit data... | |
ChangeLog | Loading commit data... | |
ChangeLog.tree-ssa | Loading commit data... | |
MAINTAINERS | Loading commit data... | |
Makefile.def | Loading commit data... | |
Makefile.in | Loading commit data... | |
Makefile.tpl | Loading commit data... | |
README | Loading commit data... | |
compile | Loading commit data... | |
config-ml.in | Loading commit data... | |
config.guess | Loading commit data... | |
config.rpath | Loading commit data... | |
config.sub | Loading commit data... | |
configure | Loading commit data... | |
configure.ac | Loading commit data... | |
depcomp | Loading commit data... | |
install-sh | Loading commit data... | |
libtool-ldflags | Loading commit data... | |
libtool.m4 | Loading commit data... | |
ltgcc.m4 | Loading commit data... | |
ltmain.sh | Loading commit data... | |
ltoptions.m4 | Loading commit data... | |
ltsugar.m4 | Loading commit data... | |
ltversion.m4 | Loading commit data... | |
lt~obsolete.m4 | Loading commit data... | |
missing | Loading commit data... | |
mkdep | Loading commit data... | |
mkinstalldirs | Loading commit data... | |
move-if-change | Loading commit data... | |
symlink-tree | Loading commit data... | |
ylwrap | Loading commit data... |