Classics Revisited
Posted on 2010-10-12 20:39:14
I've been busy these past months with getting my emulator back in shape. I also wanted to test the performance of my new JIT compilation engine, so I decided to try two games that, in my opinion, have an interesting load on the CPU while using basic PS2 hardware.


Screenshot #000212 Screenshot #000213


Well, these choices were pretty obvious. Quake was one of the first games that I tried to support in the emulator... I also saw that there was a Doom port for the PS2, so I decided to try it out. While it didn't take too much work to make these run, I'm kinda disappointed by the performance of both games: Quake runs as fast as with the old compiler engine and Doom doesn't work very fast either.

So, what I'm realizing now is that it's another case of premature optimization. I thought the generated code would be a lot faster and that it would make most games run at interesting speeds, but it's really not the case. But, on the other side, the new JIT compiler framework is a lot cleaner and generates cleaner code too. For example, I wasn't able to target the x64 processor properly beforehand, while this time, I'm able do it without any problem.

That's what I'm going to work on next. I don't think there's going to be a big difference between x86 and x64, but it's worth trying. I also thought of other solutions that could make a big speed difference, but I'm still not sure if I'm going to implement them yet.