Go to file
Jan Hubicka 9340d34599 Convert inliner to function specific param infrastructure
This patch adds opt_for_fn for all cross module params used by inliner
so they can be modified at function granuality.  With inlining almost always
there are three functions to consider (callee and caller of the inlined edge
and the outer function caller is inlined to).

I always use the outer function params since that is how local parameters
behave.  I hope it is kind of what is also expected in most case: it is better
to inline agressively into -O3 compiled code rather than inline agressively -O3
functions into their callers.

New params infrastructure is nice.  One drawback is that is very hard to
search for individual param uses since they all occupy global namespace.
With C++ world we had chance to do something like params.param_flag_name
or params::param_flag_name instead...

Bootstrapped/regtested x86_64-linux, comitted.

	* cif-code.def (MAX_INLINE_INSNS_SINGLE_O2_LIMIT): Remove.
	* doc/invoke.texi (max-inline-insns-single-O2,
	inline-heuristics-hint-percent-O2, inline-min-speedup-O2,
	early-inlining-insns-O2): Remove documentation.
	* ipa-fnsummary.c (analyze_function_body,
	compute_fn_summary): Use opt_for_fn when accessing parameters.
	* ipa-inline.c (caller_growth_limits, can_inline_edge_p,
	inline_insns_auto, can_inline_edge_by_limits_p,
	want_early_inline_function_p, big_speedup_p,
	want_inline_small_function_p, want_inline_self_recursive_call_p,
	recursive_inlining, compute_max_insns, inline_small_functions):
	Likewise.
	* opts.c (default_options): Add -O3 defaults for
	OPT__param_early_inlining_insns_,
	OPT__param_inline_heuristics_hint_percent_,
	OPT__param_inline_min_speedup_, OPT__param_max_inline_insns_single_.
	* params.opt (-param=early-inlining-insns-O2=,
	-param=inline-heuristics-hint-percent-O2=,
	-param=inline-min-speedup-O2=, -param=max-inline-insns-single-O2=
	-param=early-inlining-insns=, -param=inline-heuristics-hint-percent=,
	-param=inline-min-speedup=, -param=inline-unit-growth=,
	-param=large-function-growth=, -param=large-stack-frame=,
	-param=large-stack-frame-growth=, -param=large-unit-insns=,
	-param=max-inline-insns-recursive=,
	-param=max-inline-insns-recursive-auto=,
	-param=max-inline-insns-single=,
	-param=max-inline-insns-size=, -param=max-inline-insns-small=,
	-param=max-inline-recursive-depth=,
	-param=max-inline-recursive-depth-auto=,
	-param=min-inline-recursive-probability=,
	-param=partial-inlining-entry-probability=,
	-param=uninlined-function-insns=, -param=uninlined-function-time=,
	-param=uninlined-thunk-insns=, -param=uninlined-thunk-time=): Add
	Optimization.

	* g++.dg/tree-ssa/pr53844.C: Drop -O2 from param name.
	* g++.dg/tree-ssa/pr61034.C: Likewise.
	* g++.dg/tree-ssa/pr8781.C: Likewise.
	* g++.dg/warn/Wstringop-truncation-1.C: Likewise.
	* gcc.dg/ipa/pr63416.c: Likewise.
	* gcc.dg/tree-ssa/ssa-thread-12.c: Likewise.
	* gcc.dg/vect/pr66142.c: Likewise.
	* gcc.dg/winline-3.c: Likewise.
	* gcc.target/powerpc/pr72804.c: Likewise.

From-SVN: r278644
2019-11-23 13:11:25 +00:00
config
contrib
fixincludes
gcc Convert inliner to function specific param infrastructure 2019-11-23 13:11:25 +00:00
gnattools
gotools
include [PATCH] Fix slowness in demangler 2019-11-16 10:14:14 -07:00
INSTALL
intl
libada
libatomic
libbacktrace
libcc1
libcpp Support UTF-8 character constants for C2x. 2019-11-14 20:18:33 +00:00
libdecnumber
libffi
libgcc fix ChangeLog to reference the PR 2019-11-18 12:46:56 +00:00
libgfortran libgfortran: Regenerate Makefile.in' for runstatedir' removal 2019-11-18 00:21:45 +00:00
libgo re PR go/92605 (r278509 causes/reveals issue in building go library) 2019-11-21 01:06:47 +00:00
libgomp Fix failures on Solaris with -fno-common default 2019-11-21 16:14:21 +00:00
libhsail-rt
libiberty [PATCH] Fix slowness in demangler 2019-11-16 10:14:14 -07:00
libitm
libobjc
liboffloadmic
libphobos
libquadmath
libsanitizer Update comment in libsanitizer/*/libtool-version files. 2019-11-20 14:52:05 +00:00
libssp
libstdc++-v3 Switch gcc ftp URL's to https 2019-11-20 22:24:48 +02:00
libvtv
lto-plugin
maintainer-scripts Switch gcc ftp URL's to https 2019-11-20 22:24:48 +02:00
zlib
.dir-locals.el
.gitattributes
.gitignore
ABOUT-NLS
ar-lib
ChangeLog Switch gcc ftp URL's to https 2019-11-20 22:24:48 +02:00
ChangeLog.jit
ChangeLog.tree-ssa
compile
config-ml.in
config.guess
config.rpath
config.sub
configure Switch gcc ftp URL's to https 2019-11-20 22:24:48 +02:00
configure.ac Switch gcc ftp URL's to https 2019-11-20 22:24:48 +02:00
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.RUNTIME
depcomp
install-sh
libtool-ldflags
libtool.m4
lt~obsolete.m4
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS Remove my name from AArch64 port maintainers 2019-11-20 09:29:13 +00:00
Makefile.def
Makefile.in
Makefile.tpl
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.