Find a file
Aldy Hernandez 011d0a033a Make path_range_query standalone and add reset_path.
These are a bunch of cleanups inspired by Richi's suggestion of making
path_range_query standalone, instead of having to call
compute_ranges() for each path.

I've made the ranger need explicit, and moved the responsibility for
its creation to the caller.

I've also investigated and documented why the forward threader needs its
own compute exit dependencies variant.  I can't wait for it to go away
:-/.

I've also added constructors that take a path and dependencies, and
made compute_ranges() private.  Unfortunately, reinstantiating
path_range_query in the forward threader caused a 14% performance
regression in DOM, because the old threader calls it over and over on
the same path to simplify statements (some of which not even in the
IL, but that's old news).

In the meantime, I've left the ability to reset a path, but this time
appropriately called reset_path().

Tested, benchmarked, and thread counted on x86-64 Linux.

gcc/ChangeLog:

	* gimple-range-path.cc (path_range_query::path_range_query): Add
	various constructors to take a path.
	(path_range_query::~path_range_query): Remove m_alloced_ranger.
	(path_range_query::range_on_path_entry): Adjust for m_ranger being
	a reference.
	(path_range_query::set_path): Rename to...
	(path_range_query::reset_path): ...this and call compute_ranges.
	(path_range_query::ssa_range_in_phi): Adjust for m_ranger
	reference.
	(path_range_query::range_defined_in_block): Same.
	(path_range_query::compute_ranges_in_block): Same.
	(path_range_query::adjust_for_non_null_uses): Same.
	(path_range_query::compute_exit_dependencies): Use m_path instead
	of argument.
	(path_range_query::compute_ranges): Remove path argument.
	(path_range_query::range_of_stmt): Adjust for m_ranger reference.
	(path_range_query::compute_outgoing_relations): Same.
	* gimple-range-path.h (class path_range_query): Add various
	constructors.
	Make compute_ranges and compute_exit_dependencies private.
	Rename set_path to reset_path.
	Make m_ranger a reference.
	Remove m_alloced_ranger.
	* tree-ssa-dom.cc (pass_dominator::execute): Adjust constructor to
	path_range_query.
	* tree-ssa-loop-ch.cc (entry_loop_condition_is_static): Take a
	ranger and instantiate a new path_range_query every time.
	(ch_base::copy_headers): Pass ranger instead of path_range_query.
	* tree-ssa-threadbackward.cc (class back_threader): Remove m_solver.
	(back_threader::~back_threader): Remove m_solver.
	(back_threader::find_taken_edge_switch): Adjust for m_ranger
	reference.
	(back_threader::find_taken_edge_cond): Same.
	(back_threader::dump): Remove m_solver.
	(back_threader::back_threader): Move verify_marked_backedges
	here from the path_range_query constructor.
	* tree-ssa-threadedge.cc (hybrid_jt_simplifier::simplify): Move
	some code from compute_ranges_from_state here.
	(hybrid_jt_simplifier::compute_ranges_from_state): Rename...
	(hybrid_jt_simplifier::compute_exit_dependencies): ...to this.
	* tree-ssa-threadedge.h (class hybrid_jt_simplifier): Rename
	compute_ranges_from_state to compute_exit_dependencies.
	Remove m_path.
2022-08-18 16:38:00 +02:00
c++tools Daily bump. 2022-03-19 00:16:22 +00:00
config Daily bump. 2022-08-02 00:16:51 +00:00
contrib Daily bump. 2022-08-03 00:16:48 +00:00
fixincludes Daily bump. 2022-02-28 00:16:17 +00:00
gcc Make path_range_query standalone and add reset_path. 2022-08-18 16:38:00 +02:00
gnattools Daily bump. 2021-10-23 00:16:26 +00:00
gotools Daily bump. 2022-02-14 00:16:23 +00:00
include Daily bump. 2022-07-13 00:16:33 +00:00
INSTALL
intl Daily bump. 2021-11-30 00:16:44 +00:00
libada Update copyright years. 2022-01-03 10:42:10 +01:00
libatomic Daily bump. 2022-08-09 00:16:47 +00:00
libbacktrace Daily bump. 2022-07-09 00:16:54 +00:00
libcc1 Daily bump. 2022-06-28 00:16:58 +00:00
libcody Daily bump. 2022-06-04 00:16:27 +00:00
libcpp Daily bump. 2022-08-17 00:17:17 +00:00
libdecnumber Daily bump. 2022-05-21 00:16:32 +00:00
libffi Daily bump. 2021-11-16 00:16:31 +00:00
libgcc Daily bump. 2022-08-17 00:17:17 +00:00
libgfortran Daily bump. 2022-08-18 00:16:43 +00:00
libgo libgo: use SYS_timer_settime32 2022-07-30 10:35:23 -07:00
libgomp Daily bump. 2022-08-18 00:16:43 +00:00
libiberty Daily bump. 2022-07-23 00:16:27 +00:00
libitm Daily bump. 2022-06-03 00:16:40 +00:00
libobjc Update copyright years. 2022-01-03 10:42:10 +01:00
liboffloadmic Daily bump. 2022-07-05 00:16:36 +00:00
libphobos Daily bump. 2022-08-04 00:16:49 +00:00
libquadmath Daily bump. 2022-01-12 00:16:39 +00:00
libsanitizer libsanitizer: Cherry-pick 2bfb0fcb51510f22723c8cdfefe from upstream 2022-08-01 06:10:31 +02:00
libssp Update copyright years. 2022-01-03 10:42:10 +01:00
libstdc++-v3 Daily bump. 2022-08-18 00:16:43 +00:00
libvtv Update copyright years. 2022-01-03 10:42:10 +01:00
lto-plugin Daily bump. 2022-08-02 00:16:51 +00:00
maintainer-scripts Daily bump. 2022-07-29 00:16:21 +00:00
zlib Daily bump. 2021-12-17 00:16:20 +00:00
.dir-locals.el dir-locals: Use https for bug references 2021-07-20 11:40:34 +01:00
.gitattributes
.gitignore .gitignore: do not ignore config.h 2022-07-19 17:07:04 +03:00
ABOUT-NLS
ar-lib
ChangeLog Daily bump. 2022-08-05 00:16:24 +00:00
ChangeLog.jit
ChangeLog.tree-ssa
compile
config-ml.in
config.guess
config.rpath
config.sub config.sub: change mode to 755. 2021-12-21 09:10:57 +01:00
configure Makefile.def: drop remnants of unused libelf 2022-08-18 09:37:09 +01:00
configure.ac Makefile.def: drop remnants of unused libelf 2022-08-18 09:37:09 +01:00
COPYING
COPYING.LIB
COPYING.RUNTIME
COPYING3
COPYING3.LIB
depcomp
install-sh
libtool-ldflags
libtool.m4 Revert "Sync with binutils: GCC: Pass --plugin to AR and RANLIB" 2021-12-15 20:45:58 -08:00
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
lt~obsolete.m4
MAINTAINERS Add myself as AutoFDO maintainer 2022-08-04 13:38:28 -07:00
Makefile.def Makefile.def: drop remnants of unused libelf 2022-08-18 09:37:09 +01:00
Makefile.in Makefile.def: drop remnants of unused libelf 2022-08-18 09:37:09 +01:00
Makefile.tpl Makefile.def: drop remnants of unused libelf 2022-08-18 09:37:09 +01:00
missing
mkdep
mkinstalldirs
move-if-change
multilib.am
README
symlink-tree
test-driver
ylwrap

This directory contains the GNU Compiler Collection (GCC).

The GNU Compiler Collection is free software.  See the files whose
names start with COPYING for copying permission.  The manuals, and
some of the runtime libraries, are under different terms; see the
individual source files for details.

The directory INSTALL contains copies of the installation information
as HTML and plain text.  The source of this information is
gcc/doc/install.texi.  The installation information includes details
of what is included in the GCC sources and what files GCC installs.

See the file gcc/doc/gcc.texi (together with other files that it
includes) for usage and porting information.  An online readable
version of the manual is in the files gcc/doc/gcc.info*.

See http://gcc.gnu.org/bugs/ for how to report bugs usefully.

Copyright years on GCC source files may be listed using range
notation, e.g., 1987-2012, indicating that every year in the range,
inclusive, is a copyrightable year that could otherwise be listed
individually.