[PATCH 1/14] [x86_64] Vector math functions (vector cos)

classic Classic list List threaded Threaded
35 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Joseph Myers
Note that the addition of the first libmvec functions should be
accompanied by a NEWS entry describing this new feature in 2.22.  (That
NEWS entry can then be updated for each new function added - of course
anything added after 2.22 is released gets a separate NEWS entry for
2.23.)

--
Joseph S. Myers
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Andrew Senkevich
2015-06-05 19:44 GMT+03:00 Joseph Myers <[hidden email]>:
> Note that the addition of the first libmvec functions should be
> accompanied by a NEWS entry describing this new feature in 2.22.  (That
> NEWS entry can then be updated for each new function added - of course
> anything added after 2.22 is released gets a separate NEWS entry for
> 2.23.)

Is this update ok?

diff --git a/NEWS b/NEWS
index 881e61c..18ce8d5 100644
--- a/NEWS
+++ b/NEWS
@@ -50,6 +50,12 @@ Version 2.22
 * CVE-2014-8121 The NSS backends shared internal state between the getXXent
   and getXXbyYY NSS calls for the same database, causing a denial-of-service
   condition in some applications.
+
+* Added vector math library named libmvec with the following vectorized x86_64
+  implementations: cos.
+  Naming of x86_64 implementations is in accordance with
+  Vector ABI <https://groups.google.com/forum/#!topic/x86-64-abi/LmppCfN1rZ4>.
+  Vector math library build and ABI testing enabled by default for x86_64.
 ^L
 Version 2.21


