MIR Parser: Verify the implicit machine register operands.
[oota-llvm.git] / test / CodeGen / MIR / X86 / expected-number-after-bb.mir
1 # RUN: not llc -march=x86-64 -start-after branch-folder -stop-after branch-folder -o /dev/null %s 2>&1 | FileCheck %s
2
3 --- |
4
5   define i32 @foo(i32* %p) {
6   entry:
7     %a = load i32, i32* %p
8     %b = icmp sle i32 %a, 10
9     br i1 %b, label %yes, label %nah
10
11   yes:
12     ret i32 0
13
14   nah:
15     ret i32 %a
16   }
17
18 ...
19 ---
20 name:            foo
21 body:
22  - id: 0
23    name:   entry
24    instructions:
25      - '%eax = MOV32rm %rdi, 1, _, 0, _'
26      - 'CMP32ri8 %eax, 10, implicit-def %eflags'
27      # CHECK: [[@LINE+1]]:18: expected a number after '%bb.'
28      - 'JG_1 %bb.nah, implicit %eflags'
29  - id: 1
30    name: yes
31    instructions:
32      - '%eax = MOV32r0 implicit-def %eflags'
33  - id: 2
34    name: nah
35    instructions:
36      - 'RETQ %eax'
37 ...