ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/libev/ev.pod
(Generate patch)

Comparing libev/ev.pod (file contents):
Revision 1.350 by sf-exg, Mon Jan 10 08:36:41 2011 UTC vs.
Revision 1.352 by root, Mon Jan 10 14:30:15 2011 UTC

582=item C<EVBACKEND_PORT> (value 32, Solaris 10) 582=item C<EVBACKEND_PORT> (value 32, Solaris 10)
583 583
584This uses the Solaris 10 event port mechanism. As with everything on Solaris, 584This uses the Solaris 10 event port mechanism. As with everything on Solaris,
585it's really slow, but it still scales very well (O(active_fds)). 585it's really slow, but it still scales very well (O(active_fds)).
586 586
587Please note that Solaris event ports can deliver a lot of spurious
588notifications, so you need to use non-blocking I/O or other means to avoid
589blocking when no data (or space) is available.
590
591While this backend scales well, it requires one system call per active 587While this backend scales well, it requires one system call per active
592file descriptor per loop iteration. For small and medium numbers of file 588file descriptor per loop iteration. For small and medium numbers of file
593descriptors a "slow" C<EVBACKEND_SELECT> or C<EVBACKEND_POLL> backend 589descriptors a "slow" C<EVBACKEND_SELECT> or C<EVBACKEND_POLL> backend
594might perform better. 590might perform better.
595 591
596On the positive side, with the exception of the spurious readiness 592On the positive side, this backend actually performed fully to
597notifications, this backend actually performed fully to specification
598in all tests and is fully embeddable, which is a rare feat among the 593specification in all tests and is fully embeddable, which is a rare feat
599OS-specific backends (I vastly prefer correctness over speed hacks). 594among the OS-specific backends (I vastly prefer correctness over speed
595hacks).
596
597On the negative side, the interface is I<bizarre> - so bizarre that
598even sun itself gets it wrong in their code examples: The event polling
599function sometimes returning events to the caller even though an error
600occured, but with no indication whether it has done so or not (yes, it's
601even documented that way) - deadly for edge-triggered interfaces where
602you absolutely have to know whether an event occured or not because you
603have to re-arm the watcher.
604
605Fortunately libev seems to be able to work around these idiocies.
600 606
601This backend maps C<EV_READ> and C<EV_WRITE> in the same way as 607This backend maps C<EV_READ> and C<EV_WRITE> in the same way as
602C<EVBACKEND_POLL>. 608C<EVBACKEND_POLL>.
603 609
604=item C<EVBACKEND_ALL> 610=item C<EVBACKEND_ALL>

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines