]> granicus.if.org Git - clang/commit
Add a new driver mode to dump compiler feature and extension options.
authorAaron Ballman <aaron@aaronballman.com>
Thu, 31 May 2018 13:57:09 +0000 (13:57 +0000)
committerAaron Ballman <aaron@aaronballman.com>
Thu, 31 May 2018 13:57:09 +0000 (13:57 +0000)
commit87c5cf6ba231d0b09c81f1ff8d1362b5131d6401
tree87246583e38a24ea96073fd085676ca9ee9a1e18
parente0d354c65c7cddcc7365be534c748c13052fd6db
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
include/clang/Basic/Features.def [new file with mode: 0644]
include/clang/Driver/CC1Options.td
include/clang/Frontend/FrontendActions.h
include/clang/Frontend/FrontendOptions.h
lib/Frontend/CompilerInvocation.cpp
lib/Frontend/FrontendActions.cpp
lib/FrontendTool/ExecuteCompilerInvocation.cpp
lib/Lex/PPMacroExpansion.cpp
test/Frontend/compiler-options-dump.cpp [new file with mode: 0644]