[llvm] [TTI][AMDGPU] Allow targets to adjust `LastCallToStaticBonus` via `getInliningLastCallToStaticBonus` (PR #111311)

Shilei Tian via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 7 12:48:48 PDT 2024


================
@@ -352,6 +352,9 @@ class TargetTransformInfo {
   unsigned getInliningCostBenefitAnalysisSavingsMultiplier() const;
   unsigned getInliningCostBenefitAnalysisProfitableMultiplier() const;
 
+  /// \returns The bonus of inlining the last call to a static function.
+  int getInliningLastCallToStaticBonus() const;
----------------
shiltian wrote:

I'm not sure if it makes sense to use `unsigned` as return value, but `InlineConstants::LastCallToStaticBonus` is `int`.

https://github.com/llvm/llvm-project/pull/111311


More information about the llvm-commits mailing list