[Imprint][Data Privacy Statement][E-Mail]



View long theorem info. View the proof. Back to main index. View the specification. View theorem base summary, View theorem base listing, the used properties by spec, the dependency list, the symbol table,

Proof step 50 from proof prepost-atomic-leb-change (previous step)

# apebs0 = # wlar, LEB_SIZE = n2 + n0, apebs0[n1] = mkpeb(aehdr, empty, mkempbuf(LEB_SIZE), 0, false), wlar[n1] = wl-entry(m1, free), apebs = apebs0[n1, mkpeb(aehdr, avidhdr(v, m0, sqnum, datasize(buf, n0), checksum(buf, datasize(buf, n0))), mkempbuf(LEB_SIZE), 0, false)], err = err0, aehdr.valid?, n1 < # wlar, n1 < # apebs0, bflipset-cons(bflipset, wlar), is-aligned(n0, EB_PAGE_SIZE), ubi-io-inv(apebs0[n1, mkpeb(aehdr, avidhdr(v, m0, sqnum, datasize(buf, n0), checksum(buf, datasize(buf, n0))), mkempbuf(LEB_SIZE), 0, false)]), ubi-io-inv(apebs0), unique-sqns(apebs0), valid-ebatbl(apebs0, wlar, vols, vtblpnum1), valid-eraseq(apebs0, q), valid-eraseq(wlar, q), valid-eraseq(q), valid-global-sqn(apebs0, sqnum), valid-vtbl(apebs0, vols, wlar, vtblpnum1), valid-wl(apebs0, wlar), align↑(datasize(buf, n0), EB_PAGE_SIZE) ≤ # buf, align↑(datasize(buf, n0), EB_PAGE_SIZE) ≤ LEB_SIZE, n0 ≤ LEB_SIZE, n0 ≤ # buf, ⌊err0⌋ ∨ err0 = ESUCCESS, v ∈ vols ∧ m0 < # vols[v] ∨ v = VTBL_VOLID ∧ m0 = VTBL_LNUM ⊦ [if err = ESUCCESS then apebs[n1] := mkpeb (apebs[n1].echdr, apebs[n1].vidhdr, subarray(buf, 0, align↑(datasize(buf, n0), EB_PAGE_SIZE)) + mkempbuf(LEB_SIZE - align↑(datasize(buf, n0), EB_PAGE_SIZE)), align↑(datasize(buf, n0), EB_PAGE_SIZE), apebs[n1].bad) else {vtblpnum := n1; n := align↑(datasize(buf, n0), EB_PAGE_SIZE); buf0 := buf; choose buf1 with # buf1 ≤ n ∧ is-aligned(# buf1, EB_PAGE_SIZE) ∧ ( datasize(buf1, # buf1) < datasize(buf0, n) ∨ checksum(buf1 + mkempbuf(n - # buf1), datasize(buf0, n)) ≠ checksum(buf0, datasize(buf0, n))) in apebs[vtblpnum] := mkpeb(apebs[vtblpnum].echdr, apebs[vtblpnum].vidhdr, buf1 + mkempbuf(LEB_SIZE - # buf1), # buf1, apebs[vtblpnum].bad)}] ( ubi-io-inv(apebs) → ⟪vtblpnum0 := vtblpnum1; vols0 := vols; q0 := q; err1 := err; if err1 = ESUCCESS then {vtblpnum2 := n1; if v = VTBL_VOLID ∧ m0 = VTBL_LNUM then {ubi_wl_put_peb#(VTBL_VOLID × VTBL_LNUM, vtblpnum0; wlar, q); bflipset := bflipset -- vtblpnum0; vtblpnum0 := vtblpnum2} else {vtblpnum3 := m0; if vols[v][vtblpnum3] ≠ unmapped then let vtblpnum0 = vols[v][vtblpnum3].pnum in {ubi_wl_put_peb#(v × vtblpnum3, vtblpnum0; wlar, q); bflipset := bflipset -- vtblpnum0}; vols[v][vtblpnum3] := ⌜vtblpnum2⌝ }; wlar[vtblpnum2] := wl-entry(wlar[vtblpnum2].ec, used)} else ubi_wl_put_peb#(none, n1; wlar, q)⟫ ( (err1 = ESUCCESS ∨ ⌊err1⌋ ) ∧ id○(apebs, apebs0, n1) ∧ # apebs = # wlar ∧ unique-sqns(apebs) ∧ valid-global-sqn(apebs, sqnum + 1) ∧ valid-wl(apebs, wlar) ∧ valid-eraseq(q) ∧ valid-eraseq(wlar, q) ∧ valid-eraseq(apebs, q) ∧ ¬ VTBL_VOLID ∈ vols ∧ bflipset-cons(bflipset, wlar) ∧ ( v ∈ vols0 ∨ is-encoded(to-vtbl(vols0), subarray(buf, 0, LEB_SIZE)) ∧ n0 = LEB_SIZE ∨ err1 ≠ ESUCCESS → valid-ebatbl(apebs, wlar, vols, vtblpnum0) ∧ valid-vtbl(apebs, vols, wlar, vtblpnum0)) ∧ ( err1 = ESUCCESS ∧ v = VTBL_VOLID ∧ m0 = VTBL_LNUM → (∀ v0, m0. ¬ v0 ∈ vols0 ∧ is-encoded(to-vtbl(vols0)[v0, m0], subarray(buf, 0, LEB_SIZE)) ∧ n0 = LEB_SIZE → valid-ebatbl(apebs, wlar, vols[v0, fill(mkebatbl(m0), unmapped)], vtblpnum0) ∧ valid-vtbl(apebs, vols[v0, fill(mkebatbl(m0), unmapped)], wlar, vtblpnum0))) ∧ (err1 = ESUCCESS ∧ v ∈ vols0 ∧ vols0[v][m0] ≠ unmapped → q = q0 + eq-entry(vols0[v][m0].pnum, v × m0) ') ∧ (err1 = ESUCCESS ∧ v = VTBL_VOLID ∧ m0 = VTBL_LNUM → q = q0 + eq-entry(vtblpnum1, VTBL_VOLID × VTBL_LNUM) ') ∧ id(apebs, apebs0, mapped-pebs(vols0)) ∧ (v = VTBL_VOLID ∧ m0 = VTBL_LNUM ∨ err1 ≠ ESUCCESS → vols = vols0) ∧ (v ∈ vols0 ∧ err1 = ESUCCESS → vols = vols0[v, vols0[v][m0, ⌜n1⌝ ]]) ∧ ( err1 = ESUCCESS → apebs[n1].fill = align↑(datasize(buf, n0), EB_PAGE_SIZE) ∧ apebs[n1].data = subarray(buf, 0, n0) + mkempbuf(n2) ∧ q.lebrefs ⊆ q0.lebrefs ++ (v × m0)) ∧ (err1 ≠ ESUCCESS → q.lebrefs = q0.lebrefs))), vtblpnum1 = n1, VTBL_VOLID ∈ vols, vtblpnum1 ∈ q, ∃ buf0. buf = mkempbuf(n0) + buf0

Heuristic conditional right split applied rule if right

And obtained the following new goals

Rule argument

pos: right 1

Additional information