summaryrefslogtreecommitdiffstats
path: root/linux/LinuxProcess.h
diff options
context:
space:
mode:
authorNathan Scott <nathans@redhat.com>2020-12-10 11:57:48 +1100
committerNathan Scott <nathans@redhat.com>2020-12-10 11:57:48 +1100
commit75e9f9a8d92cda6ae8b161f1bf662597ac67c0f2 (patch)
tree397da395644c86f292d26bfe9226cfb5084c9735 /linux/LinuxProcess.h
parentdb5687a3556385521c42ee729aaa75a282b47c8c (diff)
Cull the definitions of pageSize and pageSizeKB from CRT.c
By storing the per-process m_resident and m_virt values in the form htop wants to display them in (KB, not pages), we no longer need to have definitions of pageSize and pageSizeKB in the common CRT code. These variables were never really CRT (i.e. display) related in the first place. It turns out the darwin platform code doesn't need to use these at all (the process values are extracted from the kernel in bytes not pages) and the other platforms can each use their own local pagesize variables, in more appropriate locations. Some platforms were actually already doing this, so this change is removing duplication of logic and variables there.
Diffstat (limited to 'linux/LinuxProcess.h')
-rw-r--r--linux/LinuxProcess.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/LinuxProcess.h b/linux/LinuxProcess.h
index ad396fb2..3c1e7e75 100644
--- a/linux/LinuxProcess.h
+++ b/linux/LinuxProcess.h
@@ -193,6 +193,10 @@ static inline bool Process_isUserlandThread(const Process* this) {
extern long long btime;
+extern int pageSize;
+
+extern int pageSizeKB;
+
extern ProcessFieldData Process_fields[];
extern ProcessPidColumn Process_pidColumns[];

© 2014-2024 Faster IT GmbH | imprint | privacy policy