I also would like to add wiki page (with content mostly based on
https://sourceware.org/glibc/wiki/libm#Addition_of_x86_64_vector_math_functions_to_Glibc)
to 5.4. Internals Documentation at
https://sourceware.org/glibc/wiki#Development and add according link
to NEWS.


--
WBR,
Andrew
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Joseph Myers
On Mon, 8 Jun 2015, Andrew Senkevich wrote:

> +* Added vector math library named libmvec with the following vectorized x86_64
> +  implementations: cos.
> +  Naming of x86_64 implementations is in accordance with
> +  Vector ABI <https://groups.google.com/forum/#!topic/x86-64-abi/LmppCfN1rZ4>.
> +  Vector math library build and ABI testing enabled by default for x86_64.

I don't think the NEWS file should point to a site requiring non-free
JavaScript; host a copy of the ABI somewhere else (maybe on the glibc
wiki).

I think the NEWS file needs to give information from the perspective of
people building and using glibc.  That includes: the library can be
disabled with --disable-mathvec (the configure option also needs
documenting in manual/install.texi, with INSTALL being regenerated); use
of the functions is enabled with -fopenmp -ffast-math -O3 (or whatever)
and the library is linked in as needed when using -lm rather than needing
to specify -lmvec explicitly.

--
Joseph S. Myers
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Andrew Senkevich
2015-06-08 16:06 GMT+03:00 Joseph Myers <[hidden email]>:

> On Mon, 8 Jun 2015, Andrew Senkevich wrote:
>
>> +* Added vector math library named libmvec with the following vectorized x86_64
>> +  implementations: cos.
>> +  Naming of x86_64 implementations is in accordance with
>> +  Vector ABI <https://groups.google.com/forum/#!topic/x86-64-abi/LmppCfN1rZ4>.
>> +  Vector math library build and ABI testing enabled by default for x86_64.
>
> I don't think the NEWS file should point to a site requiring non-free
> JavaScript; host a copy of the ABI somewhere else (maybe on the glibc
> wiki).
>
> I think the NEWS file needs to give information from the perspective of
> people building and using glibc.  That includes: the library can be
> disabled with --disable-mathvec (the configure option also needs
> documenting in manual/install.texi, with INSTALL being regenerated); use
> of the functions is enabled with -fopenmp -ffast-math -O3 (or whatever)
> and the library is linked in as needed when using -lm rather than needing
> to specify -lmvec explicitly.

I have prepared wiki page and put link to it.

diff --git a/NEWS b/NEWS
index 881e61c..5e223a1 100644
--- a/NEWS
+++ b/NEWS
@@ -50,6 +50,14 @@ Version 2.22
 * CVE-2014-8121 The NSS backends shared internal state between the getXXent
   and getXXbyYY NSS calls for the same database, causing a denial-of-service
   condition in some applications.
+
+* Added vector math library named libmvec with the following vectorized x86_64
+  implementations: cos.
+  The library can be disabled with --disable-mathvec. Use of the functions is
+  enabled with -fopenmp -ffast-math starting from -O1 for GCC version >= 4.9.0.
+  The library is linked in as needed when using -lm (no need to specify -lmvec
+  explicitly).
+  Visit <https://sourceware.org/glibc/wiki/libmvec> for detailed information.
 ^L
 Version 2.21


--
WBR,
Andrew
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Joseph Myers
On Mon, 8 Jun 2015, Andrew Senkevich wrote:

> diff --git a/NEWS b/NEWS
> index 881e61c..5e223a1 100644
> --- a/NEWS
> +++ b/NEWS
> @@ -50,6 +50,14 @@ Version 2.22
>  * CVE-2014-8121 The NSS backends shared internal state between the getXXent
>    and getXXbyYY NSS calls for the same database, causing a denial-of-service
>    condition in some applications.
> +
> +* Added vector math library named libmvec with the following vectorized x86_64
> +  implementations: cos.
> +  The library can be disabled with --disable-mathvec. Use of the functions is
> +  enabled with -fopenmp -ffast-math starting from -O1 for GCC version >= 4.9.0.
> +  The library is linked in as needed when using -lm (no need to specify -lmvec
> +  explicitly).
> +  Visit <https://sourceware.org/glibc/wiki/libmvec> for detailed information.

This seems reasonable as a starting point (given install.texi updated as
well).  The release manager may wish to edit the NEWS entries, of course.

--
Joseph S. Myers
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Andrew Senkevich
2015-06-08 20:08 GMT+03:00 Joseph Myers <[hidden email]>:

> On Mon, 8 Jun 2015, Andrew Senkevich wrote:
>
>> diff --git a/NEWS b/NEWS
>> index 881e61c..5e223a1 100644
>> --- a/NEWS
>> +++ b/NEWS
>> @@ -50,6 +50,14 @@ Version 2.22
>>  * CVE-2014-8121 The NSS backends shared internal state between the getXXent
>>    and getXXbyYY NSS calls for the same database, causing a denial-of-service
>>    condition in some applications.
>> +
>> +* Added vector math library named libmvec with the following vectorized x86_64
>> +  implementations: cos.
>> +  The library can be disabled with --disable-mathvec. Use of the functions is
>> +  enabled with -fopenmp -ffast-math starting from -O1 for GCC version >= 4.9.0.
>> +  The library is linked in as needed when using -lm (no need to specify -lmvec
>> +  explicitly).
>> +  Visit <https://sourceware.org/glibc/wiki/libmvec> for detailed information.
>
> This seems reasonable as a starting point (given install.texi updated as
> well).  The release manager may wish to edit the NEWS entries, of course.

Update of install.texi is:

diff --git a/manual/install.texi b/manual/install.texi
index bb09199..42ee467 100644
--- a/manual/install.texi
+++ b/manual/install.texi
@@ -181,6 +181,10 @@ version of GCC than this version of @theglibc{}
was tested with, so
 new warnings cause the build with @option{-Werror} to fail), you can
 configure with @option{--disable-werror}.

+@item --disable-mathvec
+By default for x86_64, @theglibc{} is built with vector math library.
+Use this option to disable vector math library.
+
 @item --build=@var{build-system}
 @itemx --host=@var{host-system}
 These options are for cross-compiling.  If you specify both options and



