====================== WARNING: ThreadSanitizer: data race (pid=1998707) Write of size 1 at 0x7b540006e7f0 by main thread: #0 CppEditor::CppModelManager::updateProjectInfo(std::shared_ptr const&, QSet const&) ../../src/plugins/cppeditor/cppmodelmanager.cpp:1189 (libCppEditor.so+0x3c52fc) #1 CppEditor::CppProjectUpdater::checkForExtraCompilersFinished() ../../src/plugins/cppeditor/cppprojectupdater.cpp:170 (libCppEditor.so+0x40d31c) #2 CppEditor::CppProjectUpdater::onProjectInfoGenerated() ../../src/plugins/cppeditor/cppprojectupdater.cpp:147 (libCppEditor.so+0x40ee09) #3 QtPrivate::FunctorCall, QtPrivate::List<>, void, void (CppEditor::CppProjectUpdater::*)()>::call(void (CppEditor::CppProjectUpdater::*)(), CppEditor::CppProjectUpdater*, void**) /usr/local/Qt-6.4.0/include/QtCore/qobjectdefs_impl.h:171 (libCppEditor.so+0x412ec7) #4 void QtPrivate::FunctionPointer::call, void>(void (CppEditor::CppProjectUpdater::*)(), CppEditor::CppProjectUpdater*, void**) /usr/local/Qt-6.4.0/include/QtCore/qobjectdefs_impl.h:208 (libCppEditor.so+0x412ec7) #5 QtPrivate::QSlotObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*, void**, bool*) /usr/local/Qt-6.4.0/include/QtCore/qobjectdefs_impl.h:419 (libCppEditor.so+0x412ec7) #6 void doActivate(QObject*, int, void**) (libQt6Core.so.6+0x1bd311) #7 __libc_start_main ../csu/libc-start.c:308 (libc.so.6+0x24082) Previous read of size 1 at 0x7b540006e7f0 by thread T47: #0 CppEditor::CppModelManager::ensureUpdated() ../../src/plugins/cppeditor/cppmodelmanager.cpp:711 (libCppEditor.so+0x3bcaf0) #1 CppEditor::CppModelManager::headerPaths() ../../src/plugins/cppeditor/cppmodelmanager.cpp:1679 (libCppEditor.so+0x3bd1e4) #2 index ../../src/plugins/cppeditor/builtinindexingsupport.cpp:205 (libCppEditor.so+0x15f70a) #3 parse ../../src/plugins/cppeditor/builtinindexingsupport.cpp:256 (libCppEditor.so+0x15f70a) #4 runAsyncQFutureInterfaceDispatch&, CppEditor::Internal::(anonymous namespace)::ParseParams), CppEditor::Internal::(anonymous namespace)::ParseParams> ../../src/libs/utils/runextensions.h:257 (libCppEditor.so+0x157420) #5 runAsyncMemberDispatch&, CppEditor::Internal::(anonymous namespace)::ParseParams), CppEditor::Internal::(anonymous namespace)::ParseParams> ../../src/libs/utils/runextensions.h:274 (libCppEditor.so+0x157420) #6 runAsyncImpl&, CppEditor::Internal::(anonymous namespace)::ParseParams), CppEditor::Internal::(anonymous namespace)::ParseParams> ../../src/libs/utils/runextensions.h:303 (libCppEditor.so+0x157420) #7 runHelper<0, 1> ../../src/libs/utils/runextensions.h:372 (libCppEditor.so+0x157420) #8 run ../../src/libs/utils/runextensions.h:352 (libCppEditor.so+0x157420) #9 QThreadPoolThread::run() /home/iivlev/Qt_new1/qt5/qtbase/src/corelib/thread/qthreadpool.cpp:102 (libQt6Core.so.6+0x346ce0) Location is heap block of size 576 at 0x7b540006e780 allocated by main thread: #0 operator new(unsigned long) ../../../../src/libsanitizer/tsan/tsan_new_delete.cpp:64 (libtsan.so.0+0x8c032) #1 CppEditor::CppModelManager::CppModelManager() ../../src/plugins/cppeditor/cppmodelmanager.cpp:603 (libCppEditor.so+0x3c7287) #2 CppEditor::Internal::CppEditorPluginPrivate::CppEditorPluginPrivate() ../../src/plugins/cppeditor/cppeditorplugin.cpp:179 (libCppEditor.so+0x298611) #3 CppEditor::Internal::CppEditorPlugin::initialize(QList const&, QString*) ../../src/plugins/cppeditor/cppeditorplugin.cpp:252 (libCppEditor.so+0x298611) #4 ExtensionSystem::Internal::PluginSpecPrivate::initializePlugin() ../../src/libs/extensionsystem/pluginspec.cpp:1123 (libExtensionSystem.so.7+0x6b13e) #5 ExtensionSystem::Internal::PluginManagerPrivate::loadPlugin(ExtensionSystem::PluginSpec*, ExtensionSystem::PluginSpec::State) ../../src/libs/extensionsystem/pluginmanager.cpp:1641 (libExtensionSystem.so.7+0x4d589) #6 ExtensionSystem::Internal::PluginManagerPrivate::loadPlugins() ../../src/libs/extensionsystem/pluginmanager.cpp:1366 (libExtensionSystem.so.7+0x4e4aa) #7 ExtensionSystem::PluginManager::loadPlugins() ../../src/libs/extensionsystem/pluginmanager.cpp:338 (libExtensionSystem.so.7+0x4e836) #8 main ../../src/app/main.cpp:747 (qtcreator+0x11648) Thread T47 'Thread (pooled)' (tid=1999071, running) created by main thread at: #0 pthread_create ../../../../src/libsanitizer/tsan/tsan_interceptors_posix.cpp:962 (libtsan.so.0+0x5ea79) #1 QThread::start(QThread::Priority) /home/iivlev/Qt_new1/qt5/qtbase/src/corelib/thread/qthread_unix.cpp:744 (libQt6Core.so.6+0x33f8d7) #2 QFuture Utils::runAsync&, QSharedPointer, CppEditor::BaseEditorDocumentParser::UpdateParams), QSharedPointer, CppEditor::BaseEditorDocumentParser::UpdateParams const&, void>(QThreadPool*, QThread::Priority, void (&)(QFutureInterface&, QSharedPointer, CppEditor::BaseEditorDocumentParser::UpdateParams), QSharedPointer&&, CppEditor::BaseEditorDocumentParser::UpdateParams const&) ../../src/libs/utils/runextensions.h:457 (libCppEditor.so+0x14a10f) #3 QFuture Utils::runAsync&, QSharedPointer, CppEditor::BaseEditorDocumentParser::UpdateParams), QSharedPointer, CppEditor::BaseEditorDocumentParser::UpdateParams const&, void, void>(QThreadPool*, void (&)(QFutureInterface&, QSharedPointer, CppEditor::BaseEditorDocumentParser::UpdateParams), QSharedPointer&&, CppEditor::BaseEditorDocumentParser::UpdateParams const&) ../../src/libs/utils/runextensions.h:546 (libCppEditor.so+0x14a10f) #4 CppEditor::BuiltinEditorDocumentProcessor::runImpl(CppEditor::BaseEditorDocumentParser::UpdateParams const&) ../../src/plugins/cppeditor/builtineditordocumentprocessor.cpp:204 (libCppEditor.so+0x14a10f) #5 CppEditor::BaseEditorDocumentProcessor::run(bool) ../../src/plugins/cppeditor/baseeditordocumentprocessor.cpp:61 (libCppEditor.so+0x12c05e) #6 CppEditor::Internal::CppEditorDocument::processDocument() ../../src/plugins/cppeditor/cppeditordocument.cpp:308 (libCppEditor.so+0x28560d) #7 CppEditor::Internal::CppEditorDocument::onFilePathChanged(Utils::FilePath const&, Utils::FilePath const&) ../../src/plugins/cppeditor/cppeditordocument.cpp:282 (libCppEditor.so+0x287cef) #8 QtPrivate::FunctorCall, QtPrivate::List, void, void (CppEditor::Internal::CppEditorDocument::*)(Utils::FilePath const&, Utils::FilePath const&)>::call(void (CppEditor::Internal::CppEditorDocument::*)(Utils::FilePath const&, Utils::FilePath const&), CppEditor::Internal::CppEditorDocument*, void**) /usr/local/Qt-6.4.0/include/QtCore/qobjectdefs_impl.h:171 (libCppEditor.so+0x28a500) #9 void QtPrivate::FunctionPointer::call, void>(void (CppEditor::Internal::CppEditorDocument::*)(Utils::FilePath const&, Utils::FilePath const&), CppEditor::Internal::CppEditorDocument*, void**) /usr/local/Qt-6.4.0/include/QtCore/qobjectdefs_impl.h:208 (libCppEditor.so+0x28a500) #10 QtPrivate::QSlotObject, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*, void**, bool*) /usr/local/Qt-6.4.0/include/QtCore/qobjectdefs_impl.h:419 (libCppEditor.so+0x28a500) #11 void doActivate(QObject*, int, void**) (libQt6Core.so.6+0x1bd311) #12 Core::IDocument::setFilePath(Utils::FilePath const&) ../../src/plugins/coreplugin/idocument.cpp:705 (libCore.so+0x3d118a) #13 TextEditor::TextDocument::setFilePath(Utils::FilePath const&) ../../src/plugins/texteditor/textdocument.cpp:709 (libTextEditor.so+0x23c8a8) #14 TextEditor::TextDocument::openImpl(QString*, Utils::FilePath const&, Utils::FilePath const&, bool) ../../src/plugins/texteditor/textdocument.cpp:795 (libTextEditor.so+0x23cdce) #15 TextEditor::TextDocument::open(QString*, Utils::FilePath const&, Utils::FilePath const&) ../../src/plugins/texteditor/textdocument.cpp:729 (libTextEditor.so+0x23d0b6) #16 Core::Internal::EditorManagerPrivate::openEditor(Core::Internal::EditorView*, Utils::FilePath const&, Utils::Id, QFlags, bool*) ../../src/plugins/coreplugin/editormanager/editormanager.cpp:868 (libCore.so+0x284ca7) #17 Core::Internal::SplitterOrView::restoreState(QByteArray const&) ../../src/plugins/coreplugin/editormanager/editorview.cpp:964 (libCore.so+0x2bd29f) #18 Core::EditorManager::restoreState(QByteArray const&) ../../src/plugins/coreplugin/editormanager/editormanager.cpp:3641 (libCore.so+0x28c7fe) #19 ProjectExplorer::SessionManagerPrivate::restoreEditors(Utils::PersistentSettingsReader const&) ../../src/plugins/projectexplorer/session.cpp:964 (libProjectExplorer.so+0x77d4ce) #20 ProjectExplorer::SessionManager::loadSession(QString const&, bool) ../../src/plugins/projectexplorer/session.cpp:1121 (libProjectExplorer.so+0x78e9e0) #21 ProjectExplorer::Internal::SessionModel::switchToSession(QString const&) ../../src/plugins/projectexplorer/sessionmodel.cpp:268 (libProjectExplorer.so+0x7a3d54) #22 ProjectExplorer::Internal::SessionDelegate::editorEvent(QEvent*, QAbstractItemModel*, QStyleOptionViewItem const&, QModelIndex const&) ../../src/plugins/projectexplorer/projectwelcomepage.cpp:428 (libProjectExplorer.so+0x6ef949) #23 QAbstractItemViewPrivate::sendDelegateEvent(QModelIndex const&, QEvent*) const /home/iivlev/Qt_new1/qt5/qtbase/src/widgets/itemviews/qabstractitemview.cpp:4600 (libQt6Widgets.so.6+0x53deb0) #24 __libc_start_main ../csu/libc-start.c:308 (libc.so.6+0x24082) SUMMARY: ThreadSanitizer: data race ../../src/plugins/cppeditor/cppmodelmanager.cpp:1189 in CppEditor::CppModelManager::updateProjectInfo(std::shared_ptr const&, QSet const&) ==================