Denys Vlasenko vda.linux at googlemail.com
Mon Jun 9 14:09:18 UTC 2008

On Monday 09 June 2008 12:55, Bernd Schmidt wrote:
> > This actually _improves_ our performance in near-OOM conditions.
> > How? Going back to crypt(). If we will go back and reinstate
> > static buffers there, busybox's data+bss size will jump from 8k
> > to 80k - tenfold increase. On NOMMU, if you have N running
> > busybox daemons, you already have additional N*72k bytes
> > allocated and sitting there, totally unused.
> Well, wasting memory at run-time is inherent in the design of busybox.

Only on machines which cannot share text segment.

> Have you considered that it might be busybox that is broken?

During last two years I shrank it by more than 10% text segment wise
and many orders of magniture in data+bss (from more than 1000k to 8k).
So, no, I don't think that it's broken.

> > This will be a measurable, real drop in memory utilisation
> > efficiency. Just start 1000 copies of "busybox sleep 10"
> > and measure how many more megabytes that would require.
> This only shows that busybox is unsuitable for that workload and people 
> should install normal GNU utilities if that's what they want to run.

Good luck with that.

On the machine I write this email: 4000 copies of "busybox sleep 10"
increased total memory usage from 438m to 625m (so, +200m, or 46k per process)
whereas GNU sleep went from 438m to 840m (+400m).

More information about the uClibc mailing list