diff options
author | Clement Tsang <34804052+ClementTsang@users.noreply.github.com> | 2021-04-05 01:19:17 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-05 01:19:17 -0400 |
commit | 5bd9e4f6ae399a702508b45a02e74d07e9bb7c77 (patch) | |
tree | 110ea41c5a207e444c31688cfb2502a992814527 /CHANGELOG.md | |
parent | 405ce64a02fd55ebb383ce797910b2ec82dc97b4 (diff) |
feature: Collapsing in tree mode sums usage to parent (#445)
For the process widget, we now sum the resource usage of the child processes on the parent entry when collapsing in tree mode.
Note that if you search to filter, and collapse, it will not sum the pruned values (values that cannot be seen). This is partly because I'm a bit lazy, and partly because I think this behaviour makes sense.
For example, let's say I search for a process with 4 child processes "AA, AB, BA, BB", with CPU usage 0.1, 0.2, 0.3, 0.4 respectively. Assume the parent process has 0 usage.
- Without filter, it sums to 1.0
- With a filter on A, it would sum to just 0.3
- With a filter on AA, it would sum to 0.1
I think this is fine because I'm treating this as summing any child that is still *visible* somehow. Summing unseen values would probably be weird as it would look like it's not adding up.
Further note that if you had, say, a child "CC" with a usage of, say, 2.0, and its parent of "AB", and you searched for CC in our above example, you would get a sum of 2.2. This is because AB is still visible by the fact that CC was the searched process, and AB must still exist (albeit faded out) in the tree hierarchy, and as such will still be displayed.
Diffstat (limited to 'CHANGELOG.md')
-rw-r--r-- | CHANGELOG.md | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index a36c0c4b..59006b02 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - [#437](https://github.com/ClementTsang/bottom/pull/437): Redo dynamic network y-axis, add linear scaling, unit type, and prefix options. +- [#445](https://github.com/ClementTsang/bottom/pull/445): Collapsing in tree mode sums usage to parent. + ## Changes - [#372](https://github.com/ClementTsang/bottom/pull/372): Hides the SWAP graph and legend in normal mode if SWAP is 0. |