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

Expand array sizes through U1024 #46

Merged
merged 1 commit into from
Feb 16, 2024
Merged

Expand array sizes through U1024 #46

merged 1 commit into from
Feb 16, 2024

Conversation

tarcieri
Copy link
Member

@tarcieri tarcieri commented Feb 16, 2024

Post-quantum schemes like Kyber/Saber require sizes larger than what is currently supported.

This extends the allowed array sizes through U1024 in multiples of 16, although that still won't be enough to cover all cases.

However, it's the current limit of what typenum provides convenient type aliases for.

@tarcieri
Copy link
Member Author

tarcieri commented Feb 16, 2024

This causes a fairly significant increase in build times:

For some reason I don't see this on a local build, though?

It would seem prudent to adopt only multiples of some power of two for these larger sizes, like I suggested in #45

Edit: this is actually a difference between 1.65 and stable, which explains why it built so fast locally. It looks like it currently takes 3m to build on 1.65: https://github.com/RustCrypto/hybrid-array/actions/runs/7923269699/job/21632628872

Edit again: opened #47 to track this.

Post-quantum schemes like Kyber/Saber require sizes larger than what is
currently supported.

This extends the allowed array sizes through U1024, stepping by
multiples of 16,  although that still won't be enough to cover all
cases needed for Kyber/Saber.

However, it's the current limit of what `typenum` provides convenient
type aliases for. Beyond that we'll either need to define our own types
/ type aliases.
@tarcieri
Copy link
Member Author

Using multiples of 16 for sizes above 256 has reduced build times to 2s again, although we'll still need a solution for sizes >1024.

@tarcieri tarcieri merged commit 70189c0 into master Feb 16, 2024
14 checks passed
@tarcieri tarcieri deleted the expand-sizes-to-1024 branch February 16, 2024 14:17
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.

None yet

1 participant