Skip to content

Commit

Permalink
PPU Precompilation Fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
elad335 committed Aug 6, 2023
1 parent 343ba87 commit f43208d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion rpcs3/Emu/Cell/PPUThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3573,7 +3573,7 @@ extern void ppu_precompile(std::vector<std::string>& dir_queue, std::vector<ppu_

if (std::memcpy(main_module.sha1, _main.sha1, sizeof(_main.sha1)) == 0)
{
continue;
break;
}

if (!_main.analyse(0, _main.elf_entry, _main.seg0_code_end, _main.applied_pathes, [](){ return Emu.IsStopped(); }))
Expand All @@ -3584,6 +3584,8 @@ extern void ppu_precompile(std::vector<std::string>& dir_queue, std::vector<ppu_
obj.clear(), src.close(); // Clear decrypted file and elf object memory

ppu_initialize(_main);

_main.cache.clear(); // Make ppu_finalize work
ppu_finalize(_main);
_main = {};
break;
Expand All @@ -3600,6 +3602,7 @@ extern void ppu_precompile(std::vector<std::string>& dir_queue, std::vector<ppu_
}

g_fxo->get<main_ppu_module>() = std::move(main_module);
Emu.ConfigurePPUCache();
});

exec_worker();
Expand Down

0 comments on commit f43208d

Please sign in to comment.