Merge pull request #11840 from krnlyng/blr_and_block_map_fixes

Blr and block map fixes
This commit is contained in:
Admiral H. Curtiss 2023-05-23 23:09:21 +02:00 committed by GitHub
commit 532c6a8485
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 1 deletions

View File

@ -276,6 +276,8 @@ void Jit64::Init()
m_const_pool.Init(AllocChildCodeSpace(constpool_size), constpool_size);
ResetCodePtr();
InitBLROptimization();
m_stack_guard = nullptr;
blocks.Init();

View File

@ -66,6 +66,8 @@ void JitArm64::Init()
code_block.m_gpa = &js.gpa;
code_block.m_fpa = &js.fpa;
InitBLROptimization();
GenerateAsm();
ResetFreeMemoryRanges();

View File

@ -146,7 +146,7 @@ void JitArm64::GenerateAsm()
ORR(pc_masked, ARM64Reg::WZR,
LogicalImm(JitBaseBlockCache::FAST_BLOCK_MAP_FALLBACK_MASK << 3, 32));
AND(pc_masked, pc_masked, DISPATCHER_PC, ArithOption(DISPATCHER_PC, ShiftType::LSL, 1));
MOVP2R(cache_base, GetBlockCache()->GetFastBlockMap());
MOVP2R(cache_base, GetBlockCache()->GetFastBlockMapFallback());
LDR(block, cache_base, EncodeRegTo64(pc_masked));
FixupBranch not_found = CBZ(block);