diff options
author | Torbjorn Granlund <tg@gmplib.org> | 2017-06-01 15:27:51 +0200 |
---|---|---|
committer | Torbjorn Granlund <tg@gmplib.org> | 2017-06-01 15:27:51 +0200 |
commit | 5cf59afaf7bc176a3d9e85ded1a62364385a8791 (patch) | |
tree | b92285abf7ca143c6a61b06a90f9fa14c3395348 /mpn/x86_64/bd1/hamdist.asm | |
parent | 6bde509c117b4cd7d34d0b282c1196b396fc78d2 (diff) | |
download | gmp-5cf59afaf7bc176a3d9e85ded1a62364385a8791.tar.gz |
Use GMP_AVX_NOT_REALLY_AVAILABLE.
Diffstat (limited to 'mpn/x86_64/bd1/hamdist.asm')
-rw-r--r-- | mpn/x86_64/bd1/hamdist.asm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/mpn/x86_64/bd1/hamdist.asm b/mpn/x86_64/bd1/hamdist.asm index c40a77873..aeffb9bbc 100644 --- a/mpn/x86_64/bd1/hamdist.asm +++ b/mpn/x86_64/bd1/hamdist.asm @@ -53,6 +53,14 @@ C Intel atom n/a C Intel SLM n/a C VIA nano n/a +C We use vpshlb and vpperm below, which are XOP extensions to AVX. Some +C systems, e.g., NetBSD, set OSXSAVE but nevertheless trigger SIGILL for AVX. +C We fall back to the core2 code. +ifdef(`GMP_AVX_NOT_REALLY_AVAILABLE',` +MULFUNC_PROLOGUE(mpn_hamdist) +include_mpn(`x86_64/core2/hamdist.asm') +',` + define(`up', `%rdi') define(`vp', `%rsi') define(`n', `%rdx') @@ -198,3 +206,4 @@ DEF_OBJECT(L(cnsts),16) .byte 0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f .byte 0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f,0x0f END_OBJECT(L(cnsts)) +') |