blob: 73206a5e5f3a98d7a55bf36e7e297216ed9e1744 [file] [log] [blame]
Eric Christopher2ba5fcb2013-02-05 07:29:57 +00001// Check that we split debug output properly
2//
Eric Christopher248357f2013-02-21 22:35:01 +00003// RUN: %clang -target x86_64-unknown-linux-gnu -gsplit-dwarf -c -### %s 2> %t
Eric Christopher2ba5fcb2013-02-05 07:29:57 +00004// RUN: FileCheck -check-prefix=CHECK-ACTIONS < %t %s
5//
Eric Christopher248357f2013-02-21 22:35:01 +00006// CHECK-ACTIONS: objcopy{{.*}}--extract-dwo{{.*}}"split-debug.dwo"
7// CHECK-ACTIONS: objcopy{{.*}}--strip-dwo{{.*}}"split-debug.o"
Eric Christopher2ba5fcb2013-02-05 07:29:57 +00008
Eric Christopher2ba5fcb2013-02-05 07:29:57 +00009
Eric Christopherd42fb732013-02-21 22:35:05 +000010// RUN: %clang -target x86_64-macosx -gsplit-dwarf -c -### %s 2> %t
11// RUN: FileCheck -check-prefix=CHECK-NO-ACTIONS < %t %s
12//
13// CHECK-NO-ACTIONS-NOT: -split-dwarf
Eric Christopher77569ff2013-02-22 01:33:46 +000014
15
16// RUN: %clang -target x86_64-unknown-linux-gnu -gsplit-dwarf -o Bad.x -### %s 2> %t
17// RUN: FileCheck -check-prefix=CHECK-BAD < %t %s
18//
19// CHECK-BAD-NOT: "Bad.dwo"
Eric Christopherd3804002013-02-22 20:12:52 +000020
21// RUN: %clang -target x86_64-unknown-linux-gnu -gsplit-dwarf -c -### %s 2> %t
22// RUN: FileCheck -check-prefix=CHECK-OPTION < %t %s
23//
24// CHECK-OPTION: "-split-dwarf-file" "split-debug.dwo"
Eric Christopher30aa6b62013-06-05 23:58:15 +000025
26// RUN: %clang -target x86_64-unknown-linux-gnu -gsplit-dwarf -S -### %s 2> %t
27// RUN: FileCheck -check-prefix=CHECK-ASM < %t %s
28//
29// CHECK-ASM-NOT: objcopy
30
31// RUN: %clang -target x86_64-unknown-linux-gnu -no-integrated-as -gsplit-dwarf -c -### %s 2> %t
32// RUN: FileCheck -check-prefix=CHECK-IAS < %t %s
33//
34// CHECK-IAS: objcopy
David Blaikiece3e7a62015-07-30 21:42:22 +000035
36// RUN: %clang -target x86_64-unknown-linux-gnu -gsplit-dwarf -gmlt -S -### %s 2> %t
37// RUN: FileCheck -check-prefix=CHECK-GMLT-OVER-SPLIT < %t %s
38//
Douglas Katzman3459ce22015-10-08 04:24:12 +000039// CHECK-GMLT-OVER-SPLIT: "-debug-info-kind=line-tables-only"
David Blaikiece3e7a62015-07-30 21:42:22 +000040// CHECK-GMLT-OVER-SPLIT-NOT: "-split-dwarf=Enable"
41// CHECK-GMLT-OVER-SPLIT-NOT: "-split-dwarf-file"
42
43// RUN: %clang -target x86_64-unknown-linux-gnu -gmlt -gsplit-dwarf -S -### %s 2> %t
44// RUN: FileCheck -check-prefix=CHECK-SPLIT-OVER-GMLT < %t %s
45//
Douglas Katzman3459ce22015-10-08 04:24:12 +000046// CHECK-SPLIT-OVER-GMLT: "-split-dwarf=Enable" "-debug-info-kind=limited"
David Blaikiece3e7a62015-07-30 21:42:22 +000047// CHECK-SPLIT-OVER-GMLT: "-split-dwarf-file"