… | |
… | |
2033 | |
2033 | |
2034 | Only the default event loop is capable of handling signals, and therefore |
2034 | Only the default event loop is capable of handling signals, and therefore |
2035 | you can only register child watchers in the default event loop. |
2035 | you can only register child watchers in the default event loop. |
2036 | |
2036 | |
2037 | Due to some design glitches inside libev, child watchers will always be |
2037 | Due to some design glitches inside libev, child watchers will always be |
2038 | handled at maximum priority (their priority is set to EV_MAXPRI by libev) |
2038 | handled at maximum priority (their priority is set to C<EV_MAXPRI> by |
|
|
2039 | libev) |
2039 | |
2040 | |
2040 | =head3 Process Interaction |
2041 | =head3 Process Interaction |
2041 | |
2042 | |
2042 | Libev grabs C<SIGCHLD> as soon as the default event loop is |
2043 | Libev grabs C<SIGCHLD> as soon as the default event loop is |
2043 | initialised. This is necessary to guarantee proper behaviour even if |
2044 | initialised. This is necessary to guarantee proper behaviour even if |
… | |
… | |
3670 | defined to be C<0>, then they are not. |
3671 | defined to be C<0>, then they are not. |
3671 | |
3672 | |
3672 | =item EV_MINIMAL |
3673 | =item EV_MINIMAL |
3673 | |
3674 | |
3674 | If you need to shave off some kilobytes of code at the expense of some |
3675 | If you need to shave off some kilobytes of code at the expense of some |
3675 | speed, define this symbol to C<1>. Currently this is used to override some |
3676 | speed (but with the full API), define this symbol to C<1>. Currently this |
3676 | inlining decisions, saves roughly 30% code size on amd64. It also selects a |
3677 | is used to override some inlining decisions, saves roughly 30% code size |
3677 | much smaller 2-heap for timer management over the default 4-heap. |
3678 | on amd64. It also selects a much smaller 2-heap for timer management over |
|
|
3679 | the default 4-heap. |
|
|
3680 | |
|
|
3681 | You can save even more by disabling watcher types you do not need and |
|
|
3682 | setting C<EV_MAXPRI> == C<EV_MINPRI>. |
|
|
3683 | |
|
|
3684 | Defining C<EV_MINIMAL> to C<2> will additionally reduce the core API to |
|
|
3685 | provide a bare-bones event library. See C<ev.h> for details on what parts |
|
|
3686 | of the API are still available, and do not complain if this subset changes |
|
|
3687 | over time. |
3678 | |
3688 | |
3679 | =item EV_PID_HASHSIZE |
3689 | =item EV_PID_HASHSIZE |
3680 | |
3690 | |
3681 | C<ev_child> watchers use a small hash table to distribute workload by |
3691 | C<ev_child> watchers use a small hash table to distribute workload by |
3682 | pid. The default size is C<16> (or C<1> with C<EV_MINIMAL>), usually more |
3692 | pid. The default size is C<16> (or C<1> with C<EV_MINIMAL>), usually more |