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

Massive performance loss of QTreeView::expandAll

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • 6.6.3, 6.7.0 Beta3, 6.8.0 FF
    • 6.6.1, 6.6.2, 6.6, 6.7.0 Beta1, 6.7.0 Beta2
    • Widgets: Itemviews
    • None
    • macOS Sonoma 14.3 Apple Silicon M1
    • macOS
    • a86321cb6 (dev), c374e5127 (6.7), 0b474e1b4 (6.6)

    Description

      Moving from Qt 6.2.4 to Qt 6.6 on macOS showed a huge performance degradation with using `QTreeView::expandAll()` on a tree view with approx. 92k items.

      Following discussion on the forum identified this change as the cause for the degradation.

      Removal of `resetModelIfNeeded` restores the performance of `expandAll()` from *47 seconds* back down to below a second.

      Attached is the forum's testcase which creates a treeview with 92k items. Clicking on expand button takes 40+ seconds on macOS. Detailed timings are provided in the forum post as well as screenshots tracing Qt with Apple Instruments.

      Attachments

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

        Activity

          People

            vhilshei Volker Hilsheimer
            derreisende77 Christian F
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes