Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

QV4::MemoryManager::collectFromJSStack



  • My app randomly crashes. After writing and analyzing the crash dump, I found that it crashes in the memory manager in QV4::MemoryManager::collectFromJSStack.

    I tried to debug it with QV4_MM_AGGRESSIVE_GC=1 but it does not start at all.

    I tried to setup a very basic application (see below). It crashes (access violation), too, when QV4_MM_AGGRESSIVE_GC=1 is enabled.

    How can I debug my app???

    #include "widget.h"
    #include <QApplication>
    #include <QJSEngine>
    
    int main(int argc, char *argv[])
    {
        QApplication a(argc, argv);
        QJSEngine engine;
        Widget w;
        w.show();
        return a.exec();
    }
    

  • Lifetime Qt Champion

    Hi and welcome to devnet,

    What version of Qt ?
    What OS ?
    What stack trace do you get ?



  • @SGaist
    Qt 5.13.1
    Win 10

    Stacktrace from Dump and WinDbg; AutomatorPro_v1_1_57 is my app.
    STACK_TEXT:
    WARNING: Stack unwind information not available. Following frames may be wrong.
    0018d55c 7bc57a4c 0018d58c 00000040 004c98e8 Qt5Qml!QV4::MemoryManager::collectFromJSStack+0x64
    0018d7e8 7bc40a79 00000001 04cff240 0018d8f0 Qt5Qml!QV4::MemoryManager::collectRoots+0x1c
    0018d7f8 7bc56f8e 004c98f0 00000040 04cff240 Qt5Qml!QV4::MemoryManager::allocate+0xb9
    0018d920 7bd17e75 046b14c8 046b14d0 046b14d8 Qt5Qml!QV4::MemoryManager::allocData+0xe
    0018d984 77ac1ed0 00000009 00000000 0018d99c Qt5Qml!QV4::QObjectWrapper::getQmlProperty+0x675
    0018da5c 7c64397e 0018fc20 7c9838f4 7c9838f4 ntdll!RtlpAllocateHeapInternal+0x530
    0018da70 006b067b 0018fc20 007370f0 00000000 Qt5Core!QMetaObject::activate+0x1e
    0018daa0 006aa4c1 05160ac0 258e01e6 039a5c90 AutomatorPro_v1_1_57+0x1067b
    00000000 00000000 00000000 00000000 00000000 AutomatorPro_v1_1_57+0xa4c1


Log in to reply