[PATCH] D109893: [llvm-profgen] Use context-sensitive byte size cost for preinliner decisions by default
Wenlei He via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 16 08:36:35 PDT 2021
wenlei created this revision.
wenlei added reviewers: hoy, wmi, wlei.
Herald added subscribers: modimo, lxfind, eraman.
wenlei requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Turn on `use-context-cost-for-preinliner` to use context-sensitive byte size cost for preinliner decisions by default.
This is a more accurate proxy of inline cost than profile size. We tested on our large workload that it delivers measureable CPU improvement.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D109893
Files:
llvm/tools/llvm-profgen/CSPreInliner.cpp
Index: llvm/tools/llvm-profgen/CSPreInliner.cpp
===================================================================
--- llvm/tools/llvm-profgen/CSPreInliner.cpp
+++ llvm/tools/llvm-profgen/CSPreInliner.cpp
@@ -45,7 +45,7 @@
"estimated global top-down inline decisions"));
cl::opt<bool> UseContextCostForPreInliner(
- "use-context-cost-for-preinliner", cl::Hidden, cl::init(false),
+ "use-context-cost-for-preinliner", cl::Hidden, cl::init(true),
cl::desc("Use context-sensitive byte size cost for preinliner decisions"));
static cl::opt<bool> SamplePreInlineReplay(
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D109893.372962.patch
Type: text/x-patch
Size: 597 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210916/d11d5e1f/attachment.bin>
More information about the llvm-commits
mailing list