--
WBR,
Andrew
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Joseph Myers
On Mon, 8 Jun 2015, Andrew Senkevich wrote:

> Update of install.texi is:

OK (remembering the regeneration of INSTALL when you commit).

--
Joseph S. Myers
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Adhemerval Zanella-2
In reply to this post by Andrew Senkevich
I am seeing this issue with master build using binutils 2.24:

../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: Assembler messages:
../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:281: Error: operand type mismatch for `vandpd'
../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:327: Error: operand type mismatch for `vxorpd'


On 25-05-2015 15:26, Andrew Senkevich wrote:

> 2015-05-22 18:31 GMT+03:00 Joseph Myers <[hidden email]>:
>> On Thu, 21 May 2015, Andrew Senkevich wrote:
>>
>>> diff --git a/sysdeps/x86_64/fpu/multiarch/Makefile b/sysdeps/x86_64/fpu/multiarch/Makefile
>>> index 12b0526..5ccf97b 100644
>>> --- a/sysdeps/x86_64/fpu/multiarch/Makefile
>>> +++ b/sysdeps/x86_64/fpu/multiarch/Makefile
>>> @@ -51,3 +51,7 @@ CFLAGS-slowexp-avx.c = -msse2avx -DSSE2AVX
>>>  CFLAGS-s_tan-avx.c = -msse2avx -DSSE2AVX
>>>  endif
>>>  endif
>>> +
>>> +ifeq ($(subdir),mathvec)
>>> +libmvec-support += svml_d_cos2_core svml_d_cos8_core
>>> +endif
>>
>> As far as I can tell, if you use --disable-multi-arch, then these files
>> won't be built into libmvec, and nothing else will provide the
>> _ZGVbN2v_cos and _ZGVeN8v_cos symbols.  See other multiarch code for
>> examples of how such things are handled - typically, the file outside the
>> multiarch directory implements things for an always-supported architecture
>> variant (in this case, that would be a variant guaranteed to be supported
>> if the given entry point gets called), then, in the multiarch directory,
>> there are the implementations for other variants, and a file with the same
>> name as that outside the multiarch directory, that (a) provides the IFUNC
>> resolver and (b) defines some macros before #including the file in the
>> directory above, so that the basic version of the function gets defined
>> under a different name.
>
> Hi, Joseph, updated patch is attached. Is it ok?
>
> 2015-05-25  Andrew Senkevich  <[hidden email]>
>
>         * sysdeps/x86_64/fpu/Makefile: New file.
>         * sysdeps/x86_64/fpu/Versions: New file.
>         * sysdeps/x86_64/fpu/svml_d_cos_data.S: New file.
>         * sysdeps/x86_64/fpu/svml_d_cos_data.h: New file.
>         * sysdeps/x86_64/fpu/svml_d_cos2_core.S: New file.
>         * sysdeps/x86_64/fpu/svml_d_cos4_core.S: New file.
>         * sysdeps/x86_64/fpu/svml_d_cos4_core_avx.S: New file.
>         * sysdeps/x86_64/fpu/svml_d_cos8_core.S: New file.
>         * sysdeps/x86_64/fpu/svml_d_wrapper_impl.h: New file.
>         * sysdeps/x86_64/fpu/multiarch/svml_d_cos2_core.S: New file.
>         * sysdeps/x86_64/fpu/multiarch/svml_d_cos2_core_sse4.S: New file.
>         * sysdeps/x86_64/fpu/multiarch/svml_d_cos4_core.S: New file.
>         * sysdeps/x86_64/fpu/multiarch/svml_d_cos4_core_avx2.S: New file.
>         * sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core.S: New file.
>         * sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: New file.
>         * sysdeps/x86_64/fpu/multiarch/Makefile (libmvec-sysdep_routines): Added
>         build of SSE, AVX2 and AVX512 versions which are IFUNC.
>         * sysdeps/x86/fpu/bits/math-vector.h: Added SIMD declaration for cos.
>         * math/bits/mathcalls.h: Added cos declaration with __MATHCALL_VEC.
>         * sysdeps/x86_64/configure.ac: Options for libmvec build.
>         * sysdeps/x86_64/configure: Regenerated.
>         * sysdeps/x86_64/sysdep.h (cfi_offset_rel_rsp): New macro.
>         * sysdeps/unix/sysv/linux/x86_64/libmvec.abilist: New file.
>
>
> --
> WBR,
> Andrew
>
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Martin Sebor-2
In reply to this post by Andrew Senkevich
This patch breaks x86_64 builds with Binutils 2.24 (Fedora 21):

