Skip to content

Tracking issue for deferred evaluation integration #101

Open

Description

@guybedford

When we rebase to the spec for deferred evaluation, the ESM integration should be updated to conform to the late execution semantics.

There are two aspects to the integration here:

  1. WebAssembly itself can be imported as a deferred namespace (import defer * as ns from './mod.wasm'). This was already designed for previously when we switched to synchronous instantiation, so gets supported naturally.
  2. When WebAssembly imports from JavaScript or other WebAssembly that supports deferred evaluation, whether WebAssembly itself would want to be able to defer evaluation.

While (1) we get "for free", (2) would require some design work.

In particular, WebAssembly would need a way to (a) define an import phase, and (b) obtain a JS module namespace object import. A proposal for this is outlined in #119.

Activity

  1. nicolo-ribaudo commented on Feb 13, 2025

    @nicolo-ribaudo
    Collaborator

    Is there anything we actually need to do?

  2. guybedford commented on Feb 13, 2025

    @guybedford
    CollaboratorAuthor

    Nothing right now, mainly I just wanted a tracking issue to note that this is planned for when the specification is ready to be used.

    I suppose in theory we could have a PR already up ready for the rebase, but there's no rush on that.

  3. guybedford commented on Jul 11, 2025

    @guybedford
    CollaboratorAuthor

    Following up on this one again - @nicolo-ribaudo is there anything we still need to get here, or do we get this integration naturally in the current spec model?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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