tech-kern archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Clarification of CLOCK_MONOTONIC
Hi all,
A "simple" question about CLOCK_MONOTONIC.
How does this behave under sleep states? See clock_gettime(2) or
clock_getres(2)
For example, in FreeBSD (per the manual page), it states:
"Increments in SI seconds, even while the system is suspended.
Its epoch is unspecified. The count is not adjusted by leap seconds."
NetBSD makes no such pronouncement.
In code, for say, Linux kernel I would use CLOCK_BOOTTIME because it is
aware of suspension yet CLOCK_MONOTONIC is not.
On FreeBSD I would use CLOCK_MONOTONIC as it does as it says on the
label/man page.
On NetBSD????
Regards,
JJ
Home |
Main Index |
Thread Index |
Old Index