../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: Assembler
messages:
../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:281: Error:
operand type mismatch for `vandpd'
../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:327: Error:
operand type mismatch for `vxorpd'
/build/glibc-trunk/sysd-rules:1549: recipe for target
'/build/glibc-trunk/mathvec/svml_d_cos8_core_avx512.o' failed

(with other similar errors in other files).

The first instruction the assembler complains about is:

         vandpd 0(%rax), %zmm6, %zmm1

As from Binutils 2.25 accepts the code.

Martin

On 05/25/2015 12:26 PM, Andrew Senkevich wrote:

> 2015-05-22 18:31 GMT+03:00 Joseph Myers <[hidden email]>:
>> On Thu, 21 May 2015, Andrew Senkevich wrote:
>>
>>> diff --git a/sysdeps/x86_64/fpu/multiarch/Makefile b/sysdeps/x86_64/fpu/multiarch/Makefile
>>> index 12b0526..5ccf97b 100644
>>> --- a/sysdeps/x86_64/fpu/multiarch/Makefile
>>> +++ b/sysdeps/x86_64/fpu/multiarch/Makefile
>>> @@ -51,3 +51,7 @@ CFLAGS-slowexp-avx.c = -msse2avx -DSSE2AVX
>>>   CFLAGS-s_tan-avx.c = -msse2avx -DSSE2AVX
>>>   endif
>>>   endif
>>> +
>>> +ifeq ($(subdir),mathvec)
>>> +libmvec-support += svml_d_cos2_core svml_d_cos8_core
>>> +endif
>>
>> As far as I can tell, if you use --disable-multi-arch, then these files
>> won't be built into libmvec, and nothing else will provide the
>> _ZGVbN2v_cos and _ZGVeN8v_cos symbols.  See other multiarch code for
>> examples of how such things are handled - typically, the file outside the
>> multiarch directory implements things for an always-supported architecture
>> variant (in this case, that would be a variant guaranteed to be supported
>> if the given entry point gets called), then, in the multiarch directory,
>> there are the implementations for other variants, and a file with the same
>> name as that outside the multiarch directory, that (a) provides the IFUNC
>> resolver and (b) defines some macros before #including the file in the
>> directory above, so that the basic version of the function gets defined
>> under a different name.
>
> Hi, Joseph, updated patch is attached. Is it ok?
>
> 2015-05-25  Andrew Senkevich  <[hidden email]>
>
>          * sysdeps/x86_64/fpu/Makefile: New file.
>          * sysdeps/x86_64/fpu/Versions: New file.
>          * sysdeps/x86_64/fpu/svml_d_cos_data.S: New file.
>          * sysdeps/x86_64/fpu/svml_d_cos_data.h: New file.
>          * sysdeps/x86_64/fpu/svml_d_cos2_core.S: New file.
>          * sysdeps/x86_64/fpu/svml_d_cos4_core.S: New file.
>          * sysdeps/x86_64/fpu/svml_d_cos4_core_avx.S: New file.
>          * sysdeps/x86_64/fpu/svml_d_cos8_core.S: New file.
>          * sysdeps/x86_64/fpu/svml_d_wrapper_impl.h: New file.
>          * sysdeps/x86_64/fpu/multiarch/svml_d_cos2_core.S: New file.
>          * sysdeps/x86_64/fpu/multiarch/svml_d_cos2_core_sse4.S: New file.
>          * sysdeps/x86_64/fpu/multiarch/svml_d_cos4_core.S: New file.
>          * sysdeps/x86_64/fpu/multiarch/svml_d_cos4_core_avx2.S: New file.
>          * sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core.S: New file.
>          * sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: New file.
>          * sysdeps/x86_64/fpu/multiarch/Makefile (libmvec-sysdep_routines): Added
>          build of SSE, AVX2 and AVX512 versions which are IFUNC.
>          * sysdeps/x86/fpu/bits/math-vector.h: Added SIMD declaration for cos.
>          * math/bits/mathcalls.h: Added cos declaration with __MATHCALL_VEC.
>          * sysdeps/x86_64/configure.ac: Options for libmvec build.
>          * sysdeps/x86_64/configure: Regenerated.
>          * sysdeps/x86_64/sysdep.h (cfi_offset_rel_rsp): New macro.
>          * sysdeps/unix/sysv/linux/x86_64/libmvec.abilist: New file.
>
>
> --
> WBR,
> Andrew
>

Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Andrew Senkevich
2015-06-09 21:40 GMT+03:00 Martin Sebor <[hidden email]>:

