1 ; RUN: llc < %s -march=x86-64 | FileCheck %s --check-prefix=CHECK-64
2 ; RUN: llc < %s -march=x86 | FileCheck %s --check-prefix=CHECK-32
5 ; CHECK-64: testb $8, %ah
8 ; CHECK-32: testb $8, %ah
10 define void @g64xh(i64 inreg %x) nounwind {
12 %s = icmp eq i64 %t, 0
13 br i1 %s, label %yes, label %no
22 ; CHECK-64: testb $8, %dil
25 ; CHECK-32: testb $8, %al
27 define void @g64xl(i64 inreg %x) nounwind {
29 %s = icmp eq i64 %t, 0
30 br i1 %s, label %yes, label %no
39 ; CHECK-64: testb $8, %ah
42 ; CHECK-32: testb $8, %ah
44 define void @g32xh(i32 inreg %x) nounwind {
46 %s = icmp eq i32 %t, 0
47 br i1 %s, label %yes, label %no
56 ; CHECK-64: testb $8, %dil
59 ; CHECK-32: testb $8, %al
61 define void @g32xl(i32 inreg %x) nounwind {
63 %s = icmp eq i32 %t, 0
64 br i1 %s, label %yes, label %no
73 ; CHECK-64: testb $8, %ah
76 ; CHECK-32: testb $8, %ah
78 define void @g16xh(i16 inreg %x) nounwind {
80 %s = icmp eq i16 %t, 0
81 br i1 %s, label %yes, label %no
90 ; CHECK-64: testb $8, %dil
93 ; CHECK-32: testb $8, %al
95 define void @g16xl(i16 inreg %x) nounwind {
97 %s = icmp eq i16 %t, 0
98 br i1 %s, label %yes, label %no
107 ; CHECK-64: testw $-32640, %di
110 ; CHECK-32: testw $-32640, %ax
112 define void @g64x16(i64 inreg %x) nounwind {
113 %t = and i64 %x, 32896
114 %s = icmp eq i64 %t, 0
115 br i1 %s, label %yes, label %no
124 ; CHECK-64: testw $-32640, %di
127 ; CHECK-32: testw $-32640, %ax
129 define void @g32x16(i32 inreg %x) nounwind {
130 %t = and i32 %x, 32896
131 %s = icmp eq i32 %t, 0
132 br i1 %s, label %yes, label %no
141 ; CHECK-64: testl $268468352, %edi
144 ; CHECK-32: testl $268468352, %eax
146 define void @g64x32(i64 inreg %x) nounwind {
147 %t = and i64 %x, 268468352
148 %s = icmp eq i64 %t, 0
149 br i1 %s, label %yes, label %no