]> granicus.if.org Git - procps-ng/commit
top: show fewer decimal places for memory (by default)
authorJim Warner <james.warner@comcast.net>
Wed, 8 Mar 2017 06:00:00 +0000 (00:00 -0600)
committerCraig Small <csmall@enc.com.au>
Thu, 16 Mar 2017 10:59:53 +0000 (21:59 +1100)
commitfe6e03d8a9726f32894ee4585019b11a1738c500
tree3045d2821b29d377396328734d973e05c4fefbf6
parentddcdba18b73df0ec254662618ef63ae1d9dc1f7e
top: show fewer decimal places for memory (by default)

After much reflection I've come to the conclusion that
displaying 3 decimal places (usually) when memory data
had been scaled is no longer optimal with today's ever
increasing amounts. And given that not all task memory
fields are the same widths, inconsistencies can easily
arise as illustrated and discussed in the issue below.

Instead of unilaterally reducing the number of decimal
places, this commit will sneak in such a change via an
existing configure option that was very likely unused.

The former 'disable-wide-memory' option has now become
'enable-wide-memory', which can be used if the current
behavior (3 decimal places) is preferred. Without that
option, whenever memory is scaled beyond KiB, just one
decimal place will be shown in Summary and Task areas.

And Task area field width will no longer be changed by
this revised configure option. Instead, all such field
widths will now be fixed at the former maximum values.

Reference(s):
https://gitlab.com/procps-ng/procps/issues/50

Signed-off-by: Jim Warner <james.warner@comcast.net>
NEWS
configure.ac
top/top.c
top/top.h