diff options
Diffstat (limited to 'lib/CodeGen/CGDecl.cpp')
-rw-r--r-- | lib/CodeGen/CGDecl.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/lib/CodeGen/CGDecl.cpp b/lib/CodeGen/CGDecl.cpp index 86bc347576..db6aae6dfd 100644 --- a/lib/CodeGen/CGDecl.cpp +++ b/lib/CodeGen/CGDecl.cpp @@ -192,17 +192,9 @@ void CodeGenFunction::EmitLocalBlockVarDecl(const VarDecl &D) { // Allocate memory for the array. llvm::Value *VLA = Builder.CreateAlloca(llvm::Type::Int8Ty, VLASize, "vla"); - VLA = Builder.CreateBitCast(VLA, LElemPtrTy, "tmp"); - - llvm::AllocaInst *Alloc = - CreateTempAlloca(LElemPtrTy, D.getIdentifier()->getName()); - - // FIXME: Volatile? - Builder.CreateStore(VLA, Alloc); - - DeclPtr = Alloc; + DeclPtr = Builder.CreateBitCast(VLA, LElemPtrTy, "tmp"); } - + llvm::Value *&DMEntry = LocalDeclMap[&D]; assert(DMEntry == 0 && "Decl already exists in localdeclmap!"); DMEntry = DeclPtr; |