diff --git a/llvm/lib/Analysis/InlineCost.cpp b/llvm/lib/Analysis/InlineCost.cpp --- a/llvm/lib/Analysis/InlineCost.cpp +++ b/llvm/lib/Analysis/InlineCost.cpp @@ -46,6 +46,11 @@ STATISTIC(NumCallsAnalyzed, "Number of call sites analyzed"); +static cl::opt + DefaultThreshold("inlinedefault-threshold", cl::Hidden, cl::init(225), + cl::ZeroOrMore, + cl::desc("Default amount of inlining to perform")); + static cl::opt InlineThreshold( "inline-threshold", cl::Hidden, cl::init(225), cl::ZeroOrMore, cl::desc("Control the amount of inlining to perform (default = 225)")); @@ -2197,7 +2202,7 @@ } InlineParams llvm::getInlineParams() { - return getInlineParams(InlineThreshold); + return getInlineParams(DefaultThreshold); } // Compute the default threshold for inlining based on the opt level and the @@ -2210,7 +2215,7 @@ return InlineConstants::OptSizeThreshold; if (SizeOptLevel == 2) // -Oz return InlineConstants::OptMinSizeThreshold; - return InlineThreshold; + return DefaultThreshold; } InlineParams llvm::getInlineParams(unsigned OptLevel, unsigned SizeOptLevel) {