Patch: static_const nitpicky patch
Paul Lindner
lindner at inuus.com
Tue Mar 6 00:41:08 UTC 2007
If Brad want's to give me commit access I can merge these changes into
both branches..
Guess it's time to dust off svk...
On Mon, Mar 05, 2007 at 02:55:44PM -0800, Steven Grimm wrote:
> No objections here! Paul, if you have time to merge this into the
> multithreaded branch as well as checking it in to the single-threaded
> code base, that'd be great.
>
> -Steve
>
>
> Brad Fitzpatrick wrote:
> >Paul, thanks!
> >
> >Steven, if you have no objections, where do you want this? In both the
> >2.x and mt trees? I could just get Paul commit access to commit it
> >himself, if you say where you want it.
> >
> >
> >On Fri, 2 Mar 2007, Paul Lindner wrote:
> >
> >
> >>Okay, more janitorial work. I have to go back and do day job stuff
> >>now. :)
> >>
> >> * Add autoconf magic for stdbool.h
> >> * Use booleans as appropriate in a few places
> >> * Add slabs.h, items.h and assoc.h
> >> * Move most of the declarations from memcached.h into memcached.c
> >> where they belong. Added appropriate static quantifiers.
> >> * Correctly use NULL for pointers, 0 for integers for logic tests
> >> and return values.
> >>
> >>Size clocks in at a lean 37812 bytes. With a little more pruning (or
> >>-Os) we should be able to get it to run inside the L1 cache :)
> >>
> >>
> >>On Fri, Mar 02, 2007 at 03:59:55AM -0800, Paul Lindner wrote:
> >>
> >>>So I dived into the memcached code and found a number of simple
> >>>cleanups involving judicious use of const and static.
> >>>
> >>>Depending on how the code base evolves one could move many of the
> >>>declarations in memcached.h into memcached.c and declare many more
> >>>functions static.
> >>>
> >>>Ideally only the exposed interface for each .c file would be
> >>>contained in the .h file.
> >>>
> >>>All tests pass, the compiled/stripped executable size drops about 5%
> >>>with these changes. On my machine
> >>>
> >>>clean trunk 39972 bytes
> >>>modded trunk 38244 bytes
> >>>
> >>>
> >>>
> >>
--
Paul Lindner ||||| | | | | | | | | |
lindner at inuus.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.danga.com/pipermail/memcached/attachments/20070305/0e75a02d/attachment.pgp
More information about the memcached
mailing list