Class CMethodState
java.lang.Object
com.pnfsoftware.jeb.core.units.code.asm.decompiler.ast.simulator.CMethodState
State of a simulated method.
- the concrete value associated to each
ICIdentifier - the concrete return value, if the execution terminated
- a
CMethodState.ControlWordvalue to select the next instruction to execute
areEquivalent(CMethodState, CMethodState, boolean, boolean), to test if another state
might represent the same computation.-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleanareEquivalent(CMethodState state1, CMethodState state2, boolean checkProducedValues, boolean checkControlWords) Checks if two states might represent the same computation, namely: if the return values are the same conditionally, if the same values got produced in both states conditionally, if the final control words are the sameintgetIdentifier(ICElement element) getLocalVarValue(ICElement element) booleanIf true, parameters of methods called are considered spoiled; the corresponding variables' values will be modified by the simulation.voidsetControlWord(CMethodState.ControlWord controlWord) voidsetControlWordIndex(int controlWordIndex) voidsetLocalVarValue(ICIdentifier id, Long value) voidsetMethodParametersSpoiled(boolean methodParametersSpoiled) voidsetReturnValue(Long returnValue) voidsetValue(ICElement element, Long value, CEnvironment environment) Sets a variable --either local or global-- value.toString()
-
Constructor Details
-
CMethodState
-
-
Method Details
-
setValue
Sets a variable --either local or global-- value. -
setLocalVarValue
-
getIdentifier
-
getLocalVarValue
-
getStatements
-
areEquivalent
public static boolean areEquivalent(CMethodState state1, CMethodState state2, boolean checkProducedValues, boolean checkControlWords) Checks if two states might represent the same computation, namely:- if the return values are the same
- conditionally, if the same values got produced in both states
- conditionally, if the final control words are the same
-
getControlWord
-
setControlWord
-
toString
-
getReturnValue
-
setReturnValue
-
getLocalVarValues
-
getControlWordIndex
public int getControlWordIndex() -
setControlWordIndex
public void setControlWordIndex(int controlWordIndex) -
isMethodParametersSpoiled
public boolean isMethodParametersSpoiled()If true, parameters of methods called are considered spoiled; the corresponding variables' values will be modified by the simulation. If false, they are left intact. -
setMethodParametersSpoiled
public void setMethodParametersSpoiled(boolean methodParametersSpoiled)
-