home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / sys / mac / programm / 22157 < prev    next >
Encoding:
Internet Message Format  |  1993-01-25  |  2.5 KB

  1. Path: sparky!uunet!pmafire!news.dell.com!swrinde!zaphod.mps.ohio-state.edu!howland.reston.ans.net!spool.mu.edu!olivea!apple!goofy!mumbo.apple.com!gallant.apple.com!NewsWatcher!user
  2. From: REEKES@applelink.apple.com (Jim Reekes)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: Re: bg-only, stack size
  5. Message-ID: <REEKES-250193123820@90.10.20.67>
  6. Date: 25 Jan 93 20:39:37 GMT
  7. References: <1jplelINNt88@shelley.u.washington.edu>
  8. Sender: news@gallant.apple.com
  9. Followup-To: comp.sys.mac.programmer
  10. Organization: Apple Computer, Inc.
  11. Lines: 36
  12.  
  13. In article <1jplelINNt88@shelley.u.washington.edu>, stevep@wrq.com (Steve
  14. Poole) wrote:
  15. > Can anyone offer an explanation of what happens differently for background-
  16. > only applications where the stack is concerned? My bg-only app comes up with
  17. > a 2K stack -- not enough! Clearing the bg-only bit brings it up with 24K
  18. > of stack. I've tried increasing the stack size by using SetApplLimit with 
  19. > the address of the stack base - desired stack size, which seems to work fine 
  20. > iff the bg-only bit isn't set. MemError isn't being set in either case.
  21. > Help!
  22. > Is there ANY documentation on bg-only besides the few words in the process
  23. > manager docs? I'd appreciate pointers to anything! Thanks.
  24.  
  25. There is a Tech Note or Q&A item from MacDTS about this. Faceless
  26. background only applications will only get a 2k stack by default, since
  27. most of the stack that's used is required for QuickDraw. Faceless tasks by
  28. definition don't use QuickDraw and there for the Process Manager (and even
  29. the older MultiFinder) only allocates a 2k stack for them. Back/White
  30. QuickDraw machines get an 8k stack whereas color machines get a 24k stack.
  31. These numbers are subject to change, so don't depend on them.
  32.  
  33. If you need to increase the stack, increase it for the amount you need.
  34. Don't assume you know what the default stack size is.
  35.  
  36. Background only applications work just like regular apps. They just don't
  37. use QuickDraw. (e.g. don't call InitWindows, etc.) There's also a Tech Note
  38. or Q&A item about how to increase the stack and it works for any type of
  39. application.
  40.  
  41. -----------------------------------------------------------------------
  42. Jim Reekes, Polterzeitgeist  |     Macintosh Toolbox Engineering
  43.                              |          Sound Manager Expert
  44. Apple Computer, Inc.         | "All opinions expressed are mine, and do
  45. 20525 Mariani Ave. MS: 81-KS |   not necessarily represent those of my
  46. Cupertino, CA 95014          |       employer, Apple Computer Inc."
  47.