Documentation
¶
Index ¶
- func Runtime() *_Runtime
- type Instance
- func (self Instance) AddrAppToNative(app_offset uint64) *uint8
- func (self Instance) AddrNativeToApp(native_ptr *uint8) uint64
- func (self *Instance) CallFunc(funcName string, argc uint32, args []uint32) error
- func (self *Instance) CallFuncV(funcName string, num_results uint32, results []interface{}, ...) error
- func (self *Instance) Destroy()
- func (self Instance) DumpCallStack()
- func (self Instance) DumpMemoryConsumption()
- func (self Instance) GetAppAddrRange(app_offset uint64) (bool, uint64, uint64)
- func (self *Instance) GetException() string
- func (self Instance) GetNativeAddrRange(native_ptr *uint8) (bool, *uint8, *uint8)
- func (self Instance) ModuleFree(offset uint64)
- func (self Instance) ModuleMalloc(size uint64) (uint64, *uint8)
- func (self Instance) ValidateAppAddr(app_offset uint64, size uint64) bool
- func (self Instance) ValidateNativeAddr(native_ptr *uint8, size uint64) bool
- func (self Instance) ValidateStrAddr(app_str_offset uint64) bool
- type LogLevel
- type Module
- func (self *Module) Destroy()
- func (self *Module) SetWasiAddrPool(addrPool [][]byte)
- func (self *Module) SetWasiArgs(dirList [][]byte, mapDirList [][]byte, env [][]byte, argv [][]byte)
- func (self *Module) SetWasiArgsEx(dirList [][]byte, mapDirList [][]byte, env [][]byte, argv [][]byte, ...)
- func (self *Module) SetWasiNsLookupPool(nsLookupPool [][]byte)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Instance ¶
type Instance struct {
// contains filtered or unexported fields
}
func NewInstance ¶
Create instance from the module
func (Instance) AddrAppToNative ¶
func (Instance) AddrNativeToApp ¶
func (*Instance) CallFunc ¶
Call the wasm function with argument in the uint32 array, and store
the return values back into the array
func (*Instance) CallFuncV ¶
func (self *Instance) CallFuncV(funcName string, num_results uint32, results []interface{}, args ...interface{}) error
Call the wasm function with variant arguments, and store the return
values back into the results array
func (Instance) DumpCallStack ¶
func (self Instance) DumpCallStack()
func (Instance) DumpMemoryConsumption ¶
func (self Instance) DumpMemoryConsumption()
func (Instance) GetAppAddrRange ¶
func (*Instance) GetException ¶
Get exception info of the instance
func (Instance) GetNativeAddrRange ¶
func (Instance) ModuleFree ¶
Free memory to the heap of the instance
func (Instance) ModuleMalloc ¶
Allocate memory from the heap of the instance
func (Instance) ValidateAppAddr ¶
func (Instance) ValidateNativeAddr ¶
func (Instance) ValidateStrAddr ¶
type Module ¶
type Module struct {
// contains filtered or unexported fields
}
func (*Module) SetWasiAddrPool ¶
Set module's wasi network address pool
func (*Module) SetWasiArgs ¶
Set module's wasi arguments
func (*Module) SetWasiArgsEx ¶
func (self *Module) SetWasiArgsEx(dirList [][]byte, mapDirList [][]byte, env [][]byte, argv [][]byte, stdinfd int, stdoutfd int, stderrfd int)
Set module's wasi arguments
func (*Module) SetWasiNsLookupPool ¶
Set module's wasi domain lookup pool
Click to show internal directories.
Click to hide internal directories.