The diagonal stage on a frame, generic in the registers (instantiated below) (`dgF`)
ProvedJ6Seg.KR.dgFcomplexity-theoryinteger-multiplicationkappa-improvement
The diagonal stage on a frame, generic in the registers (instantiated below).
The following holds (Lean statement, in the scope of module Solutions.J6SegKr5b):
theorem J6Seg.KR.dgF {M : MulSpec} {pM : Fin Pp} (hM : MulOK I iprog pM M) (hdom : ∀ x y, M.dom x y)
{φ B : ℕ} (hΦ : ∀ x y : ℤ, zsz x ≤ B → zsz y ≤ B → M.Φ x y ≤ φ) {X T Y : Fin HS}
(hX : X = 0 ∨ X = J6Seg.KR.W2) (hT : TabReg T) (hY : Y = W1 ∨ Y = OUT)
(P : ℕ) (s : IState HS) (F : Fin HS → List ℤ) (z : List GI) (cs lx : List ℤ) (n : ℕ)
(hFX : F X = gflat z ++ lx) (hFT : F T = cs) (hzn : z.length = n) (hcz : n ≤ cs.length)
(hCN : F CN = []) (hCC : F J6Seg.KR.CC = []) (hm1 : F dM1 = []) (hm2 : F dM2 = [])
(hN : F bN = [(n : ℤ)]) (hP : F J6Seg.KR.rP = [2 ^ P]) (hQ : F rP1 = [2 ^ (P + 1)])
(Bz : ℕ) (hz : GB Bz z) (hc : Bnd Bz cs) (hBz : 2 * Bz + 2 ≤ B) (hPB : P + 3 ≤ B)
(hn : zsz (n : ℤ) ≤ B) :
IRuns I iprog (J6Seg.KR.dgI pM X T TU Y CN J6Seg.KR.CC bN) (encK s F)
(encK s (Function.update (Function.update F X lx) Y (gflat (dgG P cs z).reverse ++ F Y)))
(cDG n φ B)
Context. B3 (chunk kernel), part 5b: the stages of one block in the frame BF
Each stage of the block body as a run between BF frames, with the untouched fields general.
Formalization Note. Part of the Lean formalization of the round-six κ-improvement (integer-multiplication-kappa campaign, target IntMul.Kappa.jain_round6_framework). The statement is copied verbatim from the Lean development; the platform node carries the same declaration name. Definitions it mentions live in the IntMul_Kappa_R6_Defs* bundles (on top of the published κ bundles IntMul_Kappa_K_Defs*).
Preamble
-- Round-six κ development (integer-multiplication-kappa), generated by skeleton subtraction.
import Definitions.Def_IntMul_Kappa_R6_Defs65
set_option autoImplicit false
set_option relaxedAutoImplicit false
set_option maxHeartbeats 1000000
open J6Seg J6Seg.KR
open IntMul NLogN NLogN.KIL NLogN.KFD NLogN.KFB NLogN.KFV
variable {Pp : ℕ} {I : List Sym} {iprog : Fin Pp → IStmt HS Pp}
Formal statement
theorem J6Seg.KR.dgF {M : MulSpec} {pM : Fin Pp} (hM : MulOK I iprog pM M) (hdom : ∀ x y, M.dom x y)
{φ B : ℕ} (hΦ : ∀ x y : ℤ, zsz x ≤ B → zsz y ≤ B → M.Φ x y ≤ φ) {X T Y : Fin HS}
(hX : X = 0 ∨ X = J6Seg.KR.W2) (hT : TabReg T) (hY : Y = W1 ∨ Y = OUT)
(P : ℕ) (s : IState HS) (F : Fin HS → List ℤ) (z : List GI) (cs lx : List ℤ) (n : ℕ)
(hFX : F X = gflat z ++ lx) (hFT : F T = cs) (hzn : z.length = n) (hcz : n ≤ cs.length)
(hCN : F CN = []) (hCC : F J6Seg.KR.CC = []) (hm1 : F dM1 = []) (hm2 : F dM2 = [])
(hN : F bN = [(n : ℤ)]) (hP : F J6Seg.KR.rP = [2 ^ P]) (hQ : F rP1 = [2 ^ (P + 1)])
(Bz : ℕ) (hz : GB Bz z) (hc : Bnd Bz cs) (hBz : 2 * Bz + 2 ≤ B) (hPB : P + 3 ≤ B)
(hn : zsz (n : ℤ) ≤ B) :
IRuns I iprog (J6Seg.KR.dgI pM X T TU Y CN J6Seg.KR.CC bN) (encK s F)
(encK s (Function.update (Function.update F X lx) Y (gflat (dgG P cs z).reverse ++ F Y)))
(cDG n φ B) := by sorrySource
S. Jain, round-six networks for the integer-multiplication κ-improvement campaign (https://github.com/Swapnil-jain/integer-mult-kappa, commit 5868dc7) and D. Colkitt, integer-mult-bounds (https://github.com/CrocSwap/integer-mult-bounds); target `IntMul.Kappa.jain_round6_framework`. Lean declaration `J6Seg.KR.dgF`, Solutions/J6SegKr5b.lean (lines 55–106) of the round-six development.