MIR Serialization: Serialize the null register operands.
[oota-llvm.git] / test / CodeGen / MIR / X86 / null-register-operands.mir
1 # RUN: llc -march=x86-64 -start-after branch-folder -stop-after branch-folder -o /dev/null %s | FileCheck %s
2 # This test ensures that the MIR parser parses null register operands correctly.
3
4 --- |
5
6   define i32 @deref(i32* %p) {
7   entry:
8     %a = load i32, i32* %p
9     ret i32 %a
10   }
11
12 ...
13 ---
14 # CHECK: name: deref
15 name:            deref
16 body:
17  - name:         entry
18    instructions:
19      # CHECK:      - '%eax = MOV32rm %rdi, 1, _, 0, _'
20      # CHECK-NEXT: - 'RETQ %eax'
21      - '%eax = MOV32rm %rdi, 1, _, 0, %noreg'
22      - 'RETQ %eax'
23 ...