dean gaudet wrote:
>
>On Wed, 26 Sep 2001, Brian Pane wrote:
>
>>I characterize Apache's performance as being limited by two very
>>different classes of factors:
>>
>> * Architectural factors  e.g., a threadperconnection server
>> generally will be slower than an eventloop server.
>>
>
>another way to think of these is as the constants which are hidden by the
>O() notation. the architecture is OK in a theoretical sense, but there
>are some really really big constants hidden in the O()s that we'd use to
>describe the architecture.
>
I like that constantfactor description because it nicely captures the other
big way in which httpd performance has improved over time: As key operations
in the OS get more efficient (quicker context switches, for example, or
zerocopy sendfile), the constant factor drops.
>> * Implementation factors  e.g., using O(n)time algorithms where
>> O(log(n)) is possible, or making extraneous system calls.
>>
>
>if you know of any cases where an O(n) > O(log(n)) change can be made i'd
>like to hear about them...
>
request_rec>headers_in
apr_table_t in general: aside from the HTTP headers, the O(n) "set"
functions
result in an O(n^2) cost for things that need to insert n items into
subprocess_env
(mod_include, CGIs).
Maybe ap_find_command_in_modules() too (possibly useful in speeding up
.htaccess
file processing)
There are various places where we may be able to go from O(n) to O(1) by
optimizing away strdup() calls.
Brian
