1 /* Function sincos vectorized in AVX ISA as wrapper to SSE4 ISA version.
2 Copyright (C) 2014-2024 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <https://www.gnu.org/licenses/>. */
20 #include "svml_d_wrapper_impl.h"
22 .section .text.avx2, "ax", @progbits
23 ENTRY (_ZGVcN4vl8l8_sincos)
24 WRAPPER_IMPL_AVX_fFF _ZGVbN2vl8l8_sincos
25 END (_ZGVcN4vl8l8_sincos)
27 /* AVX ISA version as wrapper to SSE ISA version (for vector
28 function declared with #pragma omp declare simd notinbranch). */
29 .macro WRAPPER_IMPL_AVX_fFF_vvv callee
35 vmovupd %ymm0, 64(%rsp)
37 vmovdqu %xmm1, 96(%rdi)
38 vmovdqu %xmm2, 112(%rdi)
39 vmovdqu %xmm3, 128(%rdi)
40 vmovdqu %xmm4, 144(%rdi)
43 call HIDDEN_JUMPTARGET(\callee)
44 vmovdqu 80(%rsp), %xmm0
47 call HIDDEN_JUMPTARGET(\callee)
81 .cfi_escape 0x10,0x6,0x2,0x76,0
86 .cfi_escape 0xf,0x3,0x76,0x70,0x6
87 .cfi_escape 0x10,0xc,0x2,0x76,0x78
91 .cfi_escape 0x10,0x3,0x2,0x76,0x68
94 vmovaps %xmm1, -128(%ebp)
95 vmovaps %xmm2, -144(%ebp)
96 vmovapd %ymm0, -176(%ebp)
98 call HIDDEN_JUMPTARGET(\callee)
100 vmovupd -160(%ebp), %xmm0
102 call HIDDEN_JUMPTARGET(\callee)
103 movq -128(%ebp), %rax
104 vmovsd -112(%ebp), %xmm0
105 vmovdqa -128(%ebp), %xmm5
106 vmovdqa -144(%ebp), %xmm1
108 vmovsd -104(%ebp), %xmm0
109 vpextrd $1, %xmm5, %eax
111 movq -120(%ebp), %rax
112 vmovsd -96(%ebp), %xmm0
114 vmovsd -88(%ebp), %xmm0
115 vpextrd $3, %xmm5, %eax
117 movq -144(%ebp), %rax
118 vmovsd -80(%ebp), %xmm0
120 vmovsd -72(%ebp), %xmm0
121 vpextrd $1, %xmm1, %eax
123 movq -136(%ebp), %rax
124 vmovsd -64(%ebp), %xmm0
126 vmovsd -56(%ebp), %xmm0
127 vpextrd $3, %xmm1, %eax
141 ENTRY (_ZGVcN4vvv_sincos)
142 WRAPPER_IMPL_AVX_fFF_vvv _ZGVbN2vl8l8_sincos
143 END (_ZGVcN4vvv_sincos)