aboutsummaryrefslogtreecommitdiff
path: root/include/clang/Frontend/CodeGenOptions.h
diff options
context:
space:
mode:
authorJohn McCall <rjmccall@apple.com>2010-07-06 23:57:41 +0000
committerJohn McCall <rjmccall@apple.com>2010-07-06 23:57:41 +0000
commit744016dde06fcffd50931e94a98c850f8b12cd87 (patch)
tree38c46bdfb9534bcbfc5a32e27e8c09de3a525b2d /include/clang/Frontend/CodeGenOptions.h
parent0ea0e8b4028db1e3c196025354dcddb8765f73bc (diff)
Provide a hook for the benefit of clients using clang IR gen as a subroutine:
emit metadata associating allocas and global values with a Decl*. This feature is controlled by an option that (intentionally) cannot be enabled on the command line. To use this feature, simply set CodeGenOptions.EmitDeclMetadata = true; and then interpret the completely underspecified metadata. :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107739 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/clang/Frontend/CodeGenOptions.h')
-rw-r--r--include/clang/Frontend/CodeGenOptions.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/clang/Frontend/CodeGenOptions.h b/include/clang/Frontend/CodeGenOptions.h
index c25cfb32e6..2918f4e9d3 100644
--- a/include/clang/Frontend/CodeGenOptions.h
+++ b/include/clang/Frontend/CodeGenOptions.h
@@ -67,6 +67,9 @@ public:
unsigned UnwindTables : 1; /// Emit unwind tables.
unsigned VerifyModule : 1; /// Control whether the module should be run
/// through the LLVM Verifier.
+ unsigned EmitDeclMetadata : 1; /// Emit special metadata indicating what Decl*
+ /// various IR entities came from. Only useful
+ /// when running CodeGen as a subroutine.
/// The code model to use (-mcmodel).
std::string CodeModel;
@@ -122,6 +125,7 @@ public:
UnrollLoops = 0;
UnwindTables = 0;
VerifyModule = 1;
+ EmitDeclMetadata = 0;
Inlining = NoInlining;
RelocationModel = "pic";