Henry de Valence
b4db0afe18
Allow Options in the VartimeMultiscalarMul trait
...
This changes the primary function for the `VartimeMultiscalarMul` trait
to an `optional_multiscalar_mul` trait that accepts
`Option<Self::Point>` (and returns `None` if any input points are
`None`).
The existing `vartime_multiscalar_mul` is changed to be a wrapper around
this function to avoid code duplication. This may result in an
extra copy of each input point, but that cost is probably not
significant compared to the cost of the multiscalar multiplication.
The motivation is to allow performing multiscalar multiplications with
inline decompression. Currently, API consumers have to allocate
temporary buffers for all of their points, decompress into those
buffers, then pass (iterators over) those buffers into the multiscalar
multiplication code, which then creates new buffers for lookup tables.
2018-07-17 08:19:48 -07:00
Henry de Valence
7bbf7495b0
Change VartimeMultiscalarMul docs to use vartime_
2018-07-16 22:54:45 -07:00
Henry de Valence
e0b7af8957
Merge pull request #161 from isislovecruft/fix/160-alloc-import
...
Fix alloc import
2018-07-16 21:55:37 -07:00
Isis Lovecruft
46c98224f5
Remove erroneous and extraneous alloc import from edwards module.
...
The "alloc" feature doesn't compile otherwise.
* FIXES #160 .
2018-07-17 00:28:04 +00:00
Henry de Valence
87a1815b40
Merge pull request #155 from isislovecruft/feature/148-cleanup-for-1.0.0-pre.0
...
some pre-1.0.0 cleanup
2018-07-05 14:29:01 -07:00
Henry de Valence
fa904c2c42
Add note on backend selection requirement
2018-07-05 13:39:29 -07:00
Henry de Valence
5b009a033e
Remove extra line in doctest
2018-07-05 13:34:14 -07:00
Henry de Valence
0ab60b93ee
Update wording on Scalar::invert to use self
2018-07-05 13:34:02 -07:00
Henry de Valence
b70b32a0c5
Change Scalar example to use the hasher functions
2018-07-05 13:27:09 -07:00
Henry de Valence
f6f20f4598
Merge pull request #152 from isislovecruft/feature/update-rand-0.5.3
...
Update rand dependency to 0.5.3.
2018-07-05 11:52:46 -07:00
Isis Lovecruft
f43f4f9770
Update year in copyright notices to 2018.
2018-07-05 00:30:27 +00:00
Isis Lovecruft
03154d47ec
Add an example doctest for Scalar.invert().
2018-07-05 00:30:27 +00:00
Isis Lovecruft
faf8609246
Copy the inversions of 0 warning to the invert() method.
2018-07-05 00:14:55 +00:00
Isis Lovecruft
626e070896
Document Scalar contructors with doctests.
2018-07-04 23:57:04 +00:00
Isis Lovecruft
5b263dabd0
Line wrap some docstrings in scalar.rs.
2018-07-04 21:43:13 +00:00
Isis Lovecruft
b3da93b069
Clarify README documentation on nightly-only features.
2018-07-04 21:36:57 +00:00
Isis Lovecruft
f4669c8b4d
Move the Scalar constructor documentation to the module level.
2018-07-04 21:29:36 +00:00
Isis Lovecruft
1b52b4b7b7
Thank Sean Bowe and Daira Hopwood in the README.
2018-07-04 20:59:37 +00:00
Isis Lovecruft
4a54f66a48
Move documentation of yolocrypto feature in README.
2018-07-04 20:54:05 +00:00
Isis Lovecruft
ebf0801dfc
Update warning statement on production readiness in README.
2018-07-04 20:50:22 +00:00
Isis Lovecruft
11aa71fb8d
Merge remote-tracking branch 'ebfull/sequential-montgomery-trick' into develop
2018-07-04 20:24:19 +00:00
Isis Lovecruft
3dbfad2f7a
Update rand dependency to 0.5.
2018-07-04 20:16:31 +00:00
Henry de Valence
77fac96a2c
Merge pull request #153 from isislovecruft/feature/update-subtle-0.7.0
...
Bump subtle dependency to 0.7.0.
2018-07-04 13:15:31 -07:00
Isis Lovecruft
b214e6e796
Bump subtle dependency to 0.7.0.
2018-07-04 19:56:16 +00:00
Henry de Valence
ce3595f642
Merge pull request #151 from ebfull/fix-mont-constant-comment
...
Fix adjustment factor comment
2018-07-02 14:14:10 -07:00
Sean Bowe
61d6d89cd8
Fix comment describing Montgomery adjustment factor's value.
2018-07-02 10:41:45 -06:00
Sean Bowe
c4f86b231c
Only test debug assertion in batch_invert when debug assertions are enabled.
2018-07-01 15:07:04 -06:00
Sean Bowe
02af12b81a
Replace batch inversion for FieldElement with sequential variant of Montgomery's trick.
2018-07-01 15:07:04 -06:00
Sean Bowe
6294c02b52
Replace batch inversion implementation for Scalar with sequential variant of Montgomery's trick.
2018-07-01 15:07:04 -06:00
Sean Bowe
611fc40318
Add test that an empty vector field inversion returns one.
2018-06-30 16:29:02 -06:00
Sean Bowe
11b1dc142f
Add test for behavior of Scalar::batch_invert().
2018-06-30 09:49:54 -06:00
Henry de Valence
2ea2d8e381
Merge branch 'master' into develop
2018-06-22 12:27:23 -07:00
Henry de Valence
3a5aef7eea
Merge branch 'release/0.18.0'
2018-06-22 12:27:14 -07:00
Henry de Valence
28b7ed5709
Change version to 0.18.0 (since feature flags changed)
2018-06-22 12:24:20 -07:00
Henry de Valence
3d14343d61
Merge pull request #146 from hdevalence/refactor-avx2
...
Refactor AVX2 code and remove its "yolocrypto" designation
2018-06-21 16:39:48 -07:00
Henry de Valence
791506a29f
Add avx2_backend to make doc FEATURES
2018-06-21 12:01:09 -07:00
Henry de Valence
16f39c82e5
Remove yolocrypto from avx2_backend
2018-06-18 13:32:04 -07:00
Henry de Valence
d791047aac
Rewrite notes and documentation.
2018-06-18 13:22:03 -07:00
Henry de Valence
15f97221ba
Suppress extraneous warnings
2018-06-15 13:44:31 -07:00
Henry de Valence
7198719419
Document bounds on FieldElement32x4 functions
2018-06-15 13:36:38 -07:00
Henry de Valence
9f5bd8c4c0
Rename reduce32 to reduce and have it return its result.
...
This means that all FieldElement32x4 operations return values, vs mutating interior state.
2018-06-14 15:54:36 -07:00
Henry de Valence
bab1ebbeb8
Replace scale_by_curve_constants by a Mul<(u32,u32,u32,u32)> impl
2018-06-14 15:42:20 -07:00
Henry de Valence
6ef9e9dcfb
Make publicity a little more consistent
2018-06-14 15:22:16 -07:00
Henry de Valence
97292fef91
Move packing functions to top of the module
2018-06-14 15:21:51 -07:00
Henry de Valence
4dc219910a
Move blend_lanes into the blend function
2018-06-14 15:13:53 -07:00
Henry de Valence
64b1b481ba
Rewrite diff_sum in terms of shuffle, blend, negate
2018-06-14 14:59:11 -07:00
Henry de Valence
fe51adad31
Don't expose u32x8 unpacking functions
2018-06-14 14:32:13 -07:00
Henry de Valence
c46ec9638c
Add documentation
2018-06-14 14:23:24 -07:00
Henry de Valence
eea3eadf5b
Replace special-case swap_{AB,CD} methods with general shuffles
2018-06-14 14:23:24 -07:00
Henry de Valence
02296fafb5
Delete unused constant
2018-06-14 14:23:24 -07:00