1 ; RUN: llc < %s -mtriple=nvptx64-nvidia-cuda | FileCheck --check-prefix=CHECK-NODIR %s
2 ; RUN: llc < %s -mtriple=nvptx64-nvidia-cuda -dwarf-directory=1 | FileCheck --check-prefix=CHECK-DIR %s
3 ; RUN: %if ptxas %{ llc < %s -mtriple=nvptx64-nvidia-cuda | %ptxas-verify %}
5 ; CHECK-NODIR: .file {{[0-9]+}} "/tmp/dbginfo/a{{/|\\\\}}a.cpp"
7 ; ptxas does not support .file directory syntax, but it can still be
8 ; forced by -dwarf-directory=1
9 ; CHECK-DIR: .file {{[0-9]+}} "/tmp/dbginfo/a" "a.cpp"
11 define void @_Z4funcv() !dbg !4 {
17 !llvm.module.flags = !{!8, !9}
19 !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5.0 ", isOptimized: false, emissionKind: FullDebug, file: !1, enums: !2, retainedTypes: !2, globals: !2, imports: !2, nameTableKind: None)
20 !1 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo/a")
22 !4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 1, file: !1, scope: !1, type: !6, retainedNodes: !2)
23 !5 = !DILocation(line: 2, scope: !4)
24 !6 = !DISubroutineType(types: !7)
26 !8 = !{i32 2, !"Dwarf Version", i32 4}
27 !9 = !{i32 1, !"Debug Info Version", i32 3}