Please use GitHub pull requests for new patches. Avoid migrating existing patches. Phabricator shutdown timeline
Changeset View
Changeset View
Standalone View
Standalone View
llvm/test/DebugInfo/X86/live-debug-values-remove-range.ll
; RUN: llc -mtriple=x86_64-unknown-unknown %s -o - -stop-after=livedebugvalues -experimental-debug-variable-locations=false | FileCheck %s | ; RUN: llc -mtriple=x86_64-unknown-unknown %s -o - -stop-after=livedebugvalues -experimental-debug-variable-locations=true | FileCheck %s | ||||
; | ; | ||||
; In the simple loop below, the location of the variable "toast" is %bar in | ; In the simple loop below, the location of the variable "toast" is %bar in | ||||
; the entry block, then set to constant zero at the end of the loop. We cannot | ; the entry block, then set to constant zero at the end of the loop. We cannot | ||||
; know the location of "toast" at the start of the %loop block. Test that no | ; know the location of "toast" at the start of the %loop block. Test that no | ||||
; location is given until after the call to @booler. | ; location is given until after the call to @booler. | ||||
; | ; | ||||
; Second function @baz added with an even tighter loop -- this tests different | ; Second function @baz added with an even tighter loop -- this tests different | ||||
; code-paths through LiveDebugValues. Any blocks with an incoming backedge need | ; code-paths through LiveDebugValues. Any blocks with an incoming backedge need | ||||
Show All 20 Lines | |||||
; CHECK-NOT: DBG_VALUE | ; CHECK-NOT: DBG_VALUE | ||||
; CHECK-LABEL: CALL64pcrel32 @booler | ; CHECK-LABEL: CALL64pcrel32 @booler | ||||
; CHECK: DBG_VALUE 0, $noreg, ![[BAZVARNUM]] | ; CHECK: DBG_VALUE 0, $noreg, ![[BAZVARNUM]] | ||||
; | ; | ||||
; quux tests -- the variable arrives in $edi, should get a non-undef location | ; quux tests -- the variable arrives in $edi, should get a non-undef location | ||||
; before the loop, and its position re-stated in each block. | ; before the loop, and its position re-stated in each block. | ||||
; CHECK-LABEL: name: quux | ; CHECK-LABEL: name: quux | ||||
; CHECK: DBG_VALUE $edi, $noreg, ![[QUUXVARNUM]] | ; CHECK: DBG_VALUE $edi, $noreg, ![[QUUXVARNUM]] | ||||
; CHECK: DBG_VALUE [[QUUXLOC:[a-zA-Z0-9$_]+]], $noreg, ![[QUUXVARNUM]] | |||||
; CHECK-LABEL: bb.1.loop | ; CHECK-LABEL: bb.1.loop | ||||
; CHECK: DBG_VALUE [[QUUXLOC]], $noreg, ![[QUUXVARNUM]] | ; CHECK: DBG_VALUE $ebx, $noreg, ![[QUUXVARNUM]] | ||||
; CHECK-NOT: DBG_VALUE $noreg | ; CHECK-NOT: DBG_VALUE $noreg | ||||
; CHECK-LABEL: bb.2.exit | ; CHECK-LABEL: bb.2.exit | ||||
; CHECK: DBG_VALUE [[QUUXLOC]], $noreg, ![[QUUXVARNUM]] | ; CHECK: DBG_VALUE $ebx, $noreg, ![[QUUXVARNUM]] | ||||
; CHECK-NOT: DBG_VALUE $noreg | ; CHECK-NOT: DBG_VALUE $noreg | ||||
declare dso_local i1 @booler() | declare dso_local i1 @booler() | ||||
declare dso_local void @escape(i32) | declare dso_local void @escape(i32) | ||||
declare void @llvm.dbg.value(metadata, metadata, metadata) | declare void @llvm.dbg.value(metadata, metadata, metadata) | ||||
@glob = global i32 0 | @glob = global i32 0 | ||||
define i32 @foo(i32 %bar) !dbg !4 { | define i32 @foo(i32 %bar) !dbg !4 { | ||||
▲ Show 20 Lines • Show All 63 Lines • Show Last 20 Lines |