allocate

fun allocate(    code: A_RawFunction,     offsetAfterInitialTryPrimitive: Int,     theInstructions: List<L2SimpleInstruction>,     contingentValues: A_Set,     nextOptimizationLevel: OptimizationLevel): L2SimpleChunk

Allocate and set up a new L2SimpleChunk with the given information. If code is non-null, set it up to use the new chunk for subsequent invocations.

Return

The new level two chunk.

Parameters

code

The code for which to use the new level two chunk, or null for the initial unoptimized chunk.

offsetAfterInitialTryPrimitive

The offset into my instructions at which to begin if this chunk's code was primitive and that primitive has already been attempted and failed.

theInstructions

A List of L2SimpleInstructions that can be executed in place of the level one nybblecodes.

contingentValues

A Set of methods on which the level two chunk depends.