aboutsummaryrefslogtreecommitdiff
path: root/lib/FrontendTool
diff options
context:
space:
mode:
authorAaron Ballman <aaron@aaronballman.com>2018-05-31 13:57:09 +0000
committerAaron Ballman <aaron@aaronballman.com>2018-05-31 13:57:09 +0000
commit87c5cf6ba231d0b09c81f1ff8d1362b5131d6401 (patch)
tree87246583e38a24ea96073fd085676ca9ee9a1e18 /lib/FrontendTool
parente0d354c65c7cddcc7365be534c748c13052fd6db (diff)
Add a new driver mode to dump compiler feature and extension options.
Add the ability to dump compiler option-related information to a JSON file via the -compiler-options-dump option. Specifically, it dumps the features/extensions lists -- however, this output could be extended to other information should it be useful. In order to support features and extensions, I moved them into a .def file so that we could build the various lists we care about from them without a significant increase in maintenance burden. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@333653 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/FrontendTool')
-rw-r--r--lib/FrontendTool/ExecuteCompilerInvocation.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/FrontendTool/ExecuteCompilerInvocation.cpp b/lib/FrontendTool/ExecuteCompilerInvocation.cpp
index 1bb939a6fa..ac2ee50a1e 100644
--- a/lib/FrontendTool/ExecuteCompilerInvocation.cpp
+++ b/lib/FrontendTool/ExecuteCompilerInvocation.cpp
@@ -45,6 +45,8 @@ CreateFrontendBaseAction(CompilerInstance &CI) {
case ASTDump: return llvm::make_unique<ASTDumpAction>();
case ASTPrint: return llvm::make_unique<ASTPrintAction>();
case ASTView: return llvm::make_unique<ASTViewAction>();
+ case DumpCompilerOptions:
+ return llvm::make_unique<DumpCompilerOptionsAction>();
case DumpRawTokens: return llvm::make_unique<DumpRawTokensAction>();
case DumpTokens: return llvm::make_unique<DumpTokensAction>();
case EmitAssembly: return llvm::make_unique<EmitAssemblyAction>();