aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/CodeGenModule.h
diff options
context:
space:
mode:
authorAnders Carlsson <andersca@mac.com>2009-02-12 17:55:02 +0000
committerAnders Carlsson <andersca@mac.com>2009-02-12 17:55:02 +0000
commitd5cab5435371b8cc74a9e05ebd40b5995ebad149 (patch)
treee8c27f453388860fb7126260764ca9f730c6053b /lib/CodeGen/CodeGenModule.h
parenta30b17b90033f40bb909d630466c2a04499b7bf0 (diff)
Add a very basic implemenation of global blocks. This needs to be cleaned up.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64387 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CodeGenModule.h')
-rw-r--r--lib/CodeGen/CodeGenModule.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/CodeGen/CodeGenModule.h b/lib/CodeGen/CodeGenModule.h
index bedefcaa3f..0c3964fd5f 100644
--- a/lib/CodeGen/CodeGenModule.h
+++ b/lib/CodeGen/CodeGenModule.h
@@ -40,6 +40,7 @@ namespace clang {
class ObjCImplementationDecl;
class ObjCCategoryImplDecl;
class ObjCProtocolDecl;
+ class BlockExpr;
class Decl;
class Expr;
class Stmt;
@@ -121,6 +122,10 @@ class CodeGenModule {
/// Obj-C class pointer.
llvm::Constant *CFConstantStringClassRef;
+ /// NSConcreteGlobalBlock - Cached reference to the clas pointer for
+ /// global blocks.
+ llvm::Constant *NSConcreteGlobalBlock;
+
std::vector<llvm::Function *> BuiltinFunctions;
public:
CodeGenModule(ASTContext &C, const LangOptions &Features, llvm::Module &M,
@@ -196,6 +201,8 @@ public:
llvm::Constant *GetAddrOfConstantCString(const std::string &str,
const char *GlobalName=0);
+ llvm::Constant *GetAddrOfGlobalBlock(const BlockExpr *BE);
+
/// getBuiltinLibFunction - Given a builtin id for a function like
/// "__builtin_fabsf", return a Function* for "fabsf".
llvm::Function *getBuiltinLibFunction(unsigned BuiltinID);