aboutsummaryrefslogtreecommitdiff
path: root/procps/top.c
diff options
context:
space:
mode:
Diffstat (limited to 'procps/top.c')
-rw-r--r--procps/top.c29
1 files changed, 29 insertions, 0 deletions
diff --git a/procps/top.c b/procps/top.c
index f9106fac7..1eb33dc5d 100644
--- a/procps/top.c
+++ b/procps/top.c
@@ -833,6 +833,35 @@ enum {
833 | PSSCAN_COMM, 833 | PSSCAN_COMM,
834}; 834};
835 835
836//usage:#if ENABLE_FEATURE_SHOW_THREADS || ENABLE_FEATURE_TOP_SMP_CPU
837//usage:# define IF_SHOW_THREADS_OR_TOP_SMP(...) __VA_ARGS__
838//usage:#else
839//usage:# define IF_SHOW_THREADS_OR_TOP_SMP(...)
840//usage:#endif
841//usage:#define top_trivial_usage
842//usage: "[-b] [-nCOUNT] [-dSECONDS]" IF_FEATURE_TOPMEM(" [-m]")
843//usage:#define top_full_usage "\n\n"
844//usage: "Provide a view of process activity in real time."
845//usage: "\n""Read the status of all processes from /proc each SECONDS"
846//usage: "\n""and display a screenful of them."
847//usage: "\n""Keys:"
848//usage: "\n"" N/M"
849//usage: IF_FEATURE_TOP_CPU_USAGE_PERCENTAGE("/P")
850//usage: IF_FEATURE_TOP_CPU_USAGE_PERCENTAGE("/T")
851//usage: ": " IF_FEATURE_TOPMEM("show CPU usage, ") "sort by pid/mem"
852//usage: IF_FEATURE_TOP_CPU_USAGE_PERCENTAGE("/cpu")
853//usage: IF_FEATURE_TOP_CPU_USAGE_PERCENTAGE("/time")
854//usage: IF_FEATURE_TOPMEM(
855//usage: "\n"" S: show memory, R: reverse memory sort"
856//usage: )
857//usage: IF_SHOW_THREADS_OR_TOP_SMP(
858//usage: "\n"" "
859//usage: IF_FEATURE_SHOW_THREADS("H: toggle threads")
860//usage: IF_FEATURE_SHOW_THREADS(IF_FEATURE_TOP_SMP_CPU(", "))
861//usage: IF_FEATURE_TOP_SMP_CPU("1: toggle SMP")
862//usage: )
863//usage: "\n"" Q,^C: exit"
864
836int top_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; 865int top_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
837int top_main(int argc UNUSED_PARAM, char **argv) 866int top_main(int argc UNUSED_PARAM, char **argv)
838{ 867{