Skip to content

Wasm execution is very slow compared to wazero. #1036

@dzbarsky

Description

@dzbarsky

Bazel is using Chicory to execute wasm, and I noticed that a workload that Rust can complete in 5-10ms takes around 20ms on wazero (and 80ms of loading/compilation time) but multiple seconds on Chicory. For comparison, Python can complete the same work in around 150-200ms, so this is 20-30x slower. This was using the interpreter, but even when using the Chicory AOT compiler, the result is still 2x slower than Python.

bazelbuild/bazel#26975 (comment) has more details on the setup/investigation along with a link to a standalone repo with the Rust source code and the compiled wasm

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions