1 ; RUN: llc -mcpu=core2 -mtriple=i686-pc-win32 -O0 < %s | FileCheck --check-prefix=X86 %s
3 ; This LL file was generated by running clang on the following code:
7 ; 3 static void bar(int arg, ...) {
15 ; The bar function happens to have no lexical scopes, yet it has one instruction
16 ; with debug information available. This used to be PR19239.
18 ; X86-LABEL: {{^}}"?bar@@YAXHZZ":
21 ; X86-NEXT: [[JMP_LINE:^L.*]]:{{$}}
22 ; X86: jmp "?foo@@YAXXZ"
23 ; X86-NEXT: [[END_OF_BAR:^L.*]]:{{$}}
26 ; X86-LABEL: .section .debug$S,"dr"
27 ; X86: .secrel32 "?bar@@YAXHZZ"
28 ; X86-NEXT: .secidx "?bar@@YAXHZZ"
31 ; X86-NEXT: .long {{.*}}
32 ; X86-NEXT: .long [[JMP_LINE]]-"?bar@@YAXHZZ"
35 ; X86-LABEL: .long 244
37 ; ModuleID = 'test.cpp'
38 target datalayout = "e-m:w-p:32:32-i64:64-f80:32-n8:16:32-S32"
39 target triple = "i686-pc-win32"
41 ; Function Attrs: nounwind
42 define void @"\01?spam@@YAXXZ"() #0 {
44 tail call void @"\01?bar@@YAXHZZ"(), !dbg !11
48 ; Function Attrs: nounwind
49 define internal void @"\01?bar@@YAXHZZ"() #0 {
51 tail call void @"\01?foo@@YAXXZ"() #2, !dbg !13
55 declare void @"\01?foo@@YAXXZ"() #1
57 attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "no-realign-stack" "stack-protector-buffer-size"="8" "unsafe-fp-math"="false" "use-soft-float"="false" }
58 attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "no-realign-stack" "stack-protector-buffer-size"="8" "unsafe-fp-math"="false" "use-soft-float"="false" }
59 attributes #2 = { nounwind }
62 !llvm.module.flags = !{!8, !9}
65 !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5.0 ", isOptimized: true, emissionKind: 2, file: !1, enums: !2, retainedTypes: !2, subprograms: !3, globals: !2, imports: !2)
66 !1 = !DIFile(filename: "test.cpp", directory: "D:\5C")
69 !4 = distinct !DISubprogram(name: "spam", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !1, scope: !5, type: !6, function: void ()* @"\01?spam@@YAXXZ", variables: !2)
70 !5 = !DIFile(filename: "test.cpp", directory: "D:C")
71 !6 = !DISubroutineType(types: !2)
72 !7 = distinct !DISubprogram(name: "bar", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2)
73 !8 = !{i32 2, !"CodeView", i32 1}
74 !9 = !{i32 1, !"Debug Info Version", i32 3}
75 !10 = !{!"clang version 3.5.0 "}
76 !11 = !DILocation(line: 8, scope: !4)
77 !12 = !DILocation(line: 9, scope: !4)
78 !13 = !DILocation(line: 4, scope: !7)
79 !14 = !DILocation(line: 5, scope: !7)