From dca0c284525b915df0fa147e2463ea80696c29e7 Mon Sep 17 00:00:00 2001 From: Duncan Sands Date: Tue, 10 Nov 2009 09:08:09 +0000 Subject: Codegen support for the llvm.invariant/lifetime.start/end intrinsics: just throw them away. llvm-svn: 86678 --- llvm/lib/CodeGen/IntrinsicLowering.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'llvm/lib/CodeGen/IntrinsicLowering.cpp') diff --git a/llvm/lib/CodeGen/IntrinsicLowering.cpp b/llvm/lib/CodeGen/IntrinsicLowering.cpp index 3e3b28a8109..8a3bd0bf4e0 100644 --- a/llvm/lib/CodeGen/IntrinsicLowering.cpp +++ b/llvm/lib/CodeGen/IntrinsicLowering.cpp @@ -515,6 +515,15 @@ void IntrinsicLowering::LowerIntrinsicCall(CallInst *CI) { if (CI->getType() != Type::getVoidTy(Context)) CI->replaceAllUsesWith(ConstantInt::get(CI->getType(), 1)); break; + case Intrinsic::invariant_start: + case Intrinsic::lifetime_start: + // Discard region information. + CI->replaceAllUsesWith(UndefValue::get(CI->getType())); + break; + case Intrinsic::invariant_end: + case Intrinsic::lifetime_end: + // Discard region information. + break; } assert(CI->use_empty() && -- cgit v1.2.3