WIP: replace bignumber.js with bn.js #406
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is part of an experiment to replace bignumber.js+cryptojs with @indutny's bn.js+elliptic. Hopefully this will result in faster cryptography. I have run some trials on the speed of the mocha browser tests after this change:
...so the tests are not any faster or slower. However, I have not made any direct speed comparisons between the bignum libraries, and I have not yet changed the elliptic curve code. The slowest operation is point multiplication, so that will be the ultimate test.
This PR is labeled WIP because, although all tests pass and it all works as far as I can tell, it touches a whole bunch of code, so I want to review some more and write more tests before I consider it finished.