CPUTIME(2) CPUTIME(2)
NAME
cputime, times - cpu time in this process and children
SYNOPSIS
#include <u.h>
#include <libc.h>
int times(long t[4])
double cputime(void)
DESCRIPTION
If t is non-null, times fills it in with the number of mil-
liseconds spent in user code, system calls, child processes
in user code, and child processes in system calls. Cputime
returns the sum of those same times, converted to seconds.
Times returns the real time, in milliseconds used by the
process so far.
These functions read /dev/cputime, opening that file when
they are first called.
SOURCE
/sys/src/libc/9sys
SEE ALSO
cons(3)
Page 1 Plan 9 (printed 3/7/26)