Skip to content

WASM: [Host_funcs.lookup] per revision of the PVM

Thomas Letan requested to merge lthms@refine-per-revision-host-funcs into master

Context

Before this patch, only the host funcs registry is specialized for
each WASM PVM revision. The [lookup] function is not.

This is actually bad, because during the linking phase, the [lookup]
function is used to “translate” the host function global name to their
implementation name.

Modifying this function to unconditionally add a new lookup would
therefore change the behavior of the WASM PVM: in a revision where the
new host function is missing, it will eventually fails, but not at the
same tick.

This patches fixes this issue, as a preliminary step towards adding a
new host function to the WASM PVM.

Next MR: !8074 (merged)

Manually testing the MR

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

Merge request reports

Loading