| # pebs0 = n + m1, # pebs1 = n + m1, # buf1 = EB_PAGE_SIZE, pebs1[m1] = mkpeb(buf0, m2, false), is-encoded(echdr((err1 = ESUCCESS ∧ aehdr0.valid? ⊃ aehdr0.ec + 1;0)), buf1), mtd-cons(pebs0), mtd-cons(pebs1), mtd-cons(pebs1[m1, mkpeb(emptypeb, 0, false)]), mtd-cons(pebs1[m1, mkpeb(copy(buf1, 0, emptypeb, 0, EB_PAGE_SIZE), EB_PAGE_SIZE, false)]), ubi-io-initial(subarray(pebs1, 0, m1)), EB_PAGE_SIZE ≤ PEB_SIZE, n0 ≤ m1 ⊦ n = 0, ubi-io-peb-initial(subarray(pebs1[m1, mkpeb(copy(buf1, 0, emptypeb, 0, EB_PAGE_SIZE), EB_PAGE_SIZE, false)], 0, m1 + 1)[n0]) |
⊦ n + m ≤ # pebs ∧ n0 < n → subarray(pebs, m, n)[n0] = pebs[m + n0]
# buf1 = EB_PAGE_SIZE, # pebs1 = n + m1, # pebs0 = n + m1, pebs1[m1] = mkpeb(buf0, m2, false), n0 < m1 + 1, is-encoded(echdr((err1 = ESUCCESS ∧ aehdr0.valid? ⊃ aehdr0.ec + 1;0)), buf1), mtd-cons(pebs1[m1, mkpeb(copy(buf1, 0, emptypeb, 0, EB_PAGE_SIZE), EB_PAGE_SIZE, false)]), mtd-cons(pebs1[m1, mkpeb(emptypeb, 0, false)]), mtd-cons(pebs1), mtd-cons(pebs0), ubi-io-initial(subarray(pebs1, 0, m1)), n0 ≤ m1, EB_PAGE_SIZE ≤ PEB_SIZE, (m1 + 1) + 0 ≤ # pebs1[m1, mkpeb(copy(buf1, 0, emptypeb, 0, EB_PAGE_SIZE), EB_PAGE_SIZE, false)] ⊦ n = 0, ubi-io-peb-initial(pebs1[m1, mkpeb(copy(buf1, 0, emptypeb, 0, EB_PAGE_SIZE), EB_PAGE_SIZE, false)][0 + n0])
Used simplifier rules: a: ⊦ (m + n0) + n1 = m + n0 + n1; from specification nat-basic%c: ⊦ m + n = n + m; from specification nat-basic% ⊦ # pebs[n, peb] = # pebs; (s)% ⊦ m + 1 ≤ n ↔ m < n; (s)% ⊦ m < n + 1 ↔ ¬ n < m; (s)% ⊦ m ≤ n → (n < m ↔ false); (s)% ⊦ m < n ↔ ¬ n ≤ m; (ss)% ⊦ m + m0 ≤ m ↔ m0 = 0; (s) Used terms: n0, m1 + 1, 0, pebs1 [m1, mkpeb(copy(buf1, 0, emptypeb, 0, EB_PAGE_SIZE), EB_PAGE_SIZE, false) ]