libretro / arduous

GNU General Public License v3.0
11 stars 6 forks source link

[Dingux-Miyoo_arm32] Optimization request #2

Open Apaczer opened 2 years ago

Apaczer commented 2 years ago

First of all, much thank you from Miyoo's community for adding support on these devices (which was unexpected thing!). Arduous core properly emulates *.hex files on my handheld (Powkiddy V90), albeit it struglle to reach anything above 18fps. Miyoo's 1'st gen. SOC can safely run with 798MHz value set on CPU, so it's strange that it has that much trouble with emulating Arduboy 8-bit chipset.

Is there a room for any optimization on that core? I hope I don't sound too demanding, just though you might want to know how it performs on other platforms. Below some pics with different scaling options for archive purpouses! Powkiddy_v90-Miyoo_arm32

phcoder commented 2 years ago

The problem isn't limited to miyoo. It looks like simavr is pretty resource intensive. Can you try running bomberboy? I used it as a benchmark and results I got:

Missing benchmark:

Platforms not enabled yet: PS2, psl1ght, ngc, wii, WiiU.

phcoder commented 2 years ago

I didn't try to profile the core to know what slows it down

jmaroeder commented 2 years ago

Yeah, I have a very strong suspicion that this is due to the dependence on simavr. I’ve spent a few hours here and there investigating to see if there’s some simple way to strip down simavr further to get some extra performance out of it, but that didn’t seem to lead anywhere.

I suspect we’re going to need to write the CPU/peripheral emulation ourselves to get it to be more performant. I began an attempt at this task, but I was also using it as an excuse to learn Rust and did not get to handling the timers or other peripherals, just the main instruction set.

Apaczer commented 2 years ago

Benchmark for Bomberboy-1.0:

Yes, more beefy platfroms (PC/Android) runs just fine this core, but would love to see it running full speed on these smaller handheld's screens (as it was ment to be used that way)!

phcoder commented 2 years ago

WiiU is fullspeed.

phcoder commented 2 years ago

PS2 gives 19.5 FPS

phcoder commented 2 years ago

Uzem emulators uses an own avr core and clocks in 8 fps. So it looks like we might need a JIT for low-end platforms. Of course we would need first to profile as right of now we don't even know which part is slow

phcoder commented 2 years ago

RS90 gives 4.5 FPS

schmurtzm commented 1 year ago

Miyoo mini gives 25 FPS on bomberboy with last build (aed5050). And about 10 FPS on omega horizon. If someone find somehing to improve it it's very welcome ;)