[PATCH] D106336: Fix Threshold overwrite bug in the Oz inlining model features.
Jacob Hegna via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 19 19:56:16 PDT 2021
jacobhegna created this revision.
jacobhegna added a reviewer: mtrofin.
Herald added subscribers: haicheng, hiraditya, eraman.
jacobhegna requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D106336
Files:
llvm/lib/Analysis/InlineCost.cpp
Index: llvm/lib/Analysis/InlineCost.cpp
===================================================================
--- llvm/lib/Analysis/InlineCost.cpp
+++ llvm/lib/Analysis/InlineCost.cpp
@@ -1097,9 +1097,9 @@
set(InlineCostFeatureIndex::SROASavings, SROACostSavingOpportunities);
if (NumVectorInstructions <= NumInstructions / 10)
- increment(InlineCostFeatureIndex::Threshold, -1 * VectorBonus);
+ Threshold -= VectorBonus;
else if (NumVectorInstructions <= NumInstructions / 2)
- increment(InlineCostFeatureIndex::Threshold, -1 * (VectorBonus / 2));
+ Threshold -= VectorBonus / 2;
set(InlineCostFeatureIndex::Threshold, Threshold);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D106336.359992.patch
Type: text/x-patch
Size: 676 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210720/cd59ff79/attachment.bin>
More information about the llvm-commits
mailing list