Dolphin, the GameCube and Wii emulator - Forums

Full Version: Some ideas for cpu optimizations
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

TemplarGR

Cpu emulation part of Dolphin could definitely see some optimizations. A modern gpu could play all dolphin games at high resolutions with 16x AF, but the cpu part is slow. Even my Q6600 at 3ghz with 1000mhz Dual DDR2 ram is slow with this.

I am a programmer, although i have never worked on anything similar to emulation and i don't know how Dolphin works currently, so what i say may pretty much be crap. But i would like to say it anyway.

I believe that developers should continue their efforts to use more cores. I know that it seems difficult, but it is definitely possible. For example, why not dedicating a thread to optimize the cpu code?

You have one thread to recompile the cpu and one for the video. But the JITIL recompiler could use another thread for the intermediate optimizations. I know that there are issues of synchronization and such, but it could be possible.

Another idea, could be speculative recompiling on another thread. Recompilation of possible future code on a separate thread. Or two. Use these extra cores we have, even if the results go to waste, is better than not using them at all.

Quote:I believe that developers should continue their efforts to use more cores. I know that it seems difficult, but it is definitely possible. For example, why not dedicating a thread to optimize the cpu code?

You have one thread to recompile the cpu and one for the video. But the JITIL recompiler could use another thread for the intermediate optimizations. I know that there are issues of synchronization and such, but it could be possible.

The amount of speedup gained from this would be EXTREMELY small. It would be a waste of time.

Quote:speculative recompiling on another thread

How on earth would you even do that! Not to mention dolphin already does jit caching in advance which achieves the same thing in a better way.

Only two known ways to further multi-thread dolphin that would actually make an impact exist. DSPLLE on a separate thread, which they tried and it failed miserably. And a parallel recompiler which they are working on but it will be many months before it gets implemented and probably close to a year before it's stable and reliable.