]> git.llucax.com Git - software/libev.git/blobdiff - ev.html
*** empty log message ***
[software/libev.git] / ev.html
diff --git a/ev.html b/ev.html
index 9192f3251d6c047d00e49ea797923f99f78d41e8..63ddf3b8988edf00afd61acd21c248d79d9d8c29 100644 (file)
--- a/ev.html
+++ b/ev.html
@@ -6,7 +6,7 @@
        <meta name="description" content="Pod documentation for libev" />
        <meta name="inputfile" content="&lt;standard input&gt;" />
        <meta name="outputfile" content="&lt;standard output&gt;" />
        <meta name="description" content="Pod documentation for libev" />
        <meta name="inputfile" content="&lt;standard input&gt;" />
        <meta name="outputfile" content="&lt;standard output&gt;" />
-       <meta name="created" content="Fri Dec  7 20:07:44 2007" />
+       <meta name="created" content="Fri Dec  7 20:23:46 2007" />
        <meta name="generator" content="Pod::Xhtml 1.57" />
 <link rel="stylesheet" href="http://res.tst.eu/pod.css"/></head>
 <body>
        <meta name="generator" content="Pod::Xhtml 1.57" />
 <link rel="stylesheet" href="http://res.tst.eu/pod.css"/></head>
 <body>
@@ -2241,6 +2241,11 @@ that everybody includes and which overrides some configure choices:</p>
                <p>In this section the complexities of (many of) the algorithms used inside
 libev will be explained. For complexity discussions about backends see the
 documentation for <code>ev_default_init</code>.</p>
                <p>In this section the complexities of (many of) the algorithms used inside
 libev will be explained. For complexity discussions about backends see the
 documentation for <code>ev_default_init</code>.</p>
+               <p>All of the following are about amortised time: If an array needs to be
+extended, libev needs to realloc and move the whole array, but this
+happens asymptotically never with higher number of elements, so O(1) might
+mean it might do a lengthy realloc operation in rare cases, but on average
+it is much faster and asymptotically approaches constant time.</p>
                <p>
                        <dl>
                                <dt>Starting and stopping timer/periodic watchers: O(log skipped_other_timers)</dt>
                <p>
                        <dl>
                                <dt>Starting and stopping timer/periodic watchers: O(log skipped_other_timers)</dt>
@@ -2256,12 +2261,9 @@ as only the relative motion in the event queue has to be paid for.</p>
                                </dd>
                                <dt>Starting io/check/prepare/idle/signal/child watchers: O(1)</dt>
                                <dd>
                                </dd>
                                <dt>Starting io/check/prepare/idle/signal/child watchers: O(1)</dt>
                                <dd>
-                                       <p>These just add the watcher into an array or at the head of a list. If
-the array needs to be extended libev needs to realloc and move the whole
-array, but this happen asymptotically less and less with more watchers,
-thus amortised O(1).</p>
+                                       <p>These just add the watcher into an array or at the head of a list.
+=item Stopping check/prepare/idle watchers: O(1)</p>
                                </dd>
                                </dd>
-                               <dt>Stopping check/prepare/idle watchers: O(1)</dt>
                                <dt>Stopping an io/signal/child watcher: O(number_of_watchers_for_this_(fd/signal/pid % EV_PID_HASHSIZE))</dt>
                                <dd>
                                        <p>These watchers are stored in lists then need to be walked to find the
                                <dt>Stopping an io/signal/child watcher: O(number_of_watchers_for_this_(fd/signal/pid % EV_PID_HASHSIZE))</dt>
                                <dd>
                                        <p>These watchers are stored in lists then need to be walked to find the