• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Increasing your app's stack size
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Increasing your app's stack size


  • Subject: Re: Increasing your app's stack size
  • From: Bill Bumgarner <email@hidden>
  • Date: Thu, 20 Sep 2007 19:26:02 -0700

On Sep 20, 2007, at 3:47 PM, Scott Ribe wrote:
Unless you're allocating huge arrays on the stack, you're not overflowing
it. Unlike OS 9, under OS X the default stack size is quite large (for
thread 0, not so large for other threads) since the VM can map it in as
needed for stack growth, rather than allocating it all at launch.

For secondary threads created via NSThread, it isn't really that large. Actually, the stack size overall is not that large. For example, the Python language's unit tests will crash on Mac OS X due to stack overflow in one of the recursion tests unless you bump up the stack size well above the default.


It is not unreasonable to find situations where the stack will overflow on Mac OS X where it does not on other platforms. Certainly, increasing the stack size will address the issue, but that does eat into the heap.

b.bum

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Re: Increasing your app's stack size (From: Scott Ribe <email@hidden>)

  • Prev by Date: Re: C local auto-initialized?
  • Next by Date: Re: C local auto-initialized? [SOLUTION AND APOLOGY]
  • Previous by thread: Re: Increasing your app's stack size
  • Next by thread: Objective C++ and ObjC exceptions
  • Index(es):
    • Date
    • Thread