diff options
author | Anders Carlsson <andersca@mac.com> | 2009-02-07 22:53:43 +0000 |
---|---|---|
committer | Anders Carlsson <andersca@mac.com> | 2009-02-07 22:53:43 +0000 |
commit | 15cb75a20c044f3c444fbbcb70857c29f9297cb2 (patch) | |
tree | f4098d0c57dc873c04d9f894d971a272f9bd096a /clang/lib/CodeGen/CodeGenFunction.cpp | |
parent | 0aadcd4179193fd0e89e3376ff84235eeed503c9 (diff) | |
download | bcm5719-llvm-15cb75a20c044f3c444fbbcb70857c29f9297cb2.tar.gz bcm5719-llvm-15cb75a20c044f3c444fbbcb70857c29f9297cb2.zip |
Add plumbing for the cleanup stack.
llvm-svn: 64043
Diffstat (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp')
-rw-r--r-- | clang/lib/CodeGen/CodeGenFunction.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/CodeGenFunction.cpp b/clang/lib/CodeGen/CodeGenFunction.cpp index f5a802f0b74..4ba4d600f86 100644 --- a/clang/lib/CodeGen/CodeGenFunction.cpp +++ b/clang/lib/CodeGen/CodeGenFunction.cpp @@ -512,3 +512,12 @@ llvm::Value* CodeGenFunction::EmitVAListRef(const Expr* E) { } return EmitLValue(E).getAddress(); } + +llvm::BasicBlock *CodeGenFunction::CreateCleanupBlock() +{ + llvm::BasicBlock *CleanupBlock = createBasicBlock("cleanup"); + + CleanupEntries.push_back(CleanupEntry(CleanupBlock)); + + return CleanupBlock; +} |