From a913efa19a1e3a7f8f4dbf3921a0574fc81d352a Mon Sep 17 00:00:00 2001 From: sbosse Date: Wed, 22 Jan 2025 23:35:31 +0100 Subject: [PATCH] Wed 22 Jan 23:34:35 CET 2025 --- user/sysstat.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/user/sysstat.c b/user/sysstat.c index a723fdf..56d4819 100644 --- a/user/sysstat.c +++ b/user/sysstat.c @@ -5,6 +5,7 @@ See the file LICENSE for details. */ #include "library/syscalls.h" +#include "library/stdlib.h" #include "library/string.h" #include "library/stdio.h" @@ -18,6 +19,13 @@ int main(int argc, char *argv[]) } printf("System uptime: %u:%u:%u\n", s.time / (3600), (s.time % 3600) / 60, s.time % 60); +#ifdef USER_SYSSTAT_EXT + { + unsigned long t1=micros(), + t2=micros(); + printf("System microtime: %u D=%u\n",t1,t2-t1); + } +#endif printf("Disk 0: %d blocks read, %d blocks written\n", s.blocks_read[0], s.blocks_written[0]); printf("Disk 1: %d blocks read, %d blocks written\n", s.blocks_read[1], s.blocks_written[1]); printf("Disk 2: %d blocks read, %d blocks written\n", s.blocks_read[2], s.blocks_written[2]);