use the new optimized debug info metadata accessors. In

addition to the inherent win, this eliminates the pointless
cost of going through the name -> mdkind stringmap that we
were paying.

llvm-svn: 99983
This commit is contained in:
Chris Lattner
2010-03-31 03:36:01 +00:00
parent 009de335ac
commit be49c03ff4
2 changed files with 4 additions and 4 deletions

View File

@@ -1246,8 +1246,8 @@ static void ReplaceUsesOfNonProtoTypeWithRealFunction(llvm::GlobalValue *Old,
CI->replaceAllUsesWith(NewCall);
// Copy any custom metadata attached with CI.
if (llvm::MDNode *DbgNode = CI->getMetadata("dbg"))
NewCall->setMetadata("dbg", DbgNode);
if (llvm::MDNode *DbgNode = CI->getDbgMetadata())
NewCall->setDbgMetadata(DbgNode);
CI->eraseFromParent();
}
}