NLA-lib Explorer

NLAlib.Ops.Algorithm.link

Library · def

Link fixed trees and recheck storage compatibility, full lower work/span and resident bytes. Different primitive parallel configurations require separately specified resource models.

NLAlib.Ops.Algorithm.link {Op Lo Tst K : Type} {r b : ℕ} {P : Ops.Problem K r b}
  {M : Ops.AccessModel Op Tst P} {S : Ops.Specification Op Tst P} (A : Ops.Algorithm M S)
  (T : Ops.Table Op Lo Tst) (L : Ops.AccessModel Lo Tst P) (S₂ : Ops.Specification Lo Tst P)
  (ht : (A.program.link T).wellTyped L.resources P.formats = true)
  (hcontracts :
    ∀ (d : Fin r → ℕ),
      P.valid d →
        ∀ (x : P.Input d) (I : Ops.Interp Lo Tst K), L.contracts d x I → M.contracts d x (I.link T))
  (hgood :
    ∀ (d : Fin r → ℕ),
      P.valid d →
        ∀ (x : P.Input d) (τ : Ops.Tape K) (c : Ops.Count (Op ⊕ Ops.Bookkeeping) Tst)
          (m' : Ops.Mem K),
          c ≤ S.budget d → S.good d x τ c m' → ∀ c' ≤ S₂.budget d, S₂.good d x τ c' m')
  (hcost : ∀ (d : Fin r → ℕ), P.valid d → Ops.staticCost (A.program.link T) d ≤ S₂.budget d)
  (hspace :
    ∀ (d : Fin r → ℕ), P.valid d → Ops.staticPeak L.resources (A.program.link T) d ≤ S₂.scratch d)
  (hwork : ∀ (d : Fin r → ℕ), P.valid d → L.resources.work (S₂.budget d) ≤ S₂.work d)
  (hspan : ∀ (d : Fin r → ℕ), P.valid d → L.resources.span (S₂.budget d) ≤ S₂.span d)
  (hmemory :
    ∀ (d : Fin r → ℕ),
      P.valid d → ∀ (x : P.Input d), P.initialBytes d x + S₂.scratch d ≤ S₂.memory d) :
  Ops.Algorithm L S₂

Full source on GitHub

Import NLAlib.Ops.Cert.