llvm-project/llvm/test/Transforms/SampleProfile
Wenlei He 577e58bcc7 [InlineAdvisor] New inliner advisor to replay inlining from optimization remarks
This change added a new inline advisor that takes optimization remarks from previous inlining as input, and provides the decision as advice so current inlining can replay inline decisions of a different compilation. Dwarf inline stack with line and discriminator is used as anchor for call sites including call context. The change can be useful for Inliner tuning as it provides a channel to allow external input for tweaking inline decisions. Existing alternatives like alwaysinline attribute is per-function, not per-callsite. Per-callsite inline intrinsic can be another solution (not yet existing), but it's intrusive to implement and also does not differentiate call context.

A switch -sample-profile-inline-replay=<inline_remarks_file> is added to hook up the new inline advisor with SampleProfileLoader's inline decision for replay. Since SampleProfileLoader does top-down inlining, inline decision can be specialized for each call context, hence we should be able to replay inlining accurately. However with a bottom-up inliner like CGSCC inlining, the replay can be limited due to lack of specialization for different call context. Apart from that limitation, the new inline advisor can still be used by regular CGSCC inliner later if needed for tuning purpose.

This is a resubmit of https://reviews.llvm.org/D83743
2020-08-15 20:17:21 -07:00
..
Inputs [InlineAdvisor] New inliner advisor to replay inlining from optimization remarks 2020-08-15 20:17:21 -07:00
branch.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
calls.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
cold-indirect-call.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
compressed-profile-symbol-list.ll
cov-zero-samples.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
coverage-warning.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
discriminator.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
early-inline.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
entry_counts.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
entry_counts_cold.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
entry_counts_missing_dbginfo.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
flattened.ll
fnptr.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
function_metadata.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
gcc-simple.ll [gcov] Delete XFAIL: host-byteorder-big-endian 2020-06-03 19:58:28 -07:00
indirect-call-gcc.ll [gcov] Delete XFAIL: host-byteorder-big-endian 2020-06-03 19:58:28 -07:00
indirect-call.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-act.ll Migrate function attribute "no-frame-pointer-elim"="false" to "frame-pointer"="none" as cleanups after D56351 2019-12-24 16:27:51 -08:00
inline-callee-update.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-cold-callsite-samplepgo.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-cold.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-combine.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-coverage.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-mergeprof-dup.ll [AutoFDO] Avoid merging inlinee samples multiple times 2020-07-31 09:30:05 -07:00
inline-mergeprof.ll Fix a crash when the sample profile uses md5 and -sample-profile-merge-inlinee 2020-07-30 21:21:06 -07:00
inline-replay.ll [InlineAdvisor] New inliner advisor to replay inlining from optimization remarks 2020-08-15 20:17:21 -07:00
inline-stats.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
inline-topdown.ll [SampleFDO] Enable sample-profile-top-down-load and sample-profile-merge-inlinee 2020-07-08 09:23:18 -07:00
inline.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
nodebug-error.ll [SampleFDO] Stop letting findCalleeFunctionSamples return unrelated profiles 2020-08-10 12:41:09 -07:00
nodebug.ll
nolocinfo.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
offset.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
profile-format-compress.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
profile-format.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
profile-sample-accurate.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
propagate.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
remap.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
remarks.ll [Remarks] Add callsite locations to inline remarks 2020-06-20 23:32:10 -07:00
section-accurate-samplepgo.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
summary.ll
syntax.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
uncompressed-profile-symbol-list.ll
use-sample-profile-attr.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00
warm-inline-instance.ll [SampleFDO] Add use-sample-profile function attribute. 2020-06-02 17:23:17 -07:00