From eb1bc8c273c61969b95223a2067db3606ed05a55 Mon Sep 17 00:00:00 2001 From: Jim Warner Date: Thu, 28 Jul 2022 00:00:00 -0500 Subject: [PATCH] library: change misnamed VSIZE_PGS item to VSIZE_BYTES Gosh this particular flaw originated way back in 2015. [ that was when we burdened a caller with additional ] [ responsibilities for 'stacks_alloc', 'stacks_fill' ] [ and 'stacks_dealloc'. damn implementation details. ] Reference(s): . Aug, 2015 - introduced api commit 7e6a371d8a36b250a2edddff9f5d059640b8132e Signed-off-by: Jim Warner --- proc/pids.c | 4 ++-- proc/pids.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/proc/pids.c b/proc/pids.c index 3f9b9457..0d883139 100644 --- a/proc/pids.c +++ b/proc/pids.c @@ -302,7 +302,7 @@ REG_set(VM_SIZE, ul_int, vm_size) REG_set(VM_STACK, ul_int, vm_stack) REG_set(VM_SWAP, ul_int, vm_swap) setDECL(VM_USED) { (void)I; R->result.ul_int = P->vm_swap + P->vm_rss; } -REG_set(VSIZE_PGS, ul_int, vsize) +REG_set(VSIZE_BYTES, ul_int, vsize) setDECL(WCHAN_NAME) { freNAME(str)(R); if (!(R->result.str = strdup(lookup_wchan(P->tid)))) I->seterr = 1;; } #undef setDECL @@ -593,7 +593,7 @@ static struct { { RS(VM_STACK), f_status, NULL, QS(ul_int), 0, TS(ul_int) }, { RS(VM_SWAP), f_status, NULL, QS(ul_int), 0, TS(ul_int) }, { RS(VM_USED), f_status, NULL, QS(ul_int), 0, TS(ul_int) }, - { RS(VSIZE_PGS), f_stat, NULL, QS(ul_int), 0, TS(ul_int) }, + { RS(VSIZE_BYTES), f_stat, NULL, QS(ul_int), 0, TS(ul_int) }, { RS(WCHAN_NAME), 0, FF(str), QS(str), 0, TS(str) }, // oldflags: tid already free }; diff --git a/proc/pids.h b/proc/pids.h index 13b57bde..60df4133 100644 --- a/proc/pids.h +++ b/proc/pids.h @@ -185,7 +185,7 @@ enum pids_item { PIDS_VM_STACK, // ul_int status: VmStk PIDS_VM_SWAP, // ul_int status: VmSwap PIDS_VM_USED, // ul_int derived from status: VmRSS + VmSwap - PIDS_VSIZE_PGS, // ul_int stat: vsize + PIDS_VSIZE_BYTES, // ul_int stat: vsize PIDS_WCHAN_NAME // str wchan }; // * while these are all expressed as seconds, each can be -- 2.40.0