[llvm] 0caeaff - [LiveDebugValues][NFC] Re-land 60db26a66d, add instr-ref tests

Jeremy Morse via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 11 04:15:02 PDT 2020


Author: Jeremy Morse
Date: 2020-09-11T12:14:44+01:00
New Revision: 0caeaff123768020c7b0e1a648d6b6ba67ad6d87

URL: https://github.com/llvm/llvm-project/commit/0caeaff123768020c7b0e1a648d6b6ba67ad6d87
DIFF: https://github.com/llvm/llvm-project/commit/0caeaff123768020c7b0e1a648d6b6ba67ad6d87.diff

LOG: [LiveDebugValues][NFC] Re-land 60db26a66d, add instr-ref tests

This was landed but reverted in 5b9c2b1bea7 due to asan picking up a memory
leak. This is fixed in the change to InstrRefBasedImpl.cpp. Original
commit message follows:

[LiveDebugValues][NFC] Add instr-ref tests, adapt old tests

This patch adds a few tests in DebugInfo/MIR/InstrRef/ of interesting
behaviour that the instruction referencing implementation of
LiveDebugValues has. Mostly, these tests exist to ensure that if you
give the "-experimental-debug-variable-locations" command line switch,
the right implementation runs; and to ensure it behaves the same way as
the VarLoc LiveDebugValues implementation.

I've also touched roughly 30 other tests, purely to make the tests less
rigid about what output to accept. DBG_VALUE instructions are usually
printed with a trailing !debug-location indicating its scope:

  !debug-location !1234

However InstrRefBasedLDV produces new DebugLoc instances on the fly,
meaning there sometimes isn't a numbered node when they're printed,
making the output:

  !debug-location !DILocation(line: 0, blah blah)

Which causes a ton of these tests to fail. This patch removes checks for
that final part of each DBG_VALUE instruction. None of them appear to
be actually checking the scope is correct, just that it's present, so
I don't believe there's any loss in coverage here.

Differential Revision: https://reviews.llvm.org/D83054

Added: 
    

Modified: 
    llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp
    llvm/test/DebugInfo/MIR/Mips/last-inst-bundled.mir
    llvm/test/DebugInfo/MIR/X86/kill-after-spill.mir
    llvm/test/DebugInfo/MIR/X86/live-debug-values-3preds.mir
    llvm/test/DebugInfo/MIR/X86/live-debug-values-bad-transfer.mir
    llvm/test/DebugInfo/MIR/X86/live-debug-values.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues-ignores-metaInstructions.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_clobber.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_move.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_clobber.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_move.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_loop.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_clobbered.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_move_to_clobber.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_break.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond_move.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_two_backedge.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_moved.mir
    llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_outer_moved.mir

Removed: 
    


