mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-02-22 23:22:25 +00:00
Re-replace functions after loading a savestate.
Might need to clear before saving too... anyway, this makes testing a bit easier for certain areas. Also, correctly decrease downcount on x86.
This commit is contained in:
parent
d67f91d899
commit
dde2f3ade6
@ -440,6 +440,10 @@ void __KernelModuleDoState(PointerWrap &p)
|
||||
if (s >= 2) {
|
||||
p.Do(loadedModules);
|
||||
}
|
||||
|
||||
if (g_Config.bFuncHashMap) {
|
||||
MIPSAnalyst::ReplaceFunctions();
|
||||
}
|
||||
}
|
||||
|
||||
void __KernelModuleShutdown()
|
||||
|
@ -375,8 +375,6 @@ skip:
|
||||
return furthestJumpbackAddr;
|
||||
}
|
||||
|
||||
void ReplaceFunctions();
|
||||
|
||||
void ScanForFunctions(u32 startAddr, u32 endAddr, bool insertSymbols) {
|
||||
AnalyzedFunction currentFunction = {startAddr};
|
||||
|
||||
|
@ -111,7 +111,7 @@ namespace MIPSAnalyst
|
||||
void StoreHashMap(std::string filename = "");
|
||||
|
||||
const char *LookupHash(u64 hash, int funcSize);
|
||||
void ReplaceFunctions(const ReplacementTableEntry *e, int numEntries);
|
||||
void ReplaceFunctions();
|
||||
|
||||
void UpdateHashMap();
|
||||
void ApplyHashMap();
|
||||
|
@ -491,8 +491,8 @@ void Jit::Comp_ReplacementFunc(MIPSOpcode op)
|
||||
// we can emit.
|
||||
|
||||
MOV(32, R(ECX), M(¤tMIPS->r[MIPS_REG_RA]));
|
||||
SUB(32, M(¤tMIPS->downcount - 1), R(EAX));
|
||||
js.downcountAmount = 1; // we just subtracted most of it
|
||||
SUB(32, M(¤tMIPS->downcount), R(EAX));
|
||||
js.downcountAmount = 0; // we just subtracted most of it
|
||||
WriteExitDestInReg(ECX);
|
||||
|
||||
js.compiling = false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user