From: Dan Gohman Date: Tue, 20 Jul 2010 20:09:07 +0000 (+0000) Subject: Use getDebugLoc and setDebugLoc instead of getDbgMetadata and setDbgMetadata, X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=bda025263905252aa1b7f811d0129fc4fb9322aa;p=oota-llvm.git Use getDebugLoc and setDebugLoc instead of getDbgMetadata and setDbgMetadata, avoiding MDNode overhead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108909 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Transforms/IPO/DeadArgumentElimination.cpp b/lib/Transforms/IPO/DeadArgumentElimination.cpp index 475eee8b19e..b71bf5ff468 100644 --- a/lib/Transforms/IPO/DeadArgumentElimination.cpp +++ b/lib/Transforms/IPO/DeadArgumentElimination.cpp @@ -250,8 +250,7 @@ bool DAE::DeleteDeadVarargs(Function &Fn) { if (cast(Call)->isTailCall()) cast(New)->setTailCall(); } - if (MDNode *N = Call->getDbgMetadata()) - New->setDbgMetadata(N); + New->setDebugLoc(Call->getDebugLoc()); Args.clear(); @@ -780,8 +779,7 @@ bool DAE::RemoveDeadStuffFromFunction(Function *F) { if (cast(Call)->isTailCall()) cast(New)->setTailCall(); } - if (MDNode *N = Call->getDbgMetadata()) - New->setDbgMetadata(N); + New->setDebugLoc(Call->getDebugLoc()); Args.clear();