private static void updateVTSourceAndDestinationLengths(VTMatchInfo matchInfo) {
		VTSession session = matchInfo.getMatchSet().getSession();
		Program sourceProgram = session.getSourceProgram();
		Program destinationProgram = session.getDestinationProgram();

		Address sourceAddress = matchInfo.getSourceAddress();
		Address destinationAddress = matchInfo.getDestinationAddress();

		if (matchInfo.getAssociationType() == VTAssociationType.FUNCTION) {
			Function sourceFunction =
				sourceProgram.getFunctionManager().getFunctionAt(sourceAddress);
			Function destFunction =
				destinationProgram.getFunctionManager().getFunctionAt(destinationAddress);
			if (sourceFunction != null) {
				matchInfo.setSourceLength((int) sourceFunction.getBody().getNumAddresses());
			}
			if (destFunction != null) {
				matchInfo.setDestinationLength((int) destFunction.getBody().getNumAddresses());
			}
		}
		else {
			CodeUnit cu = sourceProgram.getListing().getCodeUnitContaining(sourceAddress);
			if (cu != null) {
				matchInfo.setSourceLength(cu.getLength());
			}
			cu = destinationProgram.getListing().getCodeUnitContaining(destinationAddress);
			if (cu != null) {
				matchInfo.setDestinationLength(cu.getLength());
			}
		}
	}
Updates the length values for the source and destination functions or data in the
VTMatchInfo object
Ghidra/Features/VersionTracking/src/main/java/ghidra/feature/vt/gui/util/ImpliedMatchUtils.java