Jump to content


Photo

Tracking The Exception / Crash... How? Lost Faith In Conventional Meth


  • Please log in to reply
3 replies to this topic

#1 Mię«os∞ft

Mię«os∞ft

    X-S Member

  • Members
  • Pip
  • 147 posts

Posted 30 May 2008 - 08:49 PM


Since the past few weeks I have been trying to trace what's causing the crash.... It's getting really out of hand. sad.gif

----

Is there any, any way to keep determine the XBOX's Exception Address at the time of crash ?

for use with:
addr2line xboxmodule.o -f -e 0xEXCEPTIONADDRESS

---

I got a 100% working project that fails after a few seconds and at a regular condition. sad.gif

I would TRULY appreciate any sort of help / Guidance smile.gif

Edited by Mię«os∞ft, 30 May 2008 - 08:51 PM.


#2 openxdkman

openxdkman

    X-S Genius

  • Moderator
  • PipPipPipPip
  • 823 posts
  • Xbox Version:unk
  • 360 version:unknown

Posted 30 May 2008 - 09:04 PM

The stack structure is a bit unknown, so I don't know how to not hang on when crash occurs under openxdk.

The xbox debug model has a secondary thread communicating on network, but that is xdk stuff.

To stick to legal stuff, you need to add more traces.
I suspect you slowly overwrite outside your buffers boundaries (net ring buffers?).

In worst case, I ported to ps2, debuggued there then went back to xbox1.

Try to call often a function that verifies all the boundaries of your buffers (before and after). Check for a magic value you put at these boundaries. And make the function yell when these magic values vanish.


#3 Mię«os∞ft

Mię«os∞ft

    X-S Member

  • Members
  • Pip
  • 147 posts

Posted 30 May 2008 - 09:24 PM

QUOTE(openxdkman @ May 30 2008, 04:40 PM) View Post

The stack structure is a bit unknown, so I don't know how to not hang on when crash occurs under openxdk.

The xbox debug model has a secondary thread communicating on network, but that is xdk stuff.

To stick to legal stuff, you need to add more traces.
I suspect you slowly overwrite outside your buffers boundaries (net ring buffers?).

In worst case, I ported to ps2, debuggued there then went back to xbox1.

Try to call often a function that verifies all the boundaries of your buffers (before and after). Check for a magic value you put at these boundaries. And make the function yell when these magic values vanish.


Thanks. smile.gif


By conventional methods I mean


It crashes when packet count reaches 112 or more at Max 115.


I do

if (rxpacketcount>=112)
{

functionwherethecrashismostprobablyhappening();
pb_wait_for_vbl();
pb_reset(); //new frame, let's start from push buffer head again
pb_erase_depth_stencil_buffer(0,0,640,480); //clear depth stencil buffer (MANDATORY)
pb_fill(0,0,640,480,0x718568); //clear frame (optional)
pb_erase_text_screen();
pb_print(" were reached here, that's not the cause 'line number'.\n");
pb_draw_text_screen();
pb_finished();

Anotherfunctionwherethecrashismostprobablyhappening();
pb_wait_for_vbl();
pb_reset(); //new frame, let's start from push buffer head again
pb_erase_depth_stencil_buffer(0,0,640,480); //clear depth stencil buffer (MANDATORY)
pb_fill(0,0,640,480,0x718568); //clear frame (optional)
pb_erase_text_screen();
pb_print(" Reached here so that's not the cause of crash\n");
pb_draw_text_screen();
pb_finished();

}

I do this instead of using initialize and finish at the beggining and end of the loop so that,
If the crash occurs before the end of the loop is reached, we WILL NOT loose the text.


Is this a good strategy for "conventional" debugging?

----

Also, Is there anything like stack size setting or Heap size like the PSP?

Edited by Mię«os∞ft, 30 May 2008 - 09:39 PM.


#4 openxdkman

openxdkman

    X-S Genius

  • Moderator
  • PipPipPipPip
  • 823 posts
  • Xbox Version:unk
  • 360 version:unknown

Posted 03 June 2008 - 08:28 PM

I gave up personally, since I can port to other platforms for debugging.
If it works for you then it's good!

Try to report the total sum of the packets and compare it with low level number and size of ring buffers
Separate outgoing packets and ingoing packets

Try without any graphics at all also.

Good luck!




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users