internal void FixupBranch(InstructionList instructions, int branchIndex) { Debug.Assert(_targetIndex != UnknownIndex); instructions.FixupBranch(branchIndex, _targetIndex - branchIndex); }
public DebugView(InstructionList list) { _list = list; }
public void EmitLoadLocalBoxed(int index) { this.Emit(InstructionList.LoadLocalBoxed(index)); }
public void EmitStoreLocalBoxed(int index) { this.Emit(InstructionList.StoreLocalBoxed(index)); }
internal void EmitInitializeParameter(int index) { this.Emit(InstructionList.Parameter(index)); }
public void EmitLoad(object value, Type type) { unsafe { if (value != null) { if (type == null || type.IsValueType) { if (!(value is bool)) { if (value is int) { int num = (int)value; if (num >= -100 && num <= 100) { if (InstructionList._ints == null) { InstructionList._ints = new Instruction[201]; } num = num - -100; InstructionList instructionList = this; Instruction instruction = InstructionList._ints[num]; Instruction instruction1 = instruction; if (instruction == null) { LoadObjectInstruction loadObjectInstruction = new LoadObjectInstruction(value); Instruction instruction2 = loadObjectInstruction; InstructionList._ints[num] = loadObjectInstruction; instruction1 = instruction2; } instructionList.Emit(instruction1); return; } } } else { this.EmitLoad((bool)value); return; } } if (this._objects == null) { this._objects = new List <object>(); if (InstructionList._loadObjectCached == null) { InstructionList._loadObjectCached = new Instruction[0x100]; } } if (this._objects.Count >= (int)InstructionList._loadObjectCached.Length) { this.Emit(new LoadObjectInstruction(value)); return; } else { int count = (int)this._objects.Count; this._objects.Add(value); InstructionList instructionList1 = this; Instruction instruction3 = InstructionList._loadObjectCached[count]; Instruction instruction4 = instruction3; if (instruction3 == null) { LoadCachedObjectInstruction loadCachedObjectInstruction = new LoadCachedObjectInstruction(count); Instruction instruction5 = loadCachedObjectInstruction; InstructionList._loadObjectCached[count] = loadCachedObjectInstruction; instruction4 = instruction5; } instructionList1.Emit(instruction4); return; } } else { InstructionList instructionList2 = this; Instruction instruction6 = InstructionList._null; Instruction instruction7 = instruction6; if (instruction6 == null) { LoadObjectInstruction loadObjectInstruction1 = new LoadObjectInstruction(null); instruction7 = loadObjectInstruction1; InstructionList._null = loadObjectInstruction1; } instructionList2.Emit(instruction7); return; } } }
public void EmitDynamic(Type type, CallSiteBinder binder) { this.Emit(InstructionList.CreateDynamicInstruction(type, binder)); }
public void EmitAssignLocalBoxed(int index) { this.Emit(InstructionList.AssignLocalBoxed(index)); }
public Instruction BoxIfIndexMatches(int index) { return((index == _index) ? InstructionList.LoadLocalBoxed(index) : null); }
public Instruction BoxIfIndexMatches(int index) { return((index == _index) ? InstructionList.InitImmutableRefBox(index) : null); }
internal void FixupBranch(InstructionList instructions, int branchIndex) { instructions.FixupBranch(branchIndex, this._targetIndex - branchIndex); }