private boolean blockHasReferences(ReferenceManager referenceManager, CodeBlock block) {
		Address[] starts = block.getStartAddresses();
		for (int i = 0; i < starts.length; i++) {
			ReferenceIterator refIter = referenceManager.getReferencesTo(starts[i]);
			while (refIter.hasNext()) {
				Reference ref = refIter.next();
				if (ref.isMemoryReference()) {
					return true; // somebody is referencing this block start
				}
			}
		}
		return false;
	}
Selects subroutines that are not directly referenced. 
This is commonly referred to as DEAD code.
@param monitor a cancellable task monitor
@return address set containing the dead subroutines
@throws CancelledException
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/select/flow/SelectByFlowPlugin.java