Documentation ¶
Index ¶
- Variables
- func CalleeEffects(init *ir.Nodes, callee ir.Node)
- func CanInline(fn *ir.Func, profile *pgoir.Profile)
- func CanInlineFuncs(funcs []*ir.Func, profile *pgoir.Profile)
- func GarbageCollectUnreferencedHiddenClosures()
- func HasPgoHotInline(fn *ir.Func) bool
- func InlineImpossible(fn *ir.Func) string
- func IsBigFunc(fn *ir.Func) bool
- func IsPgoHotFunc(fn *ir.Func, profile *pgoir.Profile) bool
- func PGOInlinePrologue(p *pgoir.Profile)
- func PostProcessCallSites(profile *pgoir.Profile)
- func TryInlineCall(callerfn *ir.Func, call *ir.CallExpr, bigCaller bool, profile *pgoir.Profile) *ir.InlinedCallExpr
Constants ¶
This section is empty.
Variables ¶
var InlineCall = func(callerfn *ir.Func, call *ir.CallExpr, fn *ir.Func, inlIndex int) *ir.InlinedCallExpr { base.Fatalf("inline.InlineCall not overridden") panic("unreachable") }
InlineCall allows the inliner implementation to be overridden. If it returns nil, the function will not be inlined.
var SSADumpInline = func(*ir.Func) {}
SSADumpInline gives the SSA back end a chance to dump the function when producing output for debugging the compiler itself.
Functions ¶
func CalleeEffects ¶ added in go1.18
CalleeEffects appends any side effects from evaluating callee to init.
func CanInline ¶
CanInline determines whether fn is inlineable. If so, CanInline saves copies of fn.Body and fn.Dcl in fn.Inl. fn and fn.Body will already have been typechecked.
func CanInlineFuncs ¶ added in go1.22.0
CanInlineFuncs computes whether a batch of functions are inlinable.
func GarbageCollectUnreferencedHiddenClosures ¶ added in go1.22.0
func GarbageCollectUnreferencedHiddenClosures()
GarbageCollectUnreferencedHiddenClosures makes a pass over all the top-level (non-hidden-closure) functions looking for nested closure functions that are reachable, then sweeps through the Target.Decls list and marks any non-reachable hidden closure function as dead. See issues #59404 and #59638 for more context.
func HasPgoHotInline ¶ added in go1.23.0
func InlineImpossible ¶ added in go1.21.0
InlineImpossible returns a non-empty reason string if fn is impossible to inline regardless of cost or contents.
func IsBigFunc ¶ added in go1.22.0
IsBigFunc reports whether fn is a "big" function.
Note: The criteria for "big" is heuristic and subject to change.
func PGOInlinePrologue ¶ added in go1.22.0
PGOInlinePrologue records the hot callsites from ir-graph.
func PostProcessCallSites ¶ added in go1.22.0
Types ¶
This section is empty.
Directories ¶
Path | Synopsis |
---|---|
Package interleaved implements the interleaved devirtualization and inlining pass.
|
Package interleaved implements the interleaved devirtualization and inlining pass. |