mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-17 08:11:51 +00:00
Dealloc exec cache after sys_prx/overlay_unload_module
Must come before vm::dealloc of it.
This commit is contained in:
parent
3d6c211382
commit
3de885c7a6
@ -1036,6 +1036,12 @@ void ppu_unload_prx(const lv2_prx& prx)
|
||||
|
||||
for (auto& seg : prx.segs)
|
||||
{
|
||||
if (seg.flags & 1)
|
||||
{
|
||||
// Segment was considered executable thus needing to free exec data
|
||||
utils::memory_decommit(vm::g_exec_addr + size_t{seg.addr} * 2, size_t{seg.size} * 2);
|
||||
}
|
||||
|
||||
vm::dealloc(seg.addr, vm::main);
|
||||
}
|
||||
}
|
||||
|
@ -54,6 +54,11 @@ error_code sys_overlay_unload_module(u32 ovlmid)
|
||||
|
||||
for (auto& seg : _main->segs)
|
||||
{
|
||||
if (seg.flags & 1)
|
||||
{
|
||||
utils::memory_decommit(vm::g_exec_addr + size_t{seg.addr} * 2, size_t{seg.size} * 2);
|
||||
}
|
||||
|
||||
vm::dealloc(seg.addr);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user