[ccan] CCAN Update for 2014-11

Rusty Russell rusty at rustcorp.com.au
Fri Dec 12 15:21:49 AEDT 2014


Hi all!

        A quiet month as I wrap up my sabbatical, but there have been
three new modules:

Module of the Month: ccan/timer
===============================

This module optimizes the common case where timers are deleted before
expiry (so we don't have to sort them until they're nearly due to
expire).  It uses an exponential series of buckets, similar to that
described for the Linux kernel (see http://lwn.net/Articles/152436/ ).

It's a simple API to which you feed 'struct timer's and the time values
explicitly.  You use timer_add() and timer_del() on a "timers"
structure.  timer_earliest() tells you when the first timer expires, or
you pass timers_expire() the current time, and it will return an expired
timer (or NULL), forwarding to the current time.

New modules:
============
        cdump - trivial hacky C header parser for eg. to autogen enum strings
        iblt - an invertible bloom lookup table implementation
        pushpull - simple (little-endian) data marshalling

Minor updates & bugfixes:
========================
        timer - timer_del() is idempotent (no harm if it gets called twice), and
                timers_expire() returns a single timer not a linked list.

Tools:
======
	ccanlint - offer to insert license lines if not there already.
	ccanlint - look in all headers (not just main) for examples to test.

Cheers,
Rusty.

 
        


More information about the ccan mailing list