← Back to team overview

rohc team mailing list archive

Re: Patch to optimize WLSB memory allocation (Was: Support of RFC4996 RoHC-TCP)


> >   Attached is a new patch to optimize wlsb.c in the current branch.
> > 
> >   I suppress the field "is_used" in the c_window structure, and add
> > the fields "count" and "window_mask" in the c_wlsb structure to
> > optimize the code.
> > 
> >   Pointers "next" and "oldest" are calculated using the size of the 
> > window, minus 1, as mask. No need of modulo.
> > 
> >   I think the code is faster, and more compact.
> I committed your patch in trunk with small style changes [1]. Thank
> you!

Automated tests with Valgrind detected [2] a bug in c_ack_sn_wlsb(). I
fixed it in the trunk [3].

[2] http://buildbot.rohc-lib.org:8011/builders/rohc-library-main-x86-gcc47/builds/74
[3] http://bazaar.launchpad.net/~didier-barvaux/rohc/main/revision/395 

Attachment: signature.asc
Description: PGP signature