From 8240333f969ff1707997e080733d7f83b2385fc0 Mon Sep 17 00:00:00 2001 From: Jarek Kobus Date: Tue, 7 Mar 2023 17:31:48 +0100 Subject: TestCodeParser: Apply priority to thead pool Rather to async task. Change-Id: I253de9f04e655e394027d15273a86049f5b61f5b Reviewed-by: Christian Stenger Reviewed-by: Qt CI Bot --- src/plugins/autotest/testcodeparser.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/plugins/autotest/testcodeparser.cpp') diff --git a/src/plugins/autotest/testcodeparser.cpp b/src/plugins/autotest/testcodeparser.cpp index 3b9c396fed..55fc5ec907 100644 --- a/src/plugins/autotest/testcodeparser.cpp +++ b/src/plugins/autotest/testcodeparser.cpp @@ -50,6 +50,7 @@ TestCodeParser::TestCodeParser() m_reparseTimer.setSingleShot(true); connect(&m_reparseTimer, &QTimer::timeout, this, &TestCodeParser::parsePostponedFiles); m_threadPool->setMaxThreadCount(std::max(QThread::idealThreadCount()/4, 1)); + m_threadPool->setThreadPriority(QThread::LowestPriority); m_futureSynchronizer.setCancelOnWait(true); } @@ -361,7 +362,6 @@ void TestCodeParser::scanForTests(const FilePaths &fileList, const QList &async) { async.setConcurrentCallData(parseFileForTests, codeParsers, file); async.setThreadPool(m_threadPool); - async.setPriority(QThread::LowestPriority); async.setFutureSynchronizer(&m_futureSynchronizer); }; const auto onDone = [this](const AsyncTask &async) { -- cgit v1.2.1