@Override
	public AssemblyResolution solve(AbstractAssemblyResolutionFactory<?, ?> factory,
			ContextField cf, MaskedLong goal, Map<String, Long> vals, AssemblyResolvedPatterns cur,
			Set<SolverHint> hints, String description) {
		assert cf.minValue() == 0; // In case someone decides to do signedness there.
		if (!goal.isInRange(cf.maxValue(), cf.hasSignbit())) {
			return factory.newErrorBuilder()
					.error("Value " + goal + " is not valid for " + cf)
					.description(description)
					.build();
		}
		AssemblyPatternBlock block = AssemblyPatternBlock.fromContextField(cf, goal);
		return factory.contextOnly(block, description);
	}
Solves expressions of a context register field

<p>
Essentially, this just encodes the goal into the field, if it can be represented in the given
space and format. Otherwise, there is no solution.
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/plugin/assembler/sleigh/expr/ContextFieldSolver.java