llvm-project/llvm/test/MachineVerifier/verify-selected-dbg-undef-u...

41 lines
958 B
YAML

# RUN: not --crash llc -verify-machineinstrs -run-pass none -o /dev/null %s 2>&1 | FileCheck %s
# REQUIRES: aarch64-registered-target
--- |
target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128"
target triple = "aarch64--"
define void @selected_notrack() { ret void }
define void @selected_track() { ret void }
...
---
name: selected_notrack
regBankSelected: true
selected: true
tracksDebugUserValues: false
registers:
- { id: 0, class: _ }
body: |
bb.0:
; CHECK-NOT: function: selected_notrack
DBG_VALUE %0, $noreg, $noreg, $noreg, $noreg
...
---
name: selected_track
regBankSelected: true
selected: true
tracksDebugUserValues: true
registers:
- { id: 0, class: _ }
body: |
bb.0:
; CHECK: *** Bad machine code: Generic virtual register invalid in a Selected function ***
; CHECK: function: selected_track
; CHECK: instruction: DBG_VALUE %0:_
; CHECK: operand 0: %0
DBG_VALUE %0, $noreg, $noreg, $noreg, $noreg
...