Changeset View
Changeset View
Standalone View
Standalone View
llvm/test/DebugInfo/X86/live-debug-values.ll
; RUN: llc -filetype=asm %s -o - -experimental-debug-variable-locations=false | FileCheck %s | ; RUN: llc -filetype=asm %s -o - -experimental-debug-variable-locations=false | FileCheck %s | ||||
; RUN: llc -filetype=asm %s -o - -experimental-debug-variable-locations=true | FileCheck %s --check-prefixes=CHECK,INSTRREF | |||||
; Test the extension of debug ranges from predecessors. | ; Test the extension of debug ranges from predecessors. | ||||
; Generated from the source file LiveDebugValues.c: | ; Generated from the source file LiveDebugValues.c: | ||||
; #include <stdio.h> | ; #include <stdio.h> | ||||
; int m; | ; int m; | ||||
; extern int inc(int n); | ; extern int inc(int n); | ||||
; extern int change(int n); | ; extern int change(int n); | ||||
; extern int modify(int n); | ; extern int modify(int n); | ||||
Show All 14 Lines | |||||
; return 0; | ; return 0; | ||||
; } | ; } | ||||
; with clang -g -O3 -emit-llvm -c LiveDebugValues.c -S -o live-debug-values.ll | ; with clang -g -O3 -emit-llvm -c LiveDebugValues.c -S -o live-debug-values.ll | ||||
; This case will also produce multiple locations but only the debug range | ; This case will also produce multiple locations but only the debug range | ||||
; extension is tested here. | ; extension is tested here. | ||||
; DBG_VALUE for variable "n" is extended into %bb.5 from its predecessors %bb.3 | ; DBG_VALUE for variable "n" is extended into %bb.5 from its predecessors %bb.3 | ||||
; and %bb.4. | ; and %bb.4. | ||||
; CHECK: .LBB0_5: | ; CHECK: .LBB0_5: | ||||
; INSTRREF-NEXT: #DEBUG_VALUE: main:argc <- [DW_OP_LLVM_entry_value 1] $edi | |||||
; INSTRREF-NEXT: #DEBUG_VALUE: main:argv <- [DW_OP_LLVM_entry_value 1] $rsi | |||||
; CHECK-NEXT: #DEBUG_VALUE: main:n <- $ebx | ; CHECK-NEXT: #DEBUG_VALUE: main:n <- $ebx | ||||
; Other register values have been clobbered. | ; Other register values have been clobbered. | ||||
; CHECK-NOT: #DEBUG_VALUE: | ; CHECK-NOT: #DEBUG_VALUE: | ||||
; CHECK: movl %e{{..}}, m(%rip) | ; CHECK: movl %e{{..}}, m(%rip) | ||||
; ModuleID = 'LiveDebugValues.c' | ; ModuleID = 'LiveDebugValues.c' | ||||
source_filename = "test/DebugInfo/X86/live-debug-values.ll" | source_filename = "test/DebugInfo/X86/live-debug-values.ll" | ||||
target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" | target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" | ||||
target triple = "x86_64-unknown-linux-gnu" | target triple = "x86_64-unknown-linux-gnu" | ||||
▲ Show 20 Lines • Show All 117 Lines • Show Last 20 Lines |