Properly clear JIT cache on save states

This commit is contained in:
Chris Burgener
2016-01-19 19:29:19 -05:00
parent 5db10d83f7
commit a7a744d33c
6 changed files with 20 additions and 2 deletions

View File

@ -1014,3 +1014,11 @@ void EmuCodeBlock::JitClearCA()
{
MOV(8, PPCSTATE(xer_ca), Imm8(0));
}
void EmuCodeBlock::Clear()
{
registersInUseAtLoc.clear();
pcAtLoc.clear();
exceptionHandlerAtLoc.clear();
}

View File

@ -128,6 +128,7 @@ public:
void ConvertSingleToDouble(Gen::X64Reg dst, Gen::X64Reg src, bool src_is_gpr = false);
void ConvertDoubleToSingle(Gen::X64Reg dst, Gen::X64Reg src);
void SetFPRF(Gen::X64Reg xmm);
void Clear();
protected:
std::unordered_map<u8 *, BitSet32> registersInUseAtLoc;
std::unordered_map<u8 *, u32> pcAtLoc;