1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-23 13:02:52 +02:00
llvm-mirror/test/CodeGen/X86/invalid-liveness.mir
Puyan Lotfi d4c615be8c Followup on Proposal to move MIR physical register namespace to '$' sigil.
Discussed here:

http://lists.llvm.org/pipermail/llvm-dev/2018-January/120320.html

In preparation for adding support for named vregs we are changing the sigil for
physical registers in MIR to '$' from '%'. This will prevent name clashes of
named physical register with named vregs.

llvm-svn: 323922
2018-01-31 22:04:26 +00:00

30 lines
654 B
YAML

# RUN: not llc -mtriple=i686-- -run-pass liveintervals -o - %s 2>&1 | FileCheck %s
# REQUIRES: asserts
--- |
define void @func() { ret void }
...
---
# Liveness calculation should detect that we do not have a definition for %0
# on all paths; In this example a def for %0 is missing when jumping from
# bb.0 to bb.3.
#
# CHECK: Use of %0 does not have a corresponding definition on every path
# CHECK: ERROR: Use not jointly dominated by defs.
name: func
registers:
- { id: 0, class: gr32 }
body: |
bb.0:
JG_1 %bb.2, implicit $eflags
JMP_1 %bb.3
bb.2:
%0 = IMPLICIT_DEF
JMP_1 %bb.3
bb.3:
$eax = COPY %0
RETQ $eax
...