Class AfterThreadsSafePoints

java.lang.Object
org.ek9lang.compiler.phase9.AfterThreadsSafePoints
All Implemented Interfaces:
Function<List<IRInstr>, List<IRInstr>>, UnaryOperator<List<IRInstr>>

public final class AfterThreadsSafePoints extends Object implements UnaryOperator<List<IRInstr>>
The SAFE_POINT after_threads of one instruction list (EK9_NATIVE_CYCLE_COLLECTOR_DESIGN.md ยง13.11, T10): after the exit of the innermost scope in this list that holds a call which starts runtime threads and finishes only once they have all stopped (StartsAndStopsRuntimeThreads) - an async pipeline's statement scope, the scope of a server's accept or serve. By that exit every worker has finished and the scope has dropped its own values, so a collection there sees all the statement made. A call with no scope open in its list gets the safe point right after it, as does one whose scope does not close in the same list. Used by SafePointPlacement through IRRewriter.rewriteLists; returns the same list when there is nothing to place. Stateless: hold one.