Permit inlining into huge functions. This heuristic is ancient, and inlining

can sometimes help reduce function size.

llvm-svn: 98088
This commit is contained in:
Jakob Stoklund Olesen 2010-03-09 22:17:06 +00:00
parent 9d227a1d5e
commit 5fba36cc1b
1 changed files with 0 additions and 5 deletions

View File

@ -352,11 +352,6 @@ InlineCost InlineCostAnalyzer::getInlineCost(CallSite CS,
// Calls usually take a long time, so they make the inlining gain smaller.
InlineCost += CalleeFI.Metrics.NumCalls * InlineConstants::CallPenalty;
// Don't inline into something too big, which would make it bigger.
// "size" here is the number of basic blocks, not instructions.
//
InlineCost += Caller->size()/15;
// Look at the size of the callee. Each instruction counts as 5.
InlineCost += CalleeFI.Metrics.NumInsts*InlineConstants::InstrCost;