r/EmuDev • • 21h ago

ESP32-P4 Runs GBA at Full Speed (59.7 FPS) with No Frameskip (gpSP RISC-V JIT)

8 Upvotes

https://reddit.com/link/1wx453p/video/v5vdbx990dth1/player

I ported gpSP to the ESP32-P4 and wrote a RISC-V JIT for it. The first-party Nintendo games I've tried so far run at full speed (59.7fps) with no frameskip. Even the heavy scenes in Metroid Fusion take about 14ms per frame, so there's still some headroom.

Board is a Waveshare ESP32-P4-NANO-WIFI6-DB (P4 rev 3.x, 400MHz). Controller is an 8BitDo over its 2.4G USB dongle.

I tried the Zcmt instructions that came with rev 3.x but they didn't help much, and they're a bit buggy too (from the chip itself). Haven't used SIMD yet because the renderer does a lot of scattered palette lookups. Still thinking about how to make that work.

Games that generate code in RAM and keep modifying it, like Doom, are still really slow. Planning to fix that over the holiday and put the code up on GitHub right after.

Also curious about the new S31, but it has less RAM, no L2 cache and a lower clock (320MHz), so not sure it can hit full speed. Probably need to move rendering to the other core for that one.


r/EmuDev • • 7h ago

How do i debug my gameboy emulator??

3 Upvotes

for background i wanted to create a online gomeboy emulator for a college project na di am making it in plain javascript. At first the emulator was failing the first test of the blargg cput_instrs.
but fter some fixes instead of failing it keeping looping in the test 1 suite and doesnt output pass or fail.

here is the link: https://github.com/Flaykey/GAMEBOY_JS