Package com.ibm.wala.ssa
Class SSAConversionInstruction
- java.lang.Object
-
- com.ibm.wala.ssa.SSAInstruction
-
- com.ibm.wala.ssa.SSAConversionInstruction
-
public abstract class SSAConversionInstruction extends SSAInstruction
An instruction which converts a value of one primitive type into another primitive type.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.ibm.wala.ssa.SSAInstruction
SSAInstruction.IVisitor, SSAInstruction.Visitor
-
-
Field Summary
-
Fields inherited from class com.ibm.wala.ssa.SSAInstruction
iindex, NO_INDEX
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
SSAConversionInstruction(int iindex, int result, int val, TypeReference fromType, TypeReference toType)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getDef()
int
getDef(int i)
Return the ith defTypeReference
getFromType()
int
getNumberOfDefs()
int
getNumberOfUses()
TypeReference
getToType()
int
getUse(int j)
boolean
hasDef()
Does this instruction define a normal value, as distinct from a set of exceptions possibly thrown by it (e.g.int
hashCode()
boolean
isFallThrough()
String
toString(SymbolTable symbolTable)
void
visit(SSAInstruction.IVisitor v)
Apply an IVisitor to this instruction.-
Methods inherited from class com.ibm.wala.ssa.SSAInstruction
copyForSSA, equals, getExceptionTypes, getValueString, isPEI, toString
-
-
-
-
Constructor Detail
-
SSAConversionInstruction
protected SSAConversionInstruction(int iindex, int result, int val, TypeReference fromType, TypeReference toType)
-
-
Method Detail
-
toString
public String toString(SymbolTable symbolTable)
- Specified by:
toString
in classSSAInstruction
-
visit
public void visit(SSAInstruction.IVisitor v) throws NullPointerException
Description copied from class:SSAInstruction
Apply an IVisitor to this instruction. We invoke the appropriate IVisitor method according to the type of this instruction.- Specified by:
visit
in classSSAInstruction
- Throws:
NullPointerException
- See Also:
SSAInstruction.visit(IVisitor)
-
hasDef
public boolean hasDef()
Description copied from class:SSAInstruction
Does this instruction define a normal value, as distinct from a set of exceptions possibly thrown by it (e.g. for invoke instructions).- Overrides:
hasDef
in classSSAInstruction
- Returns:
- true if the instruction does define a proper value.
- See Also:
SSAInstruction.getDef()
-
getDef
public int getDef()
- Overrides:
getDef
in classSSAInstruction
-
getDef
public int getDef(int i)
Description copied from class:SSAInstruction
Return the ith def- Overrides:
getDef
in classSSAInstruction
- Parameters:
i
- number of the def, starting at 0.
-
getNumberOfUses
public int getNumberOfUses()
- Overrides:
getNumberOfUses
in classSSAInstruction
- See Also:
SSAInstruction.getNumberOfUses()
-
getNumberOfDefs
public int getNumberOfDefs()
- Overrides:
getNumberOfDefs
in classSSAInstruction
-
getToType
public TypeReference getToType()
-
getFromType
public TypeReference getFromType()
-
getUse
public int getUse(int j)
- Overrides:
getUse
in classSSAInstruction
- Returns:
- value number representing the jth use in this instruction. -1 means TOP (i.e., the value doesn't matter)
- See Also:
SSAInstruction.getUse(int)
-
hashCode
public int hashCode()
- Specified by:
hashCode
in classSSAInstruction
-
isFallThrough
public boolean isFallThrough()
- Specified by:
isFallThrough
in classSSAInstruction
- Returns:
- true iff this instruction may fall through to the next
-
-