• Home
  • Install
  • Cosmos Website
  • Articles
  • Cosmos
  • X#
  • IL2CPU
Show / Hide Table of Contents
  • Cosmos.IL2CPU
    • _ExceptionRegionInfo
    • _FieldInfo
    • CompilerHelpers
    • CosmosAssembler
    • ExceptionHelper
    • ExceptionHelperRefs
    • GCImplementationRefs
    • ICompilerEngineSettings
    • Il2cpuMethodInfo
    • Il2cpuMethodInfo.TypeEnum
    • ILOp
    • ILOpCode
    • ILOpCode.Code
    • ILReader
    • KernelPanics
    • MethodBaseComparer
    • OpCodeAttribute
    • PlugInfo
    • Program
    • ScannerQueueItem
    • SZArrayImpl<T>
    • VTablesImplRefs
  • Cosmos.IL2CPU.Extensions
    • FieldExtensions
    • TypeExtensions
  • Cosmos.IL2CPU.ILOpCodes
    • Box<T>
    • NullRef
    • OpBranch
    • OpDouble
    • OpField
    • OpInt
    • OpInt64
    • OpMethod
    • OpNone
    • OpSig
    • OpSingle
    • OpString
    • OpSwitch
    • OpToken
    • OpType
    • OpVar
  • Cosmos.IL2CPU.MethodAnalysis
    • ILGroup
    • ILMethod
  • Cosmos.IL2CPU.X86.IL
    • Add
    • Add_Ovf
    • Add_Ovf_Un
    • And
    • Arglist
    • Box
    • Br
    • Branch
    • Break
    • Call
    • Calli
    • Callvirt
    • Castclass
    • Ceq
    • Cgt
    • Cgt_Un
    • Ckfinite
    • Clt
    • Clt_Un
    • Constrained
    • Conv_I
    • Conv_I1
    • Conv_I2
    • Conv_I4
    • Conv_I8
    • Conv_Ovf_I
    • Conv_Ovf_I_Un
    • Conv_Ovf_I1
    • Conv_Ovf_I1_Un
    • Conv_Ovf_I2
    • Conv_Ovf_I2_Un
    • Conv_Ovf_I4
    • Conv_Ovf_I4_Un
    • Conv_Ovf_I8
    • Conv_Ovf_I8_Un
    • Conv_Ovf_U
    • Conv_Ovf_U_Un
    • Conv_Ovf_U1
    • Conv_Ovf_U1_Un
    • Conv_Ovf_U2
    • Conv_Ovf_U2_Un
    • Conv_Ovf_U4
    • Conv_Ovf_U4_Un
    • Conv_Ovf_U8
    • Conv_Ovf_U8_Un
    • Conv_R_Un
    • Conv_R4
    • Conv_R8
    • Conv_U
    • Conv_U1
    • Conv_U2
    • Conv_U4
    • Conv_U8
    • Cpblk
    • Cpobj
    • Div
    • Div_Un
    • Dup
    • Endfilter
    • Endfinally
    • Initblk
    • Initobj
    • Isinst
    • Jmp
    • Ldarg
    • Ldarga
    • Ldc_I4
    • Ldc_I8
    • Ldc_R4
    • Ldc_R8
    • Ldelem
    • Ldelem_I
    • Ldelem_I1
    • Ldelem_I2
    • Ldelem_I4
    • Ldelem_I8
    • Ldelem_R4
    • Ldelem_R8
    • Ldelem_Ref
    • Ldelem_U1
    • Ldelem_U2
    • Ldelem_U4
    • Ldelema
    • Ldfld
    • Ldflda
    • Ldftn
    • Ldind
    • Ldlen
    • Ldloc
    • Ldloca
    • Ldnull
    • Ldobj
    • Ldsfld
    • Ldsflda
    • LdStr
    • Ldtoken
    • Ldvirtftn
    • Leave
    • Localloc
    • Mkrefany
    • Mul
    • Mul_Ovf
    • Mul_Ovf_Un
    • Neg
    • Newarr
    • Newobj
    • Nop
    • Not
    • Or
    • Pop
    • Readonly
    • Refanytype
    • Refanyval
    • Rem
    • Rem_Un
    • Ret
    • Rethrow
    • Shl
    • Shr
    • Shr_Un
    • Sizeof
    • Starg
    • Stelem
    • Stelem_I
    • Stelem_I1
    • Stelem_I2
    • Stelem_I4
    • Stelem_I8
    • Stelem_R4
    • Stelem_R8
    • Stelem_Ref
    • Stfld
    • Stind
    • Stloc
    • Stobj
    • Stsfld
    • Sub
    • Sub_Ovf
    • Sub_Ovf_Un
    • Switch
    • Throw
    • Unaligned
    • Unbox
    • Unbox_Any
    • Volatile
    • Xor
  • IL2CPU.API
    • InlineAttribute
    • LabelName
    • ObjectPointerAccess
    • ObjectUtils
    • ObjectUtils.InstanceTypeEnum
    • TargetPlatform
  • IL2CPU.API.Attribs
    • AsmLabel
    • AsmMarker
    • AsmMarker.Type
    • BootEntry
    • DebugStub
    • FieldAccess
    • FieldType
    • ForceIncludeAttribute
    • ManifestResourceStreamAttribute
    • Plug
    • PlugAssembly
    • PlugAssembly.AssemblyType
    • PlugField
    • PlugMethod

