Monoton clock on IRIX

I want to get a monotonous clock on IRIX, for example:

clock_gettime(CLOCK_MONOTONIC, &t); 

But CLOCK_MONOTONIC does not exist on IRIX.

It has CLOCK_SGI_CYCLE, but this (as the names say) alternates too often (about every 90 seconds on my machine, if you're interested).

Are there any other (fairly high values) watches that I can use that are not affected by time changes (ntp or others)?

+4
source share
1 answer

_rtc is the fastest clock in the system that does not wrap. This is a compiler extension, so I think you have to use SGI compilers. If the "fairly high level" is good enough, it is likely to be good; if you need even better resolution, you will have to hack a combination of it with CLOCK_SGI_CYCLE.

http://docs.sgi.com/library/tpl/cgi-bin/getdoc.cgi?cmd=getdoc&coll=0650&db=man&fname=3%20RTC

+2
source

Source: https://habr.com/ru/post/1305857/


All Articles