Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-25350

Crash on shutdown, somewhere in qml world

    XMLWordPrintable

    Details

    • Commits:
      54f3232f63d835ef0c17aa195a64c0b248afc759 (qt-creator/qt-creator/master)

      Description

      This happens when you start loading a big project (like qtcreator) and do shutdown just after that. Most interesting threads when crash happened:

      Program terminated with signal SIGSEGV, Segmentation fault.
      #0  0x00007f267823f5ad in QmlJS::ImportKey::compare (this=0x30, other=...)
          at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsimportdependencies.cpp:361
      361	    ImportKind::Enum k1 = toImportKind(type);
      
      Thread 5 (Thread 0x7f25e17fa640 (LWP 68282)):
      #0  0x00007f26781ce288 in QmlJS::Parser::parse (this=0x7f25e17f9280, startToken=121) at qmljs.g:1159
      #1  0x00007f2678225b24 in QmlJS::Parser::parse (this=0x7f25e17f9280) at qmljs.g:324
      #2  0x00007f2678221e35 in QmlJS::Document::parse_helper (this=0x7f25a80d4ea0, startToken=121) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsdocument.cpp:307
      #3  0x00007f267822213d in QmlJS::Document::parseQml (this=0x7f25a80d4ea0) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsdocument.cpp:343
      #4  0x00007f267822210e in QmlJS::Document::parse (this=0x7f25a80d4ea0) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsdocument.cpp:336
      #5  0x00007f2678273dd3 in QmlJS::ModelManagerInterface::parseLoop(QSet<QString>&, QSet<QString>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool, std::function<bool (double)> const&) (scannedPaths=..., newLibraries=..., workingCopy=..., files=..., modelManager=0x249a960, mainLanguage=..., emitDocChangedOnDisk=true, reportProgress=...) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsmodelmanagerinterface.cpp:954
      #6  0x00007f26782748f6 in QmlJS::ModelManagerInterface::importScan (future=..., workingCopy=..., paths=..., modelManager=0x249a960, emitDocChangedOnDisk=true, libOnly=true, forceRescan=false) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsmodelmanagerinterface.cpp:1077
      #7  0x00007f26782910f6 in Utils::Internal::runAsyncQFutureInterfaceDispatch<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool), QmlJS::ModelManagerInterface::WorkingCopy, QmlJS::PathsAndLanguages, QmlJS::ModelManagerInterface*, bool, bool, bool> (futureInterface=..., function=@0x7b4aea0: 0x7f26782742d6 <QmlJS::ModelManagerInterface::importScan(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool)>) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:257
      #8  0x00007f2678290cc5 in Utils::Internal::runAsyncMemberDispatch<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool), QmlJS::ModelManagerInterface::WorkingCopy, QmlJS::PathsAndLanguages, QmlJS::ModelManagerInterface*, bool, bool, bool, void> (futureInterface=..., function=@0x7b4aea0: 0x7f26782742d6 <QmlJS::ModelManagerInterface::importScan(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool)>) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:274
      #9  0x00007f2678290835 in Utils::Internal::runAsyncImpl<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool), QmlJS::ModelManagerInterface::WorkingCopy, QmlJS::PathsAndLanguages, QmlJS::ModelManagerInterface*, bool, bool, bool> (futureInterface=..., function=@0x7b4aea0: 0x7f26782742d6 <QmlJS::ModelManagerInterface::importScan(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool)>) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:303
      #10 0x00007f2678290203 in Utils::Internal::AsyncJob<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool), QmlJS::ModelManagerInterface::WorkingCopy, QmlJS::PathsAndLanguages&, QmlJS::ModelManagerInterface*, bool, bool, bool>::runHelper<0ul, 1ul, 2ul, 3ul, 4ul, 5ul, 6ul> (this=0x7b4ae70) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:372
      #11 0x00007f267828fcec in Utils::Internal::AsyncJob<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QmlJS::PathsAndLanguages const&, QmlJS::ModelManagerInterface*, bool, bool, bool), QmlJS::ModelManagerInterface::WorkingCopy, QmlJS::PathsAndLanguages&, QmlJS::ModelManagerInterface*, bool, bool, bool>::run (this=0x7b4ae70) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:352
      #12 0x00007f26974fb941 in Utils::Internal::RunnableThread::run (this=0x6c68da0) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.cpp:39
      #13 0x00007f269581930e in QThreadPrivate::start (arg=0x6c68da0) at /home/jarek/dev/qt-515/qtbase/src/corelib/thread/qthread_unix.cpp:329
      #14 0x00007f2694ab13f9 in start_thread () from /lib64/libpthread.so.0
      #15 0x00007f269531db53 in clone () from /lib64/libc.so.6
      
      Thread 2 (Thread 0x7f2691eed8c0 (LWP 66077)):
      #0  0x00007f26952a260b in __lll_lock_wait_private () from /lib64/libc.so.6
      #1  0x00007f26952a57da in _int_free () from /lib64/libc.so.6
      #2  0x00007f2695893d95 in QListData::dispose (d=0x7f25a83d2c50) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qlist.cpp:180
      #3  0x00007f267821d56d in QList<QSharedPointer<QmlJS::Document const> >::dealloc (this=0x7f25a80dfd68, data=0x7f25a83d2c50) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qlist.h:923
      #4  0x00007f267821ce60 in QList<QSharedPointer<QmlJS::Document const> >::~QList (this=0x7f25a80dfd68, __in_chrg=<optimized out>) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qlist.h:874
      #5  0x00007f267821c0c6 in QHashNode<QString, QList<QSharedPointer<QmlJS::Document const> > >::~QHashNode (this=0x7f25a80dfd50, __in_chrg=<optimized out>) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qhash.h:147
      #6  0x00007f267821c0fa in QHash<QString, QList<QSharedPointer<QmlJS::Document const> > >::deleteNode2 (node=0x7f25a80dfd50) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qhash.h:595
      #7  0x00007f2695891dd0 in QHashData::free_helper (this=0x7f2638006970, node_delete=0x7f267821c0da <QHash<QString, QList<QSharedPointer<QmlJS::Document const> > >::deleteNode2(QHashData::Node*)>) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qhash.cpp:572
      #8  0x00007f267821b2c5 in QHash<QString, QList<QSharedPointer<QmlJS::Document const> > >::freeData (this=0x249a9a8, x=0x7f2638006970) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qhash.h:619
      #9  0x00007f267821a552 in QHash<QString, QList<QSharedPointer<QmlJS::Document const> > >::~QHash (this=0x249a9a8, __in_chrg=<optimized out>) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qhash.h:250
      #10 0x00007f267822330a in QmlJS::Snapshot::~Snapshot (this=0x249a9a0, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsdocument.cpp:467
      #11 0x00007f267826e6a6 in QmlJS::ModelManagerInterface::~ModelManagerInterface (this=0x249a960, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsmodelmanagerinterface.cpp:140
      #12 0x00007f26780be7b2 in QmlJSTools::Internal::ModelManager::~ModelManager (this=0x249a960, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/plugins/qmljstools/qmljsmodelmanager.cpp:216
      #13 0x00007f26780ce1ae in QmlJSTools::Internal::QmlJSToolsPluginPrivate::~QmlJSToolsPluginPrivate (this=0x249a940, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/plugins/qmljstools/qmljstoolsplugin.cpp:51
      #14 0x00007f26780ce1e6 in QmlJSTools::Internal::QmlJSToolsPluginPrivate::~QmlJSToolsPluginPrivate (this=0x249a940, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/plugins/qmljstools/qmljstoolsplugin.cpp:51
      #15 0x00007f26780ccc2a in QmlJSTools::Internal::QmlJSToolsPlugin::~QmlJSToolsPlugin (this=0x230c1a0, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/plugins/qmljstools/qmljstoolsplugin.cpp:69
      #16 0x00007f26780ccc52 in QmlJSTools::Internal::QmlJSToolsPlugin::~QmlJSToolsPlugin (this=0x230c1a0, __in_chrg=<optimized out>) at /home/jarek/dev/creator-master/src/plugins/qmljstools/qmljstoolsplugin.cpp:70
      #17 0x00007f2697702cbb in ExtensionSystem::Internal::PluginSpecPrivate::kill (this=0x22c34f0) at /home/jarek/dev/creator-master/src/libs/extensionsystem/pluginspec.cpp:1124
      #18 0x00007f26976ea177 in ExtensionSystem::Internal::PluginManagerPrivate::loadPlugin (this=0x1ead160, spec=0x22b5e60, destState=ExtensionSystem::PluginSpec::Deleted) at /home/jarek/dev/creator-master/src/libs/extensionsystem/pluginmanager.cpp:1488
      #19 0x00007f26976e818f in operator() (__closure=0x7ffd18037d30, spec=0x22b5e60) at /home/jarek/dev/creator-master/src/libs/extensionsystem/pluginmanager.cpp:949
      #20 0x00007f26976ec31f in Utils::reverseForeach<QVector<ExtensionSystem::PluginSpec*>, ExtensionSystem::Internal::PluginManagerPrivate::deleteAll()::<lambda(ExtensionSystem::PluginSpec*)> >(const QVector<ExtensionSystem::PluginSpec*> &, const struct {...} &) (c=..., operation=...) at /home/jarek/dev/creator-master/src/libs/utils/algorithm.h:1041
      #21 0x00007f26976e81cd in ExtensionSystem::Internal::PluginManagerPrivate::deleteAll (this=0x1ead160) at /home/jarek/dev/creator-master/src/libs/extensionsystem/pluginmanager.cpp:948
      #22 0x00007f26976e8ac4 in ExtensionSystem::Internal::PluginManagerPrivate::shutdown (this=0x1ead160) at /home/jarek/dev/creator-master/src/libs/extensionsystem/pluginmanager.cpp:1282
      #23 0x00007f26976e5273 in ExtensionSystem::PluginManager::shutdown () at /home/jarek/dev/creator-master/src/libs/extensionsystem/pluginmanager.cpp:408
      #24 0x0000000000416c6d in QtPrivate::FunctorCall<QtPrivate::IndexesList<>, QtPrivate::List<>, void, void (*)()>::call(void (*&)(), void**) (f=@0x7ffd18037e58: 0x7f26976e5260 <ExtensionSystem::PluginManager::shutdown()>, arg=0x7ffd18038080) at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qobjectdefs_impl.h:146
      #25 0x00000000004166cf in QtPrivate::FunctionPointer<void (*)()>::call<QtPrivate::List<>, void>(void (*)(), void*, void**) (f=0x7f26976e5260 <ExtensionSystem::PluginManager::shutdown()>, arg=0x7ffd18038080) at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qobjectdefs_impl.h:209
      #26 0x0000000000415c9a in QtPrivate::QStaticSlotObject<void (*)(), QtPrivate::List<>, void>::impl(int, QtPrivate::QSlotObjectBase*, QObject*, void**, bool*) (which=1, this_=0x386a790, r=0x7ffd18038280, a=0x7ffd18038080, ret=0x0) at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qobject_impl.h:90
      #27 0x00007f2695a92d3f in QtPrivate::QSlotObjectBase::call (this=0x386a790, r=0x7ffd18038280, a=0x7ffd18038080) at ../../include/QtCore/../../../../qt-515/qtbase/src/corelib/kernel/qobjectdefs_impl.h:398
      #28 0x00007f2695ad1e23 in doActivate<false> (sender=0x7ffd180382b0, signal_index=3, argv=0x7ffd18038080) at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qobject.cpp:3886
      #29 0x00007f2695acb99f in QMetaObject::activate (sender=0x7ffd180382b0, m=0x7f2695e6ec20 <QCoreApplication::staticMetaObject>, local_signal_index=0, argv=0x7ffd18038080) at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qobject.cpp:3946
      #30 0x00007f2695a863fd in QCoreApplication::aboutToQuit (this=0x7ffd180382b0, _t1=...) at .moc/moc_qcoreapplication.cpp:254
      #31 0x00007f2695a8240f in QCoreApplicationPrivate::execCleanup (this=0x1eb6fc0) at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qcoreapplication.cpp:1395
      #32 0x00007f2695a8238b in QCoreApplication::exec () at /home/jarek/dev/qt-515/qtbase/src/corelib/kernel/qcoreapplication.cpp:1379
      #33 0x00007f2696217a7c in QGuiApplication::exec () at /home/jarek/dev/qt-515/qtbase/src/gui/kernel/qguiapplication.cpp:1867
      #34 0x00007f2696b8170f in QApplication::exec () at /home/jarek/dev/qt-515/qtbase/src/widgets/kernel/qapplication.cpp:2824
      #35 0x000000000040e74d in main (argc=1, argv=0x7ffd18038b88) at /home/jarek/dev/creator-master/src/app/main.cpp:805
      
      Thread 1 (Thread 0x7f2650dba640 (LWP 68281)):
      #0  0x00007f267823f5ad in QmlJS::ImportKey::compare (this=0x30, other=...) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsimportdependencies.cpp:361
      #1  0x00007f2678240366 in QmlJS::operator< (i1=..., i2=...) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsimportdependencies.cpp:529
      #2  0x00007f2678248beb in qMapLessThanKey<QmlJS::ImportKey> (key1=..., key2=...) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qmap.h:68
      #3  0x00007f26782473f0 in QMapNode<QmlJS::ImportKey, QStringList>::lowerBound (this=0x18, akey=...) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qmap.h:153
      #4  0x00007f2678247088 in QMapData<QmlJS::ImportKey, QStringList>::findNode (this=0x7f2638007080, akey=...) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qmap.h:288
      #5  0x00007f26782455b5 in QMap<QmlJS::ImportKey, QStringList>::operator[] (this=0x249a9b8, akey=...) at /home/jarek/dev/qt-515/qtbase/src/corelib/tools/qmap.h:681
      #6  0x00007f2678241b52 in QmlJS::ImportDependencies::addCoreImport (this=0x249a9b8, import=...) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsimportdependencies.cpp:781
      #7  0x00007f2678223609 in QmlJS::Snapshot::insert (this=0x249a9a0, document=..., allowInvalid=true) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsdocument.cpp:485
      #8  0x00007f2678271bea in QmlJS::ModelManagerInterface::updateDocument (this=0x249a960, doc=...) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsmodelmanagerinterface.cpp:668
      #9  0x00007f2678273fbc in QmlJS::ModelManagerInterface::parseLoop(QSet<QString>&, QSet<QString>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool, std::function<bool (double)> const&) (scannedPaths=..., newLibraries=..., workingCopy=..., files=..., modelManager=0x249a960, mainLanguage=..., emitDocChangedOnDisk=false, reportProgress=...) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsmodelmanagerinterface.cpp:973
      #10 0x00007f2678274246 in QmlJS::ModelManagerInterface::parse (future=..., workingCopy=..., files=..., modelManager=0x249a960, mainLanguage=..., emitDocChangedOnDisk=false) at /home/jarek/dev/creator-master/src/libs/qmljs/qmljsmodelmanagerinterface.cpp:1014
      #11 0x00007f267829125b in Utils::Internal::runAsyncQFutureInterfaceDispatch<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool), QmlJS::ModelManagerInterface::WorkingCopy, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool> (futureInterface=..., function=@0x7f252db03190: 0x7f2678274166 <QmlJS::ModelManagerInterface::parse(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool)>) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:257
      #12 0x00007f2678290e57 in Utils::Internal::runAsyncMemberDispatch<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool), QmlJS::ModelManagerInterface::WorkingCopy, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool, void> (futureInterface=..., function=@0x7f252db03190: 0x7f2678274166 <QmlJS::ModelManagerInterface::parse(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool)>) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:274
      #13 0x00007f26782909dd in Utils::Internal::runAsyncImpl<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool), QmlJS::ModelManagerInterface::WorkingCopy, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool> (futureInterface=..., function=@0x7f252db03190: 0x7f2678274166 <QmlJS::ModelManagerInterface::parse(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool)>) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:303
      #14 0x00007f26782904cc in Utils::Internal::AsyncJob<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool), QmlJS::ModelManagerInterface::WorkingCopy, QStringList const&, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool&>::runHelper<0ul, 1ul, 2ul, 3ul, 4ul, 5ul> (this=0x7f252db03160) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:372
      #15 0x00007f267828ff1c in Utils::Internal::AsyncJob<void, void (*)(QFutureInterface<void>&, QmlJS::ModelManagerInterface::WorkingCopy const&, QStringList, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool), QmlJS::ModelManagerInterface::WorkingCopy, QStringList const&, QmlJS::ModelManagerInterface*, QmlJS::Dialect, bool&>::run (this=0x7f252db03160) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.h:352
      #16 0x00007f26974fb941 in Utils::Internal::RunnableThread::run (this=0x74a9050) at /home/jarek/dev/creator-master/src/libs/utils/runextensions.cpp:39
      #17 0x00007f269581930e in QThreadPrivate::start (arg=0x74a9050) at /home/jarek/dev/qt-515/qtbase/src/corelib/thread/qthread_unix.cpp:329
      #18 0x00007f2694ab13f9 in start_thread () from /lib64/libpthread.so.0
      #19 0x00007f269531db53 in clone () from /lib64/libc.so.6
      

      Update: Could reproduce reliably the crash. For details on how to reproduce see https://codereview.qt-project.org/c/qt-creator/qt-creator/+/337533

        Attachments

          Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            Activity

              People

              Assignee:
              jkobus Jarek Kobus
              Reporter:
              jkobus Jarek Kobus
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews