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

std.crypto.ml_kem tests are very slow, especially under QEMU #21255

Closed
alexrp opened this issue Aug 30, 2024 · 0 comments · Fixed by #21285
Closed

std.crypto.ml_kem tests are very slow, especially under QEMU #21255

alexrp opened this issue Aug 30, 2024 · 0 comments · Fixed by #21285

Comments

@alexrp
Copy link
Member

alexrp commented Aug 30, 2024

With the test binary already built:

❯ time zig4 build test-std -Dno-lib -fqemu -Dtest-target-filter=riscv64-linux.4.19...6.10.3-none

________________________________________________________
Executed in  375.94 secs    fish           external
   usr time  380.91 secs    0.00 micros  380.91 secs
   sys time    1.27 secs  378.00 micros    1.27 secs

The std.crypto.ml_kem tests account for just about 4 minutes of this if you watch the progress bar. Test happy flow and Test inner PKE are the big offenders.

I had to measure that manually with a stopwatch because, for whatever reason, if you add -Dtest-filter=ml_kem, the tests only take ~30 seconds to run. I have no idea why they're only so slow in a full test binary.

Note that the testing was done on my llvm-19 branch as RISC-V compilation is unusably slow with LLVM 18.

cc @jedisct1

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 a pull request may close this issue.

1 participant