[cfe-commits] r84114 - /cfe/trunk/lib/CodeGen/CodeGenModule.cpp
Devang Patel
dpatel at apple.com
Wed Oct 14 10:03:29 PDT 2009
Author: dpatel
Date: Wed Oct 14 12:03:29 2009
New Revision: 84114
URL: http://llvm.org/viewvc/llvm-project?rev=84114&view=rev
Log:
Copy metadata associated with CI
Modified:
cfe/trunk/lib/CodeGen/CodeGenModule.cpp
Modified: cfe/trunk/lib/CodeGen/CodeGenModule.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/CodeGen/CodeGenModule.cpp?rev=84114&r1=84113&r2=84114&view=diff
==============================================================================
--- cfe/trunk/lib/CodeGen/CodeGenModule.cpp (original)
+++ cfe/trunk/lib/CodeGen/CodeGenModule.cpp Wed Oct 14 12:03:29 2009
@@ -1113,6 +1113,10 @@
if (!CI->use_empty())
CI->replaceAllUsesWith(NewCall);
+ // Copy any custom metadata attached with CI.
+ llvm::MetadataContext &TheMetadata = CI->getContext().getMetadata();
+ TheMetadata.copyMD(CI, NewCall);
+
CI->eraseFromParent();
}
}
More information about the cfe-commits
mailing list