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

QWebEngine leaks memory with the software renderer

XMLWordPrintable

      When a QWebEngineView is destroyed, the nodes in QQuickRenderControl::invalidate() are not cleaned since d->initialized is false (QQuickRenderControl::initialize(QOpenGLContext *gl) is not called with the software renderer). This means that DelegatedFrameNode::~DelegatedFrameNode, which holds a QVector<QSharedPointer<QSGTexture>>, is never called.

      Steps to reproduce with QWebEngine_MemoryLeak.zip:

      • Run QWebEngine_MemoryLeak
      • Put a breakpoint on DelegatedFrameNode::DelegatedFrameNode and on DelegatedFrameNode::~DelegatedFrameNode
      • Click on refresh
      • With QQuickWindow::setSceneGraphBackend(QSGRendererInterface::Software) in main.cpp, the destructor is not called

        1. QWebEngine_MemoryLeak.zip
          2 kB
          Mathieu Genesse-Grenier
        For Gerrit Dashboard: QTBUG-70740
        # Subject Branch Project Status CR V

            allan.jensen Allan Sandfeld Jensen
            mgenessegrenier Mathieu Genesse-Grenier
            Votes:
            3 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes