1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00

[X86] Use MOVZX16rr8/MOVZXrm8 when extending input for i8 udivrem.

We can rely on X86FixupBWInsts to turn these into MOVZX32. This
simplifies a follow up commit to use MOVSX for i8 sdivrem with
a late optimization to use CBW when register allocation works out.

llvm-svn: 371242
This commit is contained in:
Craig Topper 2019-09-06 19:15:04 +00:00
parent 1c2f42a2d2
commit c7ad58cc1e
10 changed files with 3 additions and 64 deletions

View File

@ -4732,17 +4732,17 @@ void X86DAGToDAGISel::Select(SDNode *Node) {
MachineSDNode *Move;
if (tryFoldLoad(Node, N0, Tmp0, Tmp1, Tmp2, Tmp3, Tmp4)) {
SDValue Ops[] = { Tmp0, Tmp1, Tmp2, Tmp3, Tmp4, N0.getOperand(0) };
Move = CurDAG->getMachineNode(X86::MOVZX32rm8, dl, MVT::i32,
Move = CurDAG->getMachineNode(X86::MOVZX16rm8, dl, MVT::i32,
MVT::Other, Ops);
Chain = SDValue(Move, 1);
ReplaceUses(N0.getValue(1), Chain);
// Record the mem-refs
CurDAG->setNodeMemRefs(Move, {cast<LoadSDNode>(N0)->getMemOperand()});
} else {
Move = CurDAG->getMachineNode(X86::MOVZX32rr8, dl, MVT::i32, N0);
Move = CurDAG->getMachineNode(X86::MOVZX16rr8, dl, MVT::i32, N0);
Chain = CurDAG->getEntryNode();
}
Chain = CurDAG->getCopyToReg(Chain, dl, X86::EAX, SDValue(Move, 0),
Chain = CurDAG->getCopyToReg(Chain, dl, X86::AX, SDValue(Move, 0),
SDValue());
InFlag = Chain.getValue(1);
} else {

View File

@ -22,7 +22,6 @@ define i32 @func_44(i16 signext %p_46) nounwind {
; SOURCE-SCHED-NEXT: jne .LBB0_2
; SOURCE-SCHED-NEXT: # %bb.1: # %bb11
; SOURCE-SCHED-NEXT: movzbl %al, %eax
; SOURCE-SCHED-NEXT: # kill: def $eax killed $eax def $ax
; SOURCE-SCHED-NEXT: divb %dl
; SOURCE-SCHED-NEXT: movzbl %ah, %eax
; SOURCE-SCHED-NEXT: .LBB0_2: # %bb12

View File

@ -8,7 +8,6 @@ define i32 @foo(i32 %p, i8 zeroext %x) nounwind {
; X32-LABEL: foo:
; X32: # %bb.0:
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb {{[0-9]+}}(%esp)
; X32-NEXT: movzbl %al, %eax
; X32-NEXT: andl $1, %eax
@ -17,7 +16,6 @@ define i32 @foo(i32 %p, i8 zeroext %x) nounwind {
; X64-LABEL: foo:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %al, %eax
; X64-NEXT: andl $1, %eax

View File

@ -17,7 +17,6 @@ define i32 @Test_get_quotient(i32 %a, i32 %b) nounwind {
; CHECK-NEXT: retl
; CHECK-NEXT: .LBB0_1:
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %cl
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: retl
@ -41,7 +40,6 @@ define i32 @Test_get_remainder(i32 %a, i32 %b) nounwind {
; CHECK-NEXT: retl
; CHECK-NEXT: .LBB1_1:
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %cl
; CHECK-NEXT: movzbl %ah, %eax
; CHECK-NEXT: retl
@ -65,7 +63,6 @@ define i32 @Test_get_quotient_and_remainder(i32 %a, i32 %b) nounwind {
; CHECK-NEXT: retl
; CHECK-NEXT: .LBB2_1:
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %cl
; CHECK-NEXT: movzbl %ah, %edx
; CHECK-NEXT: movzbl %al, %eax
@ -103,14 +100,12 @@ define i32 @Test_use_div_and_idiv(i32 %a, i32 %b) nounwind {
; CHECK-NEXT: jmp .LBB3_6
; CHECK-NEXT: .LBB3_1:
; CHECK-NEXT: movzbl %cl, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %bl
; CHECK-NEXT: movzbl %al, %esi
; CHECK-NEXT: testl $-256, %edi
; CHECK-NEXT: jne .LBB3_5
; CHECK-NEXT: .LBB3_4:
; CHECK-NEXT: movzbl %cl, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %bl
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: .LBB3_6:
@ -208,7 +203,6 @@ define i32 @Test_use_div_imm_reg(i32 %a) nounwind {
; CHECK-NEXT: .LBB8_1:
; CHECK-NEXT: movb $4, %al
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %cl
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: retl
@ -230,7 +224,6 @@ define i32 @Test_use_rem_imm_reg(i32 %a) nounwind {
; CHECK-NEXT: .LBB9_1:
; CHECK-NEXT: movb $4, %al
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %cl
; CHECK-NEXT: movzbl %al, %eax
; CHECK-NEXT: retl

View File

@ -20,7 +20,6 @@ define i32 @div32(i32 %a, i32 %b) {
; ATOM-NEXT: retq
; ATOM-NEXT: .LBB0_1:
; ATOM-NEXT: movzbl %dil, %eax
; ATOM-NEXT: # kill: def $eax killed $eax def $ax
; ATOM-NEXT: divb %sil
; ATOM-NEXT: movzbl %al, %eax
; ATOM-NEXT: retq

View File

@ -15,7 +15,6 @@ define i8 @scalar_i8(i8 %x, i8 %y, i8* %divdst) nounwind {
; X86-NEXT: movb {{[0-9]+}}(%esp), %ch
; X86-NEXT: movb {{[0-9]+}}(%esp), %cl
; X86-NEXT: movzbl %cl, %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb %ch
; X86-NEXT: movb %al, (%edx)
; X86-NEXT: mulb %ch
@ -183,82 +182,66 @@ define <16 x i8> @vector_i128_i8(<16 x i8> %x, <16 x i8> %y, <16 x i8>* %divdst)
; X86-NEXT: movdqa %xmm0, (%esp)
; X86-NEXT: movdqa %xmm1, {{[0-9]+}}(%esp)
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm2
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm3
; X86-NEXT: punpcklbw {{.*#+}} xmm3 = xmm3[0],xmm2[0],xmm3[1],xmm2[1],xmm3[2],xmm2[2],xmm3[3],xmm2[3],xmm3[4],xmm2[4],xmm3[5],xmm2[5],xmm3[6],xmm2[6],xmm3[7],xmm2[7]
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm4
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm2
; X86-NEXT: punpcklbw {{.*#+}} xmm2 = xmm2[0],xmm4[0],xmm2[1],xmm4[1],xmm2[2],xmm4[2],xmm2[3],xmm4[3],xmm2[4],xmm4[4],xmm2[5],xmm4[5],xmm2[6],xmm4[6],xmm2[7],xmm4[7]
; X86-NEXT: punpcklwd {{.*#+}} xmm2 = xmm2[0],xmm3[0],xmm2[1],xmm3[1],xmm2[2],xmm3[2],xmm2[3],xmm3[3]
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm3
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm4
; X86-NEXT: punpcklbw {{.*#+}} xmm4 = xmm4[0],xmm3[0],xmm4[1],xmm3[1],xmm4[2],xmm3[2],xmm4[3],xmm3[3],xmm4[4],xmm3[4],xmm4[5],xmm3[5],xmm4[6],xmm3[6],xmm4[7],xmm3[7]
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm5
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm3
; X86-NEXT: punpcklbw {{.*#+}} xmm3 = xmm3[0],xmm5[0],xmm3[1],xmm5[1],xmm3[2],xmm5[2],xmm3[3],xmm5[3],xmm3[4],xmm5[4],xmm3[5],xmm5[5],xmm3[6],xmm5[6],xmm3[7],xmm5[7]
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm5
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %eax
; X86-NEXT: movd %eax, %xmm6
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %edx
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %esi
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %edi
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movzbl %al, %ebx
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: movl %eax, %ecx
; X86-NEXT: movzbl (%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb {{[0-9]+}}(%esp)
; X86-NEXT: punpcklwd {{.*#+}} xmm3 = xmm3[0],xmm4[0],xmm3[1],xmm4[1],xmm3[2],xmm4[2],xmm3[3],xmm4[3]
; X86-NEXT: movd %edx, %xmm4
@ -312,68 +295,52 @@ define <16 x i8> @vector_i128_i8(<16 x i8> %x, <16 x i8> %y, <16 x i8>* %divdst)
; X64-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
; X64-NEXT: movdqa %xmm1, -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %eax
; X64-NEXT: movd %eax, %xmm2
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r8d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r9d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r10d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r11d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r14d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r15d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r12d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %r13d
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %edi
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %esi
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %ebx
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %ebp
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movzbl %al, %edx
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movl %eax, %ecx
; X64-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb -{{[0-9]+}}(%rsp)
; X64-NEXT: movd %r8d, %xmm3
; X64-NEXT: movd %r9d, %xmm4

View File

@ -263,7 +263,6 @@ define void @ui8(i8 %x, i8 %y, i8* %p, i8* %q) nounwind {
; X32: # %bb.0:
; X32-NEXT: pushl %ebx
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb {{[0-9]+}}(%esp)
; X32-NEXT: movl {{[0-9]+}}(%esp), %ecx
; X32-NEXT: movl {{[0-9]+}}(%esp), %edx
@ -276,7 +275,6 @@ define void @ui8(i8 %x, i8 %y, i8* %p, i8* %q) nounwind {
; X64-LABEL: ui8:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %esi
; X64-NEXT: movb %al, (%rdx)

View File

@ -6,7 +6,6 @@ define zeroext i8 @test_udivrem_zext_ah(i8 %x, i8 %y) {
; X32-LABEL: test_udivrem_zext_ah:
; X32: # %bb.0:
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb {{[0-9]+}}(%esp)
; X32-NEXT: movzbl %ah, %ecx
; X32-NEXT: movb %al, z
@ -16,7 +15,6 @@ define zeroext i8 @test_udivrem_zext_ah(i8 %x, i8 %y) {
; X64-LABEL: test_udivrem_zext_ah:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %ecx
; X64-NEXT: movb %al, {{.*}}(%rip)
@ -32,7 +30,6 @@ define zeroext i8 @test_urem_zext_ah(i8 %x, i8 %y) {
; X32-LABEL: test_urem_zext_ah:
; X32: # %bb.0:
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb {{[0-9]+}}(%esp)
; X32-NEXT: movzbl %ah, %eax
; X32-NEXT: # kill: def $al killed $al killed $eax
@ -41,7 +38,6 @@ define zeroext i8 @test_urem_zext_ah(i8 %x, i8 %y) {
; X64-LABEL: test_urem_zext_ah:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %eax
; X64-NEXT: # kill: def $al killed $al killed $eax
@ -55,7 +51,6 @@ define i8 @test_urem_noext_ah(i8 %x, i8 %y) {
; X32: # %bb.0:
; X32-NEXT: movb {{[0-9]+}}(%esp), %cl
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb %cl
; X32-NEXT: movzbl %ah, %eax
; X32-NEXT: addb %cl, %al
@ -65,7 +60,6 @@ define i8 @test_urem_noext_ah(i8 %x, i8 %y) {
; X64-LABEL: test_urem_noext_ah:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %eax
; X64-NEXT: addb %sil, %al
@ -80,7 +74,6 @@ define i64 @test_urem_zext64_ah(i8 %x, i8 %y) {
; X32-LABEL: test_urem_zext64_ah:
; X32: # %bb.0:
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb {{[0-9]+}}(%esp)
; X32-NEXT: movzbl %ah, %eax
; X32-NEXT: xorl %edx, %edx
@ -89,7 +82,6 @@ define i64 @test_urem_zext64_ah(i8 %x, i8 %y) {
; X64-LABEL: test_urem_zext64_ah:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %eax
; X64-NEXT: retq
@ -204,7 +196,6 @@ define i64 @pr25754(i8 %a, i8 %c) {
; X32-LABEL: pr25754:
; X32: # %bb.0:
; X32-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X32-NEXT: # kill: def $eax killed $eax def $ax
; X32-NEXT: divb {{[0-9]+}}(%esp)
; X32-NEXT: movzbl %ah, %ecx
; X32-NEXT: movzbl %al, %eax
@ -215,7 +206,6 @@ define i64 @pr25754(i8 %a, i8 %c) {
; X64-LABEL: pr25754:
; X64: # %bb.0:
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %ecx
; X64-NEXT: movzbl %al, %eax

View File

@ -81,15 +81,12 @@ define <3 x i8> @test_uchar_div(<3 x i8> %num, <3 x i8> %div) {
; CHECK-LABEL: test_uchar_div:
; CHECK: # %bb.0:
; CHECK-NEXT: movzbl %dil, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %cl
; CHECK-NEXT: movl %eax, %edi
; CHECK-NEXT: movzbl %sil, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %r8b
; CHECK-NEXT: movl %eax, %esi
; CHECK-NEXT: movzbl %dl, %eax
; CHECK-NEXT: # kill: def $eax killed $eax def $ax
; CHECK-NEXT: divb %r9b
; CHECK-NEXT: movl %eax, %ecx
; CHECK-NEXT: movl %edi, %eax

View File

@ -83,7 +83,6 @@ define i8 @and_pow_2(i8 %x, i8 %y) {
; X86-NEXT: movb {{[0-9]+}}(%esp), %cl
; X86-NEXT: andb $4, %cl
; X86-NEXT: movzbl {{[0-9]+}}(%esp), %eax
; X86-NEXT: # kill: def $eax killed $eax def $ax
; X86-NEXT: divb %cl
; X86-NEXT: movzbl %ah, %eax
; X86-NEXT: # kill: def $al killed $al killed $eax
@ -93,7 +92,6 @@ define i8 @and_pow_2(i8 %x, i8 %y) {
; X64: # %bb.0:
; X64-NEXT: andb $4, %sil
; X64-NEXT: movzbl %dil, %eax
; X64-NEXT: # kill: def $eax killed $eax def $ax
; X64-NEXT: divb %sil
; X64-NEXT: movzbl %ah, %eax
; X64-NEXT: # kill: def $al killed $al killed $eax