summaryrefslogtreecommitdiffstats
path: root/mbbsd
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-06-08 13:27:22 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-06-08 13:27:22 +0800
commit482111964ded7556166917cdb0435bcc41796d4a (patch)
tree1d993292535f05e9f6498f9348ec7c96dcaa68a8 /mbbsd
parentc9fa92954b1c6363d16be1e8b904c2aac7acebe5 (diff)
downloadpttbbs-482111964ded7556166917cdb0435bcc41796d4a.tar
pttbbs-482111964ded7556166917cdb0435bcc41796d4a.tar.gz
pttbbs-482111964ded7556166917cdb0435bcc41796d4a.tar.bz2
pttbbs-482111964ded7556166917cdb0435bcc41796d4a.tar.lz
pttbbs-482111964ded7556166917cdb0435bcc41796d4a.tar.xz
pttbbs-482111964ded7556166917cdb0435bcc41796d4a.tar.zst
pttbbs-482111964ded7556166917cdb0435bcc41796d4a.zip
show cpu usage
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2053 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd')
-rw-r--r--mbbsd/cal.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/mbbsd/cal.c b/mbbsd/cal.c
index 1434f27d..521954c3 100644
--- a/mbbsd/cal.c
+++ b/mbbsd/cal.c
@@ -422,7 +422,13 @@ p_sysinfo(void)
prints("記憶體用量: sbrk: %d KB, idrss: %d KB, isrss: %d KB\n",
((int)sbrk(0) - 0x8048000) / 1024,
(int)ru.ru_idrss, (int)ru.ru_isrss);
- prints("特別參數:"
+ prints("CPU 用量: %ld.%06ldu %ld.%06lds",
+ ru.ru_utime.tv_sec, ru.ru_utime.tv_usec,
+ ru.ru_stime.tv_sec, ru.ru_stime.tv_usec);
+#ifdef CPULIMIT
+ prints(" (limit %d secs)", CPULIMIT * 60);
+#endif
+ prints("\n特別參數:"
#ifdef CRITICAL_MEMORY
" CRITICAL_MEMORY"
#endif