Skip to content
Commit 3a285053 authored by Arjen Hiemstra's avatar Arjen Hiemstra
Browse files

Add vmPSS to Process and display it as "total memory" column

Summary:
This adds a "proportional state set" value to ProcessCore::Process, that is then
exposed as "Total Memory" column in KSysGuard. This column is hidden by default.

PSS is the amount of memory a process uses privately + the amount of shared memory
divided by the amount of processes sharing that memory. It is, as far as I know, the
closest we can get to "total physical memory usage" for a process.

The value for PSS is read from /proc/{pid}/smaps_rollup . This unfortunately means
we cannot currently display PSS for processes not owned by the current user, as
smaps_rollup is not world-readable.

For some background on this, see https://lkml.org/lkml/2017/8/9/1073 , which is the
patch that adds smaps_rollup and talks about what Android uses it for.

Test Plan:
Run ksysguard, then toggle display of the "Total Memory" column. Values should be
higher than the "Memory" column.

Reviewers: #plasma, davidedmundson

Reviewed By: #plasma, davidedmundson

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D23382
parent 857ef2a2
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment