Accessing WebAssembly reference-typed arrays from C++

This page summarizes the projects mentioned and recommended in the original post on news.ycombinator.com

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • emscripten

    Emscripten: An LLVM-to-WebAssembly Compiler

  • A proper solution for this problem will also help with the WebGPU API. Mapping a GPU resource returns a JS array view, which currently requires copying to and from the WASM heap (for instance see here in Emscripten's WebGPU shim: https://github.com/emscripten-core/emscripten/blob/37aa752eb...).

    Ideally the array view could either be mapped directly into the WASM heap, or at least would be accessible from the C/C++/Rust side with a special pointer type (maybe WASM should get address space segmetation like back in the 286 days lol).

  • multi-memory

    Multiple per-module memories for Wasm

  • There are stray references to the concept of multiple address spaces (or 'memories') in the wasm spec at present, and I recall at one point you may have always been passing 'memory #0' to your load/store opcodes. It looks like people are still working on that as the solution.

    https://github.com/WebAssembly/multi-memory

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts