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

Implement page lifecycle API

    XMLWordPrintable

Details

    • User Story
    • Resolution: Done
    • P2: Important
    • 5.14.0
    • None
    • WebEngine
    • None
    • a69029cf9fcfd0c1fcdaafe5cbcbff2d5dd6b5c5 (qt/qtwebengine/5.15.4)

    Description

      Implement https://wicg.github.io/page-lifecycle/spec.html for reducing CPU and memory usage by freezing and discarding low-priority tabs.

      Freezing - CPU usage is throttled by suspending task queues.
      Discarding - Memory usage is reduced by discarding the browsing context and reloading when needed.

      The QWebEnginePage API should be extended to allow manual control over freezing and discarding. Additionally we should provide a simple builtin heuristic (similar to Chromium's CheckIfTabIsUsedInBackground), for detecting if hidden pages are doing useful work in the background and should therefore not be frozen or discarded.

      In Chromium this is implemented by the "resource coordinator" service/component which contains all sorts of fancy heuristics, including a pretrained deep neural network for predicting tab priorities. As this component works at the level of tabs, it is therefore tied to Chromium UI and cannot be reused cleanly.

      Attachments

        Issue Links

          For Gerrit Dashboard: QTBUG-74166
          # Subject Branch Project Status CR V

          Activity

            People

              juri.valdmann Jüri Valdmann (Inactive)
              juri.valdmann Jüri Valdmann (Inactive)
              Tino Pyssysalo Tino Pyssysalo
              Kai Köhne Kai Köhne
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes