Fix ppu_execute<Func> for HLE functions

This commit is contained in:
Eladash 2020-10-16 21:09:32 +03:00 committed by Ivan
parent 5185ddb8b5
commit 953663e00b
1 changed files with 3 additions and 0 deletions

View File

@ -530,6 +530,9 @@ static auto ppu_load_exports(ppu_linkage_info* link, u32 exports_start, u32 expo
const u32 _entry = vm::read32(faddr); const u32 _entry = vm::read32(faddr);
const u32 target = ppu_function_manager::addr + 8 * _sf->index; const u32 target = ppu_function_manager::addr + 8 * _sf->index;
// Set exported function
flink.export_addr = target;
if ((target <= _entry && _entry - target <= 0x2000000) || (target > _entry && target - _entry < 0x2000000)) if ((target <= _entry && _entry - target <= 0x2000000) || (target > _entry && target - _entry < 0x2000000))
{ {
// Use relative branch // Use relative branch