Update heuritics that estimates cost of call instructions.

llvm-svn: 48474
This commit is contained in:
Devang Patel 2008-03-17 23:41:20 +00:00
parent a9b30c0651
commit 924ca7f01d
1 changed files with 5 additions and 0 deletions

View File

@ -100,6 +100,11 @@ static unsigned ApproximateLoopSize(const Loop *L) {
// Ignore instructions only used by the loop terminator.
} else if (isa<DbgInfoIntrinsic>(I)) {
// Ignore debug instructions
} else if (isa<CallInst>(I)) {
if (isa<IntrinsicInst>(I))
Size = Size + 3;
else
Size = Size + 10;
} else {
++Size;
}