################################################################################
diff  --git a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp
index cfaec85d3f3d..e39811e33e8c 100644
--- a/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp
+++ b/llvm/lib/CodeGen/LiveDebugValues/InstrRefBasedImpl.cpp
@@ -3114,6 +3114,8 @@ bool InstrRefBasedLDV::ExtendRanges(MachineFunction &MF,
   bool Changed = TTracker->Transfers.size() != 0;
 
   delete MTracker;
+  delete TTracker;
+  MTracker = nullptr;
   VTracker = nullptr;
   TTracker = nullptr;
 

diff  --git a/llvm/test/DebugInfo/MIR/Mips/last-inst-bundled.mir b/llvm/test/DebugInfo/MIR/Mips/last-inst-bundled.mir
index 1187dd433140..ed7360a68da4 100644
--- a/llvm/test/DebugInfo/MIR/Mips/last-inst-bundled.mir
+++ b/llvm/test/DebugInfo/MIR/Mips/last-inst-bundled.mir
@@ -21,7 +21,7 @@
 #
 # Check that last bundled instruction of block gets recognized as end of basic block.
 # CHECK: bb.2.if.end
-# CHECK-NEXT: DBG_VALUE $s0, $noreg, !12, !DIExpression(), debug-location !17
+# CHECK-NEXT: DBG_VALUE $s0, $noreg, !12, !DIExpression()
 
 --- |
   ; ModuleID = '<stdin>'

diff  --git a/llvm/test/DebugInfo/MIR/X86/kill-after-spill.mir b/llvm/test/DebugInfo/MIR/X86/kill-after-spill.mir
index d85be7f6d804..fb5503d7e086 100644
--- a/llvm/test/DebugInfo/MIR/X86/kill-after-spill.mir
+++ b/llvm/test/DebugInfo/MIR/X86/kill-after-spill.mir
@@ -14,8 +14,8 @@
 # ...
 #
 # CHECK: bb.1.if.end:
-# CHECK: DBG_VALUE $rbp, 0, !37, !DIExpression(DW_OP_constu, 44, DW_OP_minus), debug-location !58
-# CHECK-NOT: DBG_VALUE $rbp, 0, !36, !DIExpression(DW_OP_constu, 48, DW_OP_minus), debug-location !57
+# CHECK: DBG_VALUE $rbp, 0, !37, !DIExpression(DW_OP_constu, 44, DW_OP_minus)
+# CHECK-NOT: DBG_VALUE $rbp, 0, !36, !DIExpression(DW_OP_constu, 48, DW_OP_minus)
 
 --- |
   ; ModuleID = '<stdin>'
@@ -283,7 +283,7 @@ body:             |
     $r13 = MOV64rr $rax
     renamable $ecx = XOR32rr undef $ecx, undef $ecx, implicit-def dead $eflags
     renamable $r13 = AND64rr killed renamable $r13, renamable $r14, implicit-def $eflags
-    JCC_1 %bb.9, 4, implicit $eflags
+    JCC_1 %bb.9, 4, implicit $eflags, debug-location !57
 
   bb.1.if.end:
     successors: %bb.2(0x30000000), %bb.3(0x50000000)
@@ -301,7 +301,7 @@ body:             |
     $r12 = MOV64rr $rax
     $r15 = MOV64rr $r12
     renamable $r15 = AND64ri8 killed renamable $r15, -123, implicit-def $eflags
-    JCC_1 %bb.2, 4, implicit $eflags
+    JCC_1 %bb.2, 4, implicit $eflags, debug-location !57
 
   bb.3.private.exit:
     successors: %bb.9(0x30000000), %bb.4(0x50000000)
@@ -316,7 +316,7 @@ body:             |
     CALL64pcrel32 @func4, csr_64, implicit $rsp, implicit $ssp, implicit $rdi, implicit-def $rsp, implicit-def $ssp, implicit-def $eax
     renamable $ecx = MOV32ri 1
     TEST32rr killed renamable $eax, renamable $eax, implicit-def $eflags
-    JCC_1 %bb.9, 4, implicit $eflags
+    JCC_1 %bb.9, 4, implicit $eflags, debug-location !57
 
   bb.4.if.then8:
     successors: %bb.8(0x30000000), %bb.5(0x50000000)
@@ -327,21 +327,21 @@ body:             |
     CALL64pcrel32 @func5, csr_64, implicit $rsp, implicit $ssp, implicit $rdi, implicit $esi, implicit-def $rsp, implicit-def $ssp
     renamable $rax = MOV64rm killed renamable $r13, 1, $noreg, 8, $noreg :: (load 8 from %ir.13)
     TEST64rr renamable $rax, renamable $rax, implicit-def $eflags
-    JCC_1 %bb.8, 4, implicit $eflags
+    JCC_1 %bb.8, 4, implicit $eflags, debug-location !57
 
   bb.5.land.lhs.true:
     successors: %bb.6(0x30000000), %bb.7(0x50000000)
     liveins: $rax, $r12, $r15
 
     CMP32mi8 renamable $r15, 1, $noreg, 0, $noreg, 0, implicit-def $eflags :: (load 4 from %ir.tot_perf2, align 8)
-    JCC_1 %bb.7, 5, implicit $eflags
+    JCC_1 %bb.7, 5, implicit $eflags, debug-location !57
 
   bb.6.lor.lhs.false:
     successors: %bb.8(0x30000000), %bb.7(0x50000000)
     liveins: $rax, $r12, $r15
 
     CMP32mi8 killed renamable $r15, 1, $noreg, 4, $noreg, 0, implicit-def $eflags :: (load 4 from %ir.tot_bw)
-    JCC_1 %bb.8, 4, implicit $eflags
+    JCC_1 %bb.8, 4, implicit $eflags, debug-location !57
 
   bb.7.if.then14:
     successors: %bb.8(0x80000000)
@@ -350,13 +350,13 @@ body:             |
     renamable $rdx = MOV64rm killed renamable $rax, 1, $noreg, 8, $noreg :: (load 8 from %ir.20)
     $rdi = MOV64rr killed $r12
     $esi = MOV32rm $rbp, 1, $noreg, -44, $noreg :: (load 4 from %stack.1)
-    CALL64pcrel32 @func6, csr_64, implicit $rsp, implicit $ssp, implicit $rdi, implicit $esi, implicit $rdx, implicit-def $rsp, implicit-def $ssp
+    CALL64pcrel32 @func6, csr_64, implicit $rsp, implicit $ssp, implicit $rdi, implicit $esi, implicit $rdx, implicit-def $rsp, implicit-def $ssp, debug-location !57
 
   bb.8.cleanup:
     successors: %bb.9(0x80000000)
 
     renamable $ecx = MOV32ri 1
-    JMP_1 %bb.9
+    JMP_1 %bb.9, debug-location !57
 
   bb.2.if.then3:
     successors: %bb.9(0x80000000)
@@ -369,7 +369,7 @@ body:             |
     $edx = MOV32ri 5
     $r8d = MOV32rm $rbp, 1, $noreg, -48, $noreg :: (load 4 from %stack.0)
     CALL64pcrel32 @func3, csr_64, implicit $rsp, implicit $ssp, implicit $edi, implicit $esi, implicit $edx, implicit $rcx, implicit $r8d, implicit-def $rsp, implicit-def $ssp
-    renamable $ecx = XOR32rr undef $ecx, undef $ecx, implicit-def dead $eflags
+    renamable $ecx = XOR32rr undef $ecx, undef $ecx, implicit-def dead $eflags, debug-location !57
 
   bb.9.cleanup:
     liveins: $ecx
@@ -382,6 +382,6 @@ body:             |
     $r14 = POP64r implicit-def $rsp, implicit $rsp
     $r15 = POP64r implicit-def $rsp, implicit $rsp
     $rbp = POP64r implicit-def $rsp, implicit $rsp
-    RETQ $eax
+    RETQ $eax, debug-location !57
 
 ...

diff  --git a/llvm/test/DebugInfo/MIR/X86/live-debug-values-3preds.mir b/llvm/test/DebugInfo/MIR/X86/live-debug-values-3preds.mir
index c55269951aa5..bef0f4e4aa5a 100644
--- a/llvm/test/DebugInfo/MIR/X86/live-debug-values-3preds.mir
+++ b/llvm/test/DebugInfo/MIR/X86/live-debug-values-3preds.mir
@@ -31,9 +31,9 @@
 # DBG_VALUE for variables "x", "y" and "z" are extended into %bb.9 from its
 # predecessors %bb.0, %bb.2 and %bb.8.
 # CHECK:      bb.9.for.end:
-# CHECK-DAG:  DBG_VALUE $edi, $noreg, ![[X_VAR]], !DIExpression(), debug-location !{{[0-9]+}}
-# CHECK-DAG:  DBG_VALUE $esi, $noreg, ![[Y_VAR]], !DIExpression(), debug-location !{{[0-9]+}}
-# CHECK-DAG:  DBG_VALUE $edx, $noreg, ![[Z_VAR]], !DIExpression(), debug-location !{{[0-9]+}}
+# CHECK-DAG:  DBG_VALUE $edi, $noreg, ![[X_VAR]], !DIExpression()
+# CHECK-DAG:  DBG_VALUE $esi, $noreg, ![[Y_VAR]], !DIExpression()
+# CHECK-DAG:  DBG_VALUE $edx, $noreg, ![[Z_VAR]], !DIExpression()
 # CHECK:      RET
 
 --- |

diff  --git a/llvm/test/DebugInfo/MIR/X86/live-debug-values-bad-transfer.mir b/llvm/test/DebugInfo/MIR/X86/live-debug-values-bad-transfer.mir
index 1d978b9c4553..97fad0755b80 100644
--- a/llvm/test/DebugInfo/MIR/X86/live-debug-values-bad-transfer.mir
+++ b/llvm/test/DebugInfo/MIR/X86/live-debug-values-bad-transfer.mir
@@ -1,4 +1,5 @@
 # RUN: llc %s -mtriple=x86_64-unknown-unknown -o - -run-pass=livedebugvalues | FileCheck %s --implicit-check-not=DBG_VALUE
+# RUN: llc %s -mtriple=x86_64-unknown-unknown -o - -run-pass=livedebugvalues -experimental-debug-variable-locations | FileCheck %s -check-prefix=NEWLDV --implicit-check-not=DBG_VALUE
 #
 # Test that the DBG_VALUE of ecx below does not get propagated. It is considered
 # live-in on LiveDebugValues' first pass through the loop, but on the second it
@@ -17,6 +18,13 @@
 # CHECK-LABEL: bb.1.loop:
 # CHECK:       $ebx = COPY killed $ecx
 # CHECK-NEXT:  DBG_VALUE
+#
+# This doesn't occur under value-tracking LiveDebugValues though.
+#
+# NEWLDV-LABEL: name: foo
+# NEWLDV-LABEL: bb.0.entry:
+# NEWLDV:       $ecx = MOV32ri 0
+# NEWLDV-NEXT:  DBG_VALUE
 
 --- |
   source_filename = "live-debug-values-remove-range.ll"
@@ -74,30 +82,30 @@ body:             |
     CFI_INSTRUCTION def_cfa_offset 16
     CFI_INSTRUCTION offset $rbx, -16
     $ebx = MOV32rr $edi
-    $eax = MOV32ri 0
-    $ecx = MOV32ri 0
+    $eax = MOV32ri 0, debug-location !10
+    $ecx = MOV32ri 0, debug-location !10
     DBG_VALUE $ecx, $noreg, !9, !DIExpression(), debug-location !10
-    $edi = MOV32ri 0
-    $esi = MOV32ri 0
+    $edi = MOV32ri 0, debug-location !10
+    $esi = MOV32ri 0, debug-location !10
   
   bb.1.loop:
     successors: %bb.1, %bb.2
     liveins: $ebx, $eax, $ecx, $edi, $esi
   
-    $eax = COPY $ecx
-    $ebx = COPY killed $ecx
-    $ecx = COPY killed $edi
-    $edi = COPY killed $esi
-    $esi = MOV32ri 1
+    $eax = COPY $ecx, debug-location !10
+    $ebx = COPY killed $ecx, debug-location !10
+    $ecx = COPY killed $edi, debug-location !10
+    $edi = COPY killed $esi, debug-location !10
+    $esi = MOV32ri 1, debug-location !10
     TEST8ri killed renamable $al, 1, implicit-def $eflags
-    JCC_1 %bb.1, 5, implicit killed $eflags
+    JCC_1 %bb.1, 5, implicit killed $eflags, debug-location !10
   
   bb.2.exit:
     liveins: $ebx
   
-    $eax = MOV32rr killed $ebx
+    $eax = MOV32rr killed $ebx, debug-location !10
     $rbx = frame-destroy POP64r implicit-def $rsp, implicit $rsp
     CFI_INSTRUCTION def_cfa_offset 8
-    RETQ $eax
+    RETQ $eax, debug-location !10
 
 ...

diff  --git a/llvm/test/DebugInfo/MIR/X86/live-debug-values.mir b/llvm/test/DebugInfo/MIR/X86/live-debug-values.mir
index 2cf52611bafd..2731eac26ecd 100644
--- a/llvm/test/DebugInfo/MIR/X86/live-debug-values.mir
+++ b/llvm/test/DebugInfo/MIR/X86/live-debug-values.mir
@@ -35,7 +35,7 @@
 # CHECK: ![[N_VAR:[0-9]+]] = !DILocalVariable(name: "n",{{.*}})
 #
 # CHECK:      bb.5.if.end.7:
-# CHECK:        DBG_VALUE $ebx, $noreg, ![[N_VAR]], !DIExpression(), debug-location !{{[0-9]+}}
+# CHECK:        DBG_VALUE $ebx, $noreg, ![[N_VAR]], !DIExpression()
 
 
 --- |

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues-ignores-metaInstructions.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues-ignores-metaInstructions.mir
index e8c3a994e59d..89c7d55d95c6 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues-ignores-metaInstructions.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues-ignores-metaInstructions.mir
@@ -6,11 +6,11 @@
   ; CHECK-LABEL: bb.0.entry:
   ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond.mir
index 4004199ad048..89b4ac63e08a 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond.mir
@@ -5,13 +5,13 @@
   ; a diamond that doesn't move or clobber their locations.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_clobber.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_clobber.mir
index 063b7f450e08..bd6dacc2fed1 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_clobber.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_clobber.mir
@@ -5,12 +5,12 @@
   ; a diamond when the location is clobbered and not into the successor block.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-NEXT:  $ebx = MOV32ri 0, debug-location !17
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-NEXT:  $ebx = MOV32ri 0, debug-location !17
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_move.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_move.mir
index 8e530c89db62..05a1955532aa 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_move.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_match_move.mir
@@ -5,17 +5,17 @@
   ; diamond CFG when the location is moved by another instruction.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-NEXT:  $eax = MOV32ri 0, debug-location !17
-  ; CHECK-NEXT:  DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK-NEXT:  DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-NEXT:  $eax = MOV32ri 0, debug-location !17
-  ; CHECK-NEXT:  DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK-NEXT:  DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_clobber.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_clobber.mir
index a89546800a21..ee843492c7b9 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_clobber.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_clobber.mir
@@ -5,11 +5,11 @@
   ; of a diamond CFG that clobbers its location.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_move.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_move.mir
index 4b9b70455407..fe3924bf846a 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_move.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_diamond_one_move.mir
@@ -5,13 +5,13 @@
   ; of a diamond CFG that moves its location.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-NEXT:  $eax = MOV32ri 0, debug-location !17
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_loop.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_loop.mir
index ba2d31ea0b46..d7eb4bd48ab3 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_loop.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_basic_loop.mir
@@ -5,13 +5,13 @@
   ; loop that doesn't move or clobber its location.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb.mir
index 2801df4832e3..f48940a24861 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb.mir
@@ -5,13 +5,13 @@
   ; sequential CFG.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_clobbered.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_clobbered.mir
index d1cacff032e1..f969179b76a7 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_clobbered.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_clobbered.mir
@@ -5,9 +5,9 @@
   ; control flow when it's location is clobbered.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_move_to_clobber.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_move_to_clobber.mir
index c1cb8d5daa95..339d21380fa6 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_move_to_clobber.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_bb_to_bb_move_to_clobber.mir
@@ -5,13 +5,13 @@
   ; no control flow when a location is moved and then clobbered.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-NEXT:  $eax = MOV32ri 0, debug-location !17
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_break.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_break.mir
index 7860517adaf0..0d9cc1905134 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_break.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_break.mir
@@ -5,15 +5,15 @@
   ; break.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.4.bb4:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond.mir
index 9854e05e20dc..1e410054dc1c 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond.mir
@@ -5,17 +5,17 @@
   ; diamond pattern and beyond.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.4.bb4:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.5.bb5:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond_move.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond_move.mir
index ed7bdcffd881..7861e7dfa9c6 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond_move.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_diamond_move.mir
@@ -5,17 +5,17 @@
   ; diamond pattern but not beyond.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.4.bb4:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.5.bb5:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_two_backedge.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_two_backedge.mir
index 0989ee335b08..83f723555894 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_two_backedge.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_two_backedge.mir
@@ -5,15 +5,15 @@
   ; backedges and beyond.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.4.bb4:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop.mir
index f15275ed60a9..7ff781a07fce 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop.mir
@@ -4,17 +4,17 @@
   ; Check that DBG_VALUE instructions are propagated into loops within loops.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.1.bb1:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.2.bb2:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.4.bb4:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.5.bb5:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_moved.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_moved.mir
index da624928c3aa..fca7f83a14be 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_moved.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_moved.mir
@@ -5,9 +5,9 @@
   ; loops that move their locations.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.3.bb3:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:

diff  --git a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_outer_moved.mir b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_outer_moved.mir
index 12f22df63b14..baade395c6ed 100644
--- a/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_outer_moved.mir
+++ b/llvm/test/DebugInfo/MIR/X86/livedebugvalues_loop_within_loop_outer_moved.mir
@@ -5,11 +5,11 @@
   ; loops that move their locations.
 
   ; CHECK-LABEL: bb.0.entry:
-  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $ebx, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.4.bb4:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
   ; CHECK-LABEL: bb.5.bb5:
-  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression(), debug-location !17
+  ; CHECK:       DBG_VALUE $eax, $noreg, !16, !DIExpression()
 
   define i32 @_Z8bb_to_bb() local_unnamed_addr !dbg !12 {
   entry:


        


More information about the llvm-commits mailing list