httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: bucket->copy()
Date Thu, 09 Nov 2000 01:33:26 GMT

Yeah, I was calling this a duplicate function in all of my conversations
with people today.  If nobody beats me to it, I'll be doing it in a few


On Wed, 8 Nov 2000, Greg Stein wrote:

> I'd like to introduce a bucket->copy() function into our bucket design.
> Motivation: consider the byterange filter. It needs to select subsets of a
> brigade and send them to the client. We can remove the content from the
> original brigade in a copy-free manner, but this is a destructive
> modification to the original brigade -- we may need it for multiple ranges.
> This can also eliminate the big alloc in the filter. Rather than copy all
> the data from the original brigade into a memory buffer(!), we can copy
> portions of the buckets and insert those into the output brigade.
> Cool part: all of the refcounted buckets can support copy with *LITTLE*
> effort. These included: HEAP, POOL, and MMAP. FILE should be, but it isn't
> code that way right now. The TRANSIENT and IMMORTAL are butt-simple because
> they would just refer to the same data. EOS and FLUSH are cake, of course.
> PIPE and SOCKET are the tougher ones since they must read first, then copy
> the result. But since they read into a HEAP... they are easily copied.
> Given a copy operation, we should be able to do byterange handling without
> any data copies.
> Cheers,
> -g
> -- 
> Greg Stein,

Ryan Bloom               
406 29th St.
San Francisco, CA 94131

View raw message