2016-03-30 21:55:00 +08:00
|
|
|
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
|
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+sse2 | FileCheck %s --check-prefix=SSE --check-prefix=SSE2
|
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+sse4.2 | FileCheck %s --check-prefix=SSE --check-prefix=SSE42
|
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx | FileCheck %s --check-prefix=AVX --check-prefix=AVX1
|
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx2 | FileCheck %s --check-prefix=AVX --check-prefix=AVX2
|
2016-04-03 05:24:42 +08:00
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f | FileCheck %s --check-prefix=AVX --check-prefix=AVX512 --check-prefix=AVX512F
|
2017-01-09 05:32:26 +08:00
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512dq | FileCheck %s --check-prefix=AVX --check-prefix=AVX512 --check-prefix=AVX512DQ
|
|
|
|
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512bw | FileCheck %s --check-prefix=AVX --check-prefix=AVX512 --check-prefix=AVX512BW
|
2016-03-30 21:55:00 +08:00
|
|
|
|
|
|
|
;
|
|
|
|
; 128-bit vector comparisons
|
|
|
|
;
|
|
|
|
|
|
|
|
define <2 x i1> @test_cmp_v2f64(<2 x double> %a0, <2 x double> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v2f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm0, %xmm1
|
|
|
|
; SSE-NEXT: movapd %xmm1, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX-LABEL: test_cmp_v2f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX-NEXT: vcmpltpd %xmm0, %xmm1, %xmm0
|
|
|
|
; AVX-NEXT: retq
|
|
|
|
%1 = fcmp ogt <2 x double> %a0, %a1
|
|
|
|
ret <2 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <4 x i1> @test_cmp_v4f32(<4 x float> %a0, <4 x float> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v4f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: cmpltps %xmm0, %xmm1
|
|
|
|
; SSE-NEXT: movaps %xmm1, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX-LABEL: test_cmp_v4f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX-NEXT: vcmpltps %xmm0, %xmm1, %xmm0
|
|
|
|
; AVX-NEXT: retq
|
|
|
|
%1 = fcmp ogt <4 x float> %a0, %a1
|
|
|
|
ret <4 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <2 x i1> @test_cmp_v2i64(<2 x i64> %a0, <2 x i64> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v2i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm2 = [2147483648,0,2147483648,0]
|
|
|
|
; SSE2-NEXT: pxor %xmm2, %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm2, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm1, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm2[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm1, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm3, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm2[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm1, %xmm0
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v2i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq %xmm1, %xmm0
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX-LABEL: test_cmp_v2i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX-NEXT: vpcmpgtq %xmm1, %xmm0, %xmm0
|
|
|
|
; AVX-NEXT: retq
|
|
|
|
%1 = icmp sgt <2 x i64> %a0, %a1
|
|
|
|
ret <2 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <4 x i1> @test_cmp_v4i32(<4 x i32> %a0, <4 x i32> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v4i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: pcmpgtd %xmm1, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX-LABEL: test_cmp_v4i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX-NEXT: vpcmpgtd %xmm1, %xmm0, %xmm0
|
|
|
|
; AVX-NEXT: retq
|
|
|
|
%1 = icmp sgt <4 x i32> %a0, %a1
|
|
|
|
ret <4 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <8 x i1> @test_cmp_v8i16(<8 x i16> %a0, <8 x i16> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v8i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: pcmpgtw %xmm1, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX-LABEL: test_cmp_v8i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX-NEXT: vpcmpgtw %xmm1, %xmm0, %xmm0
|
|
|
|
; AVX-NEXT: retq
|
|
|
|
%1 = icmp sgt <8 x i16> %a0, %a1
|
|
|
|
ret <8 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <16 x i1> @test_cmp_v16i8(<16 x i8> %a0, <16 x i8> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v16i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: pcmpgtb %xmm1, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX-LABEL: test_cmp_v16i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX-NEXT: vpcmpgtb %xmm1, %xmm0, %xmm0
|
|
|
|
; AVX-NEXT: retq
|
|
|
|
%1 = icmp sgt <16 x i8> %a0, %a1
|
|
|
|
ret <16 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
;
|
|
|
|
; 256-bit vector comparisons
|
|
|
|
;
|
|
|
|
|
|
|
|
define <4 x i1> @test_cmp_v4f64(<4 x double> %a0, <4 x double> %a1) nounwind {
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-LABEL: test_cmp_v4f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm1, %xmm3
|
|
|
|
; SSE-NEXT: cmpltpd %xmm0, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm3, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: movdqa %xmm2, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v4f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm0, %ymm1, %ymm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v4f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm0, %ymm1, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vextractf128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
|
|
|
; AVX512-LABEL: test_cmp_v4f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512: # %bb.0:
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: vcmpltpd %ymm0, %ymm1, %ymm0
|
|
|
|
; AVX512-NEXT: vpmovqd %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512-NEXT: vzeroupper
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = fcmp ogt <4 x double> %a0, %a1
|
|
|
|
ret <4 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <8 x i1> @test_cmp_v8f32(<8 x float> %a0, <8 x float> %a1) nounwind {
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-LABEL: test_cmp_v8f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: cmpltps %xmm1, %xmm3
|
|
|
|
; SSE-NEXT: cmpltps %xmm0, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm3, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: movdqa %xmm2, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v8f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm0, %ymm1, %ymm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v8f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vcmpltps %ymm0, %ymm1, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vextractf128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
|
|
|
; AVX512-LABEL: test_cmp_v8f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512: # %bb.0:
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: vcmpltps %ymm0, %ymm1, %ymm0
|
|
|
|
; AVX512-NEXT: vpmovdw %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512-NEXT: vzeroupper
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = fcmp ogt <8 x float> %a0, %a1
|
|
|
|
ret <8 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <4 x i1> @test_cmp_v4i64(<4 x i64> %a0, <4 x i64> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v4i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm4 = [2147483648,0,2147483648,0]
|
|
|
|
; SSE2-NEXT: pxor %xmm4, %xmm3
|
|
|
|
; SSE2-NEXT: pxor %xmm4, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm5
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm3, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm5[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm3, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm5[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm1, %xmm3
|
|
|
|
; SSE2-NEXT: pxor %xmm4, %xmm2
|
|
|
|
; SSE2-NEXT: pxor %xmm4, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm2, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm1[0,0,2,2]
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm2, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm4, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm2, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm3, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v4i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq %xmm3, %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtq %xmm2, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm1, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v4i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm2, %xmm3, %xmm2
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm1, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm2, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v4i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
|
|
|
; AVX512-LABEL: test_cmp_v4i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512: # %bb.0:
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: vpcmpgtq %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX512-NEXT: vpmovqd %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512-NEXT: vzeroupper
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <4 x i64> %a0, %a1
|
|
|
|
ret <4 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <8 x i1> @test_cmp_v8i32(<8 x i32> %a0, <8 x i32> %a1) nounwind {
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-LABEL: test_cmp_v8i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: pcmpgtd %xmm3, %xmm1
|
|
|
|
; SSE-NEXT: pcmpgtd %xmm2, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm1, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v8i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm2, %xmm3, %xmm2
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm1, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm2, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v8i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
|
|
|
; AVX512-LABEL: test_cmp_v8i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512: # %bb.0:
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: vpcmpgtd %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX512-NEXT: vpmovdw %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512-NEXT: vzeroupper
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <8 x i32> %a0, %a1
|
|
|
|
ret <8 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <16 x i1> @test_cmp_v16i16(<16 x i16> %a0, <16 x i16> %a1) nounwind {
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-LABEL: test_cmp_v16i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: pcmpgtw %xmm3, %xmm1
|
|
|
|
; SSE-NEXT: pcmpgtw %xmm2, %xmm0
|
|
|
|
; SSE-NEXT: packsswb %xmm1, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v16i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm2, %xmm3, %xmm2
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm1, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm2, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v16i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v16i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm0, %zmm0
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v16i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v16i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtw %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX512BW-NEXT: vpmovwb %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <16 x i16> %a0, %a1
|
|
|
|
ret <16 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <32 x i1> @test_cmp_v32i8(<32 x i8> %a0, <32 x i8> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v32i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpgtb %xmm2, %xmm0
|
|
|
|
; SSE2-NEXT: pcmpgtb %xmm3, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa %xmm1, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v32i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pcmpgtb %xmm2, %xmm0
|
|
|
|
; SSE42-NEXT: pcmpgtb %xmm3, %xmm1
|
|
|
|
; SSE42-NEXT: pextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm1, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm0, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v32i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm2, %xmm3, %xmm2
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm1, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vinsertf128 $1, %xmm2, %ymm0, %ymm0
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v32i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
|
|
|
; AVX512-LABEL: test_cmp_v32i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512: # %bb.0:
|
2016-04-03 05:24:42 +08:00
|
|
|
; AVX512-NEXT: vpcmpgtb %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX512-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <32 x i8> %a0, %a1
|
|
|
|
ret <32 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
;
|
|
|
|
; 512-bit vector comparisons
|
|
|
|
;
|
|
|
|
|
|
|
|
define <8 x i1> @test_cmp_v8f64(<8 x double> %a0, <8 x double> %a1) nounwind {
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-LABEL: test_cmp_v8f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm3, %xmm7
|
|
|
|
; SSE-NEXT: cmpltpd %xmm2, %xmm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm7, %xmm6
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm1, %xmm5
|
|
|
|
; SSE-NEXT: cmpltpd %xmm0, %xmm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm5, %xmm4
|
|
|
|
; SSE-NEXT: packssdw %xmm6, %xmm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: movdqa %xmm4, %xmm0
|
|
|
|
; SSE-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v8f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm1, %ymm3, %ymm1
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm0, %ymm2, %ymm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm2, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v8f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm1, %ymm3, %ymm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm0, %ymm2, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v8f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm0, %zmm1, %k1
|
2017-12-05 14:37:21 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k1} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdw %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512F-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v8f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm0, %zmm1, %k0
|
2017-12-05 14:37:21 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdw %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512DQ-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v8f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-03-23 17:57:01 +08:00
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm0, %zmm1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2w %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $zmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = fcmp ogt <8 x double> %a0, %a1
|
|
|
|
ret <8 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <16 x i1> @test_cmp_v16f32(<16 x float> %a0, <16 x float> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v16f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: cmpltps %xmm3, %xmm7
|
|
|
|
; SSE-NEXT: cmpltps %xmm2, %xmm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm7, %xmm6
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: cmpltps %xmm1, %xmm5
|
|
|
|
; SSE-NEXT: cmpltps %xmm0, %xmm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm5, %xmm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: packsswb %xmm6, %xmm4
|
|
|
|
; SSE-NEXT: movdqa %xmm4, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v16f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm1, %ymm3, %ymm1
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm0, %ymm2, %ymm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm2, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v16f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vcmpltps %ymm1, %ymm3, %ymm1
|
|
|
|
; AVX2-NEXT: vcmpltps %ymm0, %ymm2, %ymm0
|
2018-02-15 02:23:58 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
|
|
|
; AVX2-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v16f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: vcmpltps %zmm0, %zmm1, %k1
|
2017-01-09 10:44:34 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k1} {z}
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v16f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltps %zmm0, %zmm1, %k0
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v16f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-03-23 17:57:01 +08:00
|
|
|
; AVX512BW-NEXT: vcmpltps %zmm0, %zmm1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $zmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = fcmp ogt <16 x float> %a0, %a1
|
|
|
|
ret <16 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <8 x i1> @test_cmp_v8i64(<8 x i64> %a0, <8 x i64> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm8 = [2147483648,0,2147483648,0]
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm7
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm3
|
|
|
|
; SSE2-NEXT: movdqa %xmm3, %xmm9
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm7, %xmm9
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm10 = xmm9[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm7, %xmm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm3[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm7 = xmm9[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm3, %xmm7
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm6
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm2
|
|
|
|
; SSE2-NEXT: movdqa %xmm2, %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm6, %xmm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm3[0,0,2,2]
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm6, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm2[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm9, %xmm6
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm3[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm6, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm7, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm5
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm5, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm3[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm5, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm1
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm3[1,1,3,3]
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: por %xmm1, %xmm3
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm4, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm1[0,0,2,2]
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm4, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm5, %xmm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm1[1,1,3,3]
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: por %xmm4, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm3, %xmm0
|
|
|
|
; SSE2-NEXT: packssdw %xmm2, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq %xmm7, %xmm3
|
|
|
|
; SSE42-NEXT: pcmpgtq %xmm6, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm3, %xmm2
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq %xmm5, %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtq %xmm4, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm1, %xmm0
|
|
|
|
; SSE42-NEXT: packssdw %xmm2, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm4
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm4, %xmm5, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm3, %xmm1, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm4, %xmm1, %xmm1
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm3, %xmm4, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm2, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm3, %ymm1, %ymm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm2, %ymm0, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm1, %zmm0, %k1
|
2017-12-05 14:37:21 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k1} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdw %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512F-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm1, %zmm0, %k0
|
2017-12-05 14:37:21 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdw %zmm0, %ymm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512DQ-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v8i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-03-23 17:57:01 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm1, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2w %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $zmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <8 x i64> %a0, %a1
|
|
|
|
ret <8 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <16 x i1> @test_cmp_v16i32(<16 x i32> %a0, <16 x i32> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v16i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: pcmpgtd %xmm7, %xmm3
|
|
|
|
; SSE-NEXT: pcmpgtd %xmm6, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm3, %xmm2
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: pcmpgtd %xmm5, %xmm1
|
|
|
|
; SSE-NEXT: pcmpgtd %xmm4, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm1, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: packsswb %xmm2, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v16i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm4
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm4, %xmm5, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm3, %xmm1, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm4, %xmm1, %xmm1
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm3, %xmm4, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm2, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v16i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm3, %ymm1, %ymm1
|
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm2, %ymm0, %ymm0
|
2018-02-15 02:23:58 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
|
|
|
; AVX2-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v16i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtd %zmm1, %zmm0, %k1
|
2017-01-09 10:44:34 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k1} {z}
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v16i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtd %zmm1, %zmm0, %k0
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v16i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-03-23 17:57:01 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtd %zmm1, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $zmm0
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
2017-01-09 05:32:30 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <16 x i32> %a0, %a1
|
|
|
|
ret <16 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <32 x i1> @test_cmp_v32i16(<32 x i16> %a0, <32 x i16> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpgtw %xmm5, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtw %xmm4, %xmm0
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm1, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpgtw %xmm7, %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtw %xmm6, %xmm2
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm3, %xmm2
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm2, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw %xmm5, %xmm1
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw %xmm4, %xmm0
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw %xmm7, %xmm3
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw %xmm6, %xmm2
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pextrb $2, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm2, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pextrb $2, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm0, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm4
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm4, %xmm5, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm3, %xmm1, %xmm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm4, %xmm1, %xmm1
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm3, %xmm4, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm2, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm3, %xmm0, %xmm0
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vinsertf128 $1, %xmm1, %ymm0, %ymm0
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm3, %ymm1, %ymm1
|
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm2, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpacksswb %ymm1, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm2, %ymm0, %ymm0
|
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm0, %zmm0
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm3, %ymm1, %ymm1
|
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm1, %zmm1
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm1, %xmm1
|
|
|
|
; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm2, %ymm0, %ymm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm3, %ymm1, %ymm1
|
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm1, %zmm1
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm1, %xmm1
|
|
|
|
; AVX512DQ-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v32i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-03-23 17:57:01 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtw %zmm1, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $ymm0 killed $ymm0 killed $zmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <32 x i16> %a0, %a1
|
|
|
|
ret <32 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <64 x i1> @test_cmp_v64i8(<64 x i8> %a0, <64 x i8> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: pcmpgtb %xmm4, %xmm0
|
|
|
|
; SSE2-NEXT: pcmpgtb %xmm5, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtb %xmm6, %xmm2
|
|
|
|
; SSE2-NEXT: pcmpgtb %xmm7, %xmm3
|
|
|
|
; SSE2-NEXT: movdqa %xmm3, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 6(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm2, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 4(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm1, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pcmpgtb %xmm4, %xmm0
|
|
|
|
; SSE42-NEXT: pcmpgtb %xmm5, %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtb %xmm6, %xmm2
|
|
|
|
; SSE42-NEXT: pcmpgtb %xmm7, %xmm3
|
|
|
|
; SSE42-NEXT: pextrb $1, %xmm3, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm3, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 6(%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm2, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 4(%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm1, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm0, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm4
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm4, %xmm5, %xmm4
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm2, %xmm0, %xmm0
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm2, %xmm5, %xmm2
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm3, %xmm1, %xmm1
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm1, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, 4(%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm0, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm0, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm0, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm0, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm0, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm0, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX1-NEXT: movq %rdi, %rax
|
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm2, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm3, %ymm1, %ymm1
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm1, %xmm1
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, 4(%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm0, %eax
|
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, (%rdi)
|
2016-03-30 21:55:00 +08:00
|
|
|
; AVX2-NEXT: movq %rdi, %rax
|
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
2016-04-03 05:24:42 +08:00
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtb %ymm2, %ymm0, %ymm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vextracti128 $1, %ymm0, %xmm4
|
|
|
|
; AVX512F-NEXT: vpcmpgtb %ymm3, %ymm1, %ymm2
|
|
|
|
; AVX512F-NEXT: vextracti128 $1, %ymm2, %xmm3
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512F-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vmovdqa %xmm4, %xmm1
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512F-NEXT: # kill: def $xmm2 killed $xmm2 killed $ymm2
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtb %ymm2, %ymm0, %ymm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vextracti128 $1, %ymm0, %xmm4
|
|
|
|
; AVX512DQ-NEXT: vpcmpgtb %ymm3, %ymm1, %ymm2
|
|
|
|
; AVX512DQ-NEXT: vextracti128 $1, %ymm2, %xmm3
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512DQ-NEXT: # kill: def $xmm0 killed $xmm0 killed $ymm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vmovdqa %xmm4, %xmm1
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512DQ-NEXT: # kill: def $xmm2 killed $xmm2 killed $ymm2
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v64i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtb %zmm1, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
|
|
|
; AVX512BW-NEXT: retq
|
2016-03-30 21:55:00 +08:00
|
|
|
%1 = icmp sgt <64 x i8> %a0, %a1
|
|
|
|
ret <64 x i1> %1
|
|
|
|
}
|
2016-04-03 05:33:09 +08:00
|
|
|
|
|
|
|
;
|
|
|
|
; 1024-bit vector comparisons
|
|
|
|
;
|
|
|
|
|
|
|
|
define <16 x i1> @test_cmp_v16f64(<16 x double> %a0, <16 x double> %a1) nounwind {
|
|
|
|
; SSE-LABEL: test_cmp_v16f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE-NEXT: movapd %xmm0, %xmm8
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm11
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm10
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm12
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm9
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm13
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm14
|
|
|
|
; SSE-NEXT: movapd {{[0-9]+}}(%rsp), %xmm15
|
|
|
|
; SSE-NEXT: cmpltpd %xmm7, %xmm15
|
|
|
|
; SSE-NEXT: cmpltpd %xmm6, %xmm14
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm15, %xmm14
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm5, %xmm13
|
|
|
|
; SSE-NEXT: cmpltpd %xmm4, %xmm9
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm13, %xmm9
|
|
|
|
; SSE-NEXT: packssdw %xmm14, %xmm9
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm3, %xmm12
|
|
|
|
; SSE-NEXT: cmpltpd %xmm2, %xmm10
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm12, %xmm10
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE-NEXT: cmpltpd %xmm1, %xmm11
|
|
|
|
; SSE-NEXT: cmpltpd %xmm8, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE-NEXT: packssdw %xmm11, %xmm0
|
|
|
|
; SSE-NEXT: packssdw %xmm10, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; SSE-NEXT: packsswb %xmm9, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v16f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm3, %ymm7, %ymm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm3, %xmm3
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm2, %ymm6, %ymm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm6, %xmm2, %xmm2
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm2, %xmm2
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm1, %ymm5, %ymm1
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm0, %ymm4, %ymm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm2, %xmm0, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v16f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm3, %ymm7, %ymm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm2, %ymm6, %ymm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm3, %ymm2, %ymm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,1,3]
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm1, %ymm5, %ymm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vcmpltpd %ymm0, %ymm4, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2018-02-15 02:23:58 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm2, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
|
|
|
; AVX2-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v16f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm0, %zmm2, %k0
|
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm1, %zmm3, %k1
|
|
|
|
; AVX512F-NEXT: kunpckbw %k0, %k1, %k1
|
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k1} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vzeroupper
|
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v16f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm0, %zmm2, %k0
|
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm1, %zmm3, %k1
|
|
|
|
; AVX512DQ-NEXT: kunpckbw %k0, %k1, %k0
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v16f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm0, %zmm2, %k0
|
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm1, %zmm3, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckbw %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $zmm0
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
|
|
|
; AVX512BW-NEXT: retq
|
2016-04-03 05:33:09 +08:00
|
|
|
%1 = fcmp ogt <16 x double> %a0, %a1
|
|
|
|
ret <16 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <32 x i1> @test_cmp_v32f32(<32 x float> %a0, <32 x float> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm9
|
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm11
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm10
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm12
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm8
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm13
|
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm14
|
|
|
|
; SSE2-NEXT: movaps {{[0-9]+}}(%rsp), %xmm15
|
|
|
|
; SSE2-NEXT: cmpltps %xmm3, %xmm15
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movaps {{.*#+}} xmm3 = [255,255,255,255]
|
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm15
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm2, %xmm14
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm14
|
|
|
|
; SSE2-NEXT: packuswb %xmm15, %xmm14
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm1, %xmm13
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm13
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm0, %xmm8
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm8
|
|
|
|
; SSE2-NEXT: packuswb %xmm13, %xmm8
|
|
|
|
; SSE2-NEXT: packuswb %xmm14, %xmm8
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm7, %xmm12
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm12
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm6, %xmm10
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm10
|
|
|
|
; SSE2-NEXT: packuswb %xmm12, %xmm10
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm5, %xmm11
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm11
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: cmpltps %xmm4, %xmm9
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andps %xmm3, %xmm9
|
|
|
|
; SSE2-NEXT: packuswb %xmm11, %xmm9
|
|
|
|
; SSE2-NEXT: packuswb %xmm10, %xmm9
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm9, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm8, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm15
|
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm14
|
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm13
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm12
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm11
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm10
|
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm9
|
|
|
|
; SSE42-NEXT: movaps {{[0-9]+}}(%rsp), %xmm8
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: cmpltps %xmm3, %xmm8
|
|
|
|
; SSE42-NEXT: cmpltps %xmm2, %xmm9
|
|
|
|
; SSE42-NEXT: cmpltps %xmm1, %xmm10
|
|
|
|
; SSE42-NEXT: cmpltps %xmm0, %xmm11
|
|
|
|
; SSE42-NEXT: cmpltps %xmm7, %xmm12
|
|
|
|
; SSE42-NEXT: cmpltps %xmm6, %xmm13
|
|
|
|
; SSE42-NEXT: cmpltps %xmm5, %xmm14
|
|
|
|
; SSE42-NEXT: cmpltps %xmm4, %xmm15
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE42-NEXT: pextrb $4, %xmm15, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm15, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm15, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm15, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm14, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE42-NEXT: pextrb $4, %xmm14, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm14, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm14, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm13, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm13, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm13, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm13, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm12, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm12, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm12, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm12, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE42-NEXT: pextrb $4, %xmm11, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm11, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm11, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm11, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm10, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE42-NEXT: pextrb $4, %xmm10, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm10, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm10, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm9, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm9, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm9, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm9, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm8, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm8, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm8, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm8, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm3, %ymm7, %ymm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm3, %xmm3
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm2, %ymm6, %ymm2
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm6, %xmm2, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm3, %xmm2, %xmm2
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm1, %ymm5, %ymm1
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vcmpltps %ymm0, %ymm4, %ymm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vinsertf128 $1, %xmm2, %ymm0, %ymm0
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vcmpltps %ymm3, %ymm7, %ymm3
|
|
|
|
; AVX2-NEXT: vcmpltps %ymm2, %ymm6, %ymm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm3, %ymm2, %ymm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,1,3]
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vcmpltps %ymm1, %ymm5, %ymm1
|
|
|
|
; AVX2-NEXT: vcmpltps %ymm0, %ymm4, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vpacksswb %ymm2, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vcmpltps %zmm1, %zmm3, %k1
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vcmpltps %zmm0, %zmm2, %k2
|
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k2} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm1, %zmm1, %zmm1 {%k1} {z}
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm1, %xmm1
|
2017-11-28 07:51:40 +08:00
|
|
|
; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltps %zmm1, %zmm3, %k0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltps %zmm0, %zmm2, %k1
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k1, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm1
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm1, %xmm1
|
2017-11-28 07:51:40 +08:00
|
|
|
; AVX512DQ-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v32f32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512BW-NEXT: vcmpltps %zmm0, %zmm2, %k0
|
|
|
|
; AVX512BW-NEXT: vcmpltps %zmm1, %zmm3, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckwd %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $ymm0 killed $ymm0 killed $zmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2017-08-17 23:40:25 +08:00
|
|
|
%1 = fcmp ogt <32 x float> %a0, %a1
|
|
|
|
ret <32 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <16 x i1> @test_cmp_v16i64(<16 x i64> %a0, <16 x i64> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm8 = [2147483648,0,2147483648,0]
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm7
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm9
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm9
|
|
|
|
; SSE2-NEXT: movdqa %xmm7, %xmm10
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm9, %xmm10
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm11 = xmm10[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm7, %xmm9
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm7 = xmm9[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm11, %xmm7
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm10[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm7, %xmm9
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm6
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm7
|
|
|
|
; SSE2-NEXT: movdqa %xmm6, %xmm10
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm7, %xmm10
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm11 = xmm10[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm6, %xmm7
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm7 = xmm7[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm11, %xmm7
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm10 = xmm10[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm7, %xmm10
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm9, %xmm10
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm5
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm7
|
|
|
|
; SSE2-NEXT: movdqa %xmm5, %xmm6
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm7, %xmm6
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm6[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm5, %xmm7
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm7[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm9, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm6[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm5, %xmm6
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm5
|
|
|
|
; SSE2-NEXT: movdqa %xmm4, %xmm7
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm5, %xmm7
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm7[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm4, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm5[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm9, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm7[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm5, %xmm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm6, %xmm4
|
|
|
|
; SSE2-NEXT: packssdw %xmm10, %xmm4
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm3
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm5
|
|
|
|
; SSE2-NEXT: movdqa %xmm3, %xmm6
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm5, %xmm6
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm7 = xmm6[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm3, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm5[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm7, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm6[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm3, %xmm5
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm2
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm3
|
|
|
|
; SSE2-NEXT: movdqa %xmm2, %xmm6
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm3, %xmm6
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm7 = xmm6[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm2, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm3[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm7, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm6[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm3, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm5, %xmm2
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm3
|
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm5
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm3, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm5[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm1, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm3[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm5[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm1, %xmm3
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: pxor {{[0-9]+}}(%rsp), %xmm8
|
|
|
|
; SSE2-NEXT: movdqa %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm8, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm1[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm8
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm8[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm5, %xmm6
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm6, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE2-NEXT: packssdw %xmm3, %xmm0
|
|
|
|
; SSE2-NEXT: packssdw %xmm2, %xmm0
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm4, %xmm0
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm7, %xmm6
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm5, %xmm4
|
|
|
|
; SSE42-NEXT: packssdw %xmm6, %xmm4
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm3, %xmm2
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; SSE42-NEXT: packssdw %xmm1, %xmm0
|
|
|
|
; SSE42-NEXT: packssdw %xmm2, %xmm0
|
2017-08-17 23:40:25 +08:00
|
|
|
; SSE42-NEXT: packsswb %xmm4, %xmm0
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm7, %xmm8
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm9
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm8, %xmm9, %xmm8
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm7, %xmm3, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm8, %xmm3, %xmm8
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm7
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm7, %xmm3, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm6, %xmm2, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm2, %xmm2
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm8, %xmm2, %xmm2
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm6
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm3, %xmm6, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm5, %xmm1, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm4, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm3, %xmm5, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm4, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm2, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm7, %ymm3, %ymm3
|
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm6, %ymm2, %ymm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm3, %ymm2, %ymm2
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm5, %ymm1, %ymm1
|
|
|
|
; AVX2-NEXT: vpcmpgtq %ymm4, %ymm0, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2018-02-15 02:23:58 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm2, %ymm0, %ymm0
|
2017-08-17 23:40:25 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm1
|
|
|
|
; AVX2-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-11-28 01:51:55 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-11-28 01:51:55 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm2, %zmm0, %k0
|
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm3, %zmm1, %k1
|
|
|
|
; AVX512F-NEXT: kunpckbw %k0, %k1, %k1
|
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k1} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vzeroupper
|
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-11-28 01:51:55 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm2, %zmm0, %k0
|
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm3, %zmm1, %k1
|
|
|
|
; AVX512DQ-NEXT: kunpckbw %k0, %k1, %k0
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v16i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 01:51:55 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm2, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm3, %zmm1, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckbw %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $xmm0 killed $xmm0 killed $zmm0
|
2017-11-28 01:51:55 +08:00
|
|
|
; AVX512BW-NEXT: vzeroupper
|
|
|
|
; AVX512BW-NEXT: retq
|
2016-04-03 05:33:09 +08:00
|
|
|
%1 = icmp sgt <16 x i64> %a0, %a1
|
|
|
|
ret <16 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <32 x i1> @test_cmp_v32i32(<32 x i32> %a0, <32 x i32> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm3
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm8 = [255,255,255,255]
|
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm3
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm2
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm2
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm1
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm0
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm0
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm7
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm7
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm6
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm6
|
|
|
|
; SSE2-NEXT: packuswb %xmm7, %xmm6
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm5
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm5
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm4
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: packuswb %xmm5, %xmm4
|
|
|
|
; SSE2-NEXT: packuswb %xmm6, %xmm4
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm4, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2017-10-05 01:31:28 +08:00
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm3
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm0
|
2017-10-05 01:31:28 +08:00
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm7
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm6
|
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE42-NEXT: pcmpgtd {{[0-9]+}}(%rsp), %xmm4
|
2017-10-05 01:31:28 +08:00
|
|
|
; SSE42-NEXT: pextrb $4, %xmm4, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm5, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2017-10-05 01:31:28 +08:00
|
|
|
; SSE42-NEXT: pextrb $4, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm1, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm7, %xmm8
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm9
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm8, %xmm9, %xmm8
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm7, %xmm3, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm8, %xmm3, %xmm8
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm7
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm7, %xmm3, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm6, %xmm2, %xmm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm2, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm8, %xmm2, %xmm2
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm6
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm3, %xmm6, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm5, %xmm1, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm4, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm3, %xmm5, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtd %xmm4, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm1, %xmm0, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vinsertf128 $1, %xmm2, %ymm0, %ymm0
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm7, %ymm3, %ymm3
|
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm6, %ymm2, %ymm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm3, %ymm2, %ymm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,1,3]
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm5, %ymm1, %ymm1
|
|
|
|
; AVX2-NEXT: vpcmpgtd %ymm4, %ymm0, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vpacksswb %ymm2, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtd %zmm3, %zmm1, %k1
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtd %zmm2, %zmm0, %k2
|
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k2} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm1, %zmm1, %zmm1 {%k1} {z}
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm1, %xmm1
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtd %zmm3, %zmm1, %k0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtd %zmm2, %zmm0, %k1
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k1, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm1
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm1, %xmm1
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v32i32:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtd %zmm2, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpcmpgtd %zmm3, %zmm1, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckwd %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $ymm0 killed $ymm0 killed $zmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-04-03 05:33:09 +08:00
|
|
|
%1 = icmp sgt <32 x i32> %a0, %a1
|
|
|
|
ret <32 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <64 x i1> @test_cmp_v64i16(<64 x i16> %a0, <64 x i16> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm0
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm1, %xmm0
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm2
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm3, %xmm2
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm4
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm5, %xmm4
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE2-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm6
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE2-NEXT: packsswb %xmm7, %xmm6
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm6, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 6(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm4, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 4(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm2, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm1
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm0
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm3
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm2
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm5
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm4
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm7
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pcmpgtw {{[0-9]+}}(%rsp), %xmm6
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pextrb $2, %xmm6, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm6, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 6(%rdi)
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pextrb $2, %xmm4, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm4, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm4, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 4(%rdi)
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pextrb $2, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm2, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2017-02-28 05:01:57 +08:00
|
|
|
; SSE42-NEXT: pextrb $2, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm0, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm8
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm9
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm8, %xmm9, %xmm8
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm5, %xmm1, %xmm9
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm4, %xmm5
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm1
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm5, %xmm1, %xmm5
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm4, %xmm0, %xmm0
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm7, %xmm1
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm4
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm1, %xmm4, %xmm4
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm7, %xmm3, %xmm3
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm1
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm7
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm1, %xmm7, %xmm7
|
|
|
|
; AVX1-NEXT: vpcmpgtw %xmm6, %xmm2, %xmm2
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm2, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm2, %eax
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm7, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm7, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm7, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm7, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm7, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm7, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm7, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm7, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, 4(%rdi)
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm0, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm0, %eax
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm0, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: movq %rdi, %rax
|
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm5, %ymm1, %ymm5
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm5, %xmm1
|
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm4, %ymm0, %ymm4
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm4, %xmm0
|
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm7, %ymm3, %ymm7
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm7, %xmm3
|
|
|
|
; AVX2-NEXT: vpcmpgtw %ymm6, %ymm2, %ymm6
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm6, %xmm2
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm6, %eax
|
|
|
|
; AVX2-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm6, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm6, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm6, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm6, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm6, %eax
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm6, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm6, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm7, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm7, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm7, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm7, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm7, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm7, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm7, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm7, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, 4(%rdi)
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm4, %eax
|
|
|
|
; AVX2-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm4, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm4, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm4, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm4, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm4, %eax
|
2017-06-10 01:29:52 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm4, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm4, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm5, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm5, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm5, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm5, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm5, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm5, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm5, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm5, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: movq %rdi, %rax
|
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-12-14 16:25:58 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm7, %ymm3, %ymm3
|
2018-01-13 14:24:46 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm6, %ymm2, %ymm2
|
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm5, %ymm1, %ymm1
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtw %ymm4, %ymm0, %ymm0
|
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm0, %zmm0
|
2017-12-14 16:25:58 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm1, %zmm1
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm1, %xmm1
|
2018-01-13 14:24:46 +08:00
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm2, %zmm2
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm2, %xmm2
|
|
|
|
; AVX512F-NEXT: vpmovsxwd %ymm3, %zmm3
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm3, %xmm3
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-12-14 16:25:58 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm7, %ymm3, %ymm3
|
2018-01-13 14:24:46 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm6, %ymm2, %ymm2
|
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm5, %ymm1, %ymm1
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtw %ymm4, %ymm0, %ymm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm0, %zmm0
|
2017-12-14 16:25:58 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm1, %zmm1
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm1, %xmm1
|
2018-01-13 14:24:46 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm2, %zmm2
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm2, %xmm2
|
|
|
|
; AVX512DQ-NEXT: vpmovsxwd %ymm3, %zmm3
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm3, %xmm3
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v64i16:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 01:51:55 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtw %zmm2, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpcmpgtw %zmm3, %zmm1, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckdq %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-04-03 05:33:09 +08:00
|
|
|
%1 = icmp sgt <64 x i16> %a0, %a1
|
|
|
|
ret <64 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <128 x i1> @test_cmp_v128i8(<128 x i8> %a0, <128 x i8> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: pushq %rax
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm6
|
|
|
|
; SSE2-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE2-NEXT: movdqa %xmm7, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 14(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm6, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 12(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm5, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 10(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm4, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 8(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm3, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 6(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm2, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 4(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm1, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
In visitSTORE, always use FindBetterChain, rather than only when UseAA is enabled.
Recommiting with compiler time improvements
Recommitting after fixup of 32-bit aliasing sign offset bug in DAGCombiner.
* Simplify Consecutive Merge Store Candidate Search
Now that address aliasing is much less conservative, push through
simplified store merging search and chain alias analysis which only
checks for parallel stores through the chain subgraph. This is cleaner
as the separation of non-interfering loads/stores from the
store-merging logic.
When merging stores search up the chain through a single load, and
finds all possible stores by looking down from through a load and a
TokenFactor to all stores visited.
This improves the quality of the output SelectionDAG and the output
Codegen (save perhaps for some ARM cases where we correctly constructs
wider loads, but then promotes them to float operations which appear
but requires more expensive constant generation).
Some minor peephole optimizations to deal with improved SubDAG shapes (listed below)
Additional Minor Changes:
1. Finishes removing unused AliasLoad code
2. Unifies the chain aggregation in the merged stores across code
paths
3. Re-add the Store node to the worklist after calling
SimplifyDemandedBits.
4. Increase GatherAllAliasesMaxDepth from 6 to 18. That number is
arbitrary, but seems sufficient to not cause regressions in
tests.
5. Remove Chain dependencies of Memory operations on CopyfromReg
nodes as these are captured by data dependence
6. Forward loads-store values through tokenfactors containing
{CopyToReg,CopyFromReg} Values.
7. Peephole to convert buildvector of extract_vector_elt to
extract_subvector if possible (see
CodeGen/AArch64/store-merge.ll)
8. Store merging for the ARM target is restricted to 32-bit as
some in some contexts invalid 64-bit operations are being
generated. This can be removed once appropriate checks are
added.
This finishes the change Matt Arsenault started in r246307 and
jyknight's original patch.
Many tests required some changes as memory operations are now
reorderable, improving load-store forwarding. One test in
particular is worth noting:
CodeGen/PowerPC/ppc64-align-long-double.ll - Improved load-store
forwarding converts a load-store pair into a parallel store and
a memory-realized bitcast of the same value. However, because we
lose the sharing of the explicit and implicit store values we
must create another local store. A similar transformation
happens before SelectionDAG as well.
Reviewers: arsenm, hfinkel, tstellarAMD, jyknight, nhaehnle
llvm-svn: 297695
2017-03-14 08:34:14 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: popq %rcx
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm6
|
|
|
|
; SSE42-NEXT: pcmpgtb {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE42-NEXT: pextrb $1, %xmm7, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm7, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm7, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 14(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm6, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm6, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm6, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 12(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm5, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm5, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm5, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm5, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 10(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm4, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm4, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm4, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm4, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm4, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm4, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm4, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm4, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 8(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm3, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm3, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm3, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm3, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 6(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm2, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm2, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm2, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 4(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm1, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm1, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm1, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: pextrb $1, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE42-NEXT: pextrb $2, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE42-NEXT: pextrb $3, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE42-NEXT: pextrb $4, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $5, %xmm0, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
|
|
|
; SSE42-NEXT: pextrb $6, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $7, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $9, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $10, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $11, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $12, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $13, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: pextrb $14, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $15, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm4, %xmm8
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm9
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm8, %xmm9, %xmm8
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm4, %xmm0, %xmm9
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm4
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm0
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm4, %xmm0, %xmm4
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm5, %xmm1, %xmm1
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm0, %xmm5, %xmm5
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm6, %xmm2, %xmm2
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm7, %xmm0
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm6
|
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm0, %xmm6, %xmm6
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtb %xmm7, %xmm3, %xmm3
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm3, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm3, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm3, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm3, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm6, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm6, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, 12(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm2, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm2, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm2, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm5, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm5, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, 8(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm1, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm1, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm1, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm4, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm4, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, 4(%rdi)
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm9, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $4, %ecx
|
|
|
|
; AVX1-NEXT: orl %eax, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm9, %eax
|
|
|
|
; AVX1-NEXT: andl $1, %eax
|
|
|
|
; AVX1-NEXT: shll $5, %eax
|
|
|
|
; AVX1-NEXT: orl %ecx, %eax
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $6, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $7, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $8, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $9, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $10, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $11, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $12, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $13, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm9, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $14, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm9, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $15, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $0, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $16, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $1, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $17, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $2, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $18, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $3, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $19, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $4, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $20, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $5, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $21, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $6, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $22, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $7, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $23, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $8, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $24, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $9, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $25, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $10, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $26, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $11, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $27, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $12, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $28, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $13, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: andl $1, %edx
|
|
|
|
; AVX1-NEXT: shll $29, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: vpextrb $14, %xmm8, %ecx
|
|
|
|
; AVX1-NEXT: andl $1, %ecx
|
|
|
|
; AVX1-NEXT: shll $30, %ecx
|
|
|
|
; AVX1-NEXT: orl %edx, %ecx
|
|
|
|
; AVX1-NEXT: vpextrb $15, %xmm8, %edx
|
|
|
|
; AVX1-NEXT: shll $31, %edx
|
|
|
|
; AVX1-NEXT: orl %ecx, %edx
|
|
|
|
; AVX1-NEXT: orl %eax, %edx
|
|
|
|
; AVX1-NEXT: movl %edx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX1-NEXT: movq %rdi, %rax
|
|
|
|
; AVX1-NEXT: vzeroupper
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm4, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm5, %ymm1, %ymm1
|
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm6, %ymm2, %ymm2
|
|
|
|
; AVX2-NEXT: vpcmpgtb %ymm7, %ymm3, %ymm3
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm3, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm3, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm3, %xmm3
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm3, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm3, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, 12(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm2, %xmm2
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm2, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm2, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, 8(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm1, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm1, %xmm1
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm1, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm1, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, 4(%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $4, %ecx
|
|
|
|
; AVX2-NEXT: orl %eax, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm0, %eax
|
|
|
|
; AVX2-NEXT: andl $1, %eax
|
|
|
|
; AVX2-NEXT: shll $5, %eax
|
|
|
|
; AVX2-NEXT: orl %ecx, %eax
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $6, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $7, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $8, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $9, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $10, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $11, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $12, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $13, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $14, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $15, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX2-NEXT: vpextrb $0, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $16, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $1, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $17, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $2, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $18, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $3, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $19, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $4, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $20, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $5, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $21, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $6, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $22, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $7, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $23, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $8, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $24, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $9, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $25, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $10, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $26, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $11, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $27, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $12, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $28, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $13, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: andl $1, %edx
|
|
|
|
; AVX2-NEXT: shll $29, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: vpextrb $14, %xmm0, %ecx
|
|
|
|
; AVX2-NEXT: andl $1, %ecx
|
|
|
|
; AVX2-NEXT: shll $30, %ecx
|
|
|
|
; AVX2-NEXT: orl %edx, %ecx
|
|
|
|
; AVX2-NEXT: vpextrb $15, %xmm0, %edx
|
|
|
|
; AVX2-NEXT: shll $31, %edx
|
|
|
|
; AVX2-NEXT: orl %ecx, %edx
|
|
|
|
; AVX2-NEXT: orl %eax, %edx
|
|
|
|
; AVX2-NEXT: movl %edx, (%rdi)
|
2016-04-03 05:33:09 +08:00
|
|
|
; AVX2-NEXT: movq %rdi, %rax
|
|
|
|
; AVX2-NEXT: vzeroupper
|
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtb %ymm4, %ymm0, %ymm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm4
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vptestmd %zmm4, %zmm4, %k0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm0
|
|
|
|
; AVX512F-NEXT: vptestmd %zmm0, %zmm0, %k1
|
|
|
|
; AVX512F-NEXT: vpcmpgtb %ymm5, %ymm1, %ymm0
|
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm1
|
|
|
|
; AVX512F-NEXT: vptestmd %zmm1, %zmm1, %k2
|
|
|
|
; AVX512F-NEXT: vextracti128 $1, %ymm0, %xmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vptestmd %zmm0, %zmm0, %k3
|
|
|
|
; AVX512F-NEXT: vpcmpgtb %ymm6, %ymm2, %ymm0
|
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm1
|
|
|
|
; AVX512F-NEXT: vptestmd %zmm1, %zmm1, %k4
|
|
|
|
; AVX512F-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm0
|
|
|
|
; AVX512F-NEXT: vptestmd %zmm0, %zmm0, %k5
|
|
|
|
; AVX512F-NEXT: vpcmpgtb %ymm7, %ymm3, %ymm0
|
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm1
|
|
|
|
; AVX512F-NEXT: vptestmd %zmm1, %zmm1, %k6
|
|
|
|
; AVX512F-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX512F-NEXT: vpmovsxbd %xmm0, %zmm0
|
|
|
|
; AVX512F-NEXT: vptestmd %zmm0, %zmm0, %k7
|
|
|
|
; AVX512F-NEXT: kmovw %k7, 14(%rdi)
|
|
|
|
; AVX512F-NEXT: kmovw %k6, 12(%rdi)
|
|
|
|
; AVX512F-NEXT: kmovw %k5, 10(%rdi)
|
|
|
|
; AVX512F-NEXT: kmovw %k4, 8(%rdi)
|
|
|
|
; AVX512F-NEXT: kmovw %k3, 6(%rdi)
|
|
|
|
; AVX512F-NEXT: kmovw %k2, 4(%rdi)
|
|
|
|
; AVX512F-NEXT: kmovw %k1, 2(%rdi)
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: kmovw %k0, (%rdi)
|
|
|
|
; AVX512F-NEXT: movq %rdi, %rax
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512F-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtb %ymm4, %ymm0, %ymm0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm4
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm4, %k0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm0
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm0, %k1
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtb %ymm5, %ymm1, %ymm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm1
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm1, %k2
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm0
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm0, %k3
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtb %ymm6, %ymm2, %ymm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm1
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm1, %k4
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vextracti128 $1, %ymm0, %xmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm0
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm0, %k5
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtb %ymm7, %ymm3, %ymm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm1
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm1, %k6
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vextracti128 $1, %ymm0, %xmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovsxbd %xmm0, %zmm0
|
2018-02-20 06:07:31 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovd2m %zmm0, %k7
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: kmovw %k7, 14(%rdi)
|
|
|
|
; AVX512DQ-NEXT: kmovw %k6, 12(%rdi)
|
|
|
|
; AVX512DQ-NEXT: kmovw %k5, 10(%rdi)
|
|
|
|
; AVX512DQ-NEXT: kmovw %k4, 8(%rdi)
|
|
|
|
; AVX512DQ-NEXT: kmovw %k3, 6(%rdi)
|
|
|
|
; AVX512DQ-NEXT: kmovw %k2, 4(%rdi)
|
|
|
|
; AVX512DQ-NEXT: kmovw %k1, 2(%rdi)
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: kmovw %k0, (%rdi)
|
|
|
|
; AVX512DQ-NEXT: movq %rdi, %rax
|
2017-03-03 17:03:24 +08:00
|
|
|
; AVX512DQ-NEXT: vzeroupper
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v128i8:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtb %zmm3, %zmm1, %k0
|
|
|
|
; AVX512BW-NEXT: vpcmpgtb %zmm2, %zmm0, %k1
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k1, %zmm0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm1
|
|
|
|
; AVX512BW-NEXT: retq
|
2016-04-03 05:33:09 +08:00
|
|
|
%1 = icmp sgt <128 x i8> %a0, %a1
|
|
|
|
ret <128 x i1> %1
|
|
|
|
}
|
2016-07-26 01:56:01 +08:00
|
|
|
|
|
|
|
;
|
|
|
|
; 2048-bit vector comparisons
|
|
|
|
;
|
|
|
|
|
|
|
|
define <32 x i1> @test_cmp_v32f64(<32 x double> %a0, <32 x double> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm8
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: cmpltpd %xmm1, %xmm8
|
2017-09-19 00:45:05 +08:00
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm1
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: cmpltpd %xmm0, %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movapd {{.*#+}} xmm9 = [255,255]
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm8
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm8, %xmm1
|
2017-10-05 01:20:12 +08:00
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: cmpltpd %xmm3, %xmm0
|
2017-10-05 01:20:12 +08:00
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm3
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: cmpltpd %xmm2, %xmm3
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm3[1,1,2,3]
|
|
|
|
; SSE2-NEXT: punpckldq {{.*#+}} xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd %xmm7, %xmm0
|
2017-10-05 01:20:12 +08:00
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm3
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: cmpltpd %xmm6, %xmm3
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm3
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd %xmm5, %xmm0
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm6
|
|
|
|
; SSE2-NEXT: cmpltpd %xmm4, %xmm6
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm6
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm6
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm6, %xmm6
|
|
|
|
; SSE2-NEXT: packuswb %xmm6, %xmm6
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm6[0,1,2,2]
|
|
|
|
; SSE2-NEXT: punpckhdq {{.*#+}} xmm4 = xmm4[2],xmm3[2],xmm4[3],xmm3[3]
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm3
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movsd {{.*#+}} xmm4 = xmm1[0],xmm4[1]
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
2017-10-28 22:27:53 +08:00
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm3
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm3
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm5
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm5
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm5, %xmm5
|
|
|
|
; SSE2-NEXT: packuswb %xmm5, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm5[1,1,2,3]
|
|
|
|
; SSE2-NEXT: punpckldq {{.*#+}} xmm3 = xmm3[0],xmm0[0],xmm3[1],xmm0[1]
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm0
|
|
|
|
; SSE2-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE2-NEXT: andpd %xmm9, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm1
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm2[0,1,2,2]
|
|
|
|
; SSE2-NEXT: punpckhdq {{.*#+}} xmm0 = xmm0[2],xmm1[2],xmm0[3],xmm1[3]
|
|
|
|
; SSE2-NEXT: movsd {{.*#+}} xmm0 = xmm3[0],xmm0[1]
|
|
|
|
; SSE2-NEXT: movapd %xmm0, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movapd %xmm4, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE42-NEXT: pushq %rbp
|
|
|
|
; SSE42-NEXT: pushq %r15
|
|
|
|
; SSE42-NEXT: pushq %r14
|
|
|
|
; SSE42-NEXT: pushq %r13
|
|
|
|
; SSE42-NEXT: pushq %r12
|
|
|
|
; SSE42-NEXT: pushq %rbx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, -{{[0-9]+}}(%rsp) # 8-byte Spill
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm8
|
2018-01-12 08:17:38 +08:00
|
|
|
; SSE42-NEXT: cmpltpd %xmm7, %xmm8
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm7
|
|
|
|
; SSE42-NEXT: cmpltpd %xmm6, %xmm7
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm6
|
|
|
|
; SSE42-NEXT: cmpltpd %xmm5, %xmm6
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE42-NEXT: cmpltpd %xmm4, %xmm5
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE42-NEXT: cmpltpd %xmm3, %xmm4
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE42-NEXT: cmpltpd %xmm2, %xmm3
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE42-NEXT: cmpltpd %xmm1, %xmm2
|
2018-01-11 22:25:18 +08:00
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm1
|
2018-01-12 08:17:38 +08:00
|
|
|
; SSE42-NEXT: cmpltpd %xmm0, %xmm1
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %r8d
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %r10d
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ebp
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %edi
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %r15d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %r11d
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %r14d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %r9d
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %esi
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %r12d
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %edx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ebx
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %r13d
|
|
|
|
; SSE42-NEXT: movapd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: cmpltpd {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE42-NEXT: andl $1, %r8d
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %r10d
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: leal (%r10,%r8,2), %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ebp
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: leal (%rcx,%rbp,4), %r8d
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %ebp
|
|
|
|
; SSE42-NEXT: andl $1, %edi
|
|
|
|
; SSE42-NEXT: leal (%r8,%rdi,8), %r8d
|
|
|
|
; SSE42-NEXT: andl $1, %r15d
|
|
|
|
; SSE42-NEXT: shll $4, %r15d
|
|
|
|
; SSE42-NEXT: orl %r8d, %r15d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %edi
|
|
|
|
; SSE42-NEXT: movq %rdi, -{{[0-9]+}}(%rsp) # 8-byte Spill
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %r10d
|
|
|
|
; SSE42-NEXT: andl $1, %r11d
|
|
|
|
; SSE42-NEXT: shll $5, %r11d
|
|
|
|
; SSE42-NEXT: orl %r15d, %r11d
|
|
|
|
; SSE42-NEXT: andl $1, %r14d
|
|
|
|
; SSE42-NEXT: shll $6, %r14d
|
|
|
|
; SSE42-NEXT: andl $1, %r9d
|
|
|
|
; SSE42-NEXT: shll $7, %r9d
|
|
|
|
; SSE42-NEXT: orl %r14d, %r9d
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %r14d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %edi
|
|
|
|
; SSE42-NEXT: movq %rdi, -{{[0-9]+}}(%rsp) # 8-byte Spill
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %esi
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $8, %esi
|
|
|
|
; SSE42-NEXT: orl %r9d, %esi
|
|
|
|
; SSE42-NEXT: andl $1, %r12d
|
|
|
|
; SSE42-NEXT: shll $9, %r12d
|
|
|
|
; SSE42-NEXT: orl %esi, %r12d
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %r8d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %r15d
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $10, %edx
|
|
|
|
; SSE42-NEXT: orl %r12d, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %ebx
|
|
|
|
; SSE42-NEXT: shll $11, %ebx
|
|
|
|
; SSE42-NEXT: orl %edx, %ebx
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm4, %r12d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm4, %edi
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $12, %eax
|
|
|
|
; SSE42-NEXT: orl %ebx, %eax
|
|
|
|
; SSE42-NEXT: andl $1, %r13d
|
|
|
|
; SSE42-NEXT: shll $13, %r13d
|
|
|
|
; SSE42-NEXT: orl %eax, %r13d
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm5, %eax
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm5, %ebx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %r13d, %ecx
|
|
|
|
; SSE42-NEXT: shll $15, %ebp
|
|
|
|
; SSE42-NEXT: orl %ecx, %ebp
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm6, %r13d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm6, %edx
|
|
|
|
; SSE42-NEXT: orl %r11d, %ebp
|
|
|
|
; SSE42-NEXT: movq -{{[0-9]+}}(%rsp), %r9 # 8-byte Reload
|
|
|
|
; SSE42-NEXT: movw %bp, 2(%r9)
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm7, %r11d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm7, %ecx
|
|
|
|
; SSE42-NEXT: movq -{{[0-9]+}}(%rsp), %rsi # 8-byte Reload
|
|
|
|
; SSE42-NEXT: andl $1, %esi
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %r10d
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: leal (%r10,%rsi,2), %esi
|
|
|
|
; SSE42-NEXT: andl $1, %r14d
|
|
|
|
; SSE42-NEXT: leal (%rsi,%r14,4), %r14d
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm8, %r10d
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm8, %ebp
|
|
|
|
; SSE42-NEXT: movq -{{[0-9]+}}(%rsp), %rsi # 8-byte Reload
|
|
|
|
; SSE42-NEXT: andl $1, %esi
|
|
|
|
; SSE42-NEXT: leal (%r14,%rsi,8), %esi
|
|
|
|
; SSE42-NEXT: andl $1, %r8d
|
|
|
|
; SSE42-NEXT: shll $4, %r8d
|
|
|
|
; SSE42-NEXT: orl %esi, %r8d
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %r15d
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $5, %r15d
|
|
|
|
; SSE42-NEXT: orl %r8d, %r15d
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %r12d
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $6, %r12d
|
|
|
|
; SSE42-NEXT: andl $1, %edi
|
|
|
|
; SSE42-NEXT: shll $7, %edi
|
|
|
|
; SSE42-NEXT: orl %r12d, %edi
|
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $8, %eax
|
|
|
|
; SSE42-NEXT: orl %edi, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ebx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $9, %ebx
|
|
|
|
; SSE42-NEXT: orl %eax, %ebx
|
|
|
|
; SSE42-NEXT: andl $1, %r13d
|
|
|
|
; SSE42-NEXT: shll $10, %r13d
|
|
|
|
; SSE42-NEXT: orl %ebx, %r13d
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %r13d, %edx
|
|
|
|
; SSE42-NEXT: andl $1, %r11d
|
|
|
|
; SSE42-NEXT: shll $12, %r11d
|
|
|
|
; SSE42-NEXT: orl %edx, %r11d
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: shll $13, %ecx
|
|
|
|
; SSE42-NEXT: orl %r11d, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %r10d
|
|
|
|
; SSE42-NEXT: shll $14, %r10d
|
|
|
|
; SSE42-NEXT: orl %ecx, %r10d
|
|
|
|
; SSE42-NEXT: shll $15, %ebp
|
|
|
|
; SSE42-NEXT: orl %r10d, %ebp
|
|
|
|
; SSE42-NEXT: orl %r15d, %ebp
|
|
|
|
; SSE42-NEXT: movw %bp, (%r9)
|
|
|
|
; SSE42-NEXT: movq %r9, %rax
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE42-NEXT: popq %rbx
|
|
|
|
; SSE42-NEXT: popq %r12
|
|
|
|
; SSE42-NEXT: popq %r13
|
|
|
|
; SSE42-NEXT: popq %r14
|
|
|
|
; SSE42-NEXT: popq %r15
|
|
|
|
; SSE42-NEXT: popq %rbp
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: pushq %rbp
|
|
|
|
; AVX1-NEXT: movq %rsp, %rbp
|
|
|
|
; AVX1-NEXT: andq $-32, %rsp
|
|
|
|
; AVX1-NEXT: subq $32, %rsp
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vmovapd 16(%rbp), %ymm8
|
|
|
|
; AVX1-NEXT: vmovapd 48(%rbp), %ymm9
|
|
|
|
; AVX1-NEXT: vmovapd 80(%rbp), %ymm10
|
|
|
|
; AVX1-NEXT: vmovapd 112(%rbp), %ymm11
|
|
|
|
; AVX1-NEXT: vmovapd 144(%rbp), %ymm12
|
|
|
|
; AVX1-NEXT: vmovapd 176(%rbp), %ymm13
|
|
|
|
; AVX1-NEXT: vmovapd 208(%rbp), %ymm14
|
|
|
|
; AVX1-NEXT: vmovapd 240(%rbp), %ymm15
|
|
|
|
; AVX1-NEXT: vcmpltpd %ymm7, %ymm15, %ymm15
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm15, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm15, %xmm15
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm6, %ymm14, %ymm6
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm6, %xmm6
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm15, %xmm6, %xmm6
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm5, %ymm13, %ymm5
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm5, %xmm5
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm4, %ymm12, %ymm4
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm4, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm4, %xmm4
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm5, %xmm4, %xmm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm6, %xmm4, %xmm4
|
|
|
|
; AVX1-NEXT: vcmpltpd %ymm3, %ymm11, %ymm3
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm5
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm5, %xmm3, %xmm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm2, %ymm10, %ymm2
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm5
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm5, %xmm2, %xmm2
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm2, %xmm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm1, %ymm9, %ymm1
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vcmpltpd %ymm0, %ymm8, %ymm0
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm2, %xmm0, %xmm0
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vinsertf128 $1, %xmm4, %ymm0, %ymm0
|
|
|
|
; AVX1-NEXT: movq %rbp, %rsp
|
|
|
|
; AVX1-NEXT: popq %rbp
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: pushq %rbp
|
|
|
|
; AVX2-NEXT: movq %rsp, %rbp
|
|
|
|
; AVX2-NEXT: andq $-32, %rsp
|
|
|
|
; AVX2-NEXT: subq $32, %rsp
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vmovapd 16(%rbp), %ymm8
|
|
|
|
; AVX2-NEXT: vmovapd 48(%rbp), %ymm9
|
|
|
|
; AVX2-NEXT: vmovapd 80(%rbp), %ymm10
|
|
|
|
; AVX2-NEXT: vmovapd 112(%rbp), %ymm11
|
|
|
|
; AVX2-NEXT: vmovapd 144(%rbp), %ymm12
|
|
|
|
; AVX2-NEXT: vmovapd 176(%rbp), %ymm13
|
|
|
|
; AVX2-NEXT: vmovapd 208(%rbp), %ymm14
|
|
|
|
; AVX2-NEXT: vmovapd 240(%rbp), %ymm15
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm7, %ymm15, %ymm7
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm6, %ymm14, %ymm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm7, %ymm6, %ymm6
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm6 = ymm6[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm5, %ymm13, %ymm5
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm4, %ymm12, %ymm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm5, %ymm4, %ymm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm4 = ymm4[0,2,1,3]
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm6, %ymm4, %ymm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm4 = ymm4[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm3, %ymm11, %ymm3
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm2, %ymm10, %ymm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm3, %ymm2, %ymm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm1, %ymm9, %ymm1
|
|
|
|
; AVX2-NEXT: vcmpltpd %ymm0, %ymm8, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm2, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vpacksswb %ymm4, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: movq %rbp, %rsp
|
|
|
|
; AVX2-NEXT: popq %rbp
|
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm2, %zmm6, %k0
|
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm3, %zmm7, %k1
|
|
|
|
; AVX512F-NEXT: kunpckbw %k0, %k1, %k1
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm0, %zmm4, %k0
|
|
|
|
; AVX512F-NEXT: vcmpltpd %zmm1, %zmm5, %k2
|
|
|
|
; AVX512F-NEXT: kunpckbw %k0, %k2, %k2
|
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k2} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm1, %zmm1, %zmm1 {%k1} {z}
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm1, %xmm1
|
|
|
|
; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm2, %zmm6, %k0
|
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm3, %zmm7, %k1
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: kunpckbw %k0, %k1, %k0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm0, %zmm4, %k1
|
|
|
|
; AVX512DQ-NEXT: vcmpltpd %zmm1, %zmm5, %k2
|
|
|
|
; AVX512DQ-NEXT: kunpckbw %k1, %k2, %k1
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k1, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm1
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm1, %xmm1
|
|
|
|
; AVX512DQ-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v32f64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm0, %zmm4, %k0
|
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm1, %zmm5, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckbw %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm2, %zmm6, %k1
|
|
|
|
; AVX512BW-NEXT: vcmpltpd %zmm3, %zmm7, %k2
|
|
|
|
; AVX512BW-NEXT: kunpckbw %k1, %k2, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckwd %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $ymm0 killed $ymm0 killed $zmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-07-26 01:56:01 +08:00
|
|
|
%1 = fcmp ogt <32 x double> %a0, %a1
|
|
|
|
ret <32 x i1> %1
|
|
|
|
}
|
|
|
|
|
|
|
|
define <32 x i1> @test_cmp_v32i64(<32 x i64> %a0, <32 x i64> %a1) nounwind {
|
|
|
|
; SSE2-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE2: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm8 = [2147483648,0,2147483648,0]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm9
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm9
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm10
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd %xmm9, %xmm10
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm11 = xmm10[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm1, %xmm9
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm9[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm11, %xmm1
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm10[1,1,3,3]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: por %xmm1, %xmm9
|
|
|
|
; SSE2-NEXT: movdqa {{.*#+}} xmm10 = [255,255]
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm9
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm0, %xmm11
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm1, %xmm11
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm12 = xmm11[0,0,2,2]
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm12, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm11 = xmm11[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm1, %xmm11
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm11
|
|
|
|
; SSE2-NEXT: packuswb %xmm9, %xmm11
|
|
|
|
; SSE2-NEXT: packuswb %xmm11, %xmm11
|
|
|
|
; SSE2-NEXT: packuswb %xmm11, %xmm11
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm3
|
[x86] use a single shufps when it can save instructions
This is a tiny patch with a big pile of test changes.
This partially fixes PR27885:
https://llvm.org/bugs/show_bug.cgi?id=27885
My motivating case looks like this:
- vpshufd {{.*#+}} xmm1 = xmm1[0,1,0,2]
- vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
- vpblendw {{.*#+}} xmm0 = xmm0[0,1,2,3],xmm1[4,5,6,7]
+ vshufps {{.*#+}} xmm0 = xmm0[0,2],xmm1[0,2]
And this happens several times in the diffs. For chips with domain-crossing penalties,
the instruction count and size reduction should usually overcome any potential
domain-crossing penalty due to using an FP op in a sequence of int ops. For chips such
as recent Intel big cores and Atom, there is no domain-crossing penalty for shufps, so
using shufps is a pure win.
So the test case diffs all appear to be improvements except one test in
vector-shuffle-combining.ll where we miss an opportunity to use a shift to generate
zero elements and one test in combine-sra.ll where multiple uses prevent the expected
shuffle combining.
Differential Revision: https://reviews.llvm.org/D27692
llvm-svn: 289837
2016-12-16 02:03:38 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm3, %xmm0
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm1, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm0[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm3, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm9, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm1, %xmm0
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm0
|
[x86] use a single shufps when it can save instructions
This is a tiny patch with a big pile of test changes.
This partially fixes PR27885:
https://llvm.org/bugs/show_bug.cgi?id=27885
My motivating case looks like this:
- vpshufd {{.*#+}} xmm1 = xmm1[0,1,0,2]
- vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
- vpblendw {{.*#+}} xmm0 = xmm0[0,1,2,3],xmm1[4,5,6,7]
+ vshufps {{.*#+}} xmm0 = xmm0[0,2],xmm1[0,2]
And this happens several times in the diffs. For chips with domain-crossing penalties,
the instruction count and size reduction should usually overcome any potential
domain-crossing penalty due to using an FP op in a sequence of int ops. For chips such
as recent Intel big cores and Atom, there is no domain-crossing penalty for shufps, so
using shufps is a pure win.
So the test case diffs all appear to be improvements except one test in
vector-shuffle-combining.ll where we miss an opportunity to use a shift to generate
zero elements and one test in combine-sra.ll where multiple uses prevent the expected
shuffle combining.
Differential Revision: https://reviews.llvm.org/D27692
llvm-svn: 289837
2016-12-16 02:03:38 +08:00
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm2
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm2, %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm1, %xmm3
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm9 = xmm3[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm2, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm9, %xmm1
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm3[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm1, %xmm2
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm2[1,1,2,3]
|
|
|
|
; SSE2-NEXT: punpckldq {{.*#+}} xmm11 = xmm11[0],xmm0[0],xmm11[1],xmm0[1]
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm7
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa %xmm7, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm1[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm7, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm2, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm6
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa %xmm6, %xmm2
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm2[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm6, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm3, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm2[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm5
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa %xmm5, %xmm1
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm1[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm5, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm3, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa %xmm4, %xmm3
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm3[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm4, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm0[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm5, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm3[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm3
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: packuswb %xmm3, %xmm3
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm3 = xmm3[0,1,2,2]
|
|
|
|
; SSE2-NEXT: punpckhdq {{.*#+}} xmm3 = xmm3[2],xmm2[2],xmm3[3],xmm2[3]
|
|
|
|
; SSE2-NEXT: movsd {{.*#+}} xmm3 = xmm11[0],xmm3[1]
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm2
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm2[0,0,2,2]
|
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm4, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm2[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm2
|
|
|
|
; SSE2-NEXT: movdqa %xmm2, %xmm4
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm4
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm4[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm2[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm5, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm2 = xmm4[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm2
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: packuswb %xmm2, %xmm2
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm4
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm4
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm4[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm5, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm4[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: movdqa %xmm4, %xmm5
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm5
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm5[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm4
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm4[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm0
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm5[1,1,3,3]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: por %xmm0, %xmm4
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm4
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm4
|
|
|
|
; SSE2-NEXT: packuswb %xmm4, %xmm4
|
|
|
|
; SSE2-NEXT: packuswb %xmm4, %xmm4
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm4[1,1,2,3]
|
|
|
|
; SSE2-NEXT: punpckldq {{.*#+}} xmm2 = xmm2[0],xmm0[0],xmm2[1],xmm0[1]
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa %xmm1, %xmm4
|
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm4
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm4[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm1[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm5, %xmm0
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm4[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm0, %xmm1
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm1
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm0
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm0
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: movdqa %xmm4, %xmm5
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd %xmm0, %xmm5
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm5[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm0, %xmm4
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm4[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm4
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm0 = xmm5[1,1,3,3]
|
|
|
|
; SSE2-NEXT: por %xmm4, %xmm0
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm0
|
|
|
|
; SSE2-NEXT: packuswb %xmm1, %xmm0
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm0
|
|
|
|
; SSE2-NEXT: packuswb %xmm0, %xmm0
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm4
|
|
|
|
; SSE2-NEXT: movdqa %xmm4, %xmm5
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd %xmm1, %xmm5
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm5[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm1, %xmm4
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm4[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm1
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm4 = xmm5[1,1,3,3]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: por %xmm1, %xmm4
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm4
|
|
|
|
; SSE2-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE2-NEXT: pxor %xmm8, %xmm1
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pxor {{[0-9]+}}(%rsp), %xmm8
|
|
|
|
; SSE2-NEXT: movdqa %xmm8, %xmm5
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpgtd %xmm1, %xmm5
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm6 = xmm5[0,0,2,2]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: pcmpeqd %xmm1, %xmm8
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm8[1,1,3,3]
|
|
|
|
; SSE2-NEXT: pand %xmm6, %xmm1
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm5 = xmm5[1,1,3,3]
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: por %xmm1, %xmm5
|
|
|
|
; SSE2-NEXT: pand %xmm10, %xmm5
|
|
|
|
; SSE2-NEXT: packuswb %xmm4, %xmm5
|
|
|
|
; SSE2-NEXT: packuswb %xmm5, %xmm5
|
|
|
|
; SSE2-NEXT: packuswb %xmm5, %xmm5
|
|
|
|
; SSE2-NEXT: pshufd {{.*#+}} xmm1 = xmm5[0,1,2,2]
|
|
|
|
; SSE2-NEXT: punpckhdq {{.*#+}} xmm1 = xmm1[2],xmm0[2],xmm1[3],xmm0[3]
|
|
|
|
; SSE2-NEXT: movsd {{.*#+}} xmm1 = xmm2[0],xmm1[1]
|
|
|
|
; SSE2-NEXT: movapd %xmm1, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, 2(%rdi)
|
2018-03-16 07:04:11 +08:00
|
|
|
; SSE2-NEXT: movapd %xmm3, -{{[0-9]+}}(%rsp)
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rcx,%rax,2), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,4), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: leal (%rax,%rcx,8), %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $4, %ecx
|
|
|
|
; SSE2-NEXT: orl %eax, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %eax
|
|
|
|
; SSE2-NEXT: andl $1, %eax
|
|
|
|
; SSE2-NEXT: shll $5, %eax
|
|
|
|
; SSE2-NEXT: orl %ecx, %eax
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $6, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $7, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $8, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $9, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $10, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $11, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $12, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: andl $1, %edx
|
|
|
|
; SSE2-NEXT: shll $13, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %ecx
|
|
|
|
; SSE2-NEXT: andl $1, %ecx
|
|
|
|
; SSE2-NEXT: shll $14, %ecx
|
|
|
|
; SSE2-NEXT: orl %edx, %ecx
|
|
|
|
; SSE2-NEXT: movzbl -{{[0-9]+}}(%rsp), %edx
|
|
|
|
; SSE2-NEXT: shll $15, %edx
|
|
|
|
; SSE2-NEXT: orl %ecx, %edx
|
|
|
|
; SSE2-NEXT: orl %eax, %edx
|
|
|
|
; SSE2-NEXT: movw %dx, (%rdi)
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE2-NEXT: movq %rdi, %rax
|
|
|
|
; SSE2-NEXT: retq
|
|
|
|
;
|
|
|
|
; SSE42-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; SSE42: # %bb.0:
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm15
|
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm14
|
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm13
|
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm12
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm11
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm10
|
2017-11-27 13:52:54 +08:00
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm9
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: movdqa {{[0-9]+}}(%rsp), %xmm8
|
2018-01-11 22:25:18 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm7
|
2018-01-12 08:17:38 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm6
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm5
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm4
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm3
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm2
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm1
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm0
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm8
|
2017-10-03 20:01:31 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm9
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm10
|
2017-12-14 14:49:07 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm11
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm12
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm13
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm14
|
|
|
|
; SSE42-NEXT: pcmpgtq {{[0-9]+}}(%rsp), %xmm15
|
|
|
|
; SSE42-NEXT: pextrb $8, %xmm15, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm15, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm14, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm14, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm13, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm13, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm12, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm12, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm11, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm11, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm10, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm10, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm9, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm9, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm8, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm8, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, 2(%rdi)
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm0, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: pextrb $0, %xmm0, %ecx
|
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rcx,%rax,2), %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm1, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,4), %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm1, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: leal (%rax,%rcx,8), %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm2, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $4, %ecx
|
|
|
|
; SSE42-NEXT: orl %eax, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm2, %eax
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %eax
|
|
|
|
; SSE42-NEXT: shll $5, %eax
|
|
|
|
; SSE42-NEXT: orl %ecx, %eax
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm3, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $6, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm3, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $7, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm4, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $8, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm4, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $9, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm5, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $10, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm5, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $11, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm6, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $12, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm6, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %edx
|
|
|
|
; SSE42-NEXT: shll $13, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $0, %xmm7, %ecx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: andl $1, %ecx
|
|
|
|
; SSE42-NEXT: shll $14, %ecx
|
|
|
|
; SSE42-NEXT: orl %edx, %ecx
|
2018-01-22 20:05:17 +08:00
|
|
|
; SSE42-NEXT: pextrb $8, %xmm7, %edx
|
2018-01-21 00:05:10 +08:00
|
|
|
; SSE42-NEXT: shll $15, %edx
|
|
|
|
; SSE42-NEXT: orl %ecx, %edx
|
|
|
|
; SSE42-NEXT: orl %eax, %edx
|
|
|
|
; SSE42-NEXT: movw %dx, (%rdi)
|
2016-07-26 01:56:01 +08:00
|
|
|
; SSE42-NEXT: movq %rdi, %rax
|
|
|
|
; SSE42-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX1-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX1: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: pushq %rbp
|
|
|
|
; AVX1-NEXT: movq %rsp, %rbp
|
|
|
|
; AVX1-NEXT: andq $-32, %rsp
|
|
|
|
; AVX1-NEXT: subq $32, %rsp
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 240(%rbp), %ymm8
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm8, %xmm9
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm7, %xmm10
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm9, %xmm10, %xmm9
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 208(%rbp), %ymm10
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm8, %xmm7, %xmm7
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm9, %xmm7, %xmm8
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm10, %xmm9
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm7
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm9, %xmm7, %xmm7
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm10, %xmm6, %xmm6
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 176(%rbp), %ymm9
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm7, %xmm6, %xmm6
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm8, %xmm6, %xmm8
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm9, %xmm7
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm6
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm7, %xmm6, %xmm6
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 144(%rbp), %ymm10
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm9, %xmm5, %xmm5
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm6, %xmm5, %xmm5
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm10, %xmm6
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm4, %xmm7
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm6, %xmm7, %xmm6
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm10, %xmm4, %xmm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm6, %xmm4, %xmm4
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 112(%rbp), %ymm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm5, %xmm4, %xmm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm8, %xmm4, %xmm4
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm5
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm3, %xmm7
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm5, %xmm7, %xmm5
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 80(%rbp), %ymm7
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm6, %xmm3, %xmm3
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm5, %xmm3, %xmm3
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm7, %xmm5
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm2, %xmm6
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm5, %xmm6, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm7, %xmm2, %xmm2
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 48(%rbp), %ymm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm5, %xmm2, %xmm2
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm2, %xmm2
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm6, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm1, %xmm5
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm3, %xmm5, %xmm3
|
2017-02-11 13:32:57 +08:00
|
|
|
; AVX1-NEXT: vmovdqa 16(%rbp), %ymm5
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm6, %xmm1, %xmm1
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm1, %xmm1
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm5, %xmm3
|
|
|
|
; AVX1-NEXT: vextractf128 $1, %ymm0, %xmm6
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm3, %xmm6, %xmm3
|
|
|
|
; AVX1-NEXT: vpcmpgtq %xmm5, %xmm0, %xmm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX1-NEXT: vpackssdw %xmm3, %xmm0, %xmm0
|
|
|
|
; AVX1-NEXT: vpackssdw %xmm1, %xmm0, %xmm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX1-NEXT: vpacksswb %xmm2, %xmm0, %xmm0
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX1-NEXT: vinsertf128 $1, %xmm4, %ymm0, %ymm0
|
|
|
|
; AVX1-NEXT: movq %rbp, %rsp
|
|
|
|
; AVX1-NEXT: popq %rbp
|
|
|
|
; AVX1-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX2-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX2: # %bb.0:
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: pushq %rbp
|
|
|
|
; AVX2-NEXT: movq %rsp, %rbp
|
|
|
|
; AVX2-NEXT: andq $-32, %rsp
|
|
|
|
; AVX2-NEXT: subq $32, %rsp
|
|
|
|
; AVX2-NEXT: vpcmpgtq 240(%rbp), %ymm7, %ymm7
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 208(%rbp), %ymm6, %ymm6
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm7, %ymm6, %ymm6
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm6 = ymm6[0,2,1,3]
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 176(%rbp), %ymm5, %ymm5
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 144(%rbp), %ymm4, %ymm4
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm5, %ymm4, %ymm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm4 = ymm4[0,2,1,3]
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm6, %ymm4, %ymm4
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm4 = ymm4[0,2,1,3]
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 112(%rbp), %ymm3, %ymm3
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 80(%rbp), %ymm2, %ymm2
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm3, %ymm2, %ymm2
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm2 = ymm2[0,2,1,3]
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 48(%rbp), %ymm1, %ymm1
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpcmpgtq 16(%rbp), %ymm0, %ymm0
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm1, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2017-10-24 23:38:16 +08:00
|
|
|
; AVX2-NEXT: vpackssdw %ymm2, %ymm0, %ymm0
|
2016-07-29 18:23:10 +08:00
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
|
|
|
; AVX2-NEXT: vpacksswb %ymm4, %ymm0, %ymm0
|
|
|
|
; AVX2-NEXT: vpermq {{.*#+}} ymm0 = ymm0[0,2,1,3]
|
2016-07-26 01:56:01 +08:00
|
|
|
; AVX2-NEXT: movq %rbp, %rsp
|
|
|
|
; AVX2-NEXT: popq %rbp
|
|
|
|
; AVX2-NEXT: retq
|
|
|
|
;
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512F: # %bb.0:
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm6, %zmm2, %k0
|
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm7, %zmm3, %k1
|
|
|
|
; AVX512F-NEXT: kunpckbw %k0, %k1, %k1
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm4, %zmm0, %k0
|
|
|
|
; AVX512F-NEXT: vpcmpgtq %zmm5, %zmm1, %k2
|
|
|
|
; AVX512F-NEXT: kunpckbw %k0, %k2, %k2
|
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm0, %zmm0, %zmm0 {%k2} {z}
|
|
|
|
; AVX512F-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512F-NEXT: vpternlogd $255, %zmm1, %zmm1, %zmm1 {%k1} {z}
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512F-NEXT: vpmovdb %zmm1, %xmm1
|
|
|
|
; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512F-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512DQ-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512DQ: # %bb.0:
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm6, %zmm2, %k0
|
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm7, %zmm3, %k1
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: kunpckbw %k0, %k1, %k0
|
2018-01-23 22:25:39 +08:00
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm4, %zmm0, %k1
|
|
|
|
; AVX512DQ-NEXT: vpcmpgtq %zmm5, %zmm1, %k2
|
|
|
|
; AVX512DQ-NEXT: kunpckbw %k1, %k2, %k1
|
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k1, %zmm0
|
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm0, %xmm0
|
2017-12-22 10:30:26 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovm2d %k0, %zmm1
|
2017-12-14 16:26:00 +08:00
|
|
|
; AVX512DQ-NEXT: vpmovdb %zmm1, %xmm1
|
|
|
|
; AVX512DQ-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512DQ-NEXT: retq
|
|
|
|
;
|
|
|
|
; AVX512BW-LABEL: test_cmp_v32i64:
|
2017-12-05 01:18:51 +08:00
|
|
|
; AVX512BW: # %bb.0:
|
2017-11-28 06:56:10 +08:00
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm4, %zmm0, %k0
|
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm5, %zmm1, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckbw %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm6, %zmm2, %k1
|
|
|
|
; AVX512BW-NEXT: vpcmpgtq %zmm7, %zmm3, %k2
|
|
|
|
; AVX512BW-NEXT: kunpckbw %k1, %k2, %k1
|
|
|
|
; AVX512BW-NEXT: kunpckwd %k0, %k1, %k0
|
|
|
|
; AVX512BW-NEXT: vpmovm2b %k0, %zmm0
|
2018-02-01 06:04:26 +08:00
|
|
|
; AVX512BW-NEXT: # kill: def $ymm0 killed $ymm0 killed $zmm0
|
2017-01-09 05:32:26 +08:00
|
|
|
; AVX512BW-NEXT: retq
|
2016-07-26 01:56:01 +08:00
|
|
|
%1 = icmp sgt <32 x i64> %a0, %a1
|
|
|
|
ret <32 x i1> %1
|
|
|
|
}
|