forked from qt-creator/qt-creator
Increased the number of threads in the global thread pool.
Reviewed-by: dt
This commit is contained in:
@@ -42,6 +42,7 @@
|
||||
#include <QtCore/QTranslator>
|
||||
#include <QtCore/QSettings>
|
||||
#include <QtCore/QVariant>
|
||||
#include <QtCore/QThreadPool>
|
||||
|
||||
#include <QtNetwork/QNetworkProxyFactory>
|
||||
|
||||
@@ -184,6 +185,10 @@ int main(int argc, char **argv)
|
||||
|
||||
SharedTools::QtSingleApplication app((QLatin1String(appNameC)), argc, argv);
|
||||
|
||||
const int threadCount = QThreadPool::globalInstance()->maxThreadCount();
|
||||
QThreadPool::globalInstance()->setMaxThreadCount(qMax(4, 2 * threadCount));
|
||||
|
||||
|
||||
#ifdef ENABLE_QT_BREAKPAD
|
||||
QtSystemExceptionHandler systemExceptionHandler;
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user