Received: (from major@localhost)
	by minnie.cs.adfa.oz.au (8.8.5/8.8.5) id SAA20848
	for pups-liszt; Wed, 25 Mar 1998 18:11:48 +1100 (EST)
X-Authentication-Warning: minnie.cs.adfa.oz.au: major set sender to owner-pups@minnie.cs.adfa.oz.au using -f
Received: from allegro.lemis.com (allegro.lemis.com [192.109.197.134])
	by minnie.cs.adfa.oz.au (8.8.5/8.8.5) with ESMTP id SAA20843
	for <pups@minnie.cs.adfa.oz.au>; Wed, 25 Mar 1998 18:11:43 +1100 (EST)
Received: from freebie.lemis.com (freebie.lemis.com [192.109.197.137])
	by allegro.lemis.com (8.8.7/8.8.5) with ESMTP id RAA21565;
	Wed, 25 Mar 1998 17:41:37 +1030 (CST)
Received: (from grog@localhost)
          by freebie.lemis.com (8.8.8/8.8.7) id RAA23376;
          Wed, 25 Mar 1998 17:41:37 +1030 (CST)
          (envelope-from grog)
Message-ID: <19980325174136.47943@freebie.lemis.com>
Date: Wed, 25 Mar 1998 17:41:36 +1030
From: Greg Lehey <grog@lemis.com>
To: Peter Chubb <peterc@softway.com.au>
Cc: PDP UNIX Preservation Society <pups@minnie.cs.adfa.oz.au>
Subject: Re: gzip on PDP-11: not so simple
References: <19980325161754.63486@freebie.lemis.com> <m0yHjuC-000FlVC@bookworm.softway.com.au>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Mailer: Mutt 0.89i
In-Reply-To: <m0yHjuC-000FlVC@bookworm.softway.com.au>; from Peter Chubb on Wed, Mar 25, 1998 at 05:43:00PM +1000
WWW-Home-Page: http://www.lemis.com/~grog
Organization: LEMIS, PO Box 460, Echunga SA 5153, Australia
Phone: +61-8-8388-8286
Fax: +61-8-8388-8725
Mobile: +61-41-739-7062
Sender: owner-pups@minnie.cs.adfa.oz.au
Precedence: bulk

On Wed, 25 March 1998 at 17:43:00 +1000, Peter Chubb wrote:
>>>>>> "Greg" == Greg Lehey <grog@lemis.com> writes:
>
> Greg> OK, I've found the problems with gzip, and they're not
> Greg> encouraging.  It would appear that the undefined references are
> Greg> undefined because they refer to data which is too large.  Here's
> Greg> the preprocessor output:
>
> Greg>   uch inbuf[ 0x8000 + 64 ]; uch outbuf[ 16384 +2048 ]; ush
> Greg> d_buf[ 0x8000 ]; uch window[ 2*0x8000 ]; # 194 "gzip.c"
>
> You need to decrease the window size -- try setting it to 8k (instead
> of 32k)
>
> There should be a
> #define WSIZE 0x8000
> somewhere.

Correct.  Unfortunately, it's not as simple as that.  Here's the
definition:

#ifndef WSIZE
#  define WSIZE 0x8000     /* window size--must be a power of two, and */
#endif                     /*  at least 32K for zip's deflate method */

> It may be worth playing with a decompress only version -- compression
> will take more space than decompression (you need two windows rather
> than one, for a start).

Yes, that was really what I was thinking of doing with unzip, rather
than excising the unzip part from gunzip.

> inbuf can be smaller, too.  Try 512 bytes to match the disc record
> size.

Sure, once I get into serious modifications I can try a number of
things.  The trouble is, I just don't have the time.  I thought it was
worth 15 minutes to see what it would do, and the first attempts
looked encouraging.  Unfortunately, the second attempts didn't :-(

Greg

