gulrak/cadmium

Add a feature to switch to an easy PRNG with set-able seed for trace log generation.

FormerlyZeroCool opened this issue · 2 comments

Feature will be used for comparing trace logs to live machine state being debugged.

Adding a few new command-line options:

  • --random-gen <engine> that can override the original random generator with rand-lcg selecting a classical LCG (state = ((state * 1103515245) + 12345) & 0x7FFFFFFF; return (uint8_t)(state>>16);) and counting a generator that simply returns the state and increments it
  • --random-seed that set the initial state for the two generators, defaulting to 12345
  • --screen-dump that reenables the now by default disabled (but repaired) screen dump at the end of a trace run
    Also the auto-stop feature works in the trace run now, if a self-jump is detected and the selected CHIP-8 variant is written before the trace run to document the behavior the trace was run with.
gulrak commented

Released in v1.1.8