summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/IntrinsicLowering.cpp
diff options
context:
space:
mode:
authorJustin Holewinski <jholewinski@nvidia.com>2013-05-21 14:37:16 +0000
committerJustin Holewinski <jholewinski@nvidia.com>2013-05-21 14:37:16 +0000
commitfff1f5f5e2f2569bef475fbeb900c114c8d74b6c (patch)
treee3124bb21857b0817775e5902fcbcf2069872011 /llvm/lib/CodeGen/IntrinsicLowering.cpp
parenta8048b8216cd517f92ae36bd634299ac21bafe75 (diff)
downloadbcm5719-llvm-fff1f5f5e2f2569bef475fbeb900c114c8d74b6c.tar.gz
bcm5719-llvm-fff1f5f5e2f2569bef475fbeb900c114c8d74b6c.zip
Drop @llvm.annotation and @llvm.ptr.annotation intrinsics during codegen.
The intrinsic calls are dropped, but the annotated value is propagated. Fixes PR 15253 Original patch by Zeng Bin! llvm-svn: 182387
Diffstat (limited to 'llvm/lib/CodeGen/IntrinsicLowering.cpp')
-rw-r--r--llvm/lib/CodeGen/IntrinsicLowering.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/CodeGen/IntrinsicLowering.cpp b/llvm/lib/CodeGen/IntrinsicLowering.cpp
index 07f0ccf52f8..d894f664dcb 100644
--- a/llvm/lib/CodeGen/IntrinsicLowering.cpp
+++ b/llvm/lib/CodeGen/IntrinsicLowering.cpp
@@ -453,6 +453,12 @@ void IntrinsicLowering::LowerIntrinsicCall(CallInst *CI) {
CI->replaceAllUsesWith(ConstantInt::get(CI->getType(), 1));
break;
+ case Intrinsic::annotation:
+ case Intrinsic::ptr_annotation:
+ // Just drop the annotation, but forward the value
+ CI->replaceAllUsesWith(CI->getOperand(0));
+ break;
+
case Intrinsic::var_annotation:
break; // Strip out annotate intrinsic
OpenPOWER on IntegriCloud