Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python3 int <-> num_bigint support #543

Closed
programmerjake opened this issue Jul 17, 2019 · 3 comments · Fixed by #608
Closed

python3 int <-> num_bigint support #543

programmerjake opened this issue Jul 17, 2019 · 3 comments · Fixed by #608

Comments

@programmerjake
Copy link
Contributor

See also #124

@Askaholic
Copy link
Contributor

I implemented this for grins a while ago: https://gitlab.com/Askaholic/pyrusty.

However, it was my experience that the rust extension module using BigInt was noticeably slower than the python big integer implementation. I was testing this using the baby step giant step algorithm for finding a discrete logarithm.

@programmerjake
Copy link
Contributor Author

I implemented this for grins a while ago: https://gitlab.com/Askaholic/pyrusty.

However, it was my experience that the rust extension module using BigInt was noticeably slower than the python big integer implementation. I was testing this using the baby step giant step algorithm for finding a discrete logarithm.

I would guess python is faster because it optimises for single-word numbers, whereas BigInt doesn't really (it uses Vec internally instead of something like SmallVec)

@programmerjake
Copy link
Contributor Author

See also: rust-num/num-bigint#36

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants