On Friday 11 July 2008 20:21, Vladimir Dronnikov wrote: > I wonder what eats less memory: > e.g. running a bunch of static svlogds from runit or run a bunch of BB > svlogds?
Test it. for example, try scripts/memusage. Standalone static svlogd will use ~8..12kb less than static svlogd from busybox. Main memory usage comes from data+bss of full busybox which is: 2k of stdio buffers, ~0.5k of malloc internal state, something in resolver library, 1k in bb_common_bufsiz1 + random assorted statics and globals. This is what I see when I use "static 32bit uclibc build with BUFSIZE=1K" as my libc. > I want to shrink codebase dependencies of my build system and am > inclined to pull from busybox wonderful library the most I can. But > always doubted what is better: to add a tiny private applet (and then > try to share it with the list) or write a separate application (with > dietlibc it can be really less than some KBs even statically linked). dietlibc seems to not be actively maintained, so this is a dead end in the long term. I suggest using uclibc as it seems to be somewhat better maintained (although God knows we need more developers there). You may try, for example, audit the code and try to reduce usage of static/global variables in uclibc. This means sending patches to uclibc ml. Or work on reducing busybox's usage of libc routines which use static storage (getpwnam etc). -- vda _______________________________________________ busybox mailing list [email protected] http://busybox.net/cgi-bin/mailman/listinfo/busybox
