boringssl/crypto/fipsmodule/bn
David Benjamin 83d1a3d3c8 Enable ADX in x86_64-mont*.pl.
We have an SDE bot now and can more easily test things. We also enabled
ADX in rsaz-avx2.pl which does not work without x86_64-mont*.pl enabled.
rsa-avx2.pl's ADX code only turns itself off so that the faster ADX code
can be used... but we disable it.

Verified, after reverting the fix, the test vectors we imported combined
with Intel SDE catches CVE-2016-7055, so we do indeed have test
coverage.

Thanks to Alexey Ivanov for pointing out the discrepancy.

Skylake numbers:

Before:
Did 7296 RSA 2048 signing operations in 10038191us (726.8 ops/sec)
Did 209000 RSA 2048 verify operations in 10030629us (20836.2 ops/sec)
Did 1080 RSA 4096 signing operations in 10072221us (107.2 ops/sec)
Did 60836 RSA 4096 verify operations in 10053929us (6051.0 ops/sec)

ADX consistently off:
Did 9360 RSA 2048 signing operations in 10025823us (933.6 ops/sec)
Did 220000 RSA 2048 verify operations in 10024339us (21946.6 ops/sec)
Did 1048 RSA 4096 signing operations in 10006782us (104.7 ops/sec)
Did 61936 RSA 4096 verify operations in 10088011us (6139.6 ops/sec)

After (ADX consistently on):
Did 10444 RSA 2048 signing operations in 10006781us (1043.7 ops/sec)
Did 323000 RSA 2048 verify operations in 10012192us (32260.7 ops/sec)
Did 1610 RSA 4096 signing operations in 10044930us (160.3 ops/sec)
Did 96000 RSA 4096 verify operations in 10075606us (9528.0 ops/sec)

Change-Id: Icbbd4f06dde60d1a42a691c511b34c47b9a2da5f
Reviewed-on: https://boringssl-review.googlesource.com/18965
Reviewed-by: Adam Langley <agl@google.com>
Commit-Queue: David Benjamin <davidben@google.com>
2017-08-09 00:42:51 +00:00
..
asm Enable ADX in x86_64-mont*.pl. 2017-08-09 00:42:51 +00:00
add.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
bn_test.cc Convert bn_test to GTest. 2017-06-05 21:45:07 +00:00
bn_tests.txt Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
bn.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
bytes.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
check_bn_tests.go Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
cmp.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
ctx.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
div.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
exponentiation.c Switch some pointer casts to memcpy. 2017-07-11 02:02:41 +00:00
gcd.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
generic.c Undefine some macros in bn/ 2017-05-02 22:11:50 +00:00
internal.h Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
jacobi.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
montgomery_inv.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
montgomery.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
mul.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
prime.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
random.c Switch BN_generate_dsa_nonce's hash back to SHA-512/256. 2017-05-08 22:00:48 +00:00
rsaz_exp.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
rsaz_exp.h Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
shift.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00
sqrt.c Move bn/ into crypto/fipsmodule/ 2017-05-01 22:51:25 +00:00