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

dlimbs_algs_multi - attempted definition for when LIMBS is multiple of TPI (greater than TPI) #27

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

peterminea
Copy link

@peterminea peterminea commented Nov 14, 2023

This is an attempt to define a dlimbs_algs_multi structure, covering the cases when LIMBS is greater than TPI (e.g. a multiple of TPI). The aforementioned structure is now only referenced, but not defined, in the main source code, and when LIMBS is greater than TPI (e.g. when BITS is 2048, TPI is 32, and LIMBS is 64) we get an "Incomplete type is not allowed" showstopper error, being therefore unable to use CGBN for greater numbers.
If the source code needs further improvements, please let me know on the PR.

@peterminea
Copy link
Author

I came back with some changes to the source code. I have tested it for BITS=2048 and TPI=32, i.e. LIMBS = 64 that is two times greater than TPI. Able to represent integers that are greater than 2^1024, but sometimes my old version of code was introducing some improper/corrupted numbers (whose prime factorizations were not expected in the code).
Need to further test, maybe that big number factorization problem has also something to do with other flaws of CGBN and not necessarily with my approach to dlimbs_algs_multi. At least, we give this new structure a try!

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

Successfully merging this pull request may close these issues.

1 participant