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

QWebEngine leaks memory with the software renderer

    XMLWordPrintable

Details

    Description

      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

      Attachments

        1. QWebEngine_MemoryLeak.zip
          2 kB
          Mathieu Genesse-Grenier
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

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

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes