System: Shut down GPU backend before other components

Prevents a rare crash on shutdown if OSD stats were enabled.
This commit is contained in:
Stenzek 2025-06-03 19:06:15 +10:00
parent 7fde697118
commit 5b40d7902a
No known key found for this signature in database

View File

@ -1960,6 +1960,8 @@ void System::DestroySystem()
FreeMemoryStateStorage(true, true, false);
GPUThread::DestroyGPUBackend();
Cheats::UnloadAll();
PCDrv::Shutdown();
SIO::Shutdown();
@ -1978,7 +1980,6 @@ void System::DestroySystem()
TimingEvents::Shutdown();
Achievements::OnSystemDestroyed();
ClearRunningGame();
GPUThread::DestroyGPUBackend();
s_state.taints = 0;
s_state.bios_hash = {};