|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object
|
+--de.rwth.dfa.jvm.samples.AbstractSSDependingAbstraction
|
+--de.rwth.dfa.jvm.samples.CPAbstraction
Implementation of a constant propagation abstraction. It can be used to determine
constant values in both stack an local variables. The domain used is CFPLattice.
| Inner Class Summary | |
protected class |
CPAbstraction.AllocationFunction
Pushes a CFPComponentLattice.NONNULLCOMPONENT onto the stack. |
class |
CPAbstraction.CPFunction
The abstract base class of all function of this abstraction. |
protected class |
CPAbstraction.DupFunction
Duplicates n elements on the stack under x other elements. |
protected class |
CPAbstraction.ExceptionHeaderFunction
Creates a new stack with only a CFPComponentLattice.NONNULLCOMPONENT. |
protected class |
CPAbstraction.GenericFunction
A generic function. |
protected class |
CPAbstraction.IncLocalFunction
Increments the content of a local variable slot. |
protected class |
CPAbstraction.PopFunction
Removes entries from the stack. |
protected class |
CPAbstraction.PushConstantFunction
A function for pushing a constant onto the stack. |
protected class |
CPAbstraction.PushLocalFunction
Pushes the content of a local variable slot onto the stack. |
protected class |
CPAbstraction.StoreLocalFunction
Stores the top element in a local variable slot. |
protected class |
CPAbstraction.SwapFunction
Swaps the top element and the element below that on the stack. |
| Inner classes inherited from class de.rwth.dfa.jvm.Abstraction |
Abstraction.Default |
| Field Summary | |
protected CFPLattice |
l
The domain used in this abstraction. |
protected int |
maxLocals
The maximal number of local variable slots in the method for this abstraction. |
protected int |
maxStack
The maximal stack size in the method for this abstraction. |
| Fields inherited from class de.rwth.dfa.jvm.samples.AbstractSSDependingAbstraction |
cpg, stacksizes |
| Fields inherited from interface de.rwth.dfa.jvm.Abstraction |
DIRECTION_BACKWARD, DIRECTION_FORWARD, QUANTIFIER_ALL, QUANTIFIER_EXISTS |
| Constructor Summary | |
CPAbstraction(int maxStack,
int maxLocals,
de.fub.bytecode.generic.ConstantPoolGen constantPoolGen,
de.fub.bytecode.generic.InstructionList methodInstrs,
de.fub.bytecode.classfile.CodeException[] methodExceptions)
Creates a new CFPAbstraction instance. |
|
CPAbstraction(int maxStack,
int maxLocals,
de.fub.bytecode.classfile.ConstantPool constantPool,
de.fub.bytecode.generic.InstructionList methodInstrs,
de.fub.bytecode.classfile.CodeException[] methodExceptions)
Creates a new CFPAbstraction instance. |
|
| Method Summary | |
Function |
getAbstract(de.fub.bytecode.generic.InstructionHandle ih)
Creates an instance of CPFunction for an instruction. |
Function |
getAbstract(InstructionHandleVector ihv)
Returns the value of the default implementation in Abstraction.Default. |
int |
getDirection()
Returns DIRECTION_FORWARD. |
java.lang.Object |
getInitialValue(de.fub.bytecode.generic.InstructionHandle ih,
boolean isRoot)
Returns the initial value for an instruction. |
java.lang.Object |
getInitialValue(InstructionHandleVector ihv,
boolean isRoot)
Returns the value of the default implementation in Abstraction.Default. |
Lattice |
getLattice()
Returns the CFPLattice for this abstraction. |
int |
getQuantifier()
Returns QUANTIFIER_ALL. |
| Methods inherited from class de.rwth.dfa.jvm.samples.AbstractSSDependingAbstraction |
getConstantPoolGen, getStacksize |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected CFPLattice l
protected int maxLocals
protected int maxStack
| Constructor Detail |
public CPAbstraction(int maxStack,
int maxLocals,
de.fub.bytecode.generic.ConstantPoolGen constantPoolGen,
de.fub.bytecode.generic.InstructionList methodInstrs,
de.fub.bytecode.classfile.CodeException[] methodExceptions)
CFPAbstraction instance.maxStack - an int valuemaxLocals - an int valueconstantPool - a ConstantPool valuemethodInstrs - an InstructionList valuemethodExceptions - a CodeException[] value
public CPAbstraction(int maxStack,
int maxLocals,
de.fub.bytecode.classfile.ConstantPool constantPool,
de.fub.bytecode.generic.InstructionList methodInstrs,
de.fub.bytecode.classfile.CodeException[] methodExceptions)
CFPAbstraction instance.maxStack - an int valuemaxLocals - an int valueconstantPool - a ConstantPool valuemethodInstrs - an InstructionList valuemethodExceptions - a CodeException[] value| Method Detail |
public Lattice getLattice()
CFPLattice for this abstraction.getLattice in interface AbstractionLattice value
public java.lang.Object getInitialValue(de.fub.bytecode.generic.InstructionHandle ih,
boolean isRoot)
CFPComponentLattice.NONCONSTANTCOMPONENT
CFPComponentLattice.UNKNOWNCOMPONENT
CFPComponentLattice.NONCONSTANTCOMPONENT
CFPComponentLattice.UNKNOWNCOMPONENT
getInitialValue in interface Abstractionih - an InstructionHandle valueisRoot - a boolean valueObject valuepublic int getDirection()
DIRECTION_FORWARD.getDirection in interface Abstractionint valuepublic int getQuantifier()
QUANTIFIER_ALL.getQuantifier in interface Abstractionint valuepublic Function getAbstract(de.fub.bytecode.generic.InstructionHandle ih)
getAbstract in interface Abstractionih - an InstructionHandle valueFunction value
public java.lang.Object getInitialValue(InstructionHandleVector ihv,
boolean isRoot)
Abstraction.Default.getInitialValue in interface Abstractionihv - an InstructionHandleVector valueisRoot - a boolean valueObject valuepublic Function getAbstract(InstructionHandleVector ihv)
Abstraction.Default.getAbstract in interface Abstractionihv - an InstructionHandleVector valueFunction value
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||