Class FieldSetAnalysis
java.lang.Object
edu.umd.cs.findbugs.ba.BasicAbstractDataflowAnalysis<FieldSet>
edu.umd.cs.findbugs.ba.AbstractDataflowAnalysis<FieldSet>
edu.umd.cs.findbugs.ba.ForwardDataflowAnalysis<FieldSet>
edu.umd.cs.findbugs.ba.heap.FieldSetAnalysis
- All Implemented Interfaces:
DataflowAnalysis<FieldSet>
- Direct Known Subclasses:
LoadAnalysis, StoreAnalysis
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.apache.bcel.generic.ConstantPoolGen -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedFieldSetAnalysis(DepthFirstSearch dfs, org.apache.bcel.generic.ConstantPoolGen cpg) -
Method Summary
Modifier and TypeMethodDescriptionvoidCopy dataflow facts.Create empty (uninitialized) dataflow facts for one program point.org.apache.bcel.generic.ConstantPoolGengetCPG()private voidhandleInstruction(org.apache.bcel.generic.InstructionHandle handle, BasicBlock basicBlock, FieldSet fact) voidinitEntryFact(FieldSet result) Initialize the "entry" fact for the graph.booleanisFactValid(FieldSet fact) Determine whether the given fact is valid (neither top nor bottom).booleanIs the given fact the top value.private XFieldlookupField(org.apache.bcel.generic.InstructionHandle handle, org.apache.bcel.generic.FieldInstruction fins) voidmakeFactTop(FieldSet fact) Make given fact the top value.voidMeet a dataflow fact associated with an incoming edge into another fact.booleanAre given dataflow facts the same?protected abstract voidprotected abstract voidvoidtransferInstruction(org.apache.bcel.generic.InstructionHandle handle, BasicBlock basicBlock, FieldSet fact) Transfer function for a single instruction.Methods inherited from class ForwardDataflowAnalysis
getBlockOrder, getDepthFirstSearch, isForwardsMethods inherited from class AbstractDataflowAnalysis
getFactAfterLocation, getFactAtLocation, transferMethods inherited from class BasicAbstractDataflowAnalysis
edgeTransfer, factToString, finishIteration, getFactOnEdge, getLastUpdateTimestamp, getResultFact, getStartFact, resultFactIterator, setLastUpdateTimestamp, startIteration
-
Field Details
-
cpg
private final org.apache.bcel.generic.ConstantPoolGen cpg -
instructionToFieldMap
-
-
Constructor Details
-
FieldSetAnalysis
-
-
Method Details
-
getCPG
public org.apache.bcel.generic.ConstantPoolGen getCPG() -
makeFactTop
Description copied from interface:DataflowAnalysisMake given fact the top value. -
isTop
Description copied from interface:DataflowAnalysisIs the given fact the top value. -
initEntryFact
Description copied from interface:DataflowAnalysisInitialize the "entry" fact for the graph.- Throws:
DataflowAnalysisException
-
meetInto
Description copied from interface:DataflowAnalysisMeet a dataflow fact associated with an incoming edge into another fact. This is used to determine the start fact for a basic block.- Parameters:
fact- the predecessor fact (incoming edge)edge- the edge from the predecessorresult- the result fact- Throws:
DataflowAnalysisException
-
same
Description copied from interface:DataflowAnalysisAre given dataflow facts the same? -
createFact
Description copied from interface:DataflowAnalysisCreate empty (uninitialized) dataflow facts for one program point. A valid value will be copied into it before it is used. -
isFactValid
Description copied from class:AbstractDataflowAnalysisDetermine whether the given fact is valid (neither top nor bottom).- Specified by:
isFactValidin classAbstractDataflowAnalysis<FieldSet>
-
copy
Description copied from interface:DataflowAnalysisCopy dataflow facts. -
transferInstruction
public void transferInstruction(org.apache.bcel.generic.InstructionHandle handle, BasicBlock basicBlock, FieldSet fact) throws DataflowAnalysisException Description copied from class:AbstractDataflowAnalysisTransfer function for a single instruction.- Specified by:
transferInstructionin classAbstractDataflowAnalysis<FieldSet>- Parameters:
handle- the instructionbasicBlock- the BasicBlock containing the instruction; needed to disambiguate instructions in inlined JSR subroutinesfact- which should be modified based on the instruction- Throws:
DataflowAnalysisException
-
handleInstruction
private void handleInstruction(org.apache.bcel.generic.InstructionHandle handle, BasicBlock basicBlock, FieldSet fact) -
lookupField
@CheckForNull private XField lookupField(org.apache.bcel.generic.InstructionHandle handle, org.apache.bcel.generic.FieldInstruction fins) -
sawLoad
-
sawStore
-