JIT: get rid of useless code in JitCache.cpp.
This commit is contained in:
parent
440246a190
commit
6bb08de8a0
|
@ -116,24 +116,6 @@ using namespace Gen;
|
|||
memset(blockCodePointers, 0, sizeof(u8*)*MAX_NUM_BLOCKS);
|
||||
}
|
||||
|
||||
void JitBaseBlockCache::ClearSafe()
|
||||
{
|
||||
memset(iCache, JIT_ICACHE_INVALID_BYTE, JIT_ICACHE_SIZE);
|
||||
memset(iCacheEx, JIT_ICACHE_INVALID_BYTE, JIT_ICACHEEX_SIZE);
|
||||
memset(iCacheVMEM, JIT_ICACHE_INVALID_BYTE, JIT_ICACHE_SIZE);
|
||||
}
|
||||
|
||||
/*void JitBaseBlockCache::DestroyBlocksWithFlag(BlockFlag death_flag)
|
||||
{
|
||||
for (int i = 0; i < num_blocks; i++)
|
||||
{
|
||||
if (blocks[i].flags & death_flag)
|
||||
{
|
||||
DestroyBlock(i, false);
|
||||
}
|
||||
}
|
||||
}*/
|
||||
|
||||
void JitBaseBlockCache::Reset()
|
||||
{
|
||||
Shutdown();
|
||||
|
|
|
@ -96,7 +96,6 @@ public:
|
|||
void FinalizeBlock(int block_num, bool block_link, const u8 *code_ptr);
|
||||
|
||||
void Clear();
|
||||
void ClearSafe();
|
||||
void Init();
|
||||
void Shutdown();
|
||||
void Reset();
|
||||
|
@ -122,9 +121,6 @@ public:
|
|||
// DOES NOT WORK CORRECTLY WITH INLINING
|
||||
void InvalidateICache(u32 address, const u32 length);
|
||||
void DestroyBlock(int block_num, bool invalidate);
|
||||
|
||||
// Not currently used
|
||||
//void DestroyBlocksWithFlag(BlockFlag death_flag);
|
||||
};
|
||||
|
||||
// x86 BlockCache
|
||||
|
|
|
@ -39,7 +39,7 @@ namespace JitInterface
|
|||
void DoState(PointerWrap &p)
|
||||
{
|
||||
if (jit && p.GetMode() == PointerWrap::MODE_READ)
|
||||
jit->GetBlockCache()->ClearSafe();
|
||||
jit->GetBlockCache()->Clear();
|
||||
}
|
||||
CPUCoreBase *InitJitCore(int core)
|
||||
{
|
||||
|
@ -199,8 +199,12 @@ namespace JitInterface
|
|||
}
|
||||
void ClearSafe()
|
||||
{
|
||||
// This clear is "safe" in the sense that it's okay to run from
|
||||
// inside a JIT'ed block: it clears the instruction cache, but not
|
||||
// the JIT'ed code.
|
||||
// TODO: There's probably a better way to handle this situation.
|
||||
if (jit)
|
||||
jit->GetBlockCache()->ClearSafe();
|
||||
jit->GetBlockCache()->Clear();
|
||||
}
|
||||
|
||||
void InvalidateICache(u32 address, u32 size)
|
||||
|
|
Loading…
Reference in New Issue