Crate cton_wasm [−] [src]
Performs the translation from a wasm module in binary format to the in-memory representation
of the Cretonne IL. More particularly, it translates the code of all the functions bodies and
interacts with an environment implementing the
ModuleEnvironment
trait to deal with tables, globals and linear memory.
The crate provides a DummyEnvironment
struct that will allow to translate the code of the
functions but will fail at execution.
The main function of this module is translate_module
.
Structs
DummyEnvironment |
This |
FuncTranslator |
WebAssembly to Cretonne IL function translator. |
Global |
WebAssembly global. |
Memory |
WebAssembly linear memory. |
Table |
WebAssembly table. |
Enums
GlobalInit |
Globals are initialized via the four |
GlobalValue |
The value of a WebAssembly global variable. |
Traits
FuncEnvironment |
Environment affecting the translation of a single WebAssembly function. |
ModuleEnvironment |
An object satisfying the |
Functions
translate_module |
Translate a sequence of bytes forming a valid Wasm binary into a list of valid Cretonne IL
|
Type Definitions
FunctionIndex |
Index of a function (imported or defined) inside the WebAssembly module. |
GlobalIndex |
Index of a global variable (imported or defined) inside the WebAssembly module. |
MemoryIndex |
Index of a linear memory (imported or defined) inside the WebAssembly module. |
SignatureIndex |
Index of a signature (imported or defined) inside the WebAssembly module. |
TableIndex |
Index of a table (imported or defined) inside the WebAssembly module. |