From: Chris Duncan Date: Mon, 26 Oct 2026 18:11:31 +0000 (-0700) Subject: Fix lanewise doubling. X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=9f1a63b27e5924b2c08a1cde096a1d12c21bb7d6;p=nano25519.git Fix lanewise doubling. --- diff --git a/src/assembly/ed25519/fep.ts b/src/assembly/ed25519/fep.ts index 41c3945..44eba19 100644 --- a/src/assembly/ed25519/fep.ts +++ b/src/assembly/ed25519/fep.ts @@ -314,7 +314,7 @@ export function fep_dbl_lane (h: FieldElementPair, f: FieldElementPair): void { const f3 = v128.load(changetype(f), 3 << 4) const f4 = v128.load(changetype(f), 4 << 4) - const m = i64x2(-1, 0) + const m = i32x4(-1, 0, -1, 0) const h0 = v128.add(f0, v128.and(f0, m)) const h1 = v128.add(f1, v128.and(f1, m)) const h2 = v128.add(f2, v128.and(f2, m))