Xref: utzoo comp.sys.amiga:38129 comp.sys.amiga.tech:6561
Path: utzoo!utgpu!watmath!att!pacbell!ames!sun-barr!cs.utexas.edu!uunet!yale!eagle!jtreworgy
From: jtreworgy@eagle.wesleyan.edu
Newsgroups: comp.sys.amiga,comp.sys.amiga.tech
Subject: Re: Saving Disk Space (was Re: Relying on ARP)
Message-ID: <422@eagle.wesleyan.edu>
Date: 8 Aug 89 21:16:42 GMT
References: <12878@well.UUCP> <26758@agate.BERKELEY.EDU> <934@corpane.UUCP> <796@medsys.UUCP> <13549@netnews.upenn.edu>
Lines: 39

In article <13549@netnews.upenn.edu>, ranjit@grad2.cis.upenn.edu (Ranjit Bhatnagar) writes:
> I'm curious about the interaction of these 'cruncher' programs
> with the Resident facility.  It seems reasonable that a cruncher,
> in order to reduce the disk space taken up by a program, compresses
> that program and then prepends a loader-uncruncher.  Thus when you
> invoke the crunched version of emacs, for instance, it actually loads
> the uncruncher, which then loads and uncrunches the rest of emacs.
> The overhead of the uncruncher is made up for by the space saved.
> 

In the case of PowerPacker, the decruncher is less than 200 bytes. This is
entirely insignificant compared to the savings for all but the smallest programs
(why would you bother crunching something small anyway?)

> If this is the case, then if you make emacs Resident, what will be
> made resident is not emacs itself, but the uncruncher and the crunched
> data file.  When you subsequently run the resident emacs, rather than
> running emacs directly from the preloaded image, it will uncrunch
> the datafile again into newly allocated memory - thus losing the memory
> advantages of resident programs.
> 

I suspect if you made a crunched program resident you would meet with a very
large guru, rather than losing some memory. Solution: don't. Will emacs even
work from a resident state? I can't imagine such a large program is coded well
enough.

> On the other hand, the cruncher could patch the operating system
> so that the uncrunching process is transparent to the resident facility.
> 

Maybe, but probably much more trouble than it's worth. Just don't crunch things
you want to make resident.
-- 
James A. Treworgy               "You should have seen me with the poker man,
jtreworgy@eagle.wesleyan.edu     I had a honey and I bet a grand,
jtreworgy%eagle@WESLEYAN.BITNET  Just in the nick of time I looked at his hand"
Box 5033 Wesleyan Station                           -Paul McCartney
Middletown, CT 06475