Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ hrtcntl(3C) — Reliant UNIX 5.44c4

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

getitimer(3C)

hrtalarm(3C)

hrtcntl(3C)                                                     hrtcntl(3C)

NAME
     hrtcntl - high resolution timer control

SYNOPSIS
     #include <sys/hrtcntl.h>

     int hrtcntl(int cmd, int clk, intervalt *intp, hrtimet *hrtp);

DESCRIPTION
     hrtcntl() provides an interface for high resolution or interval
     timers.

     cmd determines the command:

          HRTGETRES
               Gets the resolution of a clock. If the call succeeds, the
               timer resolution is returned.

          HRTTOFD
               Gets the value of time since 00:00:00 GMT, January 1, 1970.
               The field hrtres determines the timer resolution. When
               called, hrtp contains the time value.

          HRTSTARTIT
               Start the time for an activity. When called, intp contains
               the current values for the specified clock type.

          HRTGETIT
               Returns the elapsed interval since the HRTSTARTIT command
               was called. When called, hrtp contains the elapsed time.

     clk determines the clock type:

          CLKSTD
               Standard real time clock.

          CLKUSERVIRT
               Clock measuring process virtual time (user mode).

          CLKPROCVIRT
               Clock measuring process virtual time and when the system is
               running on behalf of the process (user and system mode).

RESULT
     If the calls succeed, a value of 0 is returned. If an error occurs,
     the value -1 is returned, and an error code is placed in the global
     variable errno.

     Under the following conditions, the function hrtcntl() fails and sets
     errno to:

     EINVAL    Illegal value for cmd or clk.



Page 1                       Reliant UNIX 5.44                Printed 11/98

hrtcntl(3C)                                                     hrtcntl(3C)

     EFAULT    hrtp or intp points outside the allocated address space of
               the process.

     ERANGE    Illegal timer resolution.

NOTES
     The hrtsleep() and hrtcancel() functions are not supported and simply
     return the error ENOPKG.

SEE ALSO
     getitimer(3C), hrtalarm(3C).











































Page 2                       Reliant UNIX 5.44                Printed 11/98

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026