summaryrefslogtreecommitdiffstats
path: root/clang/test
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test')
-rw-r--r--clang/test/Driver/emit-llvm.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/test/Driver/emit-llvm.c b/clang/test/Driver/emit-llvm.c
index e0cc0b5dc21..3439b58d85d 100644
--- a/clang/test/Driver/emit-llvm.c
+++ b/clang/test/Driver/emit-llvm.c
@@ -1,3 +1,13 @@
// RUN: not %clang -ccc-host-triple i386-pc-linux-gnu -emit-llvm -o %t %s 2> %t.log
// RUN: grep 'unable to pass LLVM bit-code files to linker' %t.log
+// Check that -O4 is only honored as the effective -O option.
+// <rdar://problem/7046672> clang/loader problem
+
+// RUN: %clang -ccc-print-phases -c -O4 -O0 %s 2> %t
+// RUN: FileCheck --check-prefix=O4_AND_O0 %s < %t
+
+// O4_AND_O0: 0: input, "{{.*}}", c
+// O4_AND_O0: 1: preprocessor, {0}, cpp-output
+// O4_AND_O0: 2: compiler, {1}, assembler
+// O4_AND_O0: 3: assembler, {2}, object
OpenPOWER on IntegriCloud