Don't create Host objects except in headless/unittest

This commit is contained in:
Henrik Rydgård 2023-03-25 10:47:01 +01:00
parent 7d0eac730f
commit d586ec0d5e
34 changed files with 0 additions and 43 deletions

View File

@ -34,7 +34,6 @@
#include "Common/Log.h"
#include "Core/Core.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
#include "Core/SaveState.h"
#include "Core/System.h"

View File

@ -20,7 +20,6 @@
#include "Core/Debugger/WebSocket/GameSubscriber.h"
#include "Core/Debugger/WebSocket/WebSocketUtils.h"
#include "Core/ELF/ParamSFO.h"
#include "Core/Host.h"
#include "Core/System.h"
DebuggerSubscriber *WebSocketGameInit(DebuggerEventHandlerMap &map) {

View File

@ -28,7 +28,6 @@
#include "Core/Config.h"
#include "Core/Core.h"
#include "Core/CoreTiming.h"
#include "Core/Host.h"
#include "Core/MemMapHelpers.h"
#include "Core/Reporting.h"
#include "Core/System.h"

View File

@ -31,7 +31,6 @@
#include "Core/Config.h"
#include "Core/CoreTiming.h"
#include "Core/Host.h"
#include "Core/MemMapHelpers.h"
#include "Core/Reporting.h"
#include "Core/System.h"

View File

@ -64,7 +64,6 @@
#include "Common/TimeUtil.h"
#include "Core/Config.h"
#include "Core/Core.h"
#include "Core/Host.h"
#include "Core/HLE/sceKernelInterrupt.h"
#include "Core/HLE/sceKernelThread.h"
#include "Core/HLE/sceKernelMemory.h"

View File

@ -19,7 +19,6 @@
#include "Common/Serialize/SerializeFuncs.h"
#include "Common/Data/Collections/FixedSizeQueue.h"
#include "Core/MIPS/MIPS.h"
#include "Core/Host.h"
#include "Core/CoreTiming.h"
#include "Core/HLE/HLE.h"
#include "Core/HLE/FunctionWrappers.h"

View File

@ -37,7 +37,6 @@
#include "Core/Config.h"
#include "Core/CoreTiming.h"
#include "Core/CoreParameter.h"
#include "Core/Host.h"
#include "Core/Reporting.h"
#include "Core/Core.h"
#include "Core/System.h"

View File

@ -24,7 +24,6 @@
#include "Core/Loaders.h"
#include "Core/MemMap.h"
#include "Core/System.h"
#include "Core/Host.h"
#include "Core/CoreTiming.h"
#include "Core/Reporting.h"
#include "Core/MIPS/MIPS.h"

View File

@ -24,7 +24,6 @@
#include "Core/Debugger/Breakpoints.h"
#include "Core/HLE/HLE.h"
#include "Core/HLE/ReplaceTables.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
#include "Core/MIPS/MIPS.h"
#include "Core/MIPS/MIPSTables.h"

View File

@ -18,7 +18,6 @@
#include "Core/MIPS/MIPS.h"
#include "Core/MIPS/MIPSTables.h"
#include "Core/MIPS/MIPSCodeUtils.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
namespace MIPSCodeUtils

View File

@ -25,7 +25,6 @@
#include "Common/CommonTypes.h"
#include "Core/Config.h"
#include "Core/Core.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
#include "Core/MIPS/MIPS.h"
#include "Core/MIPS/MIPSCodeUtils.h"

View File

@ -26,7 +26,6 @@
#include "Core/Reporting.h"
#include "Core/HLE/HLE.h"
#include "Core/HLE/HLETables.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
#include "Core/MIPS/MIPS.h"

View File

@ -43,7 +43,6 @@
#include "RegCache.h"
#include "Jit.h"
#include "Core/Host.h"
#include "Core/Debugger/Breakpoints.h"
namespace MIPSComp

View File

@ -22,7 +22,6 @@
#include "Core/MemMap.h"
#include "Core/Config.h"
#include "Core/ConfigValues.h"
#include "Core/Host.h"
#include "Core/MIPS/MIPS.h"

View File

@ -35,7 +35,6 @@
#include "Core/Config.h"
#include "Core/Core.h"
#include "Core/CoreTiming.h"
#include "Core/Host.h"
#include "Core/Screenshot.h"
#include "Core/System.h"
#include "Core/FileSystems/MetaFileSystem.h"

View File

@ -49,7 +49,6 @@
#include "Core/MIPS/MIPSAnalyst.h"
#include "Core/MIPS/MIPSVFPUUtils.h"
#include "Core/Debugger/SymbolMap.h"
#include "Core/Host.h"
#include "Core/System.h"
#include "Core/HLE/HLE.h"
#include "Core/HLE/Plugins.h"

View File

@ -33,7 +33,6 @@
#include "Core/Config.h"
#include "Common/BitScan.h"
#include "Core/HDRemaster.h"
#include "Core/Host.h"
#include "GPU/ge_constants.h"
#include "GPU/GPUState.h"
#include "GPU/GPUInterface.h"

View File

@ -37,7 +37,6 @@
#include "Core/Core.h"
#include "Core/CoreParameter.h"
#include "Core/Debugger/MemBlockInfo.h"
#include "Core/Host.h"
#include "Core/MIPS/MIPS.h"
#include "GPU/Common/DrawEngineCommon.h"
#include "GPU/Common/FramebufferManagerCommon.h"

View File

@ -29,7 +29,6 @@
#include "Common/TimeUtil.h"
#include "Core/Config.h"
#include "Core/ConfigValues.h"
#include "Core/Host.h"
#include "Core/System.h"
#include "Core/HW/Display.h"
#include "GPU/Common/PostShader.h"

View File

@ -43,7 +43,6 @@
#include "Common/Thread/ThreadManager.h"
#include "Common/TimeUtil.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "Core/System.h"
#include "Core/ThreadPools.h"
#include "Core/ELF/ParamSFO.h"

View File

@ -35,7 +35,6 @@
#include "GPU/Common/FramebufferManagerCommon.h"
#include "GPU/Common/TextureDecoder.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "ext/xxhash.h"
#include "Common/Math/math_util.h"

View File

@ -25,7 +25,6 @@
#include "Core/Debugger/Breakpoints.h"
#include "Core/MemMapHelpers.h"
#include "Core/MIPS/MIPS.h"
#include "Core/Host.h"
#include "Core/Config.h"
#include "Core/ConfigValues.h"
#include "Core/System.h"

View File

@ -38,7 +38,6 @@
#include "Common/StringUtils.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "GPU/Math3D.h"
#include "GPU/GPUState.h"
#include "GPU/ge_constants.h"

View File

@ -31,7 +31,6 @@
#include "GPU/Common/FramebufferManagerCommon.h"
#include "GPU/Common/TextureDecoder.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "ext/xxhash.h"
#include "Common/Math/math_util.h"

View File

@ -28,7 +28,6 @@
#include "Core/Config.h"
#include "Core/Debugger/Breakpoints.h"
#include "Core/MemMapHelpers.h"
#include "Core/Host.h"
#include "Core/Config.h"
#include "Core/Reporting.h"
#include "Core/System.h"

View File

@ -42,7 +42,6 @@
#include "Common/File/FileUtil.h"
#include "Common/TimeUtil.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "Core/System.h"
#include "GPU/Math3D.h"
#include "GPU/GPUState.h"

View File

@ -29,7 +29,6 @@
#include "Common/TimeUtil.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
#include "GPU/ge_constants.h"
#include "GPU/GPUState.h"

View File

@ -29,7 +29,6 @@
#include "Core/CoreTiming.h"
#include "Core/Debugger/MemBlockInfo.h"
#include "Core/MemMap.h"
#include "Core/Host.h"
#include "Core/Reporting.h"
#include "Core/HLE/HLE.h"
#include "Core/HLE/sceKernelMemory.h"

View File

@ -36,7 +36,6 @@
#include "Common/GPU/Vulkan/VulkanMemory.h"
#include "Core/Config.h"
#include "Core/Host.h"
#include "Core/MemMap.h"
#include "Core/System.h"

View File

@ -863,9 +863,6 @@ int main(int argc, char *argv[])
g_mainWindow = new MainWindow(nullptr, g_Config.UseFullScreen());
g_mainWindow->show();
if (!host) {
host = new Host();
}
// TODO: Support other backends than GL, like Vulkan, in the Qt backend.
g_Config.iGPUBackend = (int)GPUBackend::OPENGL;

View File

@ -448,12 +448,6 @@ void NativeInit(int argc, const char *argv[], const char *savegame_dir, const ch
#endif
g_VFS.Register("", new DirectoryReader(Path(savegame_dir)));
#if (defined(MOBILE_DEVICE) || !defined(USING_QT_UI)) && !PPSSPP_PLATFORM(UWP)
if (host == nullptr) {
host = new Host();
}
#endif
g_Config.defaultCurrentDirectory = Path("/");
g_Config.internalDataDirectory = Path(savegame_dir);

View File

@ -26,7 +26,6 @@
#include "Common/System/NativeApp.h"
#include "Common/System/Request.h"
#include "Core/Host.h"
#include "Core/System.h"
#include "Core/Loaders.h"
#include "Core/Config.h"
@ -67,7 +66,6 @@ PPSSPP_UWPMain::PPSSPP_UWPMain(App ^app, const std::shared_ptr<DX::DeviceResourc
net::Init();
host = new Host();
// Register to be notified if the Device is lost or recreated
m_deviceResources->RegisterDeviceNotify(this);

View File

@ -155,8 +155,6 @@ void MainThreadFunc() {
// We'll start up a separate thread we'll call Emu
SetCurrentThreadName(useEmuThread ? "Render" : "Emu");
host = new Host();
SetConsolePosition();
System_SetWindowTitle("");

View File

@ -92,7 +92,6 @@ struct JNIEnv {};
#include "Core/System.h"
#include "Core/HLE/sceUsbCam.h"
#include "Core/HLE/sceUsbGps.h"
#include "Core/Host.h"
#include "Common/CPUDetect.h"
#include "Common/Log.h"
#include "UI/GameInfoCache.h"