diff options
author | Andy Polyakov <appro@openssl.org> | 2011-05-23 10:14:32 +0200 |
---|---|---|
committer | Andy Polyakov <appro@openssl.org> | 2011-05-23 10:14:32 +0200 |
commit | 62f29eb1cf7957b4eb9ad60eccfe1e11bbac94ce (patch) | |
tree | c6b5ffebe8ee276fe1d21cd92b55b375b0f57a6d /crypto/sparcv9cap.c | |
parent | aesni-x86[_64].pl: optimize for Sandy Bridge and add XTS mode. (diff) | |
download | openssl-62f29eb1cf7957b4eb9ad60eccfe1e11bbac94ce.tar.xz openssl-62f29eb1cf7957b4eb9ad60eccfe1e11bbac94ce.zip |
spacrv9cap.c: addenum to recent EC optimizations.
Diffstat (limited to 'crypto/sparcv9cap.c')
-rw-r--r-- | crypto/sparcv9cap.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/sparcv9cap.c b/crypto/sparcv9cap.c index ad4b3be718..b961cbe3fa 100644 --- a/crypto/sparcv9cap.c +++ b/crypto/sparcv9cap.c @@ -20,7 +20,8 @@ int bn_mul_mont(BN_ULONG *rp, const BN_ULONG *ap, const BN_ULONG *bp, const BN_U int bn_mul_mont_fpu(BN_ULONG *rp, const BN_ULONG *ap, const BN_ULONG *bp, const BN_ULONG *np,const BN_ULONG *n0, int num); int bn_mul_mont_int(BN_ULONG *rp, const BN_ULONG *ap, const BN_ULONG *bp, const BN_ULONG *np,const BN_ULONG *n0, int num); - if ((OPENSSL_sparcv9cap_P&(SPARCV9_PREFER_FPU|SPARCV9_VIS1)) == + if (num>=8 && !(num&1) && + (OPENSSL_sparcv9cap_P&(SPARCV9_PREFER_FPU|SPARCV9_VIS1)) == (SPARCV9_PREFER_FPU|SPARCV9_VIS1)) return bn_mul_mont_fpu(rp,ap,bp,np,n0,num); else |