For AI agents: the complete documentation index is available at /tc39-atlas/en/llms.txt, the full documentation bundle is available at /tc39-atlas/en/llms-full.txt, and this page is available as Markdown at /tc39-atlas/en/proposals/year/2024/proposal-atomics-wait-async.md.
  • English
  • Atomics.waitAsync S4

    Proposal details
    Proposal overview

    This proposal introduces Atomics.waitAsync, an asynchronous version of Atomics.wait for environments where blocking is not allowed. It provides a way to wait on shared memory without blocking the agent, returning a promise-like result. The proposal is currently in early stages, with historical documents available but the main proposal text evolving.

    Note

    The README below comes from the upstream repository and may contain outdated stage or status metadata. Use the proposal details above as the current source of truth.

    Asynchronous atomic wait for ECMAScript

    A proposal for an "asynchronous atomic wait" for ECMAScript, primarily for use in agents that are not allowed to block.

    Champions: Shu-yu Guo (Google) and Lars T Hansen (Mozilla).

    Historical documents

    Warning: The following documents are no longer being updated and are of historical interest only.

    See PROPOSAL.md for the evolving proposal text, polyfill.js for a simple polyfill implementation, and example.html for some examples and test cases; this file uses the polyfill.