| author | |
| committer | |
| log | a91bc9cd0fbb384ec135d5429ad5dcae56449042 |
| tree | 0168375f9acaa55a34802e9d47b455b69892947b |
| parent | 0e494a3345f1c635d5979571dd55a1c663992d97 |
Coefficient extraction generates bogus code with u64 batches.
Using u32 batches seems to work around it.1 files changed, 1 insertions(+), 0 deletions(-)
lib/std/crypto/ml_kem.zig+1| ... | ... | @@ -1179,6 +1179,7 @@ const Poly = struct { |
| 1179 | 1179 | |
| 1180 | 1180 | const T = switch (builtin.target.cpu.arch) { |
| 1181 | 1181 | .x86_64, .x86 => u32, // Generates better code on Intel CPUs |
| 1182 | .riscv64 => u32, // Work around LLVM miscompiling coefficient extraction with u64 batches https://codeberg.org/ziglang/zig/issues/37128 | |
| 1182 | 1183 | else => u64, // u128 might be faster on some other CPUs. |
| 1183 | 1184 | }; |
| 1184 | 1185 |