[llvm] [FuncSpec] Improve accounting of specialization codesize growth (PR #113448)
Alexandros Lamprineas via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 24 03:05:47 PDT 2024
================
@@ -924,16 +932,14 @@ bool FunctionSpecializer::findSpecializations(Function *F, unsigned FuncSize,
}
CodeSize += Visitor.getCodeSizeSavingsFromPendingPHIs();
+ unsigned CodeSizeSavings = getCostValue(CodeSize);
+ unsigned CodeSizeCost = FuncSize - CodeSizeSavings;
+
----------------
labrinea wrote:
I think we can sink these two back in the lambda where the TODO note was. I would rename CodeSizeCost to SpecSize.
https://github.com/llvm/llvm-project/pull/113448
More information about the llvm-commits
mailing list