diff options
author | Carlo Zancanaro <carlo@pc-4w14-0.cs.usyd.edu.au> | 2012-10-15 17:10:06 +1100 |
---|---|---|
committer | Carlo Zancanaro <carlo@pc-4w14-0.cs.usyd.edu.au> | 2012-10-15 17:10:06 +1100 |
commit | be1de4be954c80875ad4108e0a33e8e131b2f2c0 (patch) | |
tree | 1fbbecf276bf7c7bdcbb4dd446099d6d90eaa516 /clang/test/Driver/darwin-verify-debug.c | |
parent | c4626a62754862d20b41e8a46a3574264ea80e6d (diff) | |
parent | f1bd2e48c5324d3f7cda4090c87f8a5b6f463ce2 (diff) |
Merge branch 'master' of ssh://bitbucket.org/czan/honours
Diffstat (limited to 'clang/test/Driver/darwin-verify-debug.c')
-rw-r--r-- | clang/test/Driver/darwin-verify-debug.c | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/clang/test/Driver/darwin-verify-debug.c b/clang/test/Driver/darwin-verify-debug.c new file mode 100644 index 0000000..677419a --- /dev/null +++ b/clang/test/Driver/darwin-verify-debug.c @@ -0,0 +1,34 @@ +// Check that we verify debug output properly with multiple -arch options. +// +// REQUIRES: asserts +// RUN: %clang -target x86_64-apple-darwin10 -ccc-print-phases \ +// RUN: -verify -arch i386 -arch x86_64 %s -g 2> %t +// RUN: FileCheck -check-prefix=CHECK-MULTIARCH-ACTIONS < %t %s +// +// CHECK-MULTIARCH-ACTIONS: 0: input, "{{.*}}darwin-verify-debug.c", c +// CHECK-MULTIARCH-ACTIONS: 8: dsymutil, {7}, dSYM +// CHECK-MULTIARCH-ACTIONS: 9: verify, {8}, none +// +// RUN: %clang -target x86_64-apple-darwin10 -ccc-print-bindings \ +// RUN: -verify -arch i386 -arch x86_64 %s -g 2> %t +// RUN: FileCheck -check-prefix=CHECK-MULTIARCH-BINDINGS < %t %s +// +// CHECK-MULTIARCH-BINDINGS: # "x86_64-apple-darwin10" - "darwin::Dsymutil", inputs: ["a.out"], output: "a.out.dSYM" +// CHECK-MULTIARCH-BINDINGS: # "x86_64-apple-darwin10" - "darwin::VerifyDebug", inputs: ["a.out.dSYM"], output: (nothing) + +// Check output name derivation. +// +// RUN: %clang -target x86_64-apple-darwin10 -ccc-print-bindings \ +// RUN: -verify -o foo %s -g 2> %t +// RUN: FileCheck -check-prefix=CHECK-OUTPUT-NAME < %t %s +// +// CHECK-OUTPUT-NAME: "x86_64-apple-darwin10" - "darwin::Link", inputs: [{{.*}}], output: "foo" +// CHECK-OUTPUT-NAME: "x86_64-apple-darwin10" - "darwin::Dsymutil", inputs: ["foo"], output: "foo.dSYM" +// CHECK-OUTPUT-NAME: "x86_64-apple-darwin10" - "darwin::VerifyDebug", inputs: ["foo.dSYM"], output: (nothing) + +// Check that we only verify when needed. +// +// RUN: touch %t.o +// RUN: %clang -target x86_64-apple-darwin10 -ccc-print-bindings \ +// RUN: -verify -o foo %t.o -g 2> %t +// RUN: grep "Verify" %t | count 0 |