From 7e937c42267622eb85d09c953b2a61ec9e3de3d0 Mon Sep 17 00:00:00 2001 From: Reid Kleckner Date: Fri, 16 Nov 2018 23:17:11 +0000 Subject: [PATCH] Add missing test for r347072 -gcodeview-ghash llvm-svn: 347111 --- clang/test/Driver/gcodeview-ghash.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 clang/test/Driver/gcodeview-ghash.c diff --git a/clang/test/Driver/gcodeview-ghash.c b/clang/test/Driver/gcodeview-ghash.c new file mode 100644 index 000000000000..c45c8296604e --- /dev/null +++ b/clang/test/Driver/gcodeview-ghash.c @@ -0,0 +1,19 @@ +// Note: %s must be preceded by --, otherwise it may be interpreted as a +// command-line option, e.g. on Mac where %s is commonly under /Users. + +// GHASH: "-gcodeview-ghash" +// NO_GHASH-NOT: "-gcodeview-ghash" + +// default +// RUN: %clang_cl /Z7 -### -- %s 2>&1 | FileCheck -check-prefix=NO_GHASH %s +// enabled +// RUN: %clang_cl /Z7 -gcodeview-ghash -### -- %s 2>&1 | FileCheck -check-prefix=GHASH %s +// disabled +// RUN: %clang_cl /Z7 -gcodeview-ghash -gno-codeview-ghash -### -- %s 2>&1 | FileCheck -check-prefix=NO_GHASH %s + +// enabled, no /Z7 +// RUN: %clang_cl -gcodeview-ghash -### -- %s 2>&1 | FileCheck -check-prefix=NO_GHASH %s + +// GCC-style driver +// RUN: %clang -g -gcodeview -gcodeview-ghash -### -- %s 2>&1 | FileCheck -check-prefix=GHASH %s +// RUN: %clang -g -gcodeview -gcodeview-ghash -gno-codeview-ghash -### -- %s 2>&1 | FileCheck -check-prefix=NO_GHASH %s