[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 131 from proof refine-add-gnds (previous step)

# lpt1 = # avol, # lpt0 = # avol, # buf0 = gndx0.flashsize, # gndx0 = # lax0, # lpt0 = # avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))], # lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ] = # avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))], (elems nx ∪ dom gstore0) ++ n = dom gstore ∪ ginval, isbuf ↔ false, avol[n] = mapped(buf1), gstore[n] = groupblock(gndx, lax, m1), lpt1[n] = mklp(m1, # buf1, LP_GROUP_NODES, m2), err = err0, err = ESUCCESS, keyset(gch) = gc-heap(lpt1, nx + n '), keyset(gch) = gc-heap (lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ], log1), log1 = nx + n ', m = buffered((nx + n ').last).leb, pstate = journal(log1.last), remove-refsize0(istore0) = istore0, remove-refsize0(gstore0) = gstore0, ginval ∩ elems nx = ∅, buffered((nx + n ').last).isbuf?, buffered(log1.last).isbuf?, avol[m].mapped?, m < # avol, ginval < # avol, n < # avol, buffered(log1.last).leb < # lpt1, abs-gstore(avol, lpt1, gstore, ginval), abs-istore(avol, lpt1, istore), abs-nodes(buf0, # buf1, gndx0, lax0, false), awbuf-inv(avol, buffered(n)), awbuf-inv(avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))], buffered(n)), bin-heap-inv(gch, lpt1), bin-heap-inv (gch, lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ]), buf-ro-rw-mode(false, buffered(n), lpt1, avol), buf-ro-rw-mode (isbuf, buffered(n), lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ], avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))]), bufs-log-only(buffered(n), nx + n ', lpt1), bufs-log-only (buffered(n), log1, lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ]), flash-lpt-cons(lpt0, istore0, gstore0), freelist-cons(lpt1, freelist), freelist-cons (lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ], freelist), inv(groupblock(gndx, lax, m1)), inv(istore0), inv(istore), inv(gstore0), inv(gstore \ ginval), log-group-block(nx + n ', lpt1), log-group-block (log1, lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ]), lpt-free-unref(lpt1), lpt-free-unref(lpt0), lpt-free-unref (lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ]), lpt-leb-size(lpt1), lpt-leb-size(lpt0), lpt-leb-size (lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ]), lpt-ram-flash(lpt1, lpt0, nx + n '), lpt-ram-flash (lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ], lpt0, log1), n ∈ gstore, 0 + gndx0.flashsize ≤ # buf0, # buf1 + gndx0.flashsize ≤ LEB_SIZE, istore0 ⊑ istore, isbuf1 → synced(avol), ⌊err0⌋ ∨ err0 = ESUCCESS ⊦ ⟨apersistence_add_gnds#(gndx0, adr0, istore, istore0, ginval, gstore0, log1, m0, ns0; ax0, gstore, pstate, isbuf1; err1)⟩ ( abs-istore (avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))], lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ], istore) ∧ abs-gstore (avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))], lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ], gstore, ginval) ∧ ginval < # lpt1 [buffered(log1.last).leb, mklp (lpt1[buffered(log1.last).leb].ref-size, lpt1[buffered(log1.last).leb].size + gndx0.flashsize, lpt1[buffered(log1.last).leb].flags, lpt1[buffered(log1.last).leb].gcheapidx) ] ∧ (isbuf1 → synced(avol[m, mapped(avol[m].data + subarray(buf0, 0, gndx0.flashsize))])) ∧ pstate ≠ unbuffered ∧ (pstate = readonly ↔ isbuf) ∧ (pstate ≠ readonly → n = pstate.lnum) ∧ lax0.to-adr(n) = ax0 ∧ err = err1), nx + n ' = [], gndx0 = [], log1 = [], dups(nx), n ∈ nx, n ∈ ginval

Heuristic simplifier applied rule simplifier

And obtained the following new goals

Rule argument

Additional information

Used simplifier rules: ⊦ LP_FREE ≠ LP_GROUP_NODES; (s)% ⊦ m ≤ m; (s)%n < # lpt ⊦ lpt[n] = mklp(n0, n1, LP_GROUP_NODES, n2) ∧ log-group-block(nx, lpt) → log-group-block(nx, lpt[n, mklp(m0, m1, LP_GROUP_NODES, m2)]); (s)%⊦ freelist-cons(lpt, freelist) ∧ lpt[n] = mklp(m0, m1, lpf, m2) → freelist-cons(lpt[n, mklp(n0, n1, lpf, n2)], freelist); (s)%n < # lpt ⊦ lpt[n] = mklp(m0, m1, lpf0, m2) → ( bin-heap-inv(gch, lpt[n, mklp(n0, n1, lpf1, m2)]) ↔ bin-heap-inv(gch, lpt)); (s)% ⊦ mapped(buf) = mapped(buf0) ↔ buf = buf0; (s)%n < # lpt ⊦ lpt[n] = mklp(m0, m1, LP_GROUP_NODES, m2) → gc-heap(lpt[n, mklp(m0, n1, LP_GROUP_NODES, n2)], nx) = gc-heap(lpt, nx); (s)% ⊦ m < n ↔ ¬ n ≤ m; (ss)% ⊦ m + n = m + n0 ↔ n = n0; (s)% ⊦ mapped(buf).data = buf; (s)%inv-buf-in-vol: ⊦ awbuf-inv(avol, buffered(n)) → n < # avol; (forward) from specification awbuf-inv%⊦ awbuf-inv(avol, buffered(n)) → (synced(avol[n, mapped(buf)]) ↔ is-aligned(# buf, EB_PAGE_SIZE)); (s)%lpf ≠ LP_INDEX_NODES ⊦ lpt[n] = mklp(n0, n1, lpf, n2) → ( abs-istore(avol[n, aleb], lpt, istore) ↔ abs-istore(avol, lpt, istore)); (s)%lpf ≠ LP_INDEX_NODES, lp.flags ≠ LP_INDEX_NODES ⊦ lpt[n] = mklp(n0, n1, lpf, n2) → ( abs-istore(avol, lpt[n, lp], istore) ↔ abs-istore(avol, lpt, istore)); (s)% ⊦ LP_GROUP_NODES ≠ LP_INDEX_NODES; (s)% ⊦ m < n → (n ≤ m ↔ false); (s)% ⊦ ¬ ⌊ESUCCESS⌋ ; (s)% ⊦ buffered(m).isbuf?; (s)% ⊦ avol[n].mapped? ↔ (∃ buf. avol[n] = mapped(buf)); (as)%append-a: ⊦ (buf + buf0) + buf1 = buf + buf0 + buf1; from specification array-splice[buffer]% ⊦ #(buf + buf0) = # buf + # buf0; (s)%n < # lpt, n < # avol ⊦ buf-ro-rw-mode (false, buffered(n), lpt[n, mklp(m0, m1, lpf, m2)], avol[n, mapped(buf)]) ↔ m1 = # buf; (s)%lpt[n].flags = lp.flags ⊦ bufs-log-only(bleb, nx, lpt) → bufs-log-only(bleb, nx, lpt[n, lp]); (s)% ⊦ mklp(n2, n3, lpf, m).gcheapidx = m; (s)% ⊦ mklp(n2, n3, lpf, m).ref-size = n2; (s)% ⊦ mklp(n2, n3, lpf, m).flags = lpf; (s)%⊦ lpt-free-unref(lpt) → ( lpt-free-unref(lpt[n, lp]) ↔ n < # lpt ∧ lp.flags = LP_FREE → lp.ref-size = 0); (s)% ⊦ mklp(n2, n3, lpf, m).size = n3; (s)%⊦ lpt-leb-size(lpt) → (lpt-leb-size(lpt[n, lp]) ↔ # lpt ≤ n ∨ lp.size ≤ LEB_SIZE); (s)%⊦ lpt-ram-flash(lpt[n, lp], lpt0, nx + n ') ↔ lpt-ram-flash(lpt, lpt0, nx + n '); (s)%c: ⊦ m + n = n + m; from specification nat-basic%a: ⊦ (m + n0) + n1 = m + n0 + n1; from specification nat-basic% ⊦ n + 0 = n; (s)% ⊦ nx + n ' ≠ []; (s)% ⊦ # avol[n, aleb] = # avol; (s)%# buf = n ⊦ subarray(buf, 0, n) = buf; (s)% ⊦ # lpt[n, lp] = # lpt; (s)% ⊦ buffered(m).leb = m; (s)%a: ⊦ (nx + nx0) + nx1 = nx + nx0 + nx1; from specification list[nat-list-set]% ⊦ (nx + n ').last = n; (s)