[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,

Theorem format

ubi_format#(; WLARRAY, VTBLPNUM, LEBSIZE, APEBS, VOLS, ERASEQ, BFLIPSET, SQNUM; PAGESIZE, ERR) {aubi_io_format#(; ; APEBS, ERR); aubi_io_get_leb_size#(APEBS; ; LEBSIZE); aubi_io_get_page_size#(APEBS; ; PAGESIZE); if ERR ≠ ESUCCESS then debug#("ubi: ubi-io format failed") else let N = ?, PNUM = 0 in {aubi_io_get_blockcount#(APEBS; ; N); WLARRAY := mkwlarray(N); VTBLPNUM := N; ERR := ESUCCESS; while PNUM < N ∧ ERR = ESUCCESS do {/* (inv-format : invariant PNUM ≤ # APEBS ∧ N = # APEBS ∧ # WLARRAY = # APEBS ∧ (ERR = ESUCCESS ∨ ⌊ERR⌋ ) ∧ ( ERR = ESUCCESS → ubi-io-initial(APEBS) ∧ VTBLPNUM ≤ # APEBS ∧ (∀ n3. n3 < PNUM → (APEBS[n3].bad → WLARRAY[n3] = wl-entry(0, erroneous)) ∧ ( ¬ APEBS[n3].bad → APEBS[n3].echdr.valid? ∧ WLARRAY[n3] = wl-entry(APEBS[n3].echdr.ec, free) ∧ APEBS[n3].vidhdr = empty)) ∧ (VTBLPNUM ≠ # APEBS → ¬ APEBS[VTBLPNUM].bad)) wfbound N - PNUM) */; let ISBAD = ? in {aubi_io_isbad#(PNUM, APEBS; ; ISBAD, ERR); if ERR = ESUCCESS then if ¬ ISBAD then let AEHDR = ?, BITFLIPS = ? in {aubi_io_read_echdr#(PNUM, APEBS; AEHDR; BITFLIPS, ERR); if ERR = ESUCCESS ∧ VTBLPNUM = N then VTBLPNUM := PNUM; if ERR = ESUCCESS ∧ AEHDR.valid? then WLARRAY[PNUM] := wl-entry(AEHDR.ec, free)} else WLARRAY[PNUM] := wl-entry(0, erroneous); PNUM := PNUM + 1}}; if ERR = ESUCCESS then if VTBLPNUM = N then ERR := ENOSPC else {aubi_io_write_vidhdr#(VTBLPNUM, avidhdr(VTBL_VOLID, VTBL_LNUM, 0, 0, 0); APEBS; ERR); if ERR = ESUCCESS then if ENCODED_NAT_SIZE > LEBSIZE then ERR := ENOSPC else let BUF = mkbuf(LEBSIZE), VTBL = ∅ in {encode_vtbl#(; VTBL, BUF; ERR); if ERR = ESUCCESS then aubi_io_write_data#(VTBLPNUM, 0, 0, LEBSIZE, BUF; APEBS; ERR)}; VOLS := ∅; WLARRAY[VTBLPNUM].status := used; ERASEQ := []; SQNUM := 1; BFLIPSET := ∅}} }