apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cliff Woolley <jwool...@virginia.edu>
Subject Re: bucket api patch
Date Sun, 03 Mar 2002 06:51:44 GMT
On Sat, 2 Mar 2002, Brian Pane wrote:

>     8              10%
>    16              15%
>    32              73%
>  8192               2%

Cool, that looks exactly like what I'd expected it to look like.  Thanks
for doing that.

> The 8KB allocations are from apr_brigade_write().

Not all of them should be.  If they are, I forgot some changes.  All of
the APR_BUCKET_BUFF_SIZE malloc()'s should have been changed to
apr_bucket_alloc() calls, and those happen in foo_read() and
apr_bucket_heap_make() and a handful of other places in addition to
apr_brigade_write().  Though we might not be hitting many of those other
spots since we have sendfile and mmap, etc.

> These 8KB blocks imply a design constraint for
> the bucket allocator: it can't quite be a simple
> power-of-two allocator.

I'd thought about that.  We are of course free to pick whatever block
sizes we want.... if we want a block size that's just a bit bigger than
8KB, I don't see a problem with that.  Or we could just decrease
APR_BUCKET_BUFF_SIZE a bit so that we stay inside our two-page (on most
systems) 8KB boundary.  Either way's fine with me.


   Cliff Woolley
   Charlottesville, VA

View raw message