[Codegen] Adjust saturation test. NFC.
[llvm-core.git] / test / CodeGen / X86 / test_x86condbr_globaladdr.mir
blob4abe7d5e048c680ba61f37036a9808d4e97d35de
1 # RUN: llc -o - %s -mtriple=i686-- -mcpu=ivybridge --run-pass X86CondBrFolding | FileCheck %s
3 # Test wrong assertion when meet SUB32ri with global address
4 # in X86CondBrFoldingiPass
5 --- |
6   @img2buf_normal = external global i32
7   define void @func() { ret void }
8 ...
9 ---
10 # CHECK: bb.0:
11 # CHECK: %2:gr32 = SUB32ri %1, @img2buf_normal, implicit-def $eflags
13 name: func
14 tracksRegLiveness: true
15 body: |
16   bb.0:
17     liveins: $edx
18     %1:gr32 = COPY $edx
19     %2:gr32 = MOV32rm %1:gr32, 1, $noreg, 850256, $noreg
20     %3:gr32 = SUB32ri %2:gr32, @img2buf_normal, implicit-def $eflags
21     JCC_1 %bb.2, 4, implicit $eflags
22     JMP_1 %bb.3
24   bb.2:
25     RET 0, undef $eax
27   bb.3:
28     $eax = MOV32rr %3:gr32
29     RET 0, $eax
30 ...