posix-next API 0.1.0
Out-of-tree Zephyr POSIX module
Loading...
Searching...
No Matches
_POSIX_CPUTIME

POSIX CPU-Time Clocks option. More...

Macros

#define CLOCK_PROCESS_CPUTIME_ID   ((clockid_t)2)
 CPU-time clock for the calling process.
 

Functions

int clock_getcpuclockid (pid_t pid, clockid_t *clock_id)
 Get the CPU-time clock ID for a process.
 

Detailed Description

POSIX CPU-Time Clocks option.

Macro Definition Documentation

◆ CLOCK_PROCESS_CPUTIME_ID

#define CLOCK_PROCESS_CPUTIME_ID   ((clockid_t)2)

CPU-time clock for the calling process.

Definition at line 122 of file time.h.

Function Documentation

◆ clock_getcpuclockid()

int clock_getcpuclockid ( pid_t  pid,
clockid_t clock_id 
)

Get the CPU-time clock ID for a process.

Parameters
pidProcess ID (0 = calling process).
clock_idOutput: clock ID.
Returns
0 on success, or a positive error number on failure.
See also
https://pubs.opengroup.org/onlinepubs/9699919799/functions/clock_getcpuclockid.html