go/src/cmd/link/internal/ld/stackcheck.go

type stackCheck

type stackCheckEdge

const stackCheckCycle

const stackCheckIndirect

// doStackCheck walks the call tree to check that there is always
// enough stack space for call frames, especially for a chain of
// nosplit functions.
//
// It walks all functions to accumulate the number of bytes they can
// grow the stack by without a split check and checks this against the
// limit.
func (ctxt *Link) doStackCheck() {}

func newStackCheck(ctxt *Link, graph bool) *stackCheck {}

func (sc *stackCheck) symName(sym loader.Sym) string {}

// check returns the stack height of sym. It populates sc.height and
// sc.graph for sym and every function in its call tree.
func (sc *stackCheck) check(sym loader.Sym) int {}

// computeHeight returns the stack height of sym. If graph is true, it
// also returns the out-edges of sym.
//
// Caching is applied to this in check. Call check instead of calling
// this directly.
func (sc *stackCheck) computeHeight(sym loader.Sym, graph bool) (int, []stackCheckEdge) {}

func (sc *stackCheck) findRoots() []loader.Sym {}

type stackCheckChain

func (sc *stackCheck) report(sym loader.Sym, depth int, chain *[]stackCheckChain) {}