@@ -222,15 +222,18 @@ define void @subprogram() !dbg !3 {
222222define void @func_loc () !dbg !3 {
223223 ret void
224224}
225- ; CHECK: #[[SP:.+]] = #llvm.di_subprogram<compileUnit = #{{.*}}, scope = #{{.*}}, name = "func_loc", file = #{{.*}}, subprogramFlags = Definition>
226- ; CHECK: loc(fused<#[[SP]]>[
225+ ; CHECK-DAG: #[[NAME_LOC:.+]] = loc("func_loc")
226+ ; CHECK-DAG: #[[FILE_LOC:.+]] = loc("debug-info.ll":42:0)
227+ ; CHECK-DAG: #[[SP:.+]] = #llvm.di_subprogram<compileUnit = #{{.*}}, scope = #{{.*}}, name = "func_loc", file = #{{.*}}, line = 42, subprogramFlags = Definition>
228+
229+ ; CHECK: loc(fused<#[[SP]]>[#[[NAME_LOC]], #[[FILE_LOC]]]
227230
228231!llvm.dbg.cu = !{!1 }
229232!llvm.module.flags = !{!0 }
230233!0 = !{i32 2 , !"Debug Info Version" , i32 3 }
231234!1 = distinct !DICompileUnit (language: DW_LANG_C, file: !2 )
232235!2 = !DIFile (filename: "debug-info.ll" , directory: "/" )
233- !3 = distinct !DISubprogram (name: "func_loc" , scope: !2 , file: !2 , spFlags: DISPFlagDefinition, unit: !1 )
236+ !3 = distinct !DISubprogram (name: "func_loc" , scope: !2 , file: !2 , spFlags: DISPFlagDefinition, unit: !1 , line: 42 )
234237
235238; // -----
236239
@@ -538,7 +541,7 @@ define void @noname_subprogram(ptr %arg) !dbg !8 {
538541; // -----
539542
540543; CHECK: #[[MODULE:.+]] = #llvm.di_module<
541- ; CHECK-SAME: file = #{{.*}}, scope = #{{.*}}, name = "module",
544+ ; CHECK-SAME: file = #{{.*}}, scope = #{{.*}}, name = "module",
542545; CHECK-SAME: configMacros = "bar", includePath = "/",
543546; CHECK-SAME: apinotes = "/", line = 42, isDecl = true
544547; CHECK-SAME: >
0 commit comments