InlinerHeuristics

dotty.tools.backend.jvm.opt.InlinerHeuristics
See theInlinerHeuristics companion object
class InlinerHeuristics(ppa: PostProcessorFrontendAccess, backendUtils: BackendUtils, byteCodeRepository: BCodeRepository, callGraph: CallGraph, ts: CoreBTypes)(using x$6: Context)

Attributes

Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def canInlineFromSource(sourceFilePath: Option[String], calleeDeclarationClass: InternalName): Boolean

Returns the inline request for a callsite if the callsite should be inlined according to the current heuristics (-Yopt-inline-heuristics).

Returns the inline request for a callsite if the callsite should be inlined according to the current heuristics (-Yopt-inline-heuristics).

Attributes

Returns

None if this callsite should not be inlined according to the active heuristic Some(Left) if the callsite should be inlined according to the heuristic, but cannot be inlined according to an early, incomplete check (see earlyCanInlineCheck) Some(Right) if the callsite should be inlined (it's still possible that the callsite cannot be inlined in the end, for example if it contains instructions that would cause an IllegalAccessError in the new class; this is checked in the inliner)

Select callsites from the call graph that should be inlined, grouped by the containing method. Cyclic inlining requests are allowed, the inliner will eliminate requests to break cycles.

Select callsites from the call graph that should be inlined, grouped by the containing method. Cyclic inlining requests are allowed, the inliner will eliminate requests to break cycles.

Attributes

Concrete fields

val maxSize: Int
val smallSize: Int