Bob van Luijt
Bob van Luijt

Reputation: 7588

Understanding the Wasm (WebAssembly) prototype

In Chrome, the Wasm prototype has four functions:
1) instantiateModule
2) instantiateModuleFromAsm
3) verifyFunction
4) verifyModule

Where can I find the appropriate documentation on what they do and how I should call them?

PS:
I have been able to get something from the tests here: https://github.com/WebAssembly/v8-native-prototype/blob/master/test/mjsunit/wasm/asm-wasm.js

PPS:
Also asked here: https://github.com/WebAssembly/v8-native-prototype/issues/111

Upvotes: 0

Views: 587

Answers (1)

JF Bastien
JF Bastien

Reputation: 6843

As noted on the v8-native-prototype's home page, that repo is obsolete as development now happens directly in V8. Chrome canary uses a different API from the old one in that repo.

The precise web API is still being developed in the design repo, you can see a precise description in JS.md. It might change some more in the future.

March 2017 update: the MVP API has now reached consensus and will not be broken in the future. The API from the original question has been changed substantially since then! New APIs are likely to be added post-MVP.

If you want to see the details from V8 you can look at the source code for wasm as well as its cctest, unittest, and mjsunit tests.

Upvotes: 1

Related Questions