Commit | Line | Data |
---|---|---|
ae59e04c | 1 | .\" Copyright (c) 1990, 1991 The Regents of the University of California. |
936cff82 KB |
2 | .\" All rights reserved. |
3 | .\" | |
043368e6 KB |
4 | .\" This code is derived from software contributed to Berkeley by |
5 | .\" the American National Standards Committee X3, on Information | |
6 | .\" Processing Systems. | |
7 | .\" | |
91cff1e1 | 8 | .\" %sccs.include.redist.man% |
936cff82 | 9 | .\" |
043368e6 | 10 | .\" @(#)clock.3 5.4 (Berkeley) %G% |
936cff82 | 11 | .\" |
ae59e04c CL |
12 | .Dd |
13 | .Dt CLOCK 3 | |
14 | .Os | |
15 | .Sh NAME | |
16 | .Nm clock | |
17 | .Nd determine processor time used | |
18 | .Sh SYNOPSIS | |
19 | .Fd #include <sys/types.h> | |
20 | .Ft clock_t | |
21 | .Fn clock void | |
22 | .Sh DESCRIPTION | |
23 | The | |
24 | .Fn clock | |
25 | function | |
26 | determines the amount of processor time used since the invocation of the | |
27 | calling process, measured in | |
28 | .Dv CLK_TCK Ns s. | |
29 | .Sh RETURN VALUES | |
30 | The | |
31 | .Fn clock | |
32 | function returns the amount of time used unless an error occurs, in which | |
33 | case the return value is \-1. | |
34 | .Sh SEE ALSO | |
35 | .Xr getrusage 2 | |
36 | .Sh STANDARDS | |
37 | The | |
38 | .Fn clock | |
39 | function conforms to | |
40 | .St -ansiC . |