Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
what type of processor emulation does ppsspp use?
02-12-2016, 06:30 AM
Post: #4
RE: what type of processor emulation does ppsspp use?
I can't really help with the library decryption.

But, I can tell you some of them are kernel libraries and some are user libraries. Additionally, most of these are libraries that are shared (to some degree) across games - sometimes different versions (e.g. the mpeg libraries come in a few different variants.)

All of the libraries are dynamic, though, as far as I'm aware. They (like game binary) are relocated on load, and can dynamically link to each other - functions and variable references. Some games (like God Eater games, Metal Gear games, Yu Gi Oh games, and Valkyrie Profile off the top of my head) will load and unload modules for different sections of the game, dynamically. For example, I think one game even uses a different prx for each enemy or group thereof.

Note that games can (and DO) also load files (or portions thereof) in directly, for "static libraries" that don't need relocating. It's just that prx files go through the firmware and get relocated.

Just think of it this way as far as static recompilation / self modifying code -

Let's say that I have mips code that looks like this:

lui a0, 0x4013
ori a0, a0, 0x3333
mtc1 f12, a0

That's basically the code for C:

float f = 2.3f;

On x86, it's going to look different. It might end up:

mov eax, 0x40133333
movd xmm0, eax

Now let's say that the game says, "the player has moved, so my constant should be 2.31 instead of 2.3 now." So it modifies the second instruction only, changing it to:

ori a0, a0, 0xD70A

How does that modify the Intel code? That's easy, you say, it translates to modifying the constant. But, how does it do this? You need a compiler to understand how the change in the mips code will change the different code generated by static recompilation. And my simple example above isn't the only case. It could even change which register the constant is loaded into.

-[Unknown]
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: what type of processor emulation does ppsspp use? - [Unknown] - 02-12-2016 06:30 AM

Forum Jump: