clock_getcpuclockid - access a process CPU-time clock (ADVANCED REALTIME)
#include <time.h>
int clock_getcpuclockid(pid_t pid, clockid_t *clock_id);
The clock_getcpuclockid() function shall return the clock ID of the CPU-time clock of the process specified by pid. If the process described by pid exists and the calling process has permission, the clock ID of this clock shall be returned in clock_id.
If pid is zero, the clock_getcpuclockid() function shall return the clock ID of the CPU-time clock of the process making the call, in clock_id.
The conditions under which one process has permission to obtain the CPU-time clock ID of other processes are implementation-defined.
Upon successful completion, clock_getcpuclockid() shall return zero; otherwise, an error number shall be returned to indicate the error.
The clock_getcpuclockid() function shall fail if:
The clock_getcpuclockid() function may fail if:
The following sections are informative.
The clock_getcpuclockid() function is part of the Process CPU-Time Clocks option and need not be provided on all implementations.
clock_getres() , timer_create() , the Base Definitions volume of IEEE Std 1003.1-2001, <time.h>
Закладки на сайте Проследить за страницей |
Created 1996-2024 by Maxim Chirkov Добавить, Поддержать, Вебмастеру |