Class SSAConversion
java.lang.Object
com.ibm.wala.cast.ir.ssa.AbstractSSAConversion
com.ibm.wala.cast.ir.ssa.SSAConversion
- Author:
- Julian Dolby
Standard SSA conversion for local value numbers.
-
Nested Class Summary
Modifier and TypeClassDescriptionclass
static class
class
static class
-
Field Summary
Modifier and TypeFieldDescriptionstatic boolean
static boolean
static boolean
static boolean
Fields inherited from class com.ibm.wala.cast.ir.ssa.AbstractSSAConversion
C, CFG, defaultValues, DF, instructions, phiCounts, S, symbolTable, valueMap
-
Method Summary
Modifier and TypeMethodDescriptionstatic SSAConversion.SSAInformation
convert
(AstMethod M, AstIRFactory.AstIR ir, SSAOptions options) static SSAConversion.SSAInformation
convert
(AstMethod M, AstIRFactory.AstIR ir, SSAOptions options, IntSet values) static void
copyUse
(AstIRFactory.AstIR ir, int fromInst, int fromUse, int toInst, int toUse) protected void
fail
(int v) protected int
getDef
(SSAInstruction inst, int index) protected int
protected int
protected int
protected int
protected SSAPhiInstruction
getPhi
(SSACFG.BasicBlock B, int index) protected int
getUse
(SSAInstruction inst, int index) protected void
protected boolean
protected boolean
isConstant
(int valueNumber) protected boolean
isLive
(SSACFG.BasicBlock Y, int V) void
perform()
protected void
placeNewPhiAt
(int value, SSACFG.BasicBlock Y) protected void
popAssignment
(SSAInstruction inst, int index) protected void
pushAssignment
(SSAInstruction inst, int index, int newRhs) protected void
protected void
repairInstructionDefs
(SSAInstruction inst, int index, int[] newDefs, int[] newUses) protected void
repairInstructionUses
(SSAInstruction inst, int index, int[] newUses) protected SSAPhiInstruction
repairPhiDefs
(SSAPhiInstruction phi, int[] newDefs) protected void
repairPhiUse
(SSACFG.BasicBlock BB, int phiIndex, int rvalIndex, int newRval) protected void
setPhi
(SSACFG.BasicBlock B, int index, SSAPhiInstruction inst) protected boolean
skip
(int vn) protected boolean
skipRepair
(SSAInstruction inst, int index) static void
undoCopyPropagation
(AstIRFactory.AstIR ir, int instruction, int use) Methods inherited from class com.ibm.wala.cast.ir.ssa.AbstractSSAConversion
getDefaultValue, getInstructions, hasDefaultValue, init, iterateInstructions, placePhiNodes, top
-
Field Details
-
DEBUG
public static boolean DEBUG -
DEBUG_UNDO
public static boolean DEBUG_UNDO -
DEBUG_NAMES
public static boolean DEBUG_NAMES -
DUMP
public static boolean DUMP
-
-
Method Details
-
undoCopyPropagation
-
copyUse
-
getNumberOfDefs
- Specified by:
getNumberOfDefs
in classAbstractSSAConversion
-
getDef
- Specified by:
getDef
in classAbstractSSAConversion
-
getNumberOfUses
- Specified by:
getNumberOfUses
in classAbstractSSAConversion
-
getUse
- Specified by:
getUse
in classAbstractSSAConversion
-
isAssignInstruction
- Specified by:
isAssignInstruction
in classAbstractSSAConversion
-
getMaxValueNumber
protected int getMaxValueNumber()- Specified by:
getMaxValueNumber
in classAbstractSSAConversion
-
skip
protected boolean skip(int vn) - Specified by:
skip
in classAbstractSSAConversion
-
isLive
- Specified by:
isLive
in classAbstractSSAConversion
-
placeNewPhiAt
- Specified by:
placeNewPhiAt
in classAbstractSSAConversion
-
getPhi
- Specified by:
getPhi
in classAbstractSSAConversion
-
setPhi
- Specified by:
setPhi
in classAbstractSSAConversion
-
repairPhiDefs
- Specified by:
repairPhiDefs
in classAbstractSSAConversion
-
repairPhiUse
- Specified by:
repairPhiUse
in classAbstractSSAConversion
-
pushAssignment
- Specified by:
pushAssignment
in classAbstractSSAConversion
-
repairInstructionUses
- Specified by:
repairInstructionUses
in classAbstractSSAConversion
-
repairInstructionDefs
- Specified by:
repairInstructionDefs
in classAbstractSSAConversion
-
popAssignment
- Specified by:
popAssignment
in classAbstractSSAConversion
-
isConstant
protected boolean isConstant(int valueNumber) - Specified by:
isConstant
in classAbstractSSAConversion
-
skipRepair
- Overrides:
skipRepair
in classAbstractSSAConversion
-
getNextNewValueNumber
protected int getNextNewValueNumber()- Specified by:
getNextNewValueNumber
in classAbstractSSAConversion
-
initializeVariables
protected void initializeVariables()- Specified by:
initializeVariables
in classAbstractSSAConversion
-
repairExit
protected void repairExit()- Specified by:
repairExit
in classAbstractSSAConversion
-
fail
protected void fail(int v) - Overrides:
fail
in classAbstractSSAConversion
-
getComputedLocalMap
-
perform
public void perform()- Overrides:
perform
in classAbstractSSAConversion
-
convert
public static SSAConversion.SSAInformation convert(AstMethod M, AstIRFactory.AstIR ir, SSAOptions options) -
convert
public static SSAConversion.SSAInformation convert(AstMethod M, AstIRFactory.AstIR ir, SSAOptions options, IntSet values)
-