Scoru_wasm: Drop [Thunk], use chunked byte vector in [Gather_floppies]
Context
In order to reduce the overall complexity of the WASM PVM, we drop
[Thunk] in favor of the now usable [Tree_encoding_decoding] framework.
We update [Gather_floppies] accordingly. The resulting refactoring
gives a more functional flavor to the module. We also use this
opportunity to reuse the [Chunked_byte_vector] module from
[Lib_webassembly] to store the kernel.
This new implementation is likely not to produce larger proofs. This
is because the steps of the [Gather_floppies] were mostly using the
same fields.
The tests have been updated due to the difference of semantics between Thunk’s lazy_map
and Chunked_byte_vector
wrt. the notion of length
. The former was returning the number of chunks, the latter returns the size of the chunked string.
The changes need to be reviewed with this difference in mind.
Manually testing the MR
dune exec \
src/proto_alpha/lib_protocol/test/integration/main.exe \
-- test "^sc rollup wasm$"
Checklist
-
Document the interface of any function added or modified (see the coding guidelines) -
Document any change to the user interface, including configuration parameters (see node configuration) -
Provide automatic testing (see the testing guide). -
For new features and bug fixes, add an item in the appropriate changelog ( docs/protocols/alpha.rst
for the protocol and the environment,CHANGES.rst
at the root of the repository for everything else). -
Select suitable reviewers using the Reviewers
field below. -
Select as Assignee
the next person who should take action on that MR
Edited by Thomas Letan