NLA-lib Explorer

The store and the memory of a run

Library · Source module

The store and the memory of a run

A store is a stack of buffers of possibly uninitialised cells over a carrier K of opaque words; a handle is a position in the stack. A read fails outside a buffer and at an uninitialised cell. Updates (NLAlib.Ops.Store.upd, NLAlib.Ops.Store.updBlock) are total functions that do nothing out of bounds; the failing writes of the evaluator (NLAlib.Ops.Mem.write) are an update guarded by a bounds check. So the memory after a run is written as an equation between updates, and bounds are separate facts.

The memory NLAlib.Ops.Mem of a run is the store and the position on the tape of draws.

Main results

* NLAlib.Ops.Store.get_upd_self, NLAlib.Ops.Store.get_upd_of_ne: a read after an update. * NLAlib.Ops.Store.get_updBlock, NLAlib.Ops.Store.get_updBlock_of_buf_ne, NLAlib.Ops.Store.get_updBlock_of_lt, NLAlib.Ops.Store.get_updBlock_of_ge: a read after a block update. * NLAlib.Ops.Store.updBlock_append, NLAlib.Ops.Store.updBlock_concat: a block is filled piece by piece. * NLAlib.Ops.Store.get_append_of_lt, NLAlib.Ops.Store.upd_append_of_lt, NLAlib.Ops.Store.upd_append_top: reads and updates below and in a scratch buffer on top. * NLAlib.Ops.Store.readBlock_eq_some_iff: a block read, cell by cell.

Declarations