static class CheckCallSitesAndReturnInstructions {
}
private void checkCallSitesAndReturnInstructions() {
Profiler profiler = Global.getAnalysisCache().getProfiler();
profiler.start(CheckCallSitesAndReturnInstructions.class);
try {
ConstantPoolGen cpg = classContext.getConstantPoolGen();
TypeDataflow typeDataflow = classContext.getTypeDataflow(method);
for (Iterator<Location> i = classContext.getCFG(method).locationIterator(); i.hasNext();) {
Location location = i.next();
Instruction ins = location.getHandle().getInstruction();
try {
ValueNumberFrame vnaFrame = classContext.getValueNumberDataflow(method).getFactAtLocation(location);
if (!vnaFrame.isValid()) {
continue;
}
if (ins instanceof InvokeInstruction) {
examineCallSite(location, cpg, typeDataflow);
} else if (methodAnnotation == NullnessAnnotation.NONNULL && ins.getOpcode() == Constants.ARETURN) {
examineReturnInstruction(location);
} else if (ins instanceof PUTFIELD) {
examinePutfieldInstruction(location, (PUTFIELD) ins, cpg);
}
} catch (ClassNotFoundException e) {
bugReporter.reportMissingClass(e);
}
}
} catch (CheckedAnalysisException e) {
AnalysisContext.logError("error:", e);
} finally {
profiler.end(CheckCallSitesAndReturnInstructions.class);
}
}