gnash-commit
[Top][All Lists]
Advanced

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

Re: [Gnash-commit] gnash ChangeLog libamf/element.cpp libnet/cque....


From: Rob Savoye
Subject: Re: [Gnash-commit] gnash ChangeLog libamf/element.cpp libnet/cque....
Date: Mon, 07 Apr 2008 14:27:54 -0600
User-agent: Thunderbird 2.0.0.9 (X11/20071115)

strk wrote:
> On Mon, Apr 07, 2008 at 01:54:11PM -0600, Rob Savoye wrote:

> Is the "less-than" ensured somehow or just an empirical assumption ?
> I mean... what if the whole packet size happens to be a multiple of
> NETBUFSIZE ?

  Which is possible, but then it gets handled at a higher level by the
protocol code. ::merge() is only supposed to be called by protocol code
like RTMP, and isn't used internally anywhere. So far in heavy testing
though, this has never happened. RTMP knows how many bytes it wants, so
it only merges buffers when it knows it is missing data. What's more fun
is it often sends a 1 byte packet during the handshake process, preceded
by the 1536 byte one, which is why I added the ::merge() method.

  All the new networking code relies on the zero copy technique for
speed. Anytime a buffer of data is copied, there is a performance hit,
so you want to do it as seldom as possible. Ultimately I want to avoid
having to ever merge buffers, but right now it does make some issues
with RTMP, like the 1536 byte handshake packet that gets bounced back
and forth a few times.

>       Before merge:
>       A1 A2 A3 B1 B2 B3 B4 C1 C2 
> 
>       After merge starting at B:
>       A1 A2 A3 A4 B C1 C2

  Correct, the order shouldn't change.

> This would be nice adding a check for in the existing test.

  I'd be nice to have a better test case too. :-) There are only so many
hours in a day... My hope is as the bugs get all fixed, I'll add more
tests to find more bugs. Right now though I also use Cygnal as a big
testcase, since that's what is using all this new code.

        - rob -




reply via email to

[Prev in Thread] Current Thread [Next in Thread]