From: Eric Youngdale (eric@tantalus.nrl.navy.mil)
Date: 02/24/93


From: eric@tantalus.nrl.navy.mil (Eric Youngdale)
Subject: Re: Thought: compressed libc ?
Date: Wed, 24 Feb 1993 15:41:31 GMT

In article <1mfrvvINNfof@iamk4515.mathematik.uni-karlsruhe.de> bernd@iamk4515.mathematik.uni-karlsruhe.de (Bernd Wiebelt) writes:
>The new kernel 99p6 decompresses itself at boottime. This is a very nice feature
>which could make a combined boot-rootdisk combo (like the one hlu provides) very
>powerful. It would be even nicer, if libc would be selfextracting. Compressing it

>[...]

>that before. However, I would like to know if this is possible at all.
>And if this is possible, I want to know - you have guessed it - if someone is
>writing code for such a libc. After all it would be a good idea to include this
>in the to-come-non-buggy-libc4.3.1 (just dreaming a little bit).

        This is an interesting idea, but I do not think that it will work very
well. The way that linux works is that it does not read in all of libc when
you use it - it reads in those pages that the program needs, as it needs them.
When you use compression, you almost need to start at the beginning and start
decompressing if you want to locate a specific page.

        A second point is that even though ls shows that libc.so.4.3 runs about
620Kb, there is a large hole in the middle and as I recall only about 260Kb is
used on the disk. To see this, just use du to monitor the free disk space, and
then use cp to make a copy. The lite version of libc was developed for
bootable rootdisk applications so that there is only about 220Kb used.

        Finally, I will be happy just to get a non-buggy libc.4.3.1 out the
door without any new features. I think that I have identified the problem with
the core dumping, and I have a solution which should in principle work - it
just needs to be debugged.

-Eric

--