HomeFreeBSD

Improve timeout precision of pthread_cond_timedwait().

Description

Improve timeout precision of pthread_cond_timedwait().

This code was not touched when all other user-space sleep functions were
switched to sbintime_t and decoupled from hardclock. When it is possible,
convert supplied times into sbinuptime to supply directly to msleep_sbt()
with C_ABSOLUTE. This provides the timeout resolution of few microseconds
instead of 2 milliseconds, plus avoids few clock reads and conversions.

Reviewed by: vangyzen
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D34163

Details

Provenance
mavAuthored on Mar 4 2022, 3:03 AM
Reviewer
vangyzen
Differential Revision
D34163: Improve timeout precision of pthread_cond_timedwait()
Parents
rG0b25cbc79d38: Fix the size returned for NT_FPREGSET.
Branches
Unknown
Tags
Unknown