.claude/skills/check-parity/SKILL.md
Check that aarch64 JIT interpreter functions match generic CPU behavior
npx skillsauth add sebastianbiallas/pearpc check-parityInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Run the interpreter parity check and analyze results. If an opcode name is given, show a side-by-side diff for that specific opcode.
Always run the stub audit first — this catches no-op stubs (the #1 bug source):
python3 scripts/debug/stub_audit.py $ARGUMENTS
If an opcode name was given, this shows a side-by-side generic vs JIT diff. If no arguments, it scans all functions and reports no-op stubs.
Run ./scripts/debug/check_interpreter_parity.sh
For any issues found:
For each GEN_INTERPRET warning, check the x86 JIT (src/cpu/cpu_jitc_x86/ppc_opc.cc) to see how it handles the same opcode. The x86 JIT is the reference for how gen_ functions should work.
GEN_INTERPRET CANNOT dispatch synchronous exceptions. The only correct approaches are:
tools
--- name: dump-printk description: Extract and display the Linux kernel printk ring buffer from a PearPC memory dump allowed-tools: Bash, Read argument-hint: [dump-file] [search-term] --- # Extract Kernel Printk Buffer Use `scripts/debug/memdump.py printk` to extract the printk ring buffer. ``` python3 scripts/debug/memdump.py printk $ARGUMENTS ``` If no arguments, use `memdump_jit.bin`. Report the last printk message, any Oops, and what boot stage was reached.
tools
--- name: compare-dumps description: Compare memory regions between generic and JIT memory dumps to find divergences allowed-tools: Bash, Read argument-hint: [subcommand] [args...] --- # Compare Memory Dumps Use `scripts/debug/memdump.py` subcommands: ``` # Read words at a PA (accepts kernel VA, auto-converts): python3 scripts/debug/memdump.py read memdump_jit.bin PA [count] # Diff two dumps at a PA: python3 scripts/debug/memdump.py diff memdump_generic.bin memdump_jit.bin PA [count] # Sear
testing
Analyze the JIT dispatch trace to diagnose boot stalls or crashes
tools
Analyze a kernel Oops from the printk buffer in a PearPC memory dump