Class ILOpCode

Inheritance
System.Object
ILOpCode
OpBranch
OpDouble
OpField
OpInt
OpInt64
OpMethod
OpNone
OpSig
OpSingle
OpString
OpSwitch
OpToken
OpType
OpVar
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Cosmos.IL2CPU
Assembly: Cosmos.IL2CPU.dll
Syntax
public abstract class ILOpCode

Constructors

| Improve this Doc View Source

ILOpCode(ILOpCode.Code, Int32, Int32, _ExceptionRegionInfo)

Declaration
protected ILOpCode(ILOpCode.Code aOpCode, int aPos, int aNextPos, _ExceptionRegionInfo aCurrentExceptionRegion)
Parameters
Type Name Description
ILOpCode.Code aOpCode
System.Int32 aPos
System.Int32 aNextPos
_ExceptionRegionInfo aCurrentExceptionRegion

Fields

| Improve this Doc View Source

CurrentExceptionRegion

Declaration
public readonly _ExceptionRegionInfo CurrentExceptionRegion
Field Value
Type Description
_ExceptionRegionInfo
| Improve this Doc View Source

NextPosition

Declaration
public readonly int NextPosition
Field Value
Type Description
System.Int32
| Improve this Doc View Source

OpCode

Declaration
public readonly ILOpCode.Code OpCode
Field Value
Type Description
ILOpCode.Code
| Improve this Doc View Source

Position

Declaration
public readonly int Position
Field Value
Type Description
System.Int32
| Improve this Doc View Source

StackOffsetBeforeExecution

Declaration
public uint? StackOffsetBeforeExecution
Field Value
Type Description
System.Nullable<System.UInt32>

Properties

| Improve this Doc View Source

StackPopTypes

Declaration
public Type[] StackPopTypes { get; set; }
Property Value
Type Description
System.Type[]
| Improve this Doc View Source

StackPushTypes

Declaration
public Type[] StackPushTypes { get; set; }
Property Value
Type Description
System.Type[]

Methods

| Improve this Doc View Source

DoInitStackAnalysis(MethodBase)

Declaration
protected virtual void DoInitStackAnalysis(MethodBase aMethod)
Parameters
Type Name Description
System.Reflection.MethodBase aMethod
| Improve this Doc View Source

DoInterpretStackTypes()

Based on updated StackPopTypes, try to update

Declaration
public abstract void DoInterpretStackTypes()
| Improve this Doc View Source

DoStackAnalysis(Stack<Type>, ref UInt32)

Declaration
public void DoStackAnalysis(Stack<Type> aStack, ref uint aStackOffset)
Parameters
Type Name Description
System.Collections.Generic.Stack<System.Type> aStack
System.UInt32 aStackOffset
| Improve this Doc View Source

GetNextOpCodePositions()

Return the position of all instructions which can be reached from this one and if they should be part of the current group or not

Declaration
public virtual List<(bool newGroup, int Position)> GetNextOpCodePositions()
Returns
Type Description
System.Collections.Generic.List<System.ValueTuple<System.Boolean, System.Int32>>
| Improve this Doc View Source

GetNumberOfStackPops(MethodBase)

Returns the number of items popped from the stack. This is the logical stack, not physical items. So a 100byte struct is 1 pop, even though it might be multiple 32-bit or 64-bit words on the stack.

Declaration
public abstract int GetNumberOfStackPops(MethodBase aMethod)
Parameters
Type Name Description
System.Reflection.MethodBase aMethod
Returns
Type Description
System.Int32
| Improve this Doc View Source

GetNumberOfStackPushes(MethodBase)

Returns the number of items pushed to the stack. This is the logical stack, not physical items. So a 100byte struct is 1 pop, even though it might be multiple 32-bit or 64-bit words on the stack.

Declaration
public abstract int GetNumberOfStackPushes(MethodBase aMethod)
Parameters
Type Name Description
System.Reflection.MethodBase aMethod
Returns
Type Description
System.Int32
  • Improve this Doc
  • View Source
☀
☾
In This Article
Back to top
☀
☾