Files
psxrecomp/tools/read_table.py
Matthew Stanley 101fd2e1a9 feat: 46 GTE library seeds + DuckStation oracle SW readback + debug tooling
Add 46 seeds for the libgte helper functions at BFC34E00-BFC36D00.
These wrap individual GTE operations (RTPS, RTPT, NCLIP, MVMVA, etc.)
and were never discovered because they're called via JALR function
pointers, not direct JAL. Coverage: 52→114 gte_execute, 166→429
LWC2/SWC2. Emitted functions: 1178→1214. Seeds: 960→1006.

Fix DuckStation oracle VRAM readback by setting
UseSoftwareRendererForReadbacks=true in settings.ini.

Add debug/analysis tools: GTE audit, VRAM stitching, rapid polling,
GPU info, divergence comparison, jump table dumps.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-24 00:29:06 -07:00

19 lines
549 B
Python

#!/usr/bin/env python3
import socket, json, struct, sys
port = int(sys.argv[1])
addr = int(sys.argv[2], 16)
count = int(sys.argv[3]) if len(sys.argv) > 3 else 4
s = socket.create_connection(('localhost', port), timeout=5)
s.sendall(f'{{"cmd":"read_ram","addr":"0x{addr:08X}","len":{count*4}}}\n'.encode())
data = b''
while b'\n' not in data:
data += s.recv(4096)
s.close()
d = json.loads(data.split(b'\n')[0])
raw = bytes.fromhex(d['hex'])
for i in range(count):
v = struct.unpack_from('<I', raw, i * 4)[0]
print(f' [{i}] 0x{v:08X}')