top: provide a build option to change memory precision

When summary & task area memory scaling was introduced
in release 3.3.6, the memory field widths were widened
slightly so unscaled KiB values could be provided more
consistently and scaled values (beyond MiB) could show
3 decimal places of precision. However, some users may
prefer the former widths/precisions for memory fields.

This commit will provide a build time configure option
to return top to those former defaults as a compliment
to a new %CPU & %MEM field precision configure option.

Reference(s):
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=707648
commit 21e550bc08

Signed-off-by: Jim Warner <james.warner@comcast.net>
This commit is contained in:
Jim Warner
2013-05-14 00:00:00 -05:00
committed by Craig Small
parent 77abe18d01
commit 2ede50902f
2 changed files with 9 additions and 1 deletions

View File

@ -203,6 +203,14 @@ if test "x$enable_wide_percent" = xyes; then
AC_DEFINE(BOOST_PERCNT, 1, [provide extra precision under %CPU and %MEM for top])
fi
AC_ARG_ENABLE([wide-memory],
AS_HELP_STRING([--disable-wide-memory], [disable extra precision under memory fields for top]),
[disable_wide_memory=yes], []
)
if test "x$disable_wide_memory" = xyes; then
AC_DEFINE(NOBOOST_MEMS, 1, [disable extra precision under memory fields for top])
fi
DL_LIB=
AC_ARG_ENABLE([numa],
AS_HELP_STRING([--disable-numa], [disable NUMA/Node support in top]),