• 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: Corrupt stack?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Corrupt stack?


  • Subject: Re: Corrupt stack?
  • From: "Yves Poissant" <email@hidden>
  • Date: Fri, 15 Jun 2007 13:29:11 -0400
  • Organization: Hash Enterprises Inc.

From: "Lawrence Gold"
Sent: Friday, June 15, 2007 12:34 PM


I've seen odd behavior in the IDE regarding the debugger, and recommend that you try GDB from the command line to see if the problem persists.

OK. I'll try that.

If it does, then it's possible that you're seeing a stack overflow. If your app is multithreaded and the messed up stack is happening in a worker (non-main) thread, try increasing the thread's stack size. The main thread on OS X is given an 8MB stack by default, so it's unlikely you're overflowing unless you have some gigantic stack-based arrays or something. :-)

Well, yes. the application is multithreaded but we don't usually have arrays on the stack unless they are small size. Still, I will try to increase the thread stack size just to see if that will decrease the frequency of those corrupted stacks errors.


In the meantime, I had several of those errors in a row so I decided to try to find out where those errors were happening by doing a binary search with breakpoints in the application initialization function. No luck. As I was progressing with the binary search, the error happened at different places in the initialization execution code and then suddenly, the application launched without errors. The only explanation I can figure for why this is happenning in a seemingly random way is that this might be Event dependent. Meaning it would depend on the sequence of thread firing and their respective Event dependencies. That will be tough to debug if that is the case.

_______________________________________________
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: 
 >Orange breakpoint (From: "Yves Poissant" <email@hidden>)
 >Re: Orange breakpoint (From: "R. Matthew Emerson" <email@hidden>)
 >Re: Orange breakpoint (From: "Yves Poissant" <email@hidden>)
 >Corrupt stack? (From: "Yves Poissant" <email@hidden>)
 >Re: Corrupt stack? (From: Lawrence Gold <email@hidden>)

  • Prev by Date: Re: Xcode-users Digest, Vol 4, Issue 271
  • Next by Date: Re: "6 day compile" (1 GHz G4) DONE in 7 hours (8 core Intel 3.0 GHz over SSH)
  • Previous by thread: Re: Corrupt stack?
  • Next by thread: Thread Safety
  • Index(es):
    • Date
    • Thread