3 ms·
Yes, here is the source for 8 double precision logs (with avx512) in glibc, for example: https://github.molgen.mpg.de/git-mirror/glibc/blob/20003c49884422da7ffb
by celrod 7y ago
Yes, here is the source for 8 double precision logs (with avx512) in glibc, for example:
https://github.molgen.mpg.de/git-mirror/glibc/blob/20003c49884422da7ffbc459cdeee768a6fee07b/sysdeps/x86_64/fpu/multiarch/svml_d_log8_core_avx512.S https://github.molgen.mpg.de/git-mirror/glibc/blob/20003c498...
The "sysdeps/x86_64/fpu/multiarch" directory contains many of these functions.
You'll need at least GCC 8 to use them automatically, as well as the -ffast-math flag:
https://godbolt.org/z/PL26up https://godbolt.org/z/PL26up
- celrod 7y agoCorrection: gcc 6 and 7 create them too. They just have 7 unrolled calls to log finite before (and then again after) a loop surrounding the vectorized call.