This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Exception debugging

Other Parts Discussed in Thread: MATHLIB, SYSBIOS

Hello,

I'm trying to debug an exception that happens after a couple of hours but I'm having difficulties finding any useful information, I was hoping you may have some more experience how to trace the code that generated the exception.

Below is the exception log that I managed to get from ROV for my C6748 custom platform (based on EVM) CCSv5.5, SYSBIOS bios_6_35_04_50, biospsp_03_00_01_00, edma3_lld_02_11_07_04, xdctools_3_25_03_72, uia_1_03_01_08, mathlib_c674x_3_0_1_1, dsplib_c674x_3_1_1_1:

Decoded exception,
Decoded,Internal: Execute packet exception; Opcode exception; Resource conflict exception;
Address,0xc29a0874
Exception context,
$addr,0x8000fea0
$type,ti.sysbios.family.c64p.Exception.Context
ILC,0x00000000
RILC,0x00000000
AMR,0x00000000
SSR,0x8000fec8
IRP,0xc28f64a8
NRP,0xc29a0874
ITSR,0x8000fef8
NTSR,0xc2837e68
EFR,0x00000000
IERR,0xc2837c1c
B30,0xc29a89b6
B31,0x0000ff90
B28,0xc2837c10
B29,0xc29b2ae4
B26,0x00000002
B27,0x01c47e28
B24,0x00000001
B25,0x00000001
B22,0x8000fea0
B23,0x00000000
B20,0x000007de
B21,0xc2837c10
B18,0xc2966ff0
B19,0x00000080
B16,0x00000000
B17,0xc0b01930
B14,0xc29db6c0
B15,0x8000fef8
B12,0xc29a89b6
B13,0x0000ff90
B10,0xc2837c1c
B11,0xc2837c1c
B8,0x00000003
B9,0x00000000
B6,0x00000020
B7,0x0000009b
B4,0x00000000
B5,0xffffc9ad
B2,0x00000001
B3,0xc29709f0
B0,0x00000000
B1,0x00000000
A30,0x00000001
A31,0xc2837e50
A28,0x00000104
A29,0x00000603
A26,0x00000400
A27,0x00000105
A24,0x00000000
A25,0x80000000
A22,0x8000fe64
A23,0x8000fe64
A20,0x00000014
A21,0x00000000
A18,0xc0b595cc
A19,0x00000020
A16,0x80000100
A17,0x00000000
A14,0xc2837e68
A15,0xc0b6191c
A12,0xc2837c10
A13,0x00000000
A10,0xc2837c10
A11,0xc2837e68
A8,0xc29a14a0
A9,0xc29d87d8
A6,0xc29a89b6
A7,0x00000000
A4,0x01e14ee8
A5,0x0000009c
A2,0xc2839cbc
A3,0x01c47e28
A0,0x00000000
A1,0x00000001
Exception call stack,
0 xdc_runtime_System_printf__E(char *) at app_pe674.c:21737,PC = 0xC29A0874 FP = 0x8000FEF8
1 <symbol is not available>,PC = 0x00000080 FP = 0x8000FF00

The PC points to System_printf but I checked all my code and I'm calling this function just as: System_printf("Error:%d\n", error);

Thank you in advance for any help you can provide.

Best regards,

David.

  • David,

    The difficult part of this is that its happening after several hours.  If you have ROV available when the exception occurs, I would use that to make sure any Task stack and Hwi stack are not blown.

    As far as the Exception.  The NRP register tell you the instruction when the Exception was taken.  Typically an Exception happens a few cycles before whats in the NRP register.  Also, B3 is the return address.  So using those two register, you should be able to determine approximately where the code went bad.  Once you do that, its trying to rewind the code with the register print out that you have.  Typically, you will find a branch to the bad register or a memory load via a register that is bad.

    Judah

  • David,

    On closer inspection of your print out.  The ITSR and NTSR values do not look good.  These are typically restored from the ISR stack so it could be that your ISR stack is bad.  Could be that you blown your ISR stack.

    Judah

  • Thank you Judah for helping me understand the issue, the problem was using same BIOSPSP channel from different threads and was crashing the ISR.

    Best regards,

    David.