From 04905aaeffba2bc77866a4056dc3f2020a86bb26 Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Wed, 8 Mar 2017 09:39:11 +0000 Subject: Update documentation for the types change, with some extra fixes Also remove --enable-replace-libc from configure --- doc/libstddjb/iopause.html | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) (limited to 'doc/libstddjb/iopause.html') diff --git a/doc/libstddjb/iopause.html b/doc/libstddjb/iopause.html index ff8727c..bcefb91 100644 --- a/doc/libstddjb/iopause.html +++ b/doc/libstddjb/iopause.html @@ -29,12 +29,12 @@ and implemented in the libskarnet.a or libskarnet.so library.

iopause is the skalibs API for event loop selection. It's a -wrapper around the system's +wrapper around the system's ppoll() or poll() (if available) or select() -(if poll() is unavailable) function. It -works around some system-dependent quirks; also it works with +(if neither ppoll() n or poll() is available) function. + It works around some system-dependent quirks; also it works with absolute dates instead of timeouts. This is a good thing: see below.

@@ -175,22 +175,23 @@ it is recommended to use this function instead of the lower-level

Underlying implementations

- iopause is an alias to either iopause_poll or -or iopause_select. By default, it is aliased to iopause_poll; to -alias it to iopause_select instead, configure skalibs with the ---enable-iopause-select option. + iopause is an alias to one of iopause_ppoll, iopause_poll or +iopause_select. It is always aliased to iopause_ppoll if +the ppoll() function is available on the system; else, it's aliased to +iopause_poll by default, and users can alias it to iopause_select +instead if they configure skalibs with the --enable-iopause-select option.

-Both iopause_poll and iopause_select are implemented on top of the -ppoll() system call -if it is available; but if it is not, then iopause_poll defaults to -poll(), -which has a more comfortable API than +poll() +has a more comfortable API than select(), -but a maximum precision of 1 millisecond which might not be enough for some applications; whereas -iopause_select defaults to select(), which incurs some CPU overhead for the -API conversion, but has a 1 microsecond precision. +but its maximum precision is 1 millisecond, which might not be enough for some applications; +using select() instead incurs some CPU overhead for the API conversion, but has a +1 microsecond precision. +ppoll() gets the best of +both worlds with the same interface model as poll() and a 1 nanosecond precision, +which is why skalibs always uses it when available.

-- cgit v1.2.3