Skip to content

Commit c685bc5

Browse files
Update even more tests
1 parent a4360a9 commit c685bc5

File tree

5 files changed

+217
-231
lines changed

5 files changed

+217
-231
lines changed

llvm/test/CodeGen/X86/ctpop-mask.ll

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -148,10 +148,9 @@ define i16 @ctpop_shifted_mask3(i16 %x) nounwind readnone {
148148
;
149149
; X86-NO-POPCOUNT-LABEL: ctpop_shifted_mask3:
150150
; X86-NO-POPCOUNT: # %bb.0:
151-
; X86-NO-POPCOUNT-NEXT: movzwl {{[0-9]+}}(%esp), %ecx
152-
; X86-NO-POPCOUNT-NEXT: andl $14, %ecx
151+
; X86-NO-POPCOUNT-NEXT: movzbl {{[0-9]+}}(%esp), %ecx
152+
; X86-NO-POPCOUNT-NEXT: andb $14, %cl
153153
; X86-NO-POPCOUNT-NEXT: movl $59796, %eax # imm = 0xE994
154-
; X86-NO-POPCOUNT-NEXT: # kill: def $cl killed $cl killed $ecx
155154
; X86-NO-POPCOUNT-NEXT: shrl %cl, %eax
156155
; X86-NO-POPCOUNT-NEXT: andl $3, %eax
157156
; X86-NO-POPCOUNT-NEXT: # kill: def $ax killed $ax killed $eax
@@ -160,7 +159,7 @@ define i16 @ctpop_shifted_mask3(i16 %x) nounwind readnone {
160159
; X64-NO-POPCOUNT-LABEL: ctpop_shifted_mask3:
161160
; X64-NO-POPCOUNT: # %bb.0:
162161
; X64-NO-POPCOUNT-NEXT: movl %edi, %ecx
163-
; X64-NO-POPCOUNT-NEXT: andl $14, %ecx
162+
; X64-NO-POPCOUNT-NEXT: andb $14, %cl
164163
; X64-NO-POPCOUNT-NEXT: movl $59796, %eax # imm = 0xE994
165164
; X64-NO-POPCOUNT-NEXT: # kill: def $cl killed $cl killed $ecx
166165
; X64-NO-POPCOUNT-NEXT: shrl %cl, %eax
@@ -201,7 +200,7 @@ define i64 @ctpop_mask4(i64 %x) nounwind readnone {
201200
;
202201
; X64-NO-POPCOUNT-LABEL: ctpop_mask4:
203202
; X64-NO-POPCOUNT: # %bb.0:
204-
; X64-NO-POPCOUNT-NEXT: andl $15, %edi
203+
; X64-NO-POPCOUNT-NEXT: andb $15, %dil
205204
; X64-NO-POPCOUNT-NEXT: leal (,%rdi,4), %ecx
206205
; X64-NO-POPCOUNT-NEXT: movabsq $4841987667533046032, %rax # imm = 0x4332322132212110
207206
; X64-NO-POPCOUNT-NEXT: # kill: def $cl killed $cl killed $ecx
@@ -241,9 +240,10 @@ define i32 @ctpop_shifted_mask4(i32 %x) nounwind readnone {
241240
;
242241
; X64-NO-POPCOUNT-LABEL: ctpop_shifted_mask4:
243242
; X64-NO-POPCOUNT: # %bb.0:
244-
; X64-NO-POPCOUNT-NEXT: movl %edi, %ecx
245-
; X64-NO-POPCOUNT-NEXT: shrl $7, %ecx
246-
; X64-NO-POPCOUNT-NEXT: andl $60, %ecx
243+
; X64-NO-POPCOUNT-NEXT: # kill: def $edi killed $edi def $rdi
244+
; X64-NO-POPCOUNT-NEXT: shrl $9, %edi
245+
; X64-NO-POPCOUNT-NEXT: andb $15, %dil
246+
; X64-NO-POPCOUNT-NEXT: leal (,%rdi,4), %ecx
247247
; X64-NO-POPCOUNT-NEXT: movabsq $4841987667533046032, %rax # imm = 0x4332322132212110
248248
; X64-NO-POPCOUNT-NEXT: # kill: def $cl killed $cl killed $ecx
249249
; X64-NO-POPCOUNT-NEXT: shrq %cl, %rax

llvm/test/CodeGen/X86/fpenv.ll

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -185,8 +185,9 @@ define void @func_05(i32 %x) nounwind {
185185
; X86-NOSSE-LABEL: func_05:
186186
; X86-NOSSE: # %bb.0:
187187
; X86-NOSSE-NEXT: pushl %eax
188-
; X86-NOSSE-NEXT: movl {{[0-9]+}}(%esp), %eax
189-
; X86-NOSSE-NEXT: leal 4(%eax,%eax), %ecx
188+
; X86-NOSSE-NEXT: movl {{[0-9]+}}(%esp), %ecx
189+
; X86-NOSSE-NEXT: addl %ecx, %ecx
190+
; X86-NOSSE-NEXT: addb $4, %cl
190191
; X86-NOSSE-NEXT: movl $201, %eax
191192
; X86-NOSSE-NEXT: # kill: def $cl killed $cl killed $ecx
192193
; X86-NOSSE-NEXT: shll %cl, %eax
@@ -203,8 +204,9 @@ define void @func_05(i32 %x) nounwind {
203204
; X86-SSE-LABEL: func_05:
204205
; X86-SSE: # %bb.0:
205206
; X86-SSE-NEXT: pushl %eax
206-
; X86-SSE-NEXT: movl {{[0-9]+}}(%esp), %eax
207-
; X86-SSE-NEXT: leal 4(%eax,%eax), %ecx
207+
; X86-SSE-NEXT: movl {{[0-9]+}}(%esp), %ecx
208+
; X86-SSE-NEXT: addl %ecx, %ecx
209+
; X86-SSE-NEXT: addb $4, %cl
208210
; X86-SSE-NEXT: movl $201, %eax
209211
; X86-SSE-NEXT: # kill: def $cl killed $cl killed $ecx
210212
; X86-SSE-NEXT: shll %cl, %eax
@@ -227,7 +229,8 @@ define void @func_05(i32 %x) nounwind {
227229
; X64-LABEL: func_05:
228230
; X64: # %bb.0:
229231
; X64-NEXT: # kill: def $edi killed $edi def $rdi
230-
; X64-NEXT: leal 4(%rdi,%rdi), %ecx
232+
; X64-NEXT: leal (%rdi,%rdi), %ecx
233+
; X64-NEXT: addb $4, %cl
231234
; X64-NEXT: movl $201, %eax
232235
; X64-NEXT: # kill: def $cl killed $cl killed $ecx
233236
; X64-NEXT: shll %cl, %eax

llvm/test/CodeGen/X86/funnel-shift.ll

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -182,8 +182,9 @@ define i37 @fshl_i37(i37 %x, i37 %y, i37 %z) nounwind {
182182
; X64-AVX-NEXT: movabsq $498560650640798693, %rdx # imm = 0x6EB3E45306EB3E5
183183
; X64-AVX-NEXT: mulq %rdx
184184
; X64-AVX-NEXT: leal (%rdx,%rdx,8), %eax
185-
; X64-AVX-NEXT: leal (%rdx,%rax,4), %eax
186-
; X64-AVX-NEXT: subl %eax, %ecx
185+
; X64-AVX-NEXT: shll $2, %eax
186+
; X64-AVX-NEXT: addb %dl, %al
187+
; X64-AVX-NEXT: subb %al, %cl
187188
; X64-AVX-NEXT: shlq $27, %rsi
188189
; X64-AVX-NEXT: # kill: def $cl killed $cl killed $rcx
189190
; X64-AVX-NEXT: shldq %cl, %rsi, %rdi
@@ -349,9 +350,10 @@ define i37 @fshr_i37(i37 %x, i37 %y, i37 %z) nounwind {
349350
; X64-AVX-NEXT: movabsq $498560650640798693, %rdx # imm = 0x6EB3E45306EB3E5
350351
; X64-AVX-NEXT: mulq %rdx
351352
; X64-AVX-NEXT: leal (%rdx,%rdx,8), %eax
352-
; X64-AVX-NEXT: leal (%rdx,%rax,4), %eax
353-
; X64-AVX-NEXT: subl %eax, %ecx
354-
; X64-AVX-NEXT: addl $27, %ecx
353+
; X64-AVX-NEXT: shll $2, %eax
354+
; X64-AVX-NEXT: addb %dl, %al
355+
; X64-AVX-NEXT: subb %al, %cl
356+
; X64-AVX-NEXT: addb $27, %cl
355357
; X64-AVX-NEXT: shlq $27, %rsi
356358
; X64-AVX-NEXT: # kill: def $cl killed $cl killed $rcx
357359
; X64-AVX-NEXT: shrdq %cl, %rdi, %rsi
@@ -437,16 +439,15 @@ define i32 @fshl_i32_undef0_msk(i32 %a0, i32 %a1) nounwind {
437439
; X86-SSE2-LABEL: fshl_i32_undef0_msk:
438440
; X86-SSE2: # %bb.0:
439441
; X86-SSE2-NEXT: movl {{[0-9]+}}(%esp), %eax
440-
; X86-SSE2-NEXT: movl {{[0-9]+}}(%esp), %ecx
441-
; X86-SSE2-NEXT: andl $7, %ecx
442-
; X86-SSE2-NEXT: # kill: def $cl killed $cl killed $ecx
442+
; X86-SSE2-NEXT: movzbl {{[0-9]+}}(%esp), %ecx
443+
; X86-SSE2-NEXT: andb $7, %cl
443444
; X86-SSE2-NEXT: shldl %cl, %eax, %eax
444445
; X86-SSE2-NEXT: retl
445446
;
446447
; X64-AVX-LABEL: fshl_i32_undef0_msk:
447448
; X64-AVX: # %bb.0:
448449
; X64-AVX-NEXT: movl %esi, %ecx
449-
; X64-AVX-NEXT: andl $7, %ecx
450+
; X64-AVX-NEXT: andb $7, %cl
450451
; X64-AVX-NEXT: # kill: def $cl killed $cl killed $ecx
451452
; X64-AVX-NEXT: shldl %cl, %edi, %eax
452453
; X64-AVX-NEXT: retq
@@ -694,16 +695,15 @@ define i32 @fshr_i32_undef1_msk(i32 %a0, i32 %a1) nounwind {
694695
; X86-SSE2-LABEL: fshr_i32_undef1_msk:
695696
; X86-SSE2: # %bb.0:
696697
; X86-SSE2-NEXT: movl {{[0-9]+}}(%esp), %eax
697-
; X86-SSE2-NEXT: movl {{[0-9]+}}(%esp), %ecx
698-
; X86-SSE2-NEXT: andl $7, %ecx
699-
; X86-SSE2-NEXT: # kill: def $cl killed $cl killed $ecx
698+
; X86-SSE2-NEXT: movzbl {{[0-9]+}}(%esp), %ecx
699+
; X86-SSE2-NEXT: andb $7, %cl
700700
; X86-SSE2-NEXT: shrdl %cl, %eax, %eax
701701
; X86-SSE2-NEXT: retl
702702
;
703703
; X64-AVX-LABEL: fshr_i32_undef1_msk:
704704
; X64-AVX: # %bb.0:
705705
; X64-AVX-NEXT: movl %esi, %ecx
706-
; X64-AVX-NEXT: andl $7, %ecx
706+
; X64-AVX-NEXT: andb $7, %cl
707707
; X64-AVX-NEXT: # kill: def $cl killed $cl killed $ecx
708708
; X64-AVX-NEXT: shrdl %cl, %edi, %eax
709709
; X64-AVX-NEXT: retq

0 commit comments

Comments
 (0)