Skip to main content

Module kv

Module kv 

Source
Expand description

The application side of uBFT, authored in RHDL.

The hash table keeps the upstream 64-bit key / 16-bit value contract. The legacy CPU PUT format cannot fit losslessly in a 32-bit consensus proposal; the frontend exposes a bounded 16-bit-key / 16-bit-value profile and rejects larger PUT fields. Read the module-specific contracts before connecting the two replicated decision streams.

No routed resource, timing, or card performance is implied by these modules.

Follow one operation through the source:

  1. load::Load reads a CPU word without reading past the supplied buffer.
  2. kvstore::LegacyKv16 checks its representation and proposes a PUT.
  3. The external consensus controller returns matching decision streams.
  4. hash_table::HashTable applies the write atomically; only then can the frontend return a successful PUT result. A GET reads the local table.

These are separate components, not an already wired card top level. integration_tests.rs demonstrates their application-side handshake wiring. Start there for a concrete PUT, duplicate decision, upsert and GET trace.

Modulesยง

hash_table
Transactional cuckoo table, nine true synchronous RAM banks of 64 entries. Transactions are serialized; responses hold until consumed. Reset discards all in-flight work and scrubs every RAM address before accepting another request.
kvstore
An explicit, bounded compatibility frontend for the current replica.
load
Bounded replacement for upstream load/load.cpp.
tabulation
Exact upstream tabulation constants; see PROVENANCE.md and LICENSE-ETH-BSD-3-Clause.