if (!frame.isValid())  return;
			public void visitLocation(Location location) {				try {					BasicBlock basicBlock = location.getBasicBlock();					InstructionHandle handle = location.getHandle();					Instruction ins = handle.getInstruction();					if (!(ins instanceof INVOKEVIRTUAL))						return;					INVOKEVIRTUAL inv = (INVOKEVIRTUAL) ins;					String methodName = inv.getName(cpg);					String methodSig = inv.getSignature(cpg);					if (Hierarchy.isMonitorWait(methodName, methodSig) || Hierarchy.isMonitorNotify(methodName, methodSig)) {						int numConsumed = inv.consumeStack(cpg);						if (numConsumed == Constants.UNPREDICTABLE)							throw new AnalysisException("Unpredictable stack consumption", methodGen, handle);						ValueNumberFrame frame = vnaDataflow.getFactAtLocation(location);						if (frame.getStackDepth() - numConsumed < 0)							throw new AnalysisException("Stack underflow", methodGen, handle);						ValueNumber ref = frame.getValue(frame.getNumSlots() - numConsumed);						LockSet lockSet = dataflow.getFactAtLocation(location);						int lockCount = lockSet.getLockCount(ref.getNumber());						if (lockCount == 0) {							String sourceFile = classContext.getJavaClass().getSourceFileName();							String type = methodName.equals("wait")								? "MWN_MISMATCHED_WAIT"								: "MWN_MISMATCHED_NOTIFY";							bugReporter.reportBug(new BugInstance(type, NORMAL_PRIORITY)								.addClassAndMethod(methodGen, sourceFile)								.addSourceLine(methodGen, sourceFile, handle)							);						}					}				} catch (DataflowAnalysisException e) {					throw new AnalysisException("FindMismatchedWaitOrNotify: caught exception " + e.toString(), e);				}			}