> This patch breaks x86_64 builds with Binutils 2.24 (Fedora 21):
>
> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: Assembler
> messages:
> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:281: Error:
> operand type mismatch for `vandpd'
> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:327: Error:
> operand type mismatch for `vxorpd'
> /build/glibc-trunk/sysd-rules:1549: recipe for target
> '/build/glibc-trunk/mathvec/svml_d_cos8_core_avx512.o' failed
>
> (with other similar errors in other files).
>
> The first instruction the assembler complains about is:
>
>         vandpd 0(%rax), %zmm6, %zmm1
>
> As from Binutils 2.25 accepts the code.

I have tested build with manually built Binutils 2.24 (downloaded from
ftp://sourceware.org/pub/binutils/snapshots/binutils-2.24.90.tar.bz2)
on x86_64 Fedora 19 with configure/make with no addition options.

How Binutils on your side was built and what is exact version?
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Joseph Myers
On Tue, 9 Jun 2015, Andrew Senkevich wrote:

> I have tested build with manually built Binutils 2.24 (downloaded from
> ftp://sourceware.org/pub/binutils/snapshots/binutils-2.24.90.tar.bz2)
> on x86_64 Fedora 19 with configure/make with no addition options.

2.24.90 means a development version in between 2.24 and 2.25.  Try actual
2.24 release.

If you can't get consensus on requiring a binutils version recent enough
for this code, you'll need to make the x86_64 configure fragment disable
libmvec by default if the assembler is too old (and make NEWS and
install.texi note the requirement when saying it's on by default for
x86_64).

--
Joseph S. Myers
[hidden email]
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Martin Sebor-2
In reply to this post by Andrew Senkevich
On 06/09/2015 01:48 PM, Andrew Senkevich wrote:

> 2015-06-09 21:40 GMT+03:00 Martin Sebor <[hidden email]>:
>> This patch breaks x86_64 builds with Binutils 2.24 (Fedora 21):
>>
>> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: Assembler
>> messages:
>> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:281: Error:
>> operand type mismatch for `vandpd'
>> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:327: Error:
>> operand type mismatch for `vxorpd'
>> /build/glibc-trunk/sysd-rules:1549: recipe for target
>> '/build/glibc-trunk/mathvec/svml_d_cos8_core_avx512.o' failed
>>
>> (with other similar errors in other files).
>>
>> The first instruction the assembler complains about is:
>>
>>          vandpd 0(%rax), %zmm6, %zmm1
>>
>> As from Binutils 2.25 accepts the code.
>
> I have tested build with manually built Binutils 2.24 (downloaded from
> ftp://sourceware.org/pub/binutils/snapshots/binutils-2.24.90.tar.bz2)
> on x86_64 Fedora 19 with configure/make with no addition options.
>
> How Binutils on your side was built and what is exact version?

Fedora 21's current Binutils is 2.24-30.fc21, a little older
than the snapshot you used.

Martin

Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Adhemerval Zanella-2


On 09-06-2015 17:07, Martin Sebor wrote:

> On 06/09/2015 01:48 PM, Andrew Senkevich wrote:
>> 2015-06-09 21:40 GMT+03:00 Martin Sebor <[hidden email]>:
>>> This patch breaks x86_64 builds with Binutils 2.24 (Fedora 21):
>>>
>>> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S: Assembler
>>> messages:
>>> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:281: Error:
>>> operand type mismatch for `vandpd'
>>> ../sysdeps/x86_64/fpu/multiarch/svml_d_cos8_core_avx512.S:327: Error:
>>> operand type mismatch for `vxorpd'
>>> /build/glibc-trunk/sysd-rules:1549: recipe for target
>>> '/build/glibc-trunk/mathvec/svml_d_cos8_core_avx512.o' failed
>>>
>>> (with other similar errors in other files).
>>>
>>> The first instruction the assembler complains about is:
>>>
>>>          vandpd 0(%rax), %zmm6, %zmm1
>>>
>>> As from Binutils 2.25 accepts the code.
>>
>> I have tested build with manually built Binutils 2.24 (downloaded from
>> ftp://sourceware.org/pub/binutils/snapshots/binutils-2.24.90.tar.bz2)
>> on x86_64 Fedora 19 with configure/make with no addition options.
>>
>> How Binutils on your side was built and what is exact version?
>
> Fedora 21's current Binutils is 2.24-30.fc21, a little older
> than the snapshot you used.
>
> Martin
>

Ubuntu 14.04.2 one shows the same issue (and based on source contents I'd say
it is based on 2.24 release plus some backports).
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Ondřej Bílka
In reply to this post by Joseph Myers
On Tue, Jun 09, 2015 at 07:59:57PM +0000, Joseph Myers wrote:

> On Tue, 9 Jun 2015, Andrew Senkevich wrote:
>
> > I have tested build with manually built Binutils 2.24 (downloaded from
> > ftp://sourceware.org/pub/binutils/snapshots/binutils-2.24.90.tar.bz2)
> > on x86_64 Fedora 19 with configure/make with no addition options.
>
> 2.24.90 means a development version in between 2.24 and 2.25.  Try actual
> 2.24 release.
>
> If you can't get consensus on requiring a binutils version recent enough
> for this code, you'll need to make the x86_64 configure fragment disable
> libmvec by default if the assembler is too old (and make NEWS and
> install.texi note the requirement when saying it's on by default for
> x86_64).
>
No joseph, thats wrong solution. You don't have to disable entire mvec
just because you don't handle avx512.

Instead add configure test for avx512 and change makefile and surround
selection by ifdefs. We still check for sse4 and dont add memcmp_sse4 if
that configure option failed.
Reply | Threaded
Open this post in threaded view
|

Re: [PATCH 1/14] [x86_64] Vector math functions (vector cos)

Joseph Myers
On Wed, 10 Jun 2015, Ondřej Bílka wrote:

> No joseph, thats wrong solution. You don't have to disable entire mvec
> just because you don't handle avx512.
>
> Instead add configure test for avx512 and change makefile and surround
> selection by ifdefs. We still check for sse4 and dont add memcmp_sse4 if
> that configure option failed.

The libmvec ABI must not depend on assembler features.  The shared library
may or may not exist, and the functions may or may not simply be wrappers
to the scalar versions with .byte encodings of AVX512 instructions, but
building the library with AVX512-ABI functions omitted is not an option.

--
Joseph S. Myers
[hidden email]
12