llvm-6502/lib/Transforms/IPO
Chandler Carruth b16117c368 Change where we enable the heuristic that delays inlining into functions
which are small enough to themselves be inlined. Delaying in this manner
can be harmful if the function is inelligible for inlining in some (or
many) contexts as it pessimizes the code of the function itself in the
event that inlining does not eventually happen.

Previously the check was written to only do this delaying of inlining
for static functions in the hope that they could be entirely deleted and
in the knowledge that all callers of static functions will have the
opportunity to inline if it is in fact profitable. However, with C++ we
get two other important sources of functions where the definition is
always available for inlining: inline functions and templated functions.
This patch generalizes the inliner to allow linkonce-ODR (the linkage
such C++ routines receive) to also qualify for this delay-based
inlining.

Benchmarking across a range of large real-world applications shows
roughly 2% size increase across the board, but an average speedup of
about 0.5%. Some benhcmarks improved over 2%, and the 'clang' binary
itself (when bootstrapped with this feature) shows a 1% -O0 performance
improvement when run over all Sema, Lex, and Parse source code smashed
into a single file. A clean re-build of Clang+LLVM with a bootstrapped
Clang shows approximately 2% improvement, but that measurement is often
noisy.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152737 91177308-0d34-0410-b5e6-96231b3b80d8
2012-03-14 20:16:41 +00:00
..
ArgumentPromotion.cpp
CMakeLists.txt
ConstantMerge.cpp Re-fix the issue Bill fixed in r147899 in a slightly different way, which doesn't abuse the semantics of linker_private. We don't really want to merge any string constant with a weak_odr global. 2012-01-11 22:06:46 +00:00
DeadArgumentElimination.cpp
ExtractGV.cpp
FunctionAttrs.cpp
GlobalDCE.cpp
GlobalOpt.cpp Teach globalopt how to evaluate an invoke with a non-void return type. 2012-03-13 18:01:37 +00:00
InlineAlways.cpp Add comment. 2012-02-25 03:07:57 +00:00
Inliner.cpp Change where we enable the heuristic that delays inlining into functions 2012-03-14 20:16:41 +00:00
InlineSimple.cpp Add comment. 2012-02-25 03:07:57 +00:00
Internalize.cpp
IPConstantPropagation.cpp
IPO.cpp
LLVMBuild.txt Add a basic-block autovectorization pass. 2012-02-01 03:51:43 +00:00
LoopExtractor.cpp
Makefile
MergeFunctions.cpp
PartialInlining.cpp
PassManagerBuilder.cpp Add a basic-block autovectorization pass. 2012-02-01 03:51:43 +00:00
PruneEH.cpp [unwind removal] We no longer have 'unwind' instructions being generated, so 2012-02-06 21:16:41 +00:00
StripDeadPrototypes.cpp
StripSymbols.cpp