[Differential] [Request, 67 lines] D4056: Perf: Optimize ProjectItemDataProvider::itemCount()

Kevin Funk noreply at phabricator.kde.org
Mon Jan 9 22:44:46 UTC 2017


kfunk created this revision.
Restricted Application added a subscriber: kdevelop-devel.

REVISION SUMMARY
  A callgrind run showed that ProjectItemDataProvider::itemCount() is called a lot of
  times when quick open is opened, but the function itself causes massive re-computation of
  known values each time it is invoked.
  
  This patches fixes this, implementing a cache for the total item count
  of the data provider.
  
  Testing: After a second callgrind run
  ProjectItemDataProvider::itemCount() no longer showed up as an expensive
  function.

REPOSITORY
  R33 KDevPlatform

BRANCH
  perf-quickopen (branched from master)

REVISION DETAIL
  https://phabricator.kde.org/D4056

AFFECTED FILES
  plugins/quickopen/projectitemquickopen.cpp
  plugins/quickopen/projectitemquickopen.h

EMAIL PREFERENCES
  https://phabricator.kde.org/settings/panel/emailpreferences/

To: kfunk
Cc: kdevelop-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20170109/67f6b4a0/attachment.html>


More information about the KDevelop-devel mailing list