2 * Copyright 2005, Axel Dörfler, axeld@pinc-software.de.
3 * Distributed under the terms of the MIT License.
11 # include <syscalls.h>
16 main(int argc
, char **argv
)
18 const int32 loops
= 100000;
19 bigtime_t startTime
= system_time();
21 for (int32 i
= 0; i
< loops
; i
++) {
23 _kern_is_computer_on();
29 bigtime_t runTime
= system_time() - startTime
;
33 startTime
= system_time();
35 for (int32 i
= 0; i
< loops
; i
++)
38 runTime
-= system_time() - startTime
;
40 printf("%f usecs/syscall\n", 1.0 * runTime
/ loops
);