| # RUN: llc -mtriple=hexagon -run-pass=hexagon-nvj -verify-machineinstrs \ | |
| # RUN: -o - %s | FileCheck %s | |
| # A debug value that reads the feeder's register between the feeder and the | |
| # compare must not prevent the new value jump. The value is set undef where it | |
| # was, and the feeder stays adjacent to the jump. | |
| # CHECK: DBG_VALUE $noreg, $noreg, !{{[0-9]+}} | |
| # CHECK-NEXT: $r2 = S4_subaddi $r1, 1, killed $r2 | |
| # CHECK-NEXT: $r3 = A2_tfrsi 2 | |
| # CHECK-NEXT: J4_cmpgtu_t_jumpnv_t killed $r3, killed $r1, %bb.1, implicit-def $pc | |
| # CHECK-NOT: DBG_VALUE | |
| --- | | |
| define void @fred() !dbg !5 { | |
| entry: | |
| ret void, !dbg !11 | |
| } | |
| !llvm.dbg.cu = !{!0} | |
| !llvm.module.flags = !{!4} | |
| !0 = distinct !DICompileUnit(language: DW_LANG_C, file: !1, | |
| producer: "llvm", isOptimized: true, runtimeVersion: 0, | |
| emissionKind: FullDebug) | |
| !1 = !DIFile(filename: "newvaluejump-debug-use.mir", directory: "/") | |
| !4 = !{i32 2, !"Debug Info Version", i32 3} | |
| !5 = distinct !DISubprogram(name: "fred", linkageName: "fred", scope: null, | |
| file: !1, line: 1, type: !6, scopeLine: 1, | |
| spFlags: DISPFlagDefinition | DISPFlagOptimized, unit: !0) | |
| !6 = !DISubroutineType(types: !7) | |
| !7 = !{} | |
| !9 = !DILocalVariable(name: "x", scope: !5, file: !1, line: 1, type: !10) | |
| !10 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed) | |
| !11 = !DILocation(line: 1, column: 1, scope: !5) | |
| ... | |
| --- | |
| name: fred | |
| noVRegs: true | |
| body: | | |
| bb.0: | |
| successors: %bb.1(0x80000000) | |
| liveins: $r0, $r2 | |
| $r1 = A2_addi $r0, -1 | |
| $r3 = A2_tfrsi 2 | |
| DBG_VALUE $r3, $noreg, !9, !DIExpression(), debug-location !11 | |
| $p0 = C2_cmpgtu killed $r3, $r1 | |
| $r2 = S4_subaddi killed $r1, 1, killed $r2 | |
| J2_jumpt killed $p0, %bb.1, implicit-def $pc | |
| bb.1: | |
| ... |