[llvm] r286216 - [AVX-512] Add an avx512f without avx512vl command line to vec_fp_to_int.ll and regenerate. This will make a change in a future patch easier to see. NFC
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Mon Nov 7 22:58:53 PST 2016
Author: ctopper
Date: Tue Nov 8 00:58:53 2016
New Revision: 286216
URL: http://llvm.org/viewvc/llvm-project?rev=286216&view=rev
Log:
[AVX-512] Add an avx512f without avx512vl command line to vec_fp_to_int.ll and regenerate. This will make a change in a future patch easier to see. NFC
Modified:
llvm/trunk/test/CodeGen/X86/vec_fp_to_int.ll
Modified: llvm/trunk/test/CodeGen/X86/vec_fp_to_int.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/CodeGen/X86/vec_fp_to_int.ll?rev=286216&r1=286215&r2=286216&view=diff
==============================================================================
--- llvm/trunk/test/CodeGen/X86/vec_fp_to_int.ll (original)
+++ llvm/trunk/test/CodeGen/X86/vec_fp_to_int.ll Tue Nov 8 00:58:53 2016
@@ -1,8 +1,9 @@
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+sse2 | FileCheck %s --check-prefix=ALL --check-prefix=SSE --check-prefix=SSE2
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX1
; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx2 | FileCheck %s --check-prefix=ALL --check-prefix=AVX --check-prefix=AVX2
-; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512F
-; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f,+avx512dq,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512DQ
+; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512F
+; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512f,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512VL
+; RUN: llc < %s -mtriple=x86_64-unknown-unknown -mattr=+avx512dq,+avx512vl | FileCheck %s --check-prefix=ALL --check-prefix=AVX512 --check-prefix=AVX512VLDQ
;
; 32-bit tests to make sure we're not doing anything stupid.
; RUN: llc < %s -mtriple=i686-unknown-unknown
@@ -45,10 +46,20 @@ define <2 x i64> @fptosi_2f64_to_2i64(<2
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptosi_2f64_to_2i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttpd2qq %xmm0, %xmm0
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptosi_2f64_to_2i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttsd2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm0 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttsd2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_2f64_to_2i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2qq %xmm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <2 x double> %a to <2 x i64>
ret <2 x i64> %cvt
}
@@ -110,11 +121,23 @@ define <4 x i32> @fptosi_4f64_to_2i32(<2
; AVX-NEXT: vzeroupper
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptosi_4f64_to_2i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
-; AVX512-NEXT: vcvttpd2dq %ymm0, %xmm0
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptosi_4f64_to_2i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
+; AVX512F-NEXT: vcvttpd2dqy %ymm0, %xmm0
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptosi_4f64_to_2i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
+; AVX512VL-NEXT: vcvttpd2dq %ymm0, %xmm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_4f64_to_2i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
+; AVX512VLDQ-NEXT: vcvttpd2dq %ymm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%ext = shufflevector <2 x double> %a, <2 x double> undef, <4 x i32> <i32 0, i32 1, i32 undef, i32 undef>
%cvt = fptosi <4 x double> %ext to <4 x i32>
ret <4 x i32> %cvt
@@ -177,7 +200,7 @@ define <4 x i64> @fptosi_4f64_to_4i64(<4
;
; AVX512F-LABEL: fptosi_4f64_to_4i64:
; AVX512F: # BB#0:
-; AVX512F-NEXT: vextractf32x4 $1, %ymm0, %xmm1
+; AVX512F-NEXT: vextractf128 $1, %ymm0, %xmm1
; AVX512F-NEXT: vcvttsd2si %xmm1, %rax
; AVX512F-NEXT: vmovq %rax, %xmm2
; AVX512F-NEXT: vpermilpd {{.*#+}} xmm1 = xmm1[1,0]
@@ -190,13 +213,31 @@ define <4 x i64> @fptosi_4f64_to_4i64(<4
; AVX512F-NEXT: vcvttsd2si %xmm0, %rax
; AVX512F-NEXT: vmovq %rax, %xmm0
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
-; AVX512F-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptosi_4f64_to_4i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttpd2qq %ymm0, %ymm0
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptosi_4f64_to_4i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vextractf32x4 $1, %ymm0, %xmm1
+; AVX512VL-NEXT: vcvttsd2si %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm1 = xmm1[1,0]
+; AVX512VL-NEXT: vcvttsd2si %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm2[0],xmm1[0]
+; AVX512VL-NEXT: vcvttsd2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm0 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttsd2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
+; AVX512VL-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_4f64_to_4i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2qq %ymm0, %ymm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <4 x double> %a to <4 x i64>
ret <4 x i64> %cvt
}
@@ -215,10 +256,20 @@ define <4 x i32> @fptosi_4f64_to_4i32(<4
; AVX-NEXT: vzeroupper
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptosi_4f64_to_4i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: vcvttpd2dq %ymm0, %xmm0
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptosi_4f64_to_4i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: vcvttpd2dqy %ymm0, %xmm0
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptosi_4f64_to_4i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttpd2dq %ymm0, %xmm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_4f64_to_4i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2dq %ymm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <4 x double> %a to <4 x i32>
ret <4 x i32> %cvt
}
@@ -285,10 +336,20 @@ define <2 x i64> @fptoui_2f64_to_2i64(<2
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_2f64_to_2i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttpd2uqq %xmm0, %xmm0
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_2f64_to_2i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm0 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_2f64_to_2i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2uqq %xmm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <2 x double> %a to <2 x i64>
ret <2 x i64> %cvt
}
@@ -356,12 +417,24 @@ define <4 x i32> @fptoui_2f64_to_4i32(<2
; AVX512F-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_2f64_to_4i32:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttpd2uqq %xmm0, %xmm0
-; AVX512DQ-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
-; AVX512DQ-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_2f64_to_4i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm0 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
+; AVX512VL-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VL-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_2f64_to_4i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2uqq %xmm0, %xmm0
+; AVX512VLDQ-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VLDQ-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <2 x double> %a to <2 x i32>
%ext = shufflevector <2 x i32> %cvt, <2 x i32> zeroinitializer, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
ret <4 x i32> %ext
@@ -427,11 +500,22 @@ define <4 x i32> @fptoui_2f64_to_2i32(<2
; AVX512F-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_2f64_to_2i32:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttpd2uqq %xmm0, %xmm0
-; AVX512DQ-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_2f64_to_2i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm0 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
+; AVX512VL-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_2f64_to_2i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2uqq %xmm0, %xmm0
+; AVX512VLDQ-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <2 x double> %a to <2 x i32>
%ext = shufflevector <2 x i32> %cvt, <2 x i32> undef, <4 x i32> <i32 0, i32 1, i32 undef, i32 undef>
ret <4 x i32> %ext
@@ -483,11 +567,24 @@ define <4 x i32> @fptoui_4f64_to_2i32(<2
; AVX-NEXT: vpinsrd $3, %eax, %xmm0, %xmm0
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptoui_4f64_to_2i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
-; AVX512-NEXT: vcvttpd2udq %ymm0, %xmm0
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptoui_4f64_to_2i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %ZMM0<def>
+; AVX512F-NEXT: vcvttpd2udq %zmm0, %ymm0
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<kill>
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptoui_4f64_to_2i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
+; AVX512VL-NEXT: vcvttpd2udq %ymm0, %xmm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_4f64_to_2i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<def>
+; AVX512VLDQ-NEXT: vcvttpd2udq %ymm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%ext = shufflevector <2 x double> %a, <2 x double> undef, <4 x i32> <i32 0, i32 1, i32 undef, i32 undef>
%cvt = fptoui <4 x double> %ext to <4 x i32>
ret <4 x i32> %cvt
@@ -619,7 +716,7 @@ define <4 x i64> @fptoui_4f64_to_4i64(<4
;
; AVX512F-LABEL: fptoui_4f64_to_4i64:
; AVX512F: # BB#0:
-; AVX512F-NEXT: vextractf32x4 $1, %ymm0, %xmm1
+; AVX512F-NEXT: vextractf128 $1, %ymm0, %xmm1
; AVX512F-NEXT: vcvttsd2usi %xmm1, %rax
; AVX512F-NEXT: vmovq %rax, %xmm2
; AVX512F-NEXT: vpermilpd {{.*#+}} xmm1 = xmm1[1,0]
@@ -632,13 +729,31 @@ define <4 x i64> @fptoui_4f64_to_4i64(<4
; AVX512F-NEXT: vcvttsd2usi %xmm0, %rax
; AVX512F-NEXT: vmovq %rax, %xmm0
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
-; AVX512F-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_4f64_to_4i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttpd2uqq %ymm0, %ymm0
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_4f64_to_4i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vextractf32x4 $1, %ymm0, %xmm1
+; AVX512VL-NEXT: vcvttsd2usi %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm1 = xmm1[1,0]
+; AVX512VL-NEXT: vcvttsd2usi %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm2[0],xmm1[0]
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm0 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttsd2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
+; AVX512VL-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_4f64_to_4i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2uqq %ymm0, %ymm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <4 x double> %a to <4 x i64>
ret <4 x i64> %cvt
}
@@ -705,10 +820,22 @@ define <4 x i32> @fptoui_4f64_to_4i32(<4
; AVX-NEXT: vzeroupper
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptoui_4f64_to_4i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: vcvttpd2udq %ymm0, %xmm0
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptoui_4f64_to_4i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<def>
+; AVX512F-NEXT: vcvttpd2udq %zmm0, %ymm0
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<kill>
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptoui_4f64_to_4i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttpd2udq %ymm0, %xmm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_4f64_to_4i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttpd2udq %ymm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <4 x double> %a to <4 x i32>
ret <4 x i32> %cvt
}
@@ -826,11 +953,21 @@ define <2 x i64> @fptosi_4f32_to_2i64(<4
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptosi_4f32_to_2i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttps2qq %xmm0, %ymm0
-; AVX512DQ-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<kill>
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptosi_4f32_to_2i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vmovshdup {{.*#+}} xmm1 = xmm0[1,1,3,3]
+; AVX512VL-NEXT: vcvttss2si %xmm1, %rax
+; AVX512VL-NEXT: vcvttss2si %xmm0, %rcx
+; AVX512VL-NEXT: vmovq %rcx, %xmm0
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_4f32_to_2i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2qq %xmm0, %ymm0
+; AVX512VLDQ-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<kill>
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <4 x float> %a to <4 x i64>
%shuf = shufflevector <4 x i64> %cvt, <4 x i64> undef, <2 x i32> <i32 0, i32 1>
ret <2 x i64> %shuf
@@ -928,13 +1065,31 @@ define <4 x i64> @fptosi_4f32_to_4i64(<8
; AVX512F-NEXT: vcvttss2si %xmm0, %rax
; AVX512F-NEXT: vmovq %rax, %xmm0
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
-; AVX512F-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptosi_4f32_to_4i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttps2qq %xmm0, %ymm0
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptosi_4f32_to_4i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vpermilps {{.*#+}} xmm1 = xmm0[3,1,2,3]
+; AVX512VL-NEXT: vcvttss2si %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm2 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttss2si %xmm2, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm2[0],xmm1[0]
+; AVX512VL-NEXT: vcvttss2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vmovshdup {{.*#+}} xmm0 = xmm0[1,1,3,3]
+; AVX512VL-NEXT: vcvttss2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
+; AVX512VL-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_4f32_to_4i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2qq %xmm0, %ymm0
+; AVX512VLDQ-NEXT: retq
%shuf = shufflevector <8 x float> %a, <8 x float> undef, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
%cvt = fptosi <4 x float> %shuf to <4 x i64>
ret <4 x i64> %cvt
@@ -1012,14 +1167,32 @@ define <4 x i64> @fptosi_8f32_to_4i64(<8
; AVX512F-NEXT: vmovq %rcx, %xmm1
; AVX512F-NEXT: vmovq %rax, %xmm2
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm1[0],xmm2[0]
-; AVX512F-NEXT: vinserti32x4 $1, %xmm0, %ymm1, %ymm0
+; AVX512F-NEXT: vinserti128 $1, %xmm0, %ymm1, %ymm0
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptosi_8f32_to_4i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttps2qq %ymm0, %zmm0
-; AVX512DQ-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<kill>
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptosi_8f32_to_4i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vmovshdup {{.*#+}} xmm1 = xmm0[1,1,3,3]
+; AVX512VL-NEXT: vcvttss2si %xmm1, %rax
+; AVX512VL-NEXT: vcvttss2si %xmm0, %rcx
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm1 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttss2si %xmm1, %rdx
+; AVX512VL-NEXT: vpermilps {{.*#+}} xmm0 = xmm0[3,1,2,3]
+; AVX512VL-NEXT: vcvttss2si %xmm0, %rsi
+; AVX512VL-NEXT: vmovq %rsi, %xmm0
+; AVX512VL-NEXT: vmovq %rdx, %xmm1
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
+; AVX512VL-NEXT: vmovq %rcx, %xmm1
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm1[0],xmm2[0]
+; AVX512VL-NEXT: vinserti32x4 $1, %xmm0, %ymm1, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_8f32_to_4i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2qq %ymm0, %zmm0
+; AVX512VLDQ-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<kill>
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <8 x float> %a to <8 x i64>
%shuf = shufflevector <8 x i64> %cvt, <8 x i64> undef, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
ret <4 x i64> %shuf
@@ -1127,10 +1300,22 @@ define <4 x i32> @fptoui_4f32_to_4i32(<4
; AVX-NEXT: vpinsrd $3, %eax, %xmm1, %xmm0
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptoui_4f32_to_4i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: vcvttps2udq %xmm0, %xmm0
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptoui_4f32_to_4i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %ZMM0<def>
+; AVX512F-NEXT: vcvttps2udq %zmm0, %zmm0
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %ZMM0<kill>
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptoui_4f32_to_4i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttps2udq %xmm0, %xmm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_4f32_to_4i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2udq %xmm0, %xmm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <4 x float> %a to <4 x i32>
ret <4 x i32> %cvt
}
@@ -1255,11 +1440,21 @@ define <2 x i64> @fptoui_4f32_to_2i64(<4
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_4f32_to_2i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttps2uqq %xmm0, %ymm0
-; AVX512DQ-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<kill>
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_4f32_to_2i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vmovshdup {{.*#+}} xmm1 = xmm0[1,1,3,3]
+; AVX512VL-NEXT: vcvttss2usi %xmm1, %rax
+; AVX512VL-NEXT: vcvttss2usi %xmm0, %rcx
+; AVX512VL-NEXT: vmovq %rcx, %xmm0
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_4f32_to_2i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2uqq %xmm0, %ymm0
+; AVX512VLDQ-NEXT: # kill: %XMM0<def> %XMM0<kill> %YMM0<kill>
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <4 x float> %a to <4 x i64>
%shuf = shufflevector <4 x i64> %cvt, <4 x i64> undef, <2 x i32> <i32 0, i32 1>
ret <2 x i64> %shuf
@@ -1359,10 +1554,22 @@ define <8 x i32> @fptoui_8f32_to_8i32(<8
; AVX2-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
; AVX2-NEXT: retq
;
-; AVX512-LABEL: fptoui_8f32_to_8i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: vcvttps2udq %ymm0, %ymm0
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptoui_8f32_to_8i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<def>
+; AVX512F-NEXT: vcvttps2udq %zmm0, %zmm0
+; AVX512F-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<kill>
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptoui_8f32_to_8i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvttps2udq %ymm0, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_8f32_to_8i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2udq %ymm0, %ymm0
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <8 x float> %a to <8 x i32>
ret <8 x i32> %cvt
}
@@ -1509,13 +1716,31 @@ define <4 x i64> @fptoui_4f32_to_4i64(<8
; AVX512F-NEXT: vcvttss2usi %xmm0, %rax
; AVX512F-NEXT: vmovq %rax, %xmm0
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
-; AVX512F-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512F-NEXT: vinserti128 $1, %xmm1, %ymm0, %ymm0
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_4f32_to_4i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttps2uqq %xmm0, %ymm0
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_4f32_to_4i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vpermilps {{.*#+}} xmm1 = xmm0[3,1,2,3]
+; AVX512VL-NEXT: vcvttss2usi %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm2 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttss2usi %xmm2, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm2[0],xmm1[0]
+; AVX512VL-NEXT: vcvttss2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vmovshdup {{.*#+}} xmm0 = xmm0[1,1,3,3]
+; AVX512VL-NEXT: vcvttss2usi %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm2[0],xmm0[0]
+; AVX512VL-NEXT: vinserti32x4 $1, %xmm1, %ymm0, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_4f32_to_4i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2uqq %xmm0, %ymm0
+; AVX512VLDQ-NEXT: retq
%shuf = shufflevector <8 x float> %a, <8 x float> undef, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
%cvt = fptoui <4 x float> %shuf to <4 x i64>
ret <4 x i64> %cvt
@@ -1663,14 +1888,32 @@ define <4 x i64> @fptoui_8f32_to_4i64(<8
; AVX512F-NEXT: vmovq %rcx, %xmm1
; AVX512F-NEXT: vmovq %rax, %xmm2
; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm1[0],xmm2[0]
-; AVX512F-NEXT: vinserti32x4 $1, %xmm0, %ymm1, %ymm0
+; AVX512F-NEXT: vinserti128 $1, %xmm0, %ymm1, %ymm0
; AVX512F-NEXT: retq
;
-; AVX512DQ-LABEL: fptoui_8f32_to_4i64:
-; AVX512DQ: # BB#0:
-; AVX512DQ-NEXT: vcvttps2uqq %ymm0, %zmm0
-; AVX512DQ-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<kill>
-; AVX512DQ-NEXT: retq
+; AVX512VL-LABEL: fptoui_8f32_to_4i64:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vmovshdup {{.*#+}} xmm1 = xmm0[1,1,3,3]
+; AVX512VL-NEXT: vcvttss2usi %xmm1, %rax
+; AVX512VL-NEXT: vcvttss2usi %xmm0, %rcx
+; AVX512VL-NEXT: vpermilpd {{.*#+}} xmm1 = xmm0[1,0]
+; AVX512VL-NEXT: vcvttss2usi %xmm1, %rdx
+; AVX512VL-NEXT: vpermilps {{.*#+}} xmm0 = xmm0[3,1,2,3]
+; AVX512VL-NEXT: vcvttss2usi %xmm0, %rsi
+; AVX512VL-NEXT: vmovq %rsi, %xmm0
+; AVX512VL-NEXT: vmovq %rdx, %xmm1
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm1[0],xmm0[0]
+; AVX512VL-NEXT: vmovq %rcx, %xmm1
+; AVX512VL-NEXT: vmovq %rax, %xmm2
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm1 = xmm1[0],xmm2[0]
+; AVX512VL-NEXT: vinserti32x4 $1, %xmm0, %ymm1, %ymm0
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptoui_8f32_to_4i64:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvttps2uqq %ymm0, %zmm0
+; AVX512VLDQ-NEXT: # kill: %YMM0<def> %YMM0<kill> %ZMM0<kill>
+; AVX512VLDQ-NEXT: retq
%cvt = fptoui <8 x float> %a to <8 x i64>
%shuf = shufflevector <8 x i64> %cvt, <8 x i64> undef, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
ret <4 x i64> %shuf
@@ -2005,20 +2248,52 @@ define <4 x i32> @fptosi_2f16_to_4i32(<2
; AVX-NEXT: popq %rax
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptosi_2f16_to_4i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: vcvtps2ph $4, %xmm0, %xmm0
-; AVX512-NEXT: vcvtph2ps %xmm0, %xmm0
-; AVX512-NEXT: vcvtps2ph $4, %xmm1, %xmm1
-; AVX512-NEXT: vcvtph2ps %xmm1, %xmm1
-; AVX512-NEXT: vcvttss2si %xmm1, %rax
-; AVX512-NEXT: vmovq %rax, %xmm1
-; AVX512-NEXT: vcvttss2si %xmm0, %rax
-; AVX512-NEXT: vmovq %rax, %xmm0
-; AVX512-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
-; AVX512-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
-; AVX512-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptosi_2f16_to_4i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: # kill: %XMM1<def> %XMM1<kill> %ZMM1<def>
+; AVX512F-NEXT: # kill: %XMM0<def> %XMM0<kill> %ZMM0<def>
+; AVX512F-NEXT: vcvtps2ph $4, %zmm0, %ymm0
+; AVX512F-NEXT: vcvtph2ps %ymm0, %zmm0
+; AVX512F-NEXT: vcvtps2ph $4, %zmm1, %ymm1
+; AVX512F-NEXT: vcvtph2ps %ymm1, %zmm1
+; AVX512F-NEXT: vcvttss2si %xmm1, %rax
+; AVX512F-NEXT: vmovq %rax, %xmm1
+; AVX512F-NEXT: vcvttss2si %xmm0, %rax
+; AVX512F-NEXT: vmovq %rax, %xmm0
+; AVX512F-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512F-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512F-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptosi_2f16_to_4i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: vcvtps2ph $4, %xmm0, %xmm0
+; AVX512VL-NEXT: vcvtph2ps %xmm0, %xmm0
+; AVX512VL-NEXT: vcvtps2ph $4, %xmm1, %xmm1
+; AVX512VL-NEXT: vcvtph2ps %xmm1, %xmm1
+; AVX512VL-NEXT: vcvttss2si %xmm1, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm1
+; AVX512VL-NEXT: vcvttss2si %xmm0, %rax
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512VL-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VL-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_2f16_to_4i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: vcvtps2ph $4, %xmm0, %xmm0
+; AVX512VLDQ-NEXT: vcvtph2ps %xmm0, %xmm0
+; AVX512VLDQ-NEXT: vcvtps2ph $4, %xmm1, %xmm1
+; AVX512VLDQ-NEXT: vcvtph2ps %xmm1, %xmm1
+; AVX512VLDQ-NEXT: vcvttss2si %xmm1, %rax
+; AVX512VLDQ-NEXT: vmovq %rax, %xmm1
+; AVX512VLDQ-NEXT: vcvttss2si %xmm0, %rax
+; AVX512VLDQ-NEXT: vmovq %rax, %xmm0
+; AVX512VLDQ-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512VLDQ-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VLDQ-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <2 x half> %a to <2 x i32>
%ext = shufflevector <2 x i32> %cvt, <2 x i32> zeroinitializer, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
ret <4 x i32> %ext
@@ -2131,30 +2406,80 @@ define <4 x i32> @fptosi_2f128_to_4i32(<
; AVX-NEXT: popq %r14
; AVX-NEXT: retq
;
-; AVX512-LABEL: fptosi_2f128_to_4i32:
-; AVX512: # BB#0:
-; AVX512-NEXT: pushq %r14
-; AVX512-NEXT: pushq %rbx
-; AVX512-NEXT: subq $24, %rsp
-; AVX512-NEXT: movq %rsi, %r14
-; AVX512-NEXT: movq %rdi, %rbx
-; AVX512-NEXT: movq %rdx, %rdi
-; AVX512-NEXT: movq %rcx, %rsi
-; AVX512-NEXT: callq __fixtfdi
-; AVX512-NEXT: vmovq %rax, %xmm0
-; AVX512-NEXT: vmovdqa64 %xmm0, (%rsp) # 16-byte Spill
-; AVX512-NEXT: movq %rbx, %rdi
-; AVX512-NEXT: movq %r14, %rsi
-; AVX512-NEXT: callq __fixtfdi
-; AVX512-NEXT: vmovq %rax, %xmm0
-; AVX512-NEXT: vmovdqa64 (%rsp), %xmm1 # 16-byte Reload
-; AVX512-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
-; AVX512-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
-; AVX512-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
-; AVX512-NEXT: addq $24, %rsp
-; AVX512-NEXT: popq %rbx
-; AVX512-NEXT: popq %r14
-; AVX512-NEXT: retq
+; AVX512F-LABEL: fptosi_2f128_to_4i32:
+; AVX512F: # BB#0:
+; AVX512F-NEXT: pushq %r14
+; AVX512F-NEXT: pushq %rbx
+; AVX512F-NEXT: subq $24, %rsp
+; AVX512F-NEXT: movq %rsi, %r14
+; AVX512F-NEXT: movq %rdi, %rbx
+; AVX512F-NEXT: movq %rdx, %rdi
+; AVX512F-NEXT: movq %rcx, %rsi
+; AVX512F-NEXT: callq __fixtfdi
+; AVX512F-NEXT: vmovq %rax, %xmm0
+; AVX512F-NEXT: vmovdqa %xmm0, (%rsp) # 16-byte Spill
+; AVX512F-NEXT: movq %rbx, %rdi
+; AVX512F-NEXT: movq %r14, %rsi
+; AVX512F-NEXT: callq __fixtfdi
+; AVX512F-NEXT: vmovq %rax, %xmm0
+; AVX512F-NEXT: vpunpcklqdq (%rsp), %xmm0, %xmm0 # 16-byte Folded Reload
+; AVX512F-NEXT: # xmm0 = xmm0[0],mem[0]
+; AVX512F-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512F-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512F-NEXT: addq $24, %rsp
+; AVX512F-NEXT: popq %rbx
+; AVX512F-NEXT: popq %r14
+; AVX512F-NEXT: retq
+;
+; AVX512VL-LABEL: fptosi_2f128_to_4i32:
+; AVX512VL: # BB#0:
+; AVX512VL-NEXT: pushq %r14
+; AVX512VL-NEXT: pushq %rbx
+; AVX512VL-NEXT: subq $24, %rsp
+; AVX512VL-NEXT: movq %rsi, %r14
+; AVX512VL-NEXT: movq %rdi, %rbx
+; AVX512VL-NEXT: movq %rdx, %rdi
+; AVX512VL-NEXT: movq %rcx, %rsi
+; AVX512VL-NEXT: callq __fixtfdi
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vmovdqa64 %xmm0, (%rsp) # 16-byte Spill
+; AVX512VL-NEXT: movq %rbx, %rdi
+; AVX512VL-NEXT: movq %r14, %rsi
+; AVX512VL-NEXT: callq __fixtfdi
+; AVX512VL-NEXT: vmovq %rax, %xmm0
+; AVX512VL-NEXT: vmovdqa64 (%rsp), %xmm1 # 16-byte Reload
+; AVX512VL-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512VL-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VL-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512VL-NEXT: addq $24, %rsp
+; AVX512VL-NEXT: popq %rbx
+; AVX512VL-NEXT: popq %r14
+; AVX512VL-NEXT: retq
+;
+; AVX512VLDQ-LABEL: fptosi_2f128_to_4i32:
+; AVX512VLDQ: # BB#0:
+; AVX512VLDQ-NEXT: pushq %r14
+; AVX512VLDQ-NEXT: pushq %rbx
+; AVX512VLDQ-NEXT: subq $24, %rsp
+; AVX512VLDQ-NEXT: movq %rsi, %r14
+; AVX512VLDQ-NEXT: movq %rdi, %rbx
+; AVX512VLDQ-NEXT: movq %rdx, %rdi
+; AVX512VLDQ-NEXT: movq %rcx, %rsi
+; AVX512VLDQ-NEXT: callq __fixtfdi
+; AVX512VLDQ-NEXT: vmovq %rax, %xmm0
+; AVX512VLDQ-NEXT: vmovdqa64 %xmm0, (%rsp) # 16-byte Spill
+; AVX512VLDQ-NEXT: movq %rbx, %rdi
+; AVX512VLDQ-NEXT: movq %r14, %rsi
+; AVX512VLDQ-NEXT: callq __fixtfdi
+; AVX512VLDQ-NEXT: vmovq %rax, %xmm0
+; AVX512VLDQ-NEXT: vmovdqa64 (%rsp), %xmm1 # 16-byte Reload
+; AVX512VLDQ-NEXT: vpunpcklqdq {{.*#+}} xmm0 = xmm0[0],xmm1[0]
+; AVX512VLDQ-NEXT: vpshufd {{.*#+}} xmm0 = xmm0[0,2,2,3]
+; AVX512VLDQ-NEXT: vmovq {{.*#+}} xmm0 = xmm0[0],zero
+; AVX512VLDQ-NEXT: addq $24, %rsp
+; AVX512VLDQ-NEXT: popq %rbx
+; AVX512VLDQ-NEXT: popq %r14
+; AVX512VLDQ-NEXT: retq
%cvt = fptosi <2 x fp128> %a to <2 x i32>
%ext = shufflevector <2 x i32> %cvt, <2 x i32> zeroinitializer, <4 x i32> <i32 0, i32 1, i32 2, i32 3>
ret <4 x i32> %ext
More information about the llvm-commits
mailing list