pub fn roundtrip(
setup: &Setup,
at: i64,
to: i64,
extra: i64,
) -> Result<String, String>Expand description
Save states, proven complete (the reference’s scripts/state_roundtrip.py roundtrip):
power on, run to frame at plus extra instructions (so the save falls anywhere in a
frame, between two instructions), save, then build a second system the same way, load the
state into it, and run both to frame to. Every frame after the save must be the same on
both, by the gate’s own lines. A third run loads the state into a system that has run
elsewhere first (to frame at / 2); and the loaded system, saved at once, must give the
same bytes back. Ok says what was compared, Err what differed.