hi all,
I’ve finally been able to catch a weird crash that is happening in my
ios application.
After some minutes of testing on device the app misteriously crashes
– never happens on simulator. What I find strange is that this bug is
persistent, always happens after some time of playing but if i leave
the app on without interaction it never crashes.
From the limited information of the backtrace below all I can gather
is that something is ‘distubing’ the ios event queue, but I have no
idea how I can debug this further.
Is there any advice on how/what/why this is happening? Can anyone shed
some light on the event queue processing on ios?
What signal is being thrown? Does it crash with signal “0”, or SIGSEGV or
what?
Note that most unusual crashes in iOS are signal “0” crashes, when the OS
pulls the rug from under your app due to memory limitations. You’ve got to
be really conservative with memory on iOS, best to stay under 64 megs, under
40 is preferable, even on devices like the iPhone 4, with 512 megs of memory !!!
That’s for signal “0” crashes (which I can never get a stack trace for!).On Thu, Sep 15, 2011 at 4:17 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
hi all,
I’ve finally been able to catch a weird crash that is happening in my
ios application.
After some minutes of testing on device the app misteriously crashes
– never happens on simulator. What I find strange is that this bug is
persistent, always happens after some time of playing but if i leave
the app on without interaction it never crashes.
From the limited information of the backtrace below all I can gather
is that something is ‘distubing’ the ios event queue, but I have no
idea how I can debug this further.
Is there any advice on how/what/why this is happening? Can anyone shed
some light on the event queue processing on ios?
Unfortunately it receives a SIGSEGV signal; I sincerely doubt it is a
memory management problem, there is nothing being allocated when the
crash happens and when there is no user interaction, the app remains
on for a long time. Hence I believe there is some problem with the
event handling, most likely due to the transparent overlay I added to
the sdl view (with uikit buttons and so on).
Is there any way to safely debug this or can anyone better explain how
the event handling on ios works?
Best
VittorioOn Mon, Sep 19, 2011 at 10:51 AM, Jeremy Jurksztowicz wrote:
What signal is being thrown? Does it crash with signal “0”, or SIGSEGV or
what?
Note that most unusual crashes in iOS are signal “0” crashes, when the OS
pulls the rug from under your app due to memory limitations. You’ve got to
be really conservative with memory on iOS, best to stay under 64 megs, under
40 is preferable, even on devices like the iPhone 4, with 512 megs of memory !!!
That’s for signal “0” crashes (which I can never get a stack trace for!).
On Thu, Sep 15, 2011 at 4:17 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
hi all,
I’ve finally been able to catch a weird crash that is happening in my
ios application.
After some minutes of testing on device the app misteriously crashes
– never happens on simulator. What I find strange is that this bug is
persistent, always happens after some time of playing but if i leave
the app on without interaction it never crashes.
From the limited information of the backtrace below all I can gather
is that something is ‘distubing’ the ios event queue, but I have no
idea how I can debug this further.
Is there any advice on how/what/why this is happening? Can anyone shed
some light on the event queue processing on ios?
Upon further testing I am finding out that there must be some
incompatibility with the sdl touch interface and the cocoa overlay
that I’ve added above it.
I’ve run the sdl app without it for a while, implementing SDL_TOUCH*
events handling and the app didn’t crash.
I find it very strange, the event queue should lose a touch event,
not making the app crash.
If this is absolutely new to everybody, do you think it is worthwhile
to submit a bugreport to apple?
Best
VittorioOn Tue, Sep 20, 2011 at 10:53 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
Unfortunately it receives a SIGSEGV signal; I sincerely doubt it is a
memory management problem, there is nothing being allocated when the
crash happens and when there is no user interaction, the app remains
on for a long time. Hence I believe there is some problem with the
event handling, most likely due to the transparent overlay I added to
the sdl view (with uikit buttons and so on).
Is there any way to safely debug this or can anyone better explain how
the event handling on ios works?
Best
Vittorio
On Mon, Sep 19, 2011 at 10:51 AM, Jeremy Jurksztowicz wrote:
What signal is being thrown? Does it crash with signal “0”, or SIGSEGV or
what?
Note that most unusual crashes in iOS are signal “0” crashes, when the OS
pulls the rug from under your app due to memory limitations. You’ve got to
be really conservative with memory on iOS, best to stay under 64 megs, under
40 is preferable, even on devices like the iPhone 4, with 512 megs of memory !!!
That’s for signal “0” crashes (which I can never get a stack trace for!).
On Thu, Sep 15, 2011 at 4:17 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
hi all,
I’ve finally been able to catch a weird crash that is happening in my
ios application.
After some minutes of testing on device the app misteriously crashes
– never happens on simulator. What I find strange is that this bug is
persistent, always happens after some time of playing but if i leave
the app on without interaction it never crashes.
From the limited information of the backtrace below all I can gather
is that something is ‘distubing’ the ios event queue, but I have no
idea how I can debug this further.
Is there any advice on how/what/why this is happening? Can anyone shed
some light on the event queue processing on ios?
How are you reconciling the SDL event handling with Cocoa event handling? I
think that should be the first place to look for issues. Maybe when you try
to handle an event in cocoa you (or the event pump) are releasing it and
then when SDL tries to access it, the crash occurs.
I have been using only the SDL interface to iOS events with no problem thus
far. Looking at the cocoa code for mouse handling I see that SDL dequeues
the event, reads some data from it and then requeues without retaining or
releasing anything. Perhaps you can post the crash log or some code
demonstrating your event usage. If you’ve exhausted all possibilities then
by all means post a bug report.
Good luck.On Mon, Sep 26, 2011 at 3:17 PM, Vittorio G. <vitto.giova at yahoo.it> wrote:
Upon further testing I am finding out that there must be some
incompatibility with the sdl touch interface and the cocoa overlay
that I’ve added above it.
I’ve run the sdl app without it for a while, implementing SDL_TOUCH*
events handling and the app didn’t crash.
I find it very strange, the event queue should lose a touch event,
not making the app crash.
If this is absolutely new to everybody, do you think it is worthwhile
to submit a bugreport to apple?
Best
Vittorio
On Tue, Sep 20, 2011 at 10:53 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
Unfortunately it receives a SIGSEGV signal; I sincerely doubt it is a
memory management problem, there is nothing being allocated when the
crash happens and when there is no user interaction, the app remains
on for a long time. Hence I believe there is some problem with the
event handling, most likely due to the transparent overlay I added to
the sdl view (with uikit buttons and so on).
Is there any way to safely debug this or can anyone better explain how
the event handling on ios works?
Best
Vittorio
On Mon, Sep 19, 2011 at 10:51 AM, Jeremy Jurksztowicz <@Jeremy_Jurksztowicz> wrote:
What signal is being thrown? Does it crash with signal “0”, or SIGSEGV
or
what?
Note that most unusual crashes in iOS are signal “0” crashes, when the
OS
pulls the rug from under your app due to memory limitations. You’ve got
to
be really conservative with memory on iOS, best to stay under 64 megs,
under
40 is preferable, even on devices like the iPhone 4, with 512 megs of
memory !!!
That’s for signal “0” crashes (which I can never get a stack trace
for!).
On Thu, Sep 15, 2011 at 4:17 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
hi all,
I’ve finally been able to catch a weird crash that is happening in my
ios application.
After some minutes of testing on device the app misteriously crashes
– never happens on simulator. What I find strange is that this bug is
persistent, always happens after some time of playing but if i leave
the app on without interaction it never crashes.
From the limited information of the backtrace below all I can gather
is that something is ‘distubing’ the ios event queue, but I have no
idea how I can debug this further.
Is there any advice on how/what/why this is happening? Can anyone shed
some light on the event queue processing on ios?
For future history, the issue was found to be in the language binding (from
pascal to c): too little space got allocated for the different event sizes
and so when a ‘big’ event was received it corrupted the stack… fun times.
We fixed this by adding a 256byte event size as higher bound and stack
didn’t crash any more.
Cheers,
VittorioOn Mon, Sep 26, 2011 at 10:12 AM, Jeremy Jurksztowicz < jurksztowicz at gmail.com> wrote:
How are you reconciling the SDL event handling with Cocoa event handling?
I think that should be the first place to look for issues. Maybe when you
try to handle an event in cocoa you (or the event pump) are releasing it
and then when SDL tries to access it, the crash occurs.
I have been using only the SDL interface to iOS events with no problem
thus far. Looking at the cocoa code for mouse handling I see that SDL
dequeues the event, reads some data from it and then requeues without
retaining or releasing anything. Perhaps you can post the crash log or some
code demonstrating your event usage. If you’ve exhausted all possibilities
then by all means post a bug report.
Good luck.
On Mon, Sep 26, 2011 at 3:17 PM, Vittorio G. <vitto.giova at yahoo.it> wrote:
Upon further testing I am finding out that there must be some
incompatibility with the sdl touch interface and the cocoa overlay
that I’ve added above it.
I’ve run the sdl app without it for a while, implementing SDL_TOUCH*
events handling and the app didn’t crash.
I find it very strange, the event queue should lose a touch event,
not making the app crash.
If this is absolutely new to everybody, do you think it is worthwhile
to submit a bugreport to apple?
Best
Vittorio
On Tue, Sep 20, 2011 at 10:53 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
Unfortunately it receives a SIGSEGV signal; I sincerely doubt it is a
memory management problem, there is nothing being allocated when the
crash happens and when there is no user interaction, the app remains
on for a long time. Hence I believe there is some problem with the
event handling, most likely due to the transparent overlay I added to
the sdl view (with uikit buttons and so on).
Is there any way to safely debug this or can anyone better explain how
the event handling on ios works?
Best
Vittorio
On Mon, Sep 19, 2011 at 10:51 AM, Jeremy Jurksztowicz wrote:
What signal is being thrown? Does it crash with signal “0”, or SIGSEGV
or
what?
Note that most unusual crashes in iOS are signal “0” crashes, when the
OS
pulls the rug from under your app due to memory limitations. You’ve
got to
be really conservative with memory on iOS, best to stay under 64 megs,
under
40 is preferable, even on devices like the iPhone 4, with 512 megs of
memory !!!
That’s for signal “0” crashes (which I can never get a stack trace
for!).
On Thu, Sep 15, 2011 at 4:17 AM, Vittorio G. <vitto.giova at yahoo.it> wrote:
hi all,
I’ve finally been able to catch a weird crash that is happening in my
ios application.
After some minutes of testing on device the app misteriously crashes
– never happens on simulator. What I find strange is that this bug is
persistent, always happens after some time of playing but if i leave
the app on without interaction it never crashes.
From the limited information of the backtrace below all I can gather
is that something is ‘distubing’ the ios event queue, but I have no
idea how I can debug this further.
Is there any advice on how/what/why this is happening? Can anyone shed
some light on the event queue processing on ios?