diff options
| author | jsing <> | 2023-02-16 11:13:05 +0000 |
|---|---|---|
| committer | jsing <> | 2023-02-16 11:13:05 +0000 |
| commit | 02f91f3325f965a313f0cffe5053a084d05a84ea (patch) | |
| tree | a71844b7fce221564ef504741b86d1f18d98a9eb /src/lib/libcrypto/arch/amd64 | |
| parent | 67bcdfeb3f62f73d8ba148704bccbfb2cff0f697 (diff) | |
| download | openbsd-02f91f3325f965a313f0cffe5053a084d05a84ea.tar.gz openbsd-02f91f3325f965a313f0cffe5053a084d05a84ea.tar.bz2 openbsd-02f91f3325f965a313f0cffe5053a084d05a84ea.zip | |
Enable s2n-bignum word_clz() on amd64.
The BN_num_bits_word() function is a hot path, being called more than
80 million times during a libcrypto regress run. The word_clz()
implementation uses five instructions to do the same as the generic code
that uses more than 60 instructions.
Discussed with tb@
Diffstat (limited to 'src/lib/libcrypto/arch/amd64')
| -rw-r--r-- | src/lib/libcrypto/arch/amd64/Makefile.inc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lib/libcrypto/arch/amd64/Makefile.inc b/src/lib/libcrypto/arch/amd64/Makefile.inc index 5e433b572d..e9c7732691 100644 --- a/src/lib/libcrypto/arch/amd64/Makefile.inc +++ b/src/lib/libcrypto/arch/amd64/Makefile.inc | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | # $OpenBSD: Makefile.inc,v 1.11 2023/01/29 14:00:41 jsing Exp $ | 1 | # $OpenBSD: Makefile.inc,v 1.12 2023/02/16 11:13:05 jsing Exp $ |
| 2 | 2 | ||
| 3 | # amd64-specific libcrypto build rules | 3 | # amd64-specific libcrypto build rules |
| 4 | 4 | ||
| @@ -39,6 +39,7 @@ SRCS += bignum_sqr.S | |||
| 39 | SRCS += bignum_sqr_4_8_alt.S | 39 | SRCS += bignum_sqr_4_8_alt.S |
| 40 | SRCS += bignum_sqr_8_16_alt.S | 40 | SRCS += bignum_sqr_8_16_alt.S |
| 41 | SRCS += bignum_sub.S | 41 | SRCS += bignum_sub.S |
| 42 | SRCS += word_clz.S | ||
| 42 | 43 | ||
| 43 | # camellia | 44 | # camellia |
| 44 | SRCS+= cmll_misc.c | 45 | SRCS+= cmll_misc.c |
