Summary: | KProcessList::processInfo(qint64 pid) iterates through all processes only to filter them | ||
---|---|---|---|
Product: | [Frameworks and Libraries] frameworks-kcoreaddons | Reporter: | David Edmundson <kde> |
Component: | general | Assignee: | David Hallas <david> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | david, kdelibs-bugs |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | https://commits.kde.org/kcoreaddons/e16dda4d50bf9e51f1ec1f388f1267bda1c89417 | Version Fixed In: |
Description
David Edmundson
2019-08-15 15:52:27 UTC
CC'ing original David who wrote it Yeah I see :) I am working on a fix I forget to mention this bugreport in the patch commit message :/ https://phabricator.kde.org/D23205 Git commit e16dda4d50bf9e51f1ec1f388f1267bda1c89417 by David Hallas. Committed on 15/12/2019 at 06:53. Pushed by hallas into branch 'master'. [KProcessList] Optimize KProcessList::processInfo Summary: Optimize KProcessList::processInfo on unix so that it doesn't iterate over all processes and then filter the list to the requested process. Instead refactor the code that fetches process info from a single process and use that function. Test Plan: Unit Test Reviewers: davidedmundson, broulik, mpyne Reviewed By: mpyne Subscribers: mpyne, apol, kde-frameworks-devel Tags: #frameworks Differential Revision: https://phabricator.kde.org/D23205 M +0 -15 src/lib/util/kprocesslist.cpp M +64 -51 src/lib/util/kprocesslist_unix.cpp M +15 -0 src/lib/util/kprocesslist_win.cpp https://commits.kde.org/kcoreaddons/e16dda4d50bf9e51f1ec1f388f1267bda1c89417 |