Class ThrowUnknownResolver
- Namespace
- Echo.Platforms.AsmResolver.Emulation
- Assembly
- Echo.Platforms.AsmResolver.dll
Provides an implementation of the IUnknownResolver that throws upon resolving an unknown value.
public class ThrowUnknownResolver : IUnknownResolver
- Inheritance
-
ThrowUnknownResolver
- Implements
- Inherited Members
Properties
Instance
Gets the default instance of the ThrowUnknownResolver class.
public static ThrowUnknownResolver Instance { get; }
Property Value
Methods
ResolveArrayIndex(CilExecutionContext, CilInstruction, long, StackSlot)
Resolves an unknown index of an element within an array.
public virtual long? ResolveArrayIndex(CilExecutionContext context, CilInstruction instruction, long arrayAddress, StackSlot index)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe switch instruction that is being executed.
arrayAddresslongThe address of the array.
indexStackSlotThe index to resolve.
Returns
- long?
The resolved index, or
nullto treat it as an unknown value that is processed successfully.
ResolveBlockSize(CilExecutionContext, CilInstruction, StackSlot)
Resolves an unknown size for a memory block.
public virtual uint ResolveBlockSize(CilExecutionContext context, CilInstruction instruction, StackSlot size)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe instruction that is being executed.
sizeStackSlotThe size to resolve.
Returns
- uint
The resolved size, or
nullto treat it as an unknown value that is processed successfully.
ResolveBranchCondition(CilExecutionContext, CilInstruction, StackSlot)
Resolves an unknown condition value of a unary conditional branch instruction.
public virtual bool ResolveBranchCondition(CilExecutionContext context, CilInstruction instruction, StackSlot argument)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe branch instruction that is being executed.
argumentStackSlotThe condition to be resolved.
Returns
- bool
trueif the branch should be taken,falseotherwise.
ResolveBranchCondition(CilExecutionContext, CilInstruction, StackSlot, StackSlot)
Resolves an unknown condition value of a binary conditional branch instruction.
public virtual bool ResolveBranchCondition(CilExecutionContext context, CilInstruction instruction, StackSlot argument1, StackSlot argument2)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe branch instruction that is being executed.
argument1StackSlotThe first argument.
argument2StackSlotThe second argument.
Returns
- bool
trueif the branch should be taken,falseotherwise.
ResolveDelegateTarget(CilExecutionContext, ObjectHandle, IList<BitVector>)
public virtual IMethodDescriptor? ResolveDelegateTarget(CilExecutionContext context, ObjectHandle delegateObject, IList<BitVector> arguments)
Parameters
contextCilExecutionContextdelegateObjectObjectHandleargumentsIList<BitVector>
Returns
ResolveDestinationPointer(CilExecutionContext, CilInstruction, StackSlot)
Resolves an unknown destination address to a memory block or object to write data to.
public virtual long? ResolveDestinationPointer(CilExecutionContext context, CilInstruction instruction, StackSlot address)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe instruction that is being executed.
addressStackSlotThe address to resolve.
Returns
- long?
The resolved address, or
nullto treat it as an unknown value that is processed successfully.
ResolveExceptionFilter(CilExecutionContext, CilInstruction, StackSlot)
Resolves an unknown conclusion for an exception filter.
public virtual bool ResolveExceptionFilter(CilExecutionContext context, CilInstruction instruction, StackSlot conclusion)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe instruction that is being executed.
conclusionStackSlotThe unknown conclusion value.
Returns
- bool
trueif the exception should be handled,falseotherwise.
ResolveMethod(CilExecutionContext, CilInstruction, IList<BitVector>)
Resolves a method devirtualization on an unknown object instance.
public virtual IMethodDescriptor? ResolveMethod(CilExecutionContext context, CilInstruction instruction, IList<BitVector> arguments)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe instruction that is being executed.
argumentsIList<BitVector>
Returns
- IMethodDescriptor
The resolved method, or
nullif devirtualization should be ignored and the default implementation of the method should be used.
ResolveSourcePointer(CilExecutionContext, CilInstruction, StackSlot)
Resolves an unknown source address to a memory block or object to read data from.
public virtual long? ResolveSourcePointer(CilExecutionContext context, CilInstruction instruction, StackSlot address)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe instruction that is being executed.
addressStackSlotThe address to resolve.
Returns
- long?
The resolved address, or
nullto treat it as an unknown value that is processed successfully.
ResolveSwitchCondition(CilExecutionContext, CilInstruction, StackSlot)
Resolves an unknown index value of a switch instruction.
public virtual uint? ResolveSwitchCondition(CilExecutionContext context, CilInstruction instruction, StackSlot argument)
Parameters
contextCilExecutionContextThe context in which the instruction is executed in.
instructionCilInstructionThe switch instruction that is being executed.
argumentStackSlotThe switch index to resolve.
Returns
- uint?
The resolved index to jump to, or
nullto skip the switch instruction.