dalek-ed25519-verified/verification/gen/CurveScalar
mrwulf 3a10206600 Hash-to-scalar PROVEN: from_bytes_wide_spec - Scalar::from_hash's reduction is exact mod l
The apex brick of the scalar layer: for any 64 bytes (the opaque SHA-512
digest), [from_bytes_wide bytes] = (LE 512-bit value) mod l, with
canonical 52-bit-bounded output. Composition: bytes_unpack_spec (8x8
loops) -> split_words_lo/hi_spec (exact div/mod per limb, disjoint ORs
as additions) -> wide_split_telescope (isolated omega) -> montgomery_mul
by R and RR (R cancels as a unit, RR restores it) -> the canonical add.

The two kernel-capacity walls found and crossed en route (control repo
FAILURES.md updated):
- a montgomery_mul inside any walk motive replays its 400-line body at
  every kernel step (fix: named prefix functions in the pinned source);
- straight-line IndexMut closure chains make kernel defeq exponential in
  depth (fix: struct-literal construction - the split halves now build
  Scalar52([...]) directly). Full certificate: 77 s kernel-inclusive.

Regenerated gen (sources factor from_bytes_wide -> from_bytes_wide_parts
-> split_words_lo/hi; documented pure refactors, cargo-checked).
check-scalar.sh: 13 proof files, 13 kernel audits, all exactly
[propext, Classical.choice, Quot.sound]. Button pressed fresh: green.
2026-07-04 10:31:32 +02:00
..
Funs.lean Hash-to-scalar PROVEN: from_bytes_wide_spec - Scalar::from_hash's reduction is exact mod l 2026-07-04 10:31:32 +02:00
FunsExternal.lean scalar layer: clean Scalar52 extraction + denotation foundation 2026-07-02 21:13:43 +02:00
FunsExternal_Template.lean scalar layer: clean Scalar52 extraction + denotation foundation 2026-07-02 21:13:43 +02:00
Types.lean scalar layer: clean Scalar52 extraction + denotation foundation 2026-07-02 21:13:43 +02:00
TypesExternal.lean scalar layer: clean Scalar52 extraction + denotation foundation 2026-07-02 21:13:43 +02:00
TypesExternal_Template.lean scalar layer: clean Scalar52 extraction + denotation foundation 2026-07-02 21:13:43 +02:00