Move thread pool into true singleton

Thread pool needs to be stored in a single location for all of KiCad
otherwise each kiface will spin up its own pool of persistent threads
This commit is contained in:
Seth Hillbrand
2025-01-09 09:03:08 -08:00
parent 6c0e5508a9
commit 452e69de85
37 changed files with 147 additions and 67 deletions
+5 -1
View File
@@ -63,7 +63,7 @@
#include <settings/settings_manager.h>
#include <string_utils.h>
#include <systemdirsappend.h>
#include <core/thread_pool.h>
#include <thread_pool.h>
#include <trace_helpers.h>
#include <widgets/wx_splash.h>
@@ -472,6 +472,10 @@ bool PGM_BASE::InitPgm( bool aHeadless, bool aSkipPyInit, bool aIsUnitTest )
#ifdef KICAD_USE_SENTRY
sentryInit();
#endif
// Initialize the singleton instance
m_singleton.Init();
wxString pgm_name;
/// Should never happen but boost unit_test isn't playing nicely in some cases