summaryrefslogtreecommitdiffstats
path: root/test/Driver/cl-options.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Driver/cl-options.c')
-rw-r--r--test/Driver/cl-options.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/Driver/cl-options.c b/test/Driver/cl-options.c
index 9aa6ced349..eb606afed8 100644
--- a/test/Driver/cl-options.c
+++ b/test/Driver/cl-options.c
@@ -600,5 +600,19 @@
// RUN: --version \
// RUN: -Werror /Zs -- %s 2>&1
+// Accept clang options under the /clang: flag.
+// The first test case ensures that the SLP vectorizer is on by default and that
+// it's being turned off by the /clang:-fno-slp-vectorize flag.
+
+// RUN: %clang_cl -O2 -### -- %s 2>&1 | FileCheck -check-prefix=NOCLANG %s
+// NOCLANG: "--dependent-lib=libcmt"
+// NOCLANG-SAME: "-vectorize-slp"
+// NOCLANG-NOT: "--dependent-lib=msvcrt"
+
+// RUN: %clang_cl -O2 -MD /clang:-fno-slp-vectorize /clang:-MD /clang:-MF /clang:my_dependency_file.dep -### -- %s 2>&1 | FileCheck -check-prefix=CLANG %s
+// CLANG: "--dependent-lib=msvcrt"
+// CLANG-SAME: "-dependency-file" "my_dependency_file.dep"
+// CLANG-NOT: "--dependent-lib=libcmt"
+// CLANG-NOT: "-vectorize-slp"
void f() { }