| avol0 = avol, m = encoding-size(sb, m1), m0 = LEB_SIZE, m1 = EB_PAGE_SIZE, ebm-vol-inv(avol) ⊦ ⟪if m ≤ m0 then let buf = mkbuf(m) in {encode_superblock#(sb, 0, m1; buf, m; err); if err = ESUCCESS then ebm_avol_change#(0, m, buf; avol; err)} else err := ENOSPC⟫ ( (err = ESUCCESS ∨ ⌊err⌋ ) ∧ ebm-vol-inv(avol) ∧ (err = ESUCCESS → id○(avol, avol0, 0) ∧ (∃ buf. is-encoded(sb, buf) ∧ avol[0] = mapped(buf))) ∧ (err ≠ ESUCCESS → avol = avol0)), # avol = 0 |
avol0 = avol, # avol ≠ 0, ebm-vol-inv(avol) ⊦ ⟪if encoding-size(sb, EB_PAGE_SIZE) ≤ LEB_SIZE then let buf = mkbuf(encoding-size(sb, EB_PAGE_SIZE)) in {m := encoding-size(sb, EB_PAGE_SIZE); encode_superblock#(sb, 0, EB_PAGE_SIZE; buf, m; err); if err = ESUCCESS then ebm_avol_change#(0, m, buf; avol; err)} else err := ENOSPC⟫ ( (err = ESUCCESS ∨ ⌊err⌋ ) ∧ ebm-vol-inv(avol) ∧ (err = ESUCCESS → id○(avol, avol0, 0) ∧ (∃ buf. is-encoded(sb, buf) ∧ avol[0] = mapped(buf))) ∧ (err ≠ ESUCCESS → avol = avol0))