Documentation
¶
Index ¶
Constants ¶
View Source
const ( MagicNumber = uint32(0x6d736100) Version = uint32(1) )
View Source
const ( SectionUnknown = iota SectionType SectionImport SectionFunction SectionTable SectionMemory SectionGlobal SectionExport SectionStart SectionElement SectionCode SectionData NumSections )
View Source
const ( ExternalKindFunction = ExternalKind(iota) ExternalKindTable ExternalKindMemory ExternalKindGlobal )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataBuffer ¶ added in v0.3.0
type ExternalKind ¶
type ExternalKind byte
func (ExternalKind) String ¶
func (kind ExternalKind) String() (s string)
type ImportFunc ¶ added in v0.3.1
type M ¶ added in v0.3.1
type M struct {
Sigs []abi.Sig
FuncSigs []uint32
ImportFuncs []ImportFunc
TableLimitValues ResizableLimits
MemoryLimitValues ResizableLimits
Globals []Global
NumImportGlobals int
EntryIndex uint32
EntryDefined bool
StartIndex uint32
StartDefined bool
TableFuncs []uint32
Text TextBuffer
RODataAddr int32
ROData DataBuffer
TrapLinks [trap.NumTraps]links.L
FuncLinks []links.FuncL
Mapper Mapper
Regs regalloc.Allocator
Data DataBuffer
MemoryOffset int
}
type Mapper ¶ added in v0.3.1
type Mapper interface {
InitModule(numImportFuncs, numOtherFuncs int)
PutImportFuncAddr(meta.TextAddr)
PutFuncAddr(meta.TextAddr)
PutCallSite(returnAddr meta.TextAddr, stackOffset int32)
PutInsnAddr(meta.TextAddr)
}
Mapper accepts information about positions of (WebAssembly) functions, function calls and instructions within the text (machine code) section.
type ResizableLimits ¶
type TextBuffer ¶ added in v0.3.0
Click to show internal directories.
Click to hide internal directories.