Check the the ops mount pointer is not NULL before indirecting through it.
[dragonfly/vkernel-mp.git] / test / sysperf / syscall1.c
blob08149c0c39f65aa217be3dcf761efe681d7acba6
1 /*
2 * syscall1.c
4 * $DragonFly: src/test/sysperf/syscall1.c,v 1.1 2003/08/12 04:29:44 dillon Exp $
5 */
7 #include "blib.h"
9 int
10 main(int ac, char **av)
12 long long count = 0;
13 long long max;
14 int j;
16 printf("timing standard getuid() syscall\n");
18 start_timing();
19 while (stop_timing(0, NULL) == 0) {
20 for (j = 0; j < 100; ++j)
21 getuid();
22 count += 100;
24 max = count;
25 start_timing();
26 for (count = 0; count < max; count += 100) {
27 for (j = 0; j < 100; ++j)
28 getuid();
30 stop_timing(count, "getuid()");
31 return(0);