Remove premature optimization that avoided calculating argument weights

if we weren't going to inline the function. The rest of the code using
this was removed.

Fixes PR9154.

llvm-svn: 124991
This commit is contained in:
Eric Christopher 2011-02-06 21:27:46 +00:00
parent ecf8e159e3
commit b54605b8e2
1 changed files with 0 additions and 5 deletions

View File

@ -242,11 +242,6 @@ void InlineCostAnalyzer::FunctionInfo::analyzeFunction(Function *F) {
if (Metrics.NumRets==1)
--Metrics.NumInsts;
// Don't bother calculating argument weights if we are never going to inline
// the function anyway.
if (NeverInline())
return;
// Check out all of the arguments to the function, figuring out how much
// code can be eliminated if one of the arguments is a constant.
ArgumentWeights.reserve(F->arg_size());