JaCIL Framework API

JaCIL.Compiler.Instruction Namespace

The instruction abstraction layer. Provides a higher level interface to the structure of CLI programs.

Namespace hierarchy

Classes

Class Description
HandlerTable Standard implementation of the handler table. This implementation uses the ordinal of the instruction stream to calculate what stream objects are within handlers and protected blocks. Specifically, an instruction is within a handler or protected block is considered to be the same offset if the major is equal to the offset and the median is zero.
HandlerTableItem Represents an item in the handler table for a given method. This is an abstraction using the IInstructionStream interface to make compiler interaction with handlers more straightforward.
InstructionStream Standard implementation of the instruction stream.
InstructionStreamEnumerator Standard forward enumerator over an instruction stream.
InstructionStreamSet Standard implementation of the InstructionStreamSet
LocalVariable Represents a standard local variable.
LocalVariableTable Standard implementation of the local variable table mapping. This implementation maps the parameters to the first set of local variables corresponding to the parameters, then the next set based on locals, and any named ones past that.
Stack Standard stack state implementation
StackObject Represents an item of the simulated stack.

Interfaces

Interface Description
IHandlerTable Provides an abstraction on top of the Cecil exception handler framework to make it easier for JaCIL instructions to determine what handlers they lie in.
IInstructionStream Represents a stream of instructions. This interface provides a higher level interface to represent the instructions in a method body.
IInstructionStreamSet Represents a set of instruction streams.
ILocalVariableTable Represents the symbol table between locals in a CLI method and their JVM equivalent.
IStack Represents the stack state for a particular CLI instruction.

Structures

Structure Description
Ordinal Represents a ranking.

Enumerations

Enumeration Description
CilOps Represents the op codes for the Common Intermediate Language normalized to 32-bit values.
LocalType Represents the type of slots that can be allocated in a JVM local variable table.
StackArrayType Represents a particular operand stack state for the CLI code as it pertains to array types. These align well with the JVM array store/load instructions.
StackPointerType Represents a particular operand stack state for the CLI code as it pertains to managed pointers.
StackType Represents a particular operand stack state for the CLI code. This represents the bare minimum for JaCIL compiler analysis and is not complete for the full verification algorithm as specified by ECMA-335.
StackValueType Represents a particular operand stack state for the CLI code as it pertains to value types.