[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [patch] Re: Can modules block on socket writes? (fwd)

On Wednesday 14 March 2001 00:25 you wrote:
> On Tue, 13 Mar 2001, Marcus Gruendler wrote:
> > Okay, this can be done and I understand your concern keeping a clean
> > and simple interface. Nevertheless this requires one switch between
> > user/kernel space each time SEND_BUFFER is issued. This would lead to
> > similar results as my approach to issue many GET/SEND_OBJECTs.
> the overhead of this is truly small, and is expected to become even
> smaller with eg. fast-syscall entry point support. iovecs are really
> unnecessery complexity.

Okay you are right. 

I just made some tests. I wrote three modules that assemble 1024 parts of a 
file into one part and send it to the client. Here are my results:

direct access ( /index.html )  76.1 Hps
write(req->sock, ... )         73.3 Hps
SEND_BUFFER                    61.5 Hps
GET/SEND_OBJECT                14.0 Hps

As you can see SEND_BUFFER is about 20% slower than the socket write. I am 
quite amazed aboud the low speed of the GET/SEND_OBJECT speed. Is there so 
much overhead in retrieving the OBJECTs? The files GET_OBJECT retrieves are 
very small (10 Bytes), but so are the buffers with SEND_BUFFER.

Bye, Marcus

Marcus Gruendler
eMail: runner@tamalin.de
WWW: http://www.tamalin.de/runner/index.html

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] []