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.ControlWord
value 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 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 sameint
getIdentifier
(ICElement element) getLocalVarValue
(ICElement element) boolean
If true, parameters of methods called are considered spoiled; the corresponding variables' values will be modified by the simulation.void
setControlWord
(CMethodState.ControlWord controlWord) void
setControlWordIndex
(int controlWordIndex) void
setLocalVarValue
(ICIdentifier id, Long value) void
setMethodParametersSpoiled
(boolean methodParametersSpoiled) void
setReturnValue
(Long returnValue) void
setValue
(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)
-