• 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: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh?


  • Subject: Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh?
  • From: Sailesh Agrawal <email@hidden>
  • Date: Tue, 19 Jul 2005 16:38:47 -0700

James Larcombe wrote:

Sailesh Agrawal wrote:

3. weird vtable issue. i had a similar crash that wouldn't leave a stack trace. it turned out that the problem was the vtable in one of my classes was messed up. when a certain function was called the app would crash. i'm not sure how you could debug this problem.


I am having precisely this problem with one of my classes. When calling
a virtual function through a base class pointer, execution steps in to the
wrong function, whereupon the application crashes (because the arguments
for this wrong function are invalid). This only happens in the Xcode build.


Did you manage to resolve your problem? Can you tell us how you went
about it?

It turns out that my most thread in my application were using about 1 MB of stack each. Carbon thread have a default stack limit of 4kb and Cocoa (pthread) have a default stack limit of 512 kB. Usually when you run of the stack limit you won't notice right away. Until you right over some data that you'll need :-P


The way I figured out that this was happening was allocating a huge array on the stack at the beginning and filling it with a particular number. Later on you can look at the memory on your stack and see how much has been used. The code looked something like this:

mark_stack()
{
   char large_buffer[1024*1024*2]; // a 2MB buffer
   for (int i = 0; i < 1024*1024*2; i++)
      large_buffer[i] = 0xaa;
}

void some_main_function()
{
   mark_stack();
   do_work();
   // break here and look at your stack from GDB
}
_______________________________________________
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


  • Follow-Ups:
    • Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh?
      • From: Eric Albert <email@hidden>
References: 
 >"Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh? (From: Jonathan del Strother <email@hidden>)
 >Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh? (From: Sailesh Agrawal <email@hidden>)
 >Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh? (From: "James Larcombe" <email@hidden>)

  • Prev by Date: Re: Can you use Build Configurations to link with different libraries?
  • Next by Date: Re: Displaying Custom Data Types in Debugger
  • Previous by thread: Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh?
  • Next by thread: Re: "Program exited with status value:45. mi_cmd_stack_list_frames_lite: No stack." Eh?
  • Index(es):
    • Date
    • Thread