Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-36871

[REG] Widget applications allocate and leak a GL context after QQuickWidget/QOpenGLWidget) changes

    XMLWordPrintable

    Details

    • Commits:
      0febd75d5242653be3202ea0e46ed6107e4333bd

      Description

      Apparently introduced by the QOpenGLWidget changes eacd58d4e78e7238ba5fcca90ba960aaf3ebd263(Enabling QQuickWidget and QOpenGLWidget) . Valgrind excerpt from tst_qmessagebox:

      =25150== 32 bytes in 1 blocks are possibly lost in loss record 265 of 956
      ==25150==    at 0x4C2B1C7: operator new(unsigned long) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==25150==    by 0x6B20A88: std::string::_Rep::_S_create(unsigned long, unsigned long, std::allocator<char> const&) (in /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.16)
      ==25150==    by 0x6B22494: char* std::string::_S_construct<char const*>(char const*, char const*, std::allocator<char> const&, std::forward_iterator_tag) (in /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.16)
      ==25150==    by 0x6B2261C: std::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string(char const*, unsigned long, std::allocator<char> const&) (in /usr/lib/x86_64-linux-gnu/libstdc++.so.6.0.16)
      ==25150==    by 0x13FD5693: llvm::Module::Module(llvm::StringRef, llvm::LLVMContext&) (in /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1)
      ==25150==    by 0x13F73FCF: LLVMModuleCreateWithNameInContext (in /usr/lib/x86_64-linux-gnu/libLLVM-3.0.so.1)
      ==25150==    by 0x122939FD: ??? (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x12293BDA: gallivm_create (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x12219AF4: ??? (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x121BD765: nv50_create (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x131B9231: ??? (in /usr/lib/x86_64-linux-gnu/dri/libgallium.so)
      ==25150==    by 0x12174994: dri_create_context (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x12170E44: ??? (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x12170F5C: ??? (in /usr/lib/x86_64-linux-gnu/dri/nouveau_dri.so)
      ==25150==    by 0x75B9BD2: ??? (in /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1.2)
      ==25150==    by 0x759333D: ??? (in /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1.2)
      ==25150==    by 0x7593569: glXCreateNewContext (in /usr/lib/x86_64-linux-gnu/mesa/libGL.so.1.2)
      ==25150==    by 0xBE1A4B2: ???
      ==25150==    by 0xBDF5E94: ???
      ==25150==    by 0x5B687EF: QOpenGLContext::create() (qopenglcontext.cpp:483)
      ==25150==    by 0x4FFADEA: QWidgetPrivate::shareContext() const (qwidget.cpp:11143)
      ==25150==    by 0x4FB8F9F: QWidgetBackingStore::flush(QWidget*) (qwidgetbackingstore.cpp:1193)
      ==25150==    by 0x4FB45DE: QWidgetBackingStore::endPaint(QRegion const&, QBackingStore*, BeginPaintInfo*) (qwidgetbackingstore.cpp:337)
      ==25150==    by 0x4FB8ECF: QWidgetBackingStore::doSync() (qwidgetbackingstore.cpp:1181)
      ==25150==    by 0x4FB7B6A: QWidgetBackingStore::sync(QWidget*, QRegion const&) (qwidgetbackingstore.cpp:948)
      ==25150==    by 0x4FE4481: QWidgetPrivate::syncBackingStore(QRegion const&) (qwidget.cpp:1699)
      ==25150==    by 0x5021F99: QWidgetWindow::handleExposeEvent(QExposeEvent*) (qwidgetwindow.cpp:713)
      ==25150==    by 0x501FD0D: QWidgetWindow::event(QEvent*) (qwidgetwindow.cpp:225)
      ==25150==    by 0x4FA97ED: QApplicationPrivate::notify_helper(QObject*, QEvent*) (qapplication.cpp:3517)
      ==25150==    by 0x4FA6DD3: QApplication::notify(QObject*, QEvent*) (qapplication.cpp:2937)
      ==25150==    by 0x65811E7: QCoreApplication::notifyInternal(QObject*, QEvent*) (qcoreapplication.cpp:937)
      ==25150==    by 0x5B2A910: QCoreApplication::sendSpontaneousEvent(QObject*, QEvent*) (in /depot/fkleint/qt-5/qtbase/lib/libQt5Gui.so.5.3.0)
      ==25150==    by 0x5B27EA1: QGuiApplicationPrivate::processExposeEvent(QWindowSystemInterfacePrivate::ExposeEvent*) (qguiapplication.cpp:2429)
      ==25150==    by 0x5B23D7B: QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) (qguiapplication.cpp:1491)
      ==25150==    by 0x5B0DE20: QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) (qwindowsysteminterface.cpp:579)
      ==25150==    by 0xBE82242: ???
      ==25150==    by 0x657DD87: QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) (qeventloop.cpp:136)
      ==25150==    by 0x657E060: QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) (qeventloop.cpp:212)
      ==25150==    by 0x5201944: QDialog::exec() (qdialog.cpp:549)
      ==25150==    by 0x408E8F: tst_QMessageBox::exec(QMessageBox*, int) (tst_qmessagebox.cpp:166)
      ==25150==    by 0x409760: tst_QMessageBox::defaultButton() (tst_qmessagebox.cpp:249)
      ==25150==    by 0x40D939: tst_QMessageBox::qt_static_metacall(QObject*, QMetaObject::Call, int, void**) (tst_qmessagebox.moc:132)
      ==25150==    by 0x658D8BE: QMetaMethod::invoke(QObject*, Qt::ConnectionType, QGenericReturnArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument) const (qmetaobject.cpp:2169)
      ==25150==    by 0x658CD7A: QMetaObject::invokeMethod(QObject*, char const*, Qt::ConnectionType, QGenericReturnArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument) (qmetaobject.cpp:1464)
      ==25150==    by 0x57F852C: QMetaObject::invokeMethod(QObject*, char const*, Qt::ConnectionType, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument, QGenericArgument) (qobjectdefs.h:399)
      ==25150==    by 0x57F432F: QTest::qInvokeTestMethodDataEntry(char*) (qtestcase.cpp:1721)
      ==25150==    by 0x57F4BAC: QTest::qInvokeTestMethod(char const*, char const*) (qtestcase.cpp:1846)
      ==25150==    by 0x57F5448: QTest::qInvokeTestMethods(QObject*) (qtestcase.cpp:2000)
      ==25150==    by 0x57F595E: QTest::qExec(QObject*, int, char**) (qtestcase.cpp:2230)
      ==25150==    by 0x40D867: main (tst_qmessagebox.cpp:710)
      

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              tvete Paul Olav Tvete
              Reporter:
              kleint Friedemann Kleint
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes