[tbnl-devel] SBCL, hunchentoot, performance

Graham Fawcett graham.fawcett at gmail.com
Thu Oct 5 15:24:26 UTC 2006


On 10/5/06, Edi Weitz <edi at agharta.de> wrote:
> On Thu, 05 Oct 2006 01:19:22 +0200, Edi Weitz <edi at agharta.de> wrote:
>
> > It just occurred to me that I know what the reason for this
> > excessive consing is, and I think I also know how to fix it.  I'll
> > do that tomorrow - have to go to bed now... :)
>
> Please try with the latest (0.6.4) version of FLEXI-STREAMS.  That
> should make a difference.

I updated flexi-streams (and trivial-gray-streams, since the new
flexi-streams required an update of it). I see quite an improvement:

  seconds  |  consed | calls |  sec/call  |  name
-----------------------------------------------------
     1.044 |  36,832 |     1 |   1.043898 | TBNL:HANDLE-STATIC-FILE
     0.000 |       0 |     1 |   0.000000 | TBNL::READ-HTTP-HEADERS
     0.000 |  28,664 |     6 |   0.000000 | TBNL::WRITE-HEADER-LINE/HTTP

Reduced the conses for handle-static-file by 90%.

On the FLEX side:

  seconds  |   consed   |   calls   |  sec/call  |  name
------------------------------------------------------------
     0.000 | 71,507,496 | 1,488,124 |   0.000000 | FLEXI-STREAMS::WRITE-BYTE*
     0.000 |     49,152 |       349 |   0.000000 | FLEXI-STREAMS::READ-BYTE*

71M conses down from 106M conses on the write-byte* call; 45M down
from 81M on read-byte*.

According to the wall-clock (never trust the wall-clock!), I'm getting
downloads of my large binary at ~1800KB/sec, an apparent three-fold
improvement.

Thanks! Though not exactly fast yet, this is useable for development
purposes. I'll play with some optimization-declarations, as you
suggested, and see if I can squeeze out a bit more performance.

Regards,
Graham



More information about the Tbnl-devel mailing list