diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2010-06-07 19:39:39 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2010-06-07 19:39:39 +0000 |
commit | a2d7c34e93ad7e33af3e9a9052b7530f697fbc67 (patch) | |
tree | 4820f388aeb2f4078da117141a318603cccaa7e5 /clang/lib/CodeGen/CGBlocks.cpp | |
parent | ebf2e977cf45e4d338d45fdaeae91cee12117377 (diff) | |
download | bcm5719-llvm-a2d7c34e93ad7e33af3e9a9052b7530f697fbc67.tar.gz bcm5719-llvm-a2d7c34e93ad7e33af3e9a9052b7530f697fbc67.zip |
Fixed a block regression caused by trying to use
an existing ir for load of a bock variable. This cannot be
done across basic blocks.
Fixes radar 8064140.
llvm-svn: 105549
Diffstat (limited to 'clang/lib/CodeGen/CGBlocks.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGBlocks.cpp | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/clang/lib/CodeGen/CGBlocks.cpp b/clang/lib/CodeGen/CGBlocks.cpp index f789787b616..b2d7f2e81d4 100644 --- a/clang/lib/CodeGen/CGBlocks.cpp +++ b/clang/lib/CodeGen/CGBlocks.cpp @@ -612,9 +612,6 @@ void CodeGenFunction::AllocateBlockDecl(const BlockDeclRefExpr *E) { llvm::Value *CodeGenFunction::GetAddrOfBlockDecl(const ValueDecl *VD, bool IsByRef) { - llvm::Value *&VE = BlockDeclsValue[VD]; - if (VE) - return VE; CharUnits offset = BlockDecls[VD]; assert(!offset.isZero() && "getting address of unallocated decl"); @@ -648,7 +645,6 @@ llvm::Value *CodeGenFunction::GetAddrOfBlockDecl(const ValueDecl *VD, if (VD->getType()->isReferenceType()) V = Builder.CreateLoad(V, "ref.tmp"); } - VE = V; return V; } |