freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

libev手冊-資料下載頁

2025-06-29 08:31本頁面
  

【正文】 han epoll for maybe up to a hundred file descriptors, depending on the usage. So sad.While nominally embeddable in other event loops, this feature is broken in all kernel versions tested so far.This backend maps EV_READ and EV_WRITE in the same way as EVBACKEND_POLL.EVBACKEND_KQUEUE (value 8, most BSD clones) Kqueue deserves special mention, as at the time of this writing, it was broken on all BSDs except NetBSD (usually it doesn39。t work reliably with anything but sockets and pipes, except on Darwin, where of course it39。s pletely useless). Unlike epoll, however, whose brokenness is by design, these kqueue bugs can (and eventually will) be fixed without API changes to existing programs. For this reason it39。s not being autodetected unless you explicitly specify it in the flags (. using EVBACKEND_KQUEUE) or libev was piled on a knowntobegood (enough) system like NetBSD.You still can embed kqueue into a normal poll or select backend and use it only for sockets (after having made sure that sockets work with kqueue on the target platform). See ev_embed watchers for more info.It scales in the same way as the epoll backend, but the interface to the kernel is more efficient (which says nothing about its actual speed, of course). While stopping, setting and starting an I/O watcher does never cause an extra system call as with EVBACKEND_EPOLL, it still adds up to two event changes per incident. Support for fork () is very bad (but sane, unlike epoll) and it drops fds silently in similarly hardtodetect casesThis backend usually performs well under most conditions.While nominally embeddable in other event loops, this doesn39。t work everywhere, so you might need to test for this. And since it is broken almost everywhere, you should only use it when you have a lot of sockets (for which it usually works), by embedding it into another event loop (. EVBACKEND_SELECT or EVBACKEND_POLL (but poll is of course also broken on OS X)) and, did I mention it, using it only for sockets.This backend maps EV_READ into an EVFILT_READ kevent with NOTE_EOF, and EV_WRITE into an EVFILT_WRITE kevent with NOTE_EOF.EVBACKEND_DEVPOLL (value 16, Solaris 8) This is not implemented yet (and might never be, unless you send me an implementation). According to reports, /dev/poll only supports sockets and is not embeddable, which would limit the usefulness of this backend immensely.EVBACKEND_PORT (value 32, Solaris 10) This uses the Solaris 10 event port mechanism. As with everything on Solaris, it39。s really slow, but it still scales very well (O(active_fds)).While this backend scales well, it requires one system call per active file descriptor per loop iteration. For small and medium numbers of file descriptors a slow EVBACKEND_SELECT or EVBACKEND_POLL backend might perform better.On the positive side, this backend actually performed fully to specification in all tests and is fully embeddable, which is a rare feat among the OSspecific backends (I vastly prefer correctness over speed hacks).On the negative side, the interface is bizarre so bizarre that even sun itself gets it wrong in their code examples: The event polling function sometimes returns events to the caller even though an error occurred, but with no indication whether it has done so or not (yes, it39。s even documented that way) deadly for edgetriggered interfaces where you absolutely have to know whether an event occurred or not because you have to rearm the watcher.Fortunately libev seems to be able to work around these idiocies.This backend maps EV_READ and EV_WRITE in the same way as EVBACKEND_POLL.EVBACKEND_ALL Try all backends (even potentially broken ones that wouldn39。t be tried with EVFLAG_AUTO). Since this is a mask, you can do stuff such as EVBACKEND_ALL amp。 ~EVBACKEND_KQUEUE.It is definitely not remended to use this flag, use whatever ev_remended_backends () returns, or simply do not specify a backend at all.EVBACKEND_MASK Not a backend at all, but a mask to select all backend bits from a flags value, in case you want to mask out any backends from a flags value (. when modifying the LIBEV_FLAGS environment variable).If one or more of the backend flags are or39。ed into the flags value, then only these backends will be tried (in the reverse order as listed here). If none are specified, all backends in ev_remended_backends () will be tried.Example: Try to create a event loop that uses epoll and nothing else. struct ev_loop *epoller = ev_loop_new (EVBACKEND_EPOLL | EVFLAG_NOENV)。 if (!epoller) fatal (no epoll found here, maybe it hides under your chair)。Example: Use whatever libev has to offer, but make sure that kqueue is used if available. struct ev_loop *loop = ev_loop_new (ev_remended_backends () | EVBACKEND_KQUEUE)。ev_loop_destroy (loop) Destroys an event loop object (frees all memory and kernel state etc.). None of the active event watchers will be stopped in the normal sense, so . ev_is_active might still return true. It is your responsibility to either stop all watchers cleanly yourself before calling this function, or cope with the fact afterwards (which is usually the easiest thing, you can just ignore the watchers and/or free () them for example).Note that certain global state, such as signal state (and installed signal handlers), will not be freed by this function, and related watchers (such as signal and child watchers) would need to be stopped manually.This function is normally used on loop objects allocated by ev_loop_new, but it can also be used on the default loop returned by ev_default_loop, in which case it is not threadsafe.Note that it is not advisable to call this function on the default loop except in the rare occasion where you really need to free its resources. If you need dynamically allocated loops it is better to use ev_loop_new and ev_loop_destroy.ev_loop_fork (loop) This function sets a flag that causes subsequent ev_run iterations to re
點擊復制文檔內(nèi)容
范文總結(jié)相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1