1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00
llvm-mirror/test/Other
Vedant Kumar fa99fcaf87 [HotColdSplit] Move splitting earlier in the pipeline
Performing splitting early has several advantages:

  - Inhibiting inlining of cold code early improves code size. Compared
    to scheduling splitting at the end of the pipeline, this cuts code
    size growth in half within the iOS shared cache (0.69% to 0.34%).

  - Inhibiting inlining of cold code improves compile time. There's no
    need to inline split cold functions, or to inline as much *within*
    those split functions as they are marked `minsize`.

  - During LTO, extra work is only done in the pre-link step. Less code
    must be inlined during cross-module inlining.

An additional motivation here is that the most common cold regions
identified by the static/conservative splitting heuristic can (a) be
found before inlining and (b) do not grow after inlining. E.g.
__assert_fail, os_log_error.

The disadvantages are:

  - Some opportunities for splitting out cold code may be missed. This
    gap can potentially be narrowed by adding a worklist algorithm to the
    splitting pass.

  - Some opportunities to reduce code size may be lost (e.g. store
    sinking, when one side of the CFG diamond is split). This does not
    outweigh the code size benefits of splitting earlier.

On net, splitting early in the pipeline has substantial code size
benefits, and no major effects on memory locality or performance. We
measured memory locality using ktrace data, and consistently found that
10% fewer pages were needed to capture 95% of text page faults in key
iOS benchmarks. We measured performance on frequency-stabilized iOS
devices using LNT+externals.

This reverses course on the decision made to schedule splitting late in
r344869 (D53437).

Differential Revision: https://reviews.llvm.org/D57082

llvm-svn: 352080
2019-01-24 18:55:49 +00:00
..
Inputs
X86 [HotColdSplit] Move splitting earlier in the pipeline 2019-01-24 18:55:49 +00:00
2002-01-31-CallGraph.ll
2002-02-24-InlineBrokePHINodes.ll
2002-03-11-ConstPropCrash.ll
2003-02-19-LoopInfoNestingBug.ll
2004-08-16-PackedConstantInlineStore.ll
2004-08-16-PackedGlobalConstant.ll
2004-08-16-PackedSelect.ll
2004-08-16-PackedSimple.ll
2004-08-20-PackedControlFlow.ll
2006-02-05-PassManager.ll
2007-04-24-eliminate-mostly-empty-blocks.ll
2007-06-05-PassID.ll
2007-06-28-PassManager.ll
2007-09-10-PassManager.ll
2008-02-14-PassManager.ll
2008-06-04-FieldSizeInPacked.ll
2008-10-06-RemoveDeadPass.ll
2008-10-15-MissingSpace.ll
2009-03-31-CallGraph.ll
2009-06-05-no-implicit-float.ll
2009-09-14-function-elements.ll
2010-05-06-Printer.ll
attribute-comment.ll
bcanalyzer-block-info.txt
can-execute.txt
cfg-printer-branch-weights.ll
cgscc-devirt-iteration.ll
cgscc-disconnected-invalidation.ll
cgscc-iterate-function-mutation.ll
cgscc-libcall-update.ll
cgscc-observe-devirt.ll
cleanup-lcssa.ll
close-stderr.ll
codegenprepare-and-debug.ll
constant-fold-gep-address-spaces.ll
constant-fold-gep.ll
debugcounter-dce.ll
debugcounter-earlycse.ll
debugcounter-newgvn.ll
debugcounter-predicateinfo.ll
extract-alias.ll
extract-linkonce.ll
extract-weak-odr.ll
extract.ll
FileCheck-space.txt
invalid-commandline-option.ll
invariant.group.ll
lint.ll
lit-globbing.ll
lit-quoting.txt
lit-unicode.txt
llvm-nm-without-aliases.ll
loop-deletion-printer.ll
loop-pass-ordering.ll
loop-pass-printer.ll
loop-pm-invalidation.ll
machine-size-remarks.ll
new-pass-manager.ll
new-pm-defaults.ll
new-pm-lto-defaults.ll
new-pm-pgo.ll [PGO] Make pgo related options in opt more consistent. 2019-01-16 23:19:02 +00:00
new-pm-thinlto-defaults.ll [HotColdSplit] Move splitting earlier in the pipeline 2019-01-24 18:55:49 +00:00
opt-bisect-helper.py
opt-bisect-legacy-pass-manager.ll
opt-hot-cold-split.ll [HotColdSplit] Move splitting earlier in the pipeline 2019-01-24 18:55:49 +00:00
opt-O0-pipeline.ll
opt-O2-pipeline.ll
opt-O3-pipeline.ll
opt-Os-pipeline.ll
opt-override-mcpu-mattr.ll
opt-twice.ll
optimization-remarks-inline.ll
optimization-remarks-invalidation.ll
optimization-remarks-lazy-bfi.ll
optimize-inrange-gep.ll
optimize-options.ll
pass-pipeline-parsing.ll
pass-pipelines.ll
pipefail.txt
pr32085.ll
print-debug-counter.ll
print-module-scope.ll
printer.ll
ResponseFile.ll
scc-deleted-printer.ll
scc-pass-printer.ll
size-remarks.ll
spir_cc.ll
statistic.ll
time-passes.ll
umask.ll
writing-to-stdout.ll