Skip to content

Should we add our own wasmi_parse crate to replace wasmparser usage? #1514

Open
@Robbepop

Description

@Robbepop

As the title suggests this is currently an unanswered question.

This issue is about the idea to add a custom Wasm parsing crate to the Wasmi workspace: wasmi_parse
The wasmi_parse crate would replace today's Wasmi's wasmparser uage.

The main reason behind a custom wasmi_parse crate is that it seems that Wasmi's niche needs are somewhat unaligned with most other users of wasmparser. For example:

Advantages

  • More control over the features implemented in the Wasm parsing abtractions.
  • Wasm parsing could potentially be more specific to Wasmi's unique needs and thus improve performance.
  • The wasmparser crate deals with way more than what Wasmi needs, e.g. the component model and legacy features such as the legacy exception handling.

Downsides

  • The Wasmi team (me) has to maintain yet another major crate.
  • Wasmi no longer profits from upstream improvements so easily.
  • It is no longer as easy to help upstream wasmparser with wasmi_parse being its own fork.
  • We once had wasmparser-nostd and it was a mess to maintain it, however, unlike wasmi_parse, wasmparser-nostd was never meant to evolve away from wasmparser and be specific to Wasmi's needs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions