Revert "Use allocation granularity as the 'page_size' in /proc/<pid>/status as well, for consistency with /proc/<pid>/statm"
This reverts commit 8a32c24a7b
.
Replacing page_size() with allocation_granularity() was incorrect.
The values returned by get_mem_values() are # of pages of size
page_size(). Multiplying with allocation_granularity() here
results in values 16 times too big.
This commit is contained in:
parent
76d17e6860
commit
ca2ec0c5cc
|
@ -1216,7 +1216,7 @@ format_process_status (void *data, char *&destbuf)
|
||||||
if (!get_mem_values (p->dwProcessId, &vmsize, &vmrss, &vmtext, &vmdata,
|
if (!get_mem_values (p->dwProcessId, &vmsize, &vmrss, &vmtext, &vmdata,
|
||||||
&vmlib, &vmshare))
|
&vmlib, &vmshare))
|
||||||
return 0;
|
return 0;
|
||||||
unsigned page_size = wincap.allocation_granularity ();
|
unsigned page_size = wincap.page_size ();
|
||||||
vmsize *= page_size; vmrss *= page_size; vmdata *= page_size;
|
vmsize *= page_size; vmrss *= page_size; vmdata *= page_size;
|
||||||
vmtext *= page_size; vmlib *= page_size;
|
vmtext *= page_size; vmlib *= page_size;
|
||||||
/* The real uid value for *this* process is stored at cygheap->user.real_uid
|
/* The real uid value for *this* process is stored at cygheap->user.real_uid
|
||||||
|
|
Loading…
Reference in New Issue