@@ -397,6 +397,48 @@ define i1 @PR38788(<4 x i32> %0, <4 x i32> %1) {
397
397
ret i1 %7
398
398
}
399
399
400
+ define i32 @PR88958_1 (ptr %0 , <2 x i64 > %1 ) {
401
+ ; SSE-LABEL: PR88958_1:
402
+ ; SSE: # %bb.0:
403
+ ; SSE-NEXT: movdqa (%rdi), %xmm1
404
+ ; SSE-NEXT: xorl %eax, %eax
405
+ ; SSE-NEXT: ptest %xmm0, %xmm1
406
+ ; SSE-NEXT: sete %al
407
+ ; SSE-NEXT: retq
408
+ ;
409
+ ; AVX-LABEL: PR88958_1:
410
+ ; AVX: # %bb.0:
411
+ ; AVX-NEXT: vmovdqa (%rdi), %xmm1
412
+ ; AVX-NEXT: xorl %eax, %eax
413
+ ; AVX-NEXT: vptest %xmm0, %xmm1
414
+ ; AVX-NEXT: sete %al
415
+ ; AVX-NEXT: retq
416
+ %3 = load <2 x i64 >, ptr %0
417
+ %4 = tail call i32 @llvm.x86.sse41.ptestz (<2 x i64 > %3 , <2 x i64 > %1 )
418
+ ret i32 %4
419
+ }
420
+
421
+ define i32 @PR88958_2 (ptr %0 , <2 x i64 > %1 ) {
422
+ ; SSE-LABEL: PR88958_2:
423
+ ; SSE: # %bb.0:
424
+ ; SSE-NEXT: movdqa (%rdi), %xmm1
425
+ ; SSE-NEXT: xorl %eax, %eax
426
+ ; SSE-NEXT: ptest %xmm0, %xmm1
427
+ ; SSE-NEXT: setb %al
428
+ ; SSE-NEXT: retq
429
+ ;
430
+ ; AVX-LABEL: PR88958_2:
431
+ ; AVX: # %bb.0:
432
+ ; AVX-NEXT: vmovdqa (%rdi), %xmm1
433
+ ; AVX-NEXT: xorl %eax, %eax
434
+ ; AVX-NEXT: vptest %xmm0, %xmm1
435
+ ; AVX-NEXT: setb %al
436
+ ; AVX-NEXT: retq
437
+ %3 = load <2 x i64 >, ptr %0
438
+ %4 = tail call i32 @llvm.x86.sse41.ptestc (<2 x i64 > %3 , <2 x i64 > %1 )
439
+ ret i32 %4
440
+ }
441
+
400
442
declare i32 @llvm.x86.sse41.ptestz (<2 x i64 >, <2 x i64 >) nounwind readnone
401
443
declare i32 @llvm.x86.sse41.ptestc (<2 x i64 >, <2 x i64 >) nounwind readnone
402
444
declare i32 @llvm.x86.sse41.ptestnzc (<2 x i64 >, <2 x i64 >) nounwind readnone
0 commit comments