Documentation ¶
Index ¶
- Constants
- type Linker
- func (Linker) UpdateCalls(text []byte, l *link.L)
- func (Linker) UpdateFarBranches(text []byte, l *link.L)
- func (Linker) UpdateNearBranch(text []byte, site int32)
- func (Linker) UpdateNearBranches(text []byte, sites []int32)
- func (Linker) UpdateNearLoad(text []byte, addr int32)
- func (Linker) UpdateStackCheck(text []byte, addr int32, depth int)
- type MacroAssembler
- func (MacroAssembler) AddToStackPtrUpper32(f *gen.Func, r reg.R)
- func (MacroAssembler) AlignData(*gen.Prog, int)
- func (MacroAssembler) AlignFunc(*gen.Prog)
- func (MacroAssembler) Binary(f *gen.Func, props uint16, a, b operand.O) (result operand.O)
- func (MacroAssembler) Branch(p *gen.Prog, addr int32)
- func (MacroAssembler) BranchIf(f *gen.Func, x operand.O, labelAddr int32) (sites []int32)
- func (MacroAssembler) BranchIfOutOfBounds(p *gen.Prog, indexReg reg.R, upperBound, addr int32)
- func (MacroAssembler) BranchIfOutOfBoundsStub(p *gen.Prog, indexReg reg.R, upperBound int32) int32
- func (MacroAssembler) BranchIfStub(f *gen.Func, x operand.O, yes, near bool) (sites []int32)
- func (MacroAssembler) BranchIndirect(f *gen.Func, addr reg.R)
- func (MacroAssembler) BranchStub(p *gen.Prog) int32
- func (MacroAssembler) BranchSuspend(f *gen.Func, addr int32)
- func (MacroAssembler) Breakpoint(f *gen.Func)
- func (MacroAssembler) Call(p *gen.Prog, addr int32)
- func (MacroAssembler) CallImportVector(p *gen.Prog, index int, variadic bool, argCount, sigIndex int)
- func (MacroAssembler) CallIndirect(f *gen.Func, sigIndex int32, r reg.R)
- func (MacroAssembler) CallMissing(p *gen.Prog, atomic bool)
- func (MacroAssembler) ClearIntResultReg(p *gen.Prog)
- func (MacroAssembler) Convert(f *gen.Func, props uint16, resultType wa.Type, source operand.O) operand.O
- func (MacroAssembler) CurrentMemory(f *gen.Func) int32
- func (MacroAssembler) DropStackValues(p *gen.Prog, n int)
- func (MacroAssembler) Enter(p *gen.Prog)
- func (MacroAssembler) GrowMemory(f *gen.Func) int32
- func (MacroAssembler) Load(f *gen.Func, props uint16, index operand.O, resultType wa.Type, ...) operand.O
- func (MacroAssembler) LoadGlobal(p *gen.Prog, t wa.Type, target reg.R, offset int32) (zeroExt bool)
- func (MacroAssembler) LoadIntStubNear(f *gen.Func, indexType wa.Type, r reg.R) (addr int32)
- func (MacroAssembler) LoadStack(p *gen.Prog, t wa.Type, target reg.R, offset int32)
- func (MacroAssembler) Move(f *gen.Func, target reg.R, x operand.O) (zeroExt bool)
- func (MacroAssembler) MoveReg(p *gen.Prog, t wa.Type, target, source reg.R)
- func (MacroAssembler) PadUntil(p *gen.Prog, addr int32)
- func (MacroAssembler) PushCond(p *gen.Prog, cond condition.C)
- func (MacroAssembler) PushImm(p *gen.Prog, value int64)
- func (MacroAssembler) PushReg(p *gen.Prog, t wa.Type, r reg.R)
- func (MacroAssembler) PushZeros(p *gen.Prog, n int)
- func (MacroAssembler) Resume(p *gen.Prog)
- func (MacroAssembler) Return(p *gen.Prog, numStackValues int)
- func (MacroAssembler) Select(f *gen.Func, a, b, condOperand operand.O) operand.O
- func (MacroAssembler) SetBool(p *gen.Prog, target reg.R, cond condition.C)
- func (MacroAssembler) SetupStackFrame(f *gen.Func) (stackCheckAddr int32)
- func (MacroAssembler) Store(f *gen.Func, props uint16, index, x operand.O, align, offset uint32)
- func (MacroAssembler) StoreGlobal(f *gen.Func, offset int32, x operand.O)
- func (MacroAssembler) StoreStack(f *gen.Func, offset int32, x operand.O)
- func (MacroAssembler) StoreStackImm(p *gen.Prog, t wa.Type, offset int32, value int64)
- func (MacroAssembler) StoreStackReg(p *gen.Prog, t wa.Type, offset int32, r reg.R)
- func (MacroAssembler) SuspendSaveInt(f *gen.Func, saveReg reg.R)
- func (MacroAssembler) Trap(f *gen.Func, id trap.ID)
- func (MacroAssembler) TrapHandler(p *gen.Prog, id trap.ID)
- func (MacroAssembler) TrapHandlerRewindCallStackExhausted(p *gen.Prog)
- func (MacroAssembler) TrapHandlerRewindSuspended(p *gen.Prog, index int)
- func (MacroAssembler) TrapHandlerTruncOverflow(p *gen.Prog, trapIndex int)
- func (MacroAssembler) Unary(f *gen.Func, props uint16, x operand.O) operand.O
- func (MacroAssembler) ZeroExtendResultReg(p *gen.Prog)
Constants ¶
View Source
const ( NopWord = 0xd503201f PadWord = 0xd4200000 // BRK #0 instruction )
View Source
const ( RegResult = reg.Result RegScratch = reg.ScratchISA RegImportVariadic = reg.R(2) // <- AllocIntFirst RegMemoryBase = reg.R(26) RegTextBase = reg.R(27) RegStackLimit4 = reg.R(28) RegFakeSP = in.RegFakeSP RegLink = reg.R(30) RegScratch2 = reg.R(30) RegRealSP = reg.R(31) RegZero = reg.R(31) RegDiscard = reg.R(31) )
View Source
const (
MaxFuncSize = 4 * 1024 * 1024 // Conditional branch distance.
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Linker ¶
type Linker struct{}
func (Linker) UpdateNearBranch ¶
func (Linker) UpdateNearBranches ¶
func (Linker) UpdateNearLoad ¶
UpdateNearLoad overwrites an instruction with an ADR instruction.
type MacroAssembler ¶
type MacroAssembler struct{}
func (MacroAssembler) AddToStackPtrUpper32 ¶
func (MacroAssembler) AddToStackPtrUpper32(f *gen.Func, r reg.R)
func (MacroAssembler) AlignFunc ¶
func (MacroAssembler) AlignFunc(*gen.Prog)
func (MacroAssembler) BranchIfOutOfBounds ¶
func (MacroAssembler) BranchIfOutOfBoundsStub ¶ added in v0.12.3
func (MacroAssembler) BranchIfStub ¶
func (MacroAssembler) BranchIndirect ¶
func (MacroAssembler) BranchIndirect(f *gen.Func, addr reg.R)
func (MacroAssembler) BranchStub ¶ added in v0.12.3
func (MacroAssembler) BranchStub(p *gen.Prog) int32
func (MacroAssembler) BranchSuspend ¶ added in v0.25.0
func (MacroAssembler) BranchSuspend(f *gen.Func, addr int32)
func (MacroAssembler) Breakpoint ¶ added in v0.28.0
func (MacroAssembler) Breakpoint(f *gen.Func)
func (MacroAssembler) CallImportVector ¶ added in v0.21.0
func (MacroAssembler) CallIndirect ¶
func (MacroAssembler) CallMissing ¶
func (MacroAssembler) CallMissing(p *gen.Prog, atomic bool)
func (MacroAssembler) ClearIntResultReg ¶
func (MacroAssembler) ClearIntResultReg(p *gen.Prog)
func (MacroAssembler) CurrentMemory ¶ added in v0.13.0
func (MacroAssembler) CurrentMemory(f *gen.Func) int32
func (MacroAssembler) DropStackValues ¶
func (MacroAssembler) DropStackValues(p *gen.Prog, n int)
func (MacroAssembler) Enter ¶ added in v0.23.0
func (MacroAssembler) Enter(p *gen.Prog)
func (MacroAssembler) GrowMemory ¶
func (MacroAssembler) GrowMemory(f *gen.Func) int32
func (MacroAssembler) LoadGlobal ¶
func (MacroAssembler) LoadIntStubNear ¶
func (MacroAssembler) Resume ¶
func (MacroAssembler) Resume(p *gen.Prog)
func (MacroAssembler) SetupStackFrame ¶
func (MacroAssembler) SetupStackFrame(f *gen.Func) (stackCheckAddr int32)
func (MacroAssembler) StoreGlobal ¶
func (MacroAssembler) StoreStack ¶
func (MacroAssembler) StoreStackImm ¶
func (MacroAssembler) StoreStackReg ¶
func (MacroAssembler) SuspendSaveInt ¶ added in v0.25.0
func (MacroAssembler) SuspendSaveInt(f *gen.Func, saveReg reg.R)
func (MacroAssembler) TrapHandler ¶ added in v0.25.0
func (MacroAssembler) TrapHandler(p *gen.Prog, id trap.ID)
func (MacroAssembler) TrapHandlerRewindCallStackExhausted ¶ added in v0.25.0
func (MacroAssembler) TrapHandlerRewindCallStackExhausted(p *gen.Prog)
func (MacroAssembler) TrapHandlerRewindSuspended ¶ added in v0.25.0
func (MacroAssembler) TrapHandlerRewindSuspended(p *gen.Prog, index int)
func (MacroAssembler) TrapHandlerTruncOverflow ¶ added in v0.31.0
func (MacroAssembler) TrapHandlerTruncOverflow(p *gen.Prog, trapIndex int)
func (MacroAssembler) ZeroExtendResultReg ¶
func (MacroAssembler) ZeroExtendResultReg(p *gen.Prog)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.