Tezos_alpha_test_helpers.Dummy_zk_rollupSourceDummy ZK Rollup for testing the ZKRU integration in the protocol. The library Plompiler is used to build the circuits (in a module V as verifier) and the corresponding functions to produce the inputs for the circuits (in a module P as prover).
The state of this rollup is a boolean value, which will be represented with a scalar value of zero for false and one for true.
This RU has only one operation, with op_code 0. In addition to the common header (see Zk_rollup_operation_repr), this operation has as payload one scalar representing a boolean value.
The transition function f for this rollup is:
f : operation -> state -> state
f (Op b) s = if b = s then not s else sThat is, the state bool is flipped only if the operation's payload is equal to the current state.
The operation can be used publicly or in a private batch. The circuits that describe the RU are:
"op": for a single public operation."batch-"[N]: for a batch of N private operations. N is determined by the batch_size parameter to the Operator functor."fee": the trivial fees circuit, since this RU has no concept of fees.NB: the "op" circuit does not add any constraints over the operation's exit_validity other than it being in {0, 1}. This means that the dummy rollup can be used to test deposits/withdrawals, but the rollup will not perform any monetary bookkeeping.
Helper types and modules
Empty types to represent bounds
Modules to manipulate bounded integers, both as OCaml values and in circuit representation.
Types used for the Dummy Rollup circuits. This module is split into:
Plompiler circuits for the dummy rollup