Xref: utzoo comp.sys.mac:43509 comp.sys.mac.programmer:10901 Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!hoptoad!tim From: tim@hoptoad.uucp (Tim Maroney) Newsgroups: comp.sys.mac,comp.sys.mac.programmer Subject: Re: Resizing the System Heap Message-ID: <9195@hoptoad.uucp> Date: 5 Dec 89 08:09:31 GMT References: <1195@kl-cs.UUCP> <32961@ucbvax.BERKELEY.EDU> <2578F219.21993@paris.ics.uci.edu> Reply-To: tim@hoptoad.UUCP (Tim Maroney) Organization: Eclectic Software, San Francisco Lines: 38 oster@dewey.soe.berkeley.edu (David Phillip Oster) writes: >You should not need to manually resize the system heap. There is a >mechanism, documented in the Startup Manager chapter of Inside Mac, Vol 5, >for attaching a 'size' resource to an INIT that will cause the system to >automatically grow the system heap. > >Apple put this in so INITs that start big device drivers in the system >heap can get the system heap space without going through contortions at >run time. (Those interested can read the brief docuemntation of the 'sysz' 0 resource on page IM V-352.) In article <2578F219.21993@paris.ics.uci.edu> truesdel@ics.uci.edu (Scott Truesdell) writes: >Then why is it that when people start running lots of INITs and/or some >memory hog INITs, the system heap gets so full? Is this because not >many INIT writers use the aforementioned 'size" resource correctly or >at all? Probably a combination of that and the strange implementation of the sysz resource. It does *not* grow the system heap by the size specified in the sysz resource. Instead, it makes sure that there is at least that much space in the system heap. This is an important difference, and frankly, it makes the sysz pretty near useless. There's no cumulative effect. Having twenty INITs each asking for X bytes in the system heap is the same as having two INITs each asking for X bytes. >Is there a better way to deal with this problem? Hopefully, Apple will not break INITs that continue to use the time- honored BufPtr method, which at least lets you guarantee yourself enough space to run. -- Tim Maroney, Mac Software Consultant, sun!hoptoad!tim, tim@toad.com "Jesus died for somebody's sins, but not mine." -- Patti Smith