[clang] 64bc627 - clang-cl: Parse new MSVC flags /Qspectre-load and /Qspectre-load-cf

Hans Wennborg via cfe-commits cfe-commits at lists.llvm.org
Fri Feb 7 04:01:04 PST 2020


Author: Hans Wennborg
Date: 2020-02-07T13:00:52+01:00
New Revision: 64bc627b8878dd77fc3a85007e2ced0a515c77d3

URL: https://github.com/llvm/llvm-project/commit/64bc627b8878dd77fc3a85007e2ced0a515c77d3
DIFF: https://github.com/llvm/llvm-project/commit/64bc627b8878dd77fc3a85007e2ced0a515c77d3.diff

LOG: clang-cl: Parse new MSVC flags /Qspectre-load and /Qspectre-load-cf

See https://github.com/MicrosoftDocs/cpp-docs/commit/2fdf0ba0bf8d3875c754776ca1084654135cb710

Added: 
    

Modified: 
    clang/include/clang/Driver/CLCompatOptions.td
    clang/test/Driver/cl-options.c

Removed: 
    


################################################################################
diff  --git a/clang/include/clang/Driver/CLCompatOptions.td b/clang/include/clang/Driver/CLCompatOptions.td
index 90be1d3f3c04..561746d931ed 100644
--- a/clang/include/clang/Driver/CLCompatOptions.td
+++ b/clang/include/clang/Driver/CLCompatOptions.td
@@ -452,6 +452,8 @@ def _SLASH_Qpar : CLFlag<"Qpar">;
 def _SLASH_Qpar_report : CLJoined<"Qpar-report">;
 def _SLASH_Qsafe_fp_loads : CLFlag<"Qsafe_fp_loads">;
 def _SLASH_Qspectre : CLFlag<"Qspectre">;
+def _SLASH_Qspectre_load : CLFlag<"Qspectre-load">;
+def _SLASH_Qspectre_load_cf : CLFlag<"Qspectre-load-cf">;
 def _SLASH_Qvec_report : CLJoined<"Qvec-report">;
 def _SLASH_u : CLFlag<"u">;
 def _SLASH_V : CLFlag<"V">;

diff  --git a/clang/test/Driver/cl-options.c b/clang/test/Driver/cl-options.c
index b5dd667943d2..f230caa936be 100644
--- a/clang/test/Driver/cl-options.c
+++ b/clang/test/Driver/cl-options.c
@@ -464,6 +464,8 @@
 // RUN:     /Qpar-report:1 \
 // RUN:     /Qsafe_fp_loads \
 // RUN:     /Qspectre \
+// RUN:     /Qspectre-load \
+// RUN:     /Qspectre-load-cf \
 // RUN:     /Qvec-report:2 \
 // RUN:     /u \
 // RUN:     /V \


        


More information about the cfe-commits mailing list