[ARM][CMSE] Add commandline option and feature macro
authorJaved Absar <javed.absar@arm.com>
Tue, 21 May 2019 14:21:26 +0000 (14:21 +0000)
committerJaved Absar <javed.absar@arm.com>
Tue, 21 May 2019 14:21:26 +0000 (14:21 +0000)
commit603a2bac05a8be513536c3742a6531fcf02888ed
treef9fd79a0ca466dd01b051658102092b24ea109e3
parente289e988378120e1a6f628f29745816b25e9c33f
[ARM][CMSE] Add commandline option and feature macro

Defines macro ARM_FEATURE_CMSE to 1 for v8-M targets and introduces
-mcmse option which for v8-M targets sets ARM_FEATURE_CMSE to 3.
A diagnostic is produced when the option is given on architectures
without support for Security Extensions.
Reviewed By: dmgreen, snidertm
Differential Revision: https://reviews.llvm.org/D59879

llvm-svn: 361261
clang/include/clang/Basic/Attr.td
clang/include/clang/Basic/DiagnosticCommonKinds.td
clang/include/clang/Basic/LangOptions.def
clang/include/clang/Driver/Options.td
clang/lib/Basic/Targets/ARM.cpp
clang/lib/Driver/ToolChains/Arch/ARM.cpp
clang/lib/Driver/ToolChains/Clang.cpp
clang/lib/Frontend/CompilerInvocation.cpp
clang/test/Preprocessor/arm-target-features.c