mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-12 14:00:27 +02:00
Don't lock armjit memory before aligning code.
This commit is contained in:
1 parent
710368d143
commit
ead6983ad2
2 files changed
+4
-5
No files matched your search
@@ -190,9 +190,7 @@ void ARMXEmitter::SetCodePtr(u8 *ptr)
|
||||
{
|
||||
code = ptr;
|
||||
startcode = code;
|
||||
#ifdef IOS
|
||||
lastCacheFlushEnd = ptr;
|
||||
#endif
|
||||
}
|
||||
|
||||
const u8 *ARMXEmitter::GetCodePtr() const
|
||||
@@ -236,6 +234,7 @@ void ARMXEmitter::FlushIcacheSection(u8 *start, u8 *end)
|
||||
#elif defined(BLACKBERRY)
|
||||
msync(start, end - start, MS_SYNC | MS_INVALIDATE_ICACHE);
|
||||
#elif defined(IOS)
|
||||
// Header file says this is equivalent to: sys_icache_invalidate(start, end - start);
|
||||
sys_cache_control(kCacheFunctionPrepareForExecution, start, end - start);
|
||||
#elif !defined(_WIN32)
|
||||
__builtin___clear_cache(start, end);
|
||||
|
||||
@@ -265,9 +265,6 @@ const u8 *Jit::DoJit(u32 em_address, ArmJitBlock *b)
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#ifdef IOS
|
||||
WriteProtect();
|
||||
#endif
|
||||
|
||||
b->codeSize = GetCodePtr() - b->normalEntry;
|
||||
|
||||
@@ -278,6 +275,9 @@ const u8 *Jit::DoJit(u32 em_address, ArmJitBlock *b)
|
||||
}
|
||||
#endif
|
||||
AlignCode16();
|
||||
#ifdef IOS
|
||||
WriteProtect();
|
||||
#endif
|
||||
|
||||
// Don't forget to zap the instruction cache!
|
||||
FlushIcache();
|
||||
|
||||
Reference in new issue
Block a user