private boolean resolveComputableFlow(Program program, Address location, TaskMonitor monitor)
			throws CancelledException {

		Register isaModeSwitchRegister = program.getRegister("ISAModeSwitch");
		Register isaModeRegister = program.getRegister("ISA_MODE");

		// get the basic block
		//
		// NOTE: Assumption, target address must be computable in single flow, or else isn't a thunk

		BasicBlockModel basicBlockModel = new BasicBlockModel(program);
		final CodeBlock jumpBlockAt =
			basicBlockModel.getFirstCodeBlockContaining(location, monitor);
		if (jumpBlockAt == null) {
			return false;
		}

		final AtomicInteger foundCount = new AtomicInteger(0);
		SymbolicPropogator prop = new SymbolicPropogator(program);

		// try to compute the thunk by flowing constants from the start of the block
		prop.flowConstants(jumpBlockAt.getFirstStartAddress(), jumpBlockAt,
			new ContextEvaluatorAdapter() {
				@Override
				public boolean evaluateReference(VarnodeContext context, Instruction instr,
						int pcodeop, Address address, int size, DataType dataType,
						RefType refType) {
					// go ahead and place the reference, since it is a constant.
					if (refType.isComputed() && refType.isFlow() &&
						program.getMemory().contains(address)) {
						propogateCodeMode(context, address);
						foundCount.incrementAndGet();
						return true;
					}
					return false;
				}

				@Override
				public boolean allowAccess(VarnodeContext context, Address addr) {
					return true;
				}

				private void propogateCodeMode(VarnodeContext context, Address addr) {
					// get CodeModeRegister and flow it to destination, if it is set here

					if (isaModeSwitchRegister == null) {
						return;
					}
					BigInteger value = context.getValue(isaModeSwitchRegister, false);
					if (value != null && program.getListing().getInstructionAt(addr) == null) {
						try {
							program.getProgramContext()
									.setValue(isaModeRegister, addr, addr, value);
						}
						catch (ContextChangeException e) {
							// ignore
						}
					}
				}
			}, false, monitor);

		// If added only one computed flow reference, then recovered a good thunk.

		return foundCount.get() == 1;
	}
resolve the flow destination by computing to a single value with a restriction to a single basic block.
  
@return single flow address, null if single flow can't be resolved
Ghidra/Features/Base/src/main/java/ghidra/app/cmd/function/CreateThunkFunctionCmd.java