public static PcodeExecutor<Pair<byte[], TraceMemoryState>> buildByteWithStateExecutor(
			TracePlatform platform, long snap, TraceThread thread, int frame) {
		DirectBytesTracePcodeExecutorState state =
			new DirectBytesTracePcodeExecutorState(platform, snap, thread, frame);
		PcodeExecutorState<Pair<byte[], TraceMemoryState>> paired = state.withMemoryState();
		Language language = platform.getLanguage();
		if (!(language instanceof SleighLanguage)) {
			throw new IllegalArgumentException("TracePlatform must use a Sleigh language");
		}
		return new PcodeExecutor<>((SleighLanguage) language, new PairedPcodeArithmetic<>(
			BytesPcodeArithmetic.forLanguage(language), TraceMemoryStatePcodeArithmetic.INSTANCE),
			paired, Reason.INSPECT);
	}
Build a p-code executor that operates directly on bytes and memory state of the given trace

<p>
This executor is most suitable for evaluating Sleigh expressions on a given trace snapshot,
when the client would also like to know if all variables involved are
{@link TraceMemoryState#KNOWN}.

@param platform the platform
@param snap the snap
@param thread the thread, required if register space is used
@param frame the frame, for when register space is used
@return the executor
Ghidra/Debug/Framework-TraceModeling/src/main/java/ghidra/pcode/exec/trace/TraceSleighUtils.java