Package | Description |
---|---|
edu.umd.cs.findbugs.ba |
A bytecode analysis framework for BCEL, providing CFG construction,
generic dataflow analysis, and a variety of specific dataflow analyses.
|
edu.umd.cs.findbugs.ba.bcp | |
edu.umd.cs.findbugs.ba.deref | |
edu.umd.cs.findbugs.ba.jsr305 |
Support for analyzing code containing JSR-305 type qualifier annotations.
|
edu.umd.cs.findbugs.ba.npe | |
edu.umd.cs.findbugs.ba.type | |
edu.umd.cs.findbugs.ba.vna | |
edu.umd.cs.findbugs.detect |
Modifier and Type | Method and Description |
---|---|
java.util.Collection<ValueNumber> |
LockSet.getLockedValueNumbers(ValueNumberFrame frame) |
Constructor and Description |
---|
FieldVariable(ValueNumber ref,
java.lang.String className,
java.lang.String fieldName,
java.lang.String fieldSig)
Constructor for instance fields.
|
LocalVariable(ValueNumber valueNumber) |
LongOrDoubleLocalVariable(ValueNumber topValue,
ValueNumber nextValue) |
Modifier and Type | Method and Description |
---|---|
static java.util.Set<ValueNumber> |
UnconditionalValueDerefAnalysis.checkAllNonNullParams(Location location,
ValueNumberFrame vnaFrame,
org.apache.bcel.generic.ConstantPoolGen constantPool,
org.apache.bcel.classfile.Method method,
IsNullValueDataflow invDataflow,
TypeDataflow typeDataflow) |
static java.util.Set<ValueNumber> |
UnconditionalValueDerefAnalysis.checkNonNullParams(Location location,
ValueNumberFrame vnaFrame,
org.apache.bcel.generic.ConstantPoolGen constantPool,
org.apache.bcel.classfile.Method method,
IsNullValueFrame invFrame) |
static java.util.Set<ValueNumber> |
UnconditionalValueDerefAnalysis.checkUnconditionalDerefDatabase(Location location,
ValueNumberFrame vnaFrame,
org.apache.bcel.generic.ConstantPoolGen constantPool,
IsNullValueFrame invFrame,
TypeDataflow typeDataflow) |
java.util.Set<ValueNumber> |
UnconditionalValueDerefSet.getValueNumbersThatAreUnconditionallyDereferenced() |
Modifier and Type | Method and Description |
---|---|
void |
UnconditionalValueDerefSet.addDeref(ValueNumber vn,
Location location)
Mark a value as being dereferenced at given Location.
|
void |
UnconditionalValueDerefSet.clearDerefSet(ValueNumber value)
Clear the set of dereferences for given ValueNumber
|
java.util.Set<Location> |
UnconditionalValueDerefSet.getDerefLocationSet(ValueNumber vn)
Get the set of dereference Locations for given value number.
|
java.util.Set<Location> |
UnconditionalValueDerefSet.getUnconditionalDerefLocationSet(ValueNumber vn)
Get the set of Locations where given value is guaranteed to be
dereferenced.
|
boolean |
UnconditionalValueDerefSet.isUnconditionallyDereferenced(ValueNumber vn)
Return whether or not the given value number is unconditionally
dereferenced.
|
void |
UnconditionalValueDerefSet.mergeWith(UnconditionalValueDerefSet fact,
ValueNumber skipMe,
ValueNumberFactory valueNumberFactory)
Merge given dataflow fact into this one.
|
void |
UnconditionalValueDerefSet.setDerefSet(ValueNumber vn,
java.util.Set<Location> derefSet)
Set a value as being unconditionally dereferenced at the given set of
locations.
|
Modifier and Type | Method and Description |
---|---|
void |
UnconditionalValueDerefSet.retainOnlyTheseValueNumbers(java.util.Collection<ValueNumber> valueNumbers) |
Modifier and Type | Method and Description |
---|---|
ValueNumber |
SourceSinkInfo.getValueNumber() |
Modifier and Type | Method and Description |
---|---|
java.util.Collection<? extends ValueNumber> |
TypeQualifierValueSet.getValueNumbers() |
Modifier and Type | Method and Description |
---|---|
FlowValue |
TypeQualifierValueSet.getValue(ValueNumber vn) |
java.util.Set<? extends SourceSinkInfo> |
TypeQualifierValueSet.getWhere(ValueNumber vn) |
java.util.Set<? extends SourceSinkInfo> |
TypeQualifierValueSet.getWhereAlways(ValueNumber vn) |
java.util.Set<? extends SourceSinkInfo> |
TypeQualifierValueSet.getWhereNever(ValueNumber vn) |
protected abstract void |
TypeQualifierDataflowAnalysis.propagateAcrossPhiNode(TypeQualifierValueSet fact,
ValueNumber sourceVN,
ValueNumber targetVN) |
protected void |
ForwardTypeQualifierDataflowAnalysis.propagateAcrossPhiNode(TypeQualifierValueSet fact,
ValueNumber sourceVN,
ValueNumber targetVN) |
protected void |
BackwardTypeQualifierDataflowAnalysis.propagateAcrossPhiNode(TypeQualifierValueSet fact,
ValueNumber sourceVN,
ValueNumber targetVN) |
void |
TypeQualifierValueSet.propagateAcrossPhiNode(ValueNumber fromVN,
ValueNumber toVN) |
void |
TypeQualifierValueSet.pruneValue(ValueNumber vn) |
java.lang.String |
TypeQualifierValueSet.valueNumberToString(ValueNumber vn) |
java.lang.String |
TypeQualifierValueSet.valueNumberToString(ValueNumber vn,
FlowValue value) |
Constructor and Description |
---|
SourceSinkInfo(SourceSinkType type,
Location location,
ValueNumber vn,
javax.annotation.meta.When when)
Constructor.
|
Modifier and Type | Field and Description |
---|---|
ValueNumber |
UsagesRequiringNonNullValues.Pair.vn |
Modifier and Type | Method and Description |
---|---|
ValueNumber |
IsNullConditionDecision.getValue()
Get the value about which the branch yields information.
|
ValueNumber |
LocationWhereValueBecomesNull.getValueNumber() |
Modifier and Type | Method and Description |
---|---|
java.util.Map<ValueNumber,java.util.Set<Location>> |
NullDerefAndRedundantComparisonFinder.findNullAssignments(java.util.Set<LocationWhereValueBecomesNull> locationWhereValueBecomesNullSet) |
java.util.Collection<java.util.Map.Entry<ValueNumber,IsNullValue>> |
IsNullValueFrame.getKnownValueMapEntrySet() |
java.util.Collection<ValueNumber> |
IsNullValueFrame.getKnownValues() |
Modifier and Type | Method and Description |
---|---|
void |
UsagesRequiringNonNullValues.add(Location loc,
ValueNumber vn,
PointerUsageRequiringNonNullValue usage) |
static BugAnnotation |
NullDerefAndRedundantComparisonFinder.findAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame)
|
static FieldAnnotation |
NullDerefAndRedundantComparisonFinder.findFieldAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame)
|
static LocalVariableAnnotation |
NullDerefAndRedundantComparisonFinder.findLocalAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame)
|
static XField |
NullDerefAndRedundantComparisonFinder.findXFieldFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame)
Deprecated.
|
void |
NullDerefAndRedundantComparisonCollector.foundGuaranteedNullDeref(java.util.Set<Location> assignedNullLocationSet,
java.util.Set<Location> derefLocationSet,
java.util.SortedSet<Location> doomedLocations,
ValueNumberDataflow vna,
ValueNumber refValue,
BugAnnotation variableAnnotation,
NullValueUnconditionalDeref deref,
boolean npeIfStatementCovered)
Subclasses should override this method to capture values assigned null
(or that become null through a comparison and branch) that are guaranteed
to reach a dereference (ignoring implicit exception paths).
|
void |
NullDerefAndRedundantComparisonCollector.foundNullDeref(Location location,
ValueNumber valueNumber,
IsNullValue refValue,
ValueNumberFrame vnaFrame)
|
void |
NullDerefAndRedundantComparisonCollector.foundNullDeref(Location location,
ValueNumber valueNumber,
IsNullValue refValue,
ValueNumberFrame vnaFrame,
boolean isConsistent)
Subclasses should override this method to capture locations where a null
pointer is dereferenced.
|
PointerUsageRequiringNonNullValue |
UsagesRequiringNonNullValues.get(Location loc,
ValueNumber vn,
ValueNumberDataflow vnaDataflow) |
IsNullValue |
IsNullValueFrame.getKnownValue(ValueNumber valueNumber) |
void |
IsNullValueFrame.setKnownValue(ValueNumber valueNumber,
IsNullValue knownValue) |
void |
IsNullValueFrame.useNewValueNumberForLoad(ValueNumber oldValueNumber,
ValueNumber newValueNumber) |
Modifier and Type | Method and Description |
---|---|
void |
NullDerefAndRedundantComparisonFinder.checkEdges(CFG cfg,
java.util.Map<ValueNumber,NullValueUnconditionalDeref> nullValueGuaranteedDerefMap,
java.util.Map<ValueNumber,java.util.SortedSet<Location>> bugEdgeLocationMap) |
void |
NullDerefAndRedundantComparisonFinder.checkEdges(CFG cfg,
java.util.Map<ValueNumber,NullValueUnconditionalDeref> nullValueGuaranteedDerefMap,
java.util.Map<ValueNumber,java.util.SortedSet<Location>> bugEdgeLocationMap) |
void |
NullDerefAndRedundantComparisonFinder.reportBugs(java.util.Map<ValueNumber,NullValueUnconditionalDeref> nullValueGuaranteedDerefMap,
java.util.HashSet<ValueNumber> npeIfStatementCovered,
java.util.Map<ValueNumber,java.util.SortedSet<Location>> bugLocationMap,
java.util.Map<ValueNumber,java.util.Set<Location>> nullValueAssignmentMap) |
void |
NullDerefAndRedundantComparisonFinder.reportBugs(java.util.Map<ValueNumber,NullValueUnconditionalDeref> nullValueGuaranteedDerefMap,
java.util.HashSet<ValueNumber> npeIfStatementCovered,
java.util.Map<ValueNumber,java.util.SortedSet<Location>> bugLocationMap,
java.util.Map<ValueNumber,java.util.Set<Location>> nullValueAssignmentMap) |
void |
NullDerefAndRedundantComparisonFinder.reportBugs(java.util.Map<ValueNumber,NullValueUnconditionalDeref> nullValueGuaranteedDerefMap,
java.util.HashSet<ValueNumber> npeIfStatementCovered,
java.util.Map<ValueNumber,java.util.SortedSet<Location>> bugLocationMap,
java.util.Map<ValueNumber,java.util.Set<Location>> nullValueAssignmentMap) |
void |
NullDerefAndRedundantComparisonFinder.reportBugs(java.util.Map<ValueNumber,NullValueUnconditionalDeref> nullValueGuaranteedDerefMap,
java.util.HashSet<ValueNumber> npeIfStatementCovered,
java.util.Map<ValueNumber,java.util.SortedSet<Location>> bugLocationMap,
java.util.Map<ValueNumber,java.util.Set<Location>> nullValueAssignmentMap) |
Constructor and Description |
---|
IsNullConditionDecision(ValueNumber value,
IsNullValue ifcmpDecision,
IsNullValue fallThroughDecision)
Constructor.
|
IsNullValueAnalysis.PointerEqualityCheck(ValueNumber reg1,
ValueNumber reg2,
int firstValuePC) |
LocationWhereValueBecomesNull(Location location,
ValueNumber valueNumber)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
ValueNumber |
TypeFrameModelingVisitor.getInstanceOfValueNumber()
Get the value number of the most recent instanceof instruction modeled.
|
Modifier and Type | Field and Description |
---|---|
ValueNumber[] |
ValueNumberCache.Entry.inputValueList |
Modifier and Type | Method and Description |
---|---|
ValueNumber |
ValueNumberFactory.createFreshValue()
Create a fresh (unique) value number.
|
ValueNumber |
ValueNumberFactory.createFreshValue(int flags) |
static ValueNumber |
ValueNumber.createValueNumber(int number) |
static ValueNumber |
ValueNumber.createValueNumber(int number,
int flags) |
ValueNumber |
ValueNumberFactory.forNumber(int number)
Return a previously allocated value.
|
ValueNumber[] |
ValueNumberFrame.getAvailableLoad(AvailableLoad availableLoad)
Look for an available load.
|
ValueNumber |
ValueNumberFactory.getClassObjectValue(java.lang.String className)
Get the ValueNumber for given class's Class object.
|
ValueNumber |
ValueNumberAnalysis.getClassObjectValue(java.lang.String className) |
ValueNumber |
ValueNumberFrameModelingVisitor.getDefaultValue() |
ValueNumber |
ValueNumberAnalysis.getEntryValue(int local)
Get the value number assigned to the given local variable upon entry to
the method.
|
ValueNumber |
ValueNumberAnalysis.getEntryValueForParameter(int param)
Get the value number assigned to the given parameter upon entry to the
method.
|
ValueNumber |
AvailableLoad.getReference()
Get the ValueNumber of the object reference.
|
ValueNumber |
ValueNumberAnalysis.getThisValue() |
ValueNumber[] |
ValueNumberCache.lookupOutputValues(ValueNumberCache.Entry entry)
Look up cached output values for given entry.
|
Modifier and Type | Method and Description |
---|---|
java.util.Map<ValueNumber,java.lang.Integer> |
ValueNumberDataflow.getValueNumberToParamMap(org.apache.bcel.classfile.Method method)
Build map of value numbers to param indices.
|
java.util.Map<ValueNumber,java.lang.Integer> |
ValueNumberDataflow.getValueNumberToParamMap(java.lang.String methodSignature,
boolean isStatic)
Build map of value numbers to param indices.
|
java.util.Collection<ValueNumber> |
ValueNumberFrame.valueNumbersForLoads() |
Modifier and Type | Method and Description |
---|---|
void |
ValueNumberFrame.addAvailableLoad(AvailableLoad availableLoad,
ValueNumber[] value)
Add an available load.
|
void |
ValueNumberCache.addOutputValues(ValueNumberCache.Entry entry,
ValueNumber[] outputValueList)
Add output values for given entry.
|
int |
ValueNumber.compareTo(ValueNumber other) |
static BugAnnotation |
ValueNumberSourceInfo.findAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame,
java.lang.String partialRole) |
static FieldAnnotation |
ValueNumberSourceInfo.findFieldAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame) |
static LocalVariableAnnotation |
ValueNumberSourceInfo.findLocalAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame) |
static BugAnnotation |
ValueNumberSourceInfo.findRequiredAnnotationFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame,
java.lang.String partialRole) |
static XField |
ValueNumberSourceInfo.findXFieldFromValueNumber(org.apache.bcel.classfile.Method method,
Location location,
ValueNumber valueNumber,
ValueNumberFrame vnaFrame) |
boolean |
ValueNumberFrame.fromMatchingFields(ValueNumber v1,
ValueNumber v2) |
boolean |
ValueNumberFrame.fromMatchingLoads(ValueNumber v1,
ValueNumber v2) |
boolean |
ValueNumberFrame.fuzzyMatch(ValueNumber v1,
ValueNumber v2) |
java.lang.String |
ValueNumberFactory.getClassName(ValueNumber v) |
java.lang.String |
ValueNumberDataflow.getClassName(ValueNumber v) |
java.lang.String |
ValueNumberAnalysis.getClassName(ValueNumber v) |
java.util.BitSet |
MergeTree.getInputSet(ValueNumber output)
Get the set of input ValueNumbers which directly contributed to the given
output ValueNumber.
|
AvailableLoad |
ValueNumberFrame.getLoad(ValueNumber v) |
java.util.BitSet |
MergeTree.getTransitiveInputSet(ValueNumber output)
Get the transitive set of input ValueNumbers which contributed (directly
or indirectly) to the given output ValueNumber.
|
boolean |
ValueNumberFrame.haveMatchingFlags(ValueNumber v1,
ValueNumber v2) |
boolean |
ValueNumberAnalysis.isThisValue(ValueNumber value) |
void |
ValueNumberFrame.killAllLoadsExceptFor(ValueNumber v) |
void |
ValueNumberFrame.killAllLoadsOf(ValueNumber v)
Kill all loads.
|
void |
MergeTree.mapInputToOutput(ValueNumber input,
ValueNumber output)
Map an input ValueNumber to an output ValueNumber.
|
boolean |
AvailableLoad.matchesReference(ValueNumber v) |
boolean |
ValueNumberFrame.veryFuzzyMatch(ValueNumber v1,
ValueNumber v2) |
Modifier and Type | Method and Description |
---|---|
void |
ValueNumberFrame.copyFrom(Frame<ValueNumber> other) |
boolean |
ValueNumberFrame.sameAs(Frame<ValueNumber> other) |
Constructor and Description |
---|
AvailableLoad(ValueNumber reference,
XField field)
Constructor from object reference and instance field.
|
ValueNumberCache.Entry(org.apache.bcel.generic.InstructionHandle handle,
ValueNumber[] inputValueList) |
Modifier and Type | Method and Description |
---|---|
void |
NoiseNullDeref.foundGuaranteedNullDeref(java.util.Set<Location> assignedNullLocationSet,
java.util.Set<Location> derefLocationSet,
java.util.SortedSet<Location> doomedLocations,
ValueNumberDataflow vna,
ValueNumber refValue,
BugAnnotation variableAnnotation,
NullValueUnconditionalDeref deref,
boolean npeIfStatementCovered) |
void |
FindNullDeref.foundGuaranteedNullDeref(java.util.Set<Location> assignedNullLocationSet,
java.util.Set<Location> derefLocationSet,
java.util.SortedSet<Location> doomedLocations,
ValueNumberDataflow vna,
ValueNumber refValue,
BugAnnotation variableAnnotation,
NullValueUnconditionalDeref deref,
boolean npeIfStatementCovered) |
void |
NoiseNullDeref.foundNullDeref(Location location,
ValueNumber valueNumber,
IsNullValue refValue,
ValueNumberFrame vnaFrame)
Deprecated.
|
void |
FindNullDeref.foundNullDeref(Location location,
ValueNumber valueNumber,
IsNullValue refValue,
ValueNumberFrame vnaFrame)
Deprecated.
|
void |
NoiseNullDeref.foundNullDeref(Location location,
ValueNumber valueNumber,
IsNullValue refValue,
ValueNumberFrame vnaFrame,
boolean isConsistent) |
void |
FindNullDeref.foundNullDeref(Location location,
ValueNumber valueNumber,
IsNullValue refValue,
ValueNumberFrame vnaFrame,
boolean isConsistent) |
boolean |
BuildUnconditionalParamDerefDatabase.isCaught(ClassContext classContext,
org.apache.bcel.classfile.Method method,
UnconditionalValueDerefSet entryFact,
ValueNumber paramVN) |
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.