AnsweredAssumed Answered

stack trace question

Question asked by MarkBishop on Jan 7, 2013
Latest reply on Jan 9, 2013 by sonic

I recently got this stack trace when my app was running.  I see that the fault is happening inside libc, any idea on how I can utilize this better would be appreciated.

 

 

Data access misaligned address violation

<5> - Attempted misaligned data memory or data cache access.

Deferred Exception context

CURRENT PROCESS:

COMM=audio PID=600  CPU=0

TEXT = 0x00a00000-0x00aa823c        DATA = 0x005f023c-0x005fc8b0

BSS = 0x005fc8b0-0x00c80000  USER-STACK = 0x00c9fe80

 

return address: [0x02ef0cba]; contents of:

0x02ef0c90:  300c  325d  e3fe dee6  304f  3007  67e1  325d

0x02ef0ca0:  e3fe  de5e  e52b 00b9  3038  3006  9159  ac5b

0x02ef0cb0:  0061  0c07  1c06 3217  b9f0 [9210] 0c42  1408

0x02ef0cc0:  325d  e3fe  de89 3210  6060  9310  6802  e801

 

ADSP-BF548-0.2 525(MHz CCLK) 131(MHz SCLK) (mpu off)

Linux version 3.0.8-ADI-2011R1-svn43 (mark@linux-hez9) (gcc version 4.3.5 (ADI-2011R1-RC4) ) #640 Thu Nov 29 11:12:05 EST 2012

 

SEQUENCER STATUS: Not tainted

SEQSTAT: 00060024  IPEND: 0008  IMASK: ffff SYSCFG: 0006

  EXCAUSE   : 0x24

  physical IVG3 asserted : <0xffa0077c> { _trap + 0x0 }

RETE: <0x00000000> /* Maybe null pointer? */

RETN: <0x00bfc000> [ /etc/ld.so.cache + 0x0 ]

RETX: <0x00000480> /* Maybe fixed code section */

RETS: <0x02ef0c44> [ /lib/libc.so.0 + 0x30c44 ]

PC  : <0x02ef0cba> [ /lib/libc.so.0 + 0x30cba ]

DCPLB_FAULT_ADDR: <0x002fb5a0> [ audio + 0x35a0 ]

ICPLB_FAULT_ADDR: <0x02ef0cba> [ /lib/libc.so.0 + 0x30cba ]

PROCESSOR STATE:

R0 : 000000b0    R1 : 00000001    R2 : 00000000    R3 : 002fb7fc

R4 : 00000006    R5 : 00410004    R6 : 00e89128    R7 : 002fb5a3

P0 : 00e89138    P1 : 00c17744    P2 : 002fb5a3    P3 : 00cd1488

P4 : 00414e24    P5 : 00e89808 FP : 00414bac    SP : 00bfbf24

LB0: 02ee1729    LT0: 02ee1728    LC0: 00000000

LB1: 02ede137    LT1: 02ede136    LC1: 00000000

B0 : 00535160    L0 : 00000000    M0 : ffffffff    I0 : 00000000

B1 : 00000007    L1 : 00000000    M1 : bca43b68    I1 : 00000001

B2 : 7f735e13    L2 : 00000000    M2 : 50916faf    I2 : 00c9f644

B3 : 3553f588    L3 : 00000000    M3 : 371bfd80    I3 : 00b88240

A0.w: 00000010   A0.x: 00000000   A1.w: 00000010   A1.x: 00000000

USP : 00414b90  ASTAT: 02001004

 

Hardware Trace:

   0 Target : <0x00003cf4> { _trap_c + 0x0 }

     Source : <0xffa00710> { _exception_to_level5 + 0xa4 } JUMP.L

   1 Target : <0xffa0066c> { _exception_to_level5 + 0x0 }

     Source : <0xffa00520> { _bfin_return_from_exception + 0x18 } RTX

   2 Target : <0xffa00508> { _bfin_return_from_exception + 0x0 }

     Source : <0xffa005c4> { _ex_trap_c + 0x74 } JUMP.S

   3 Target : <0xffa00550> { _ex_trap_c + 0x0 }

     Source : <0xffa007d6> { _trap + 0x5a } JUMP (P4)

   4 Target : <0xffa0077c> { _trap + 0x0 }

      FAULT : <0x02ef0cba> [ /lib/libc.so.0 + 0x30cba ] [P2++] = R0

     Source : <0x02ef0cb8> [ /lib/libc.so.0 + 0x30cb8 ] W[P6 + 7] = R0

   5 Target : <0x02ef0cb6> [ /lib/libc.so.0 + 0x30cb6 ]

     Source : <0x02ef0c46> [ /lib/libc.so.0 + 0x30c46 ] IF !CC JUMP pcrel (BP)

   6 Target : <0x02ef0c44> [ /lib/libc.so.0 + 0x30c44 ]

     Source : <0x00c15cba> [ /lib/libpthread.so.0 + 0x5cba ] RTS

   7 Target : <0x00c15cb4> [ /lib/libpthread.so.0 + 0x5cb4 ]

     Source : <0x00c15c80> [ /lib/libpthread.so.0 + 0x5c80 ] JUMP.S

   8 Target : <0x00c15c7e> [ /lib/libpthread.so.0 + 0x5c7e ]

     Source : <0x00c15c90> [ /lib/libpthread.so.0 + 0x5c90 ] JUMP.S

   9 Target : <0x00c15c90> [ /lib/libpthread.so.0 + 0x5c90 ]

     Source : <0x00c177d6> [ /lib/libpthread.so.0 + 0x77d6 ] RTS

  10 Target : <0x00c177ce> [ /lib/libpthread.so.0 + 0x77ce ]

     Source : <0x00c17762> [ /lib/libpthread.so.0 + 0x7762 ] IF CC JUMP pcrel (BP)

  11 Target : <0x00c17760> [ /lib/libpthread.so.0 + 0x7760 ]

     Source : <0x00000428> /* Maybe fixed code section */ RTS

  12 Target : <0x00000420> /* Maybe fixed code section */

     Source : <0x00c1775e> [ /lib/libpthread.so.0 + 0x775e ] CALL (P5)

  13 Target : <0x00c1775a> [ /lib/libpthread.so.0 + 0x775a ]

     Source : <0x00c1776a> [ /lib/libpthread.so.0 + 0x776a ] IF CC JUMP pcrel

  14 Target : <0x00c17764> [ /lib/libpthread.so.0 + 0x7764 ]

     Source : <0x00c17758> [ /lib/libpthread.so.0 + 0x7758 ] JUMP.S

  15 Target : <0x00c17744> [ /lib/libpthread.so.0 + 0x7744 ]

     Source : <0x00c13f82> [ /lib/libpthread.so.0 + 0x3f82 ] JUMP (P1)

Userspace Stack

Stack info:

SP: [0x00414b90] <0x00414b90> [ audio + 0x4b90 ]

FP: (0x00414d30)

Memory from 0x00414b90 to 00415000

00414b90:[00414bc0] 00a54108  00410004 00000006  00e89138  00000000  000000b0  00414c2c

00414bb0: 00a3cb98  00cd1488  005f35e8 00c9eedc  00410004  00000006  0000000c  005f5920

00414bd0: 000005b4  00000002  00414bfc 00414bf8  00414bf4  005f35e8  00414c08  00414e24

00414bf0: 00cd1488  00000000  00000010 92130002  1f2a640a  00000000  00000000  00000035

00414c10: 00a44210  00000000  00000000 00000000  00000000  002fa650  005f35e8  00414cfc

00414c30: 00a3d22a  0000000c  002fa650 00000001  00000000  00414cd4  00414cd0  005f35e8

00414c50: 00001000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414c70: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414c90: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414cb0: 00000000  00000000  00000000  00000000 00000000  00000000  00000000  00000000

00414cd0: 00000000  00000000  0003d090 00000001  002fa650  00000001  0000000f  00000004

00414cf0: 00000000  00000020  00414c50 00414d1c  00a3d46a  00000001  000000fa  00000000

00414d10: 005f35e8  00000000  000000fa 00414d30  00a285a4  00000000  00a53ae8  005f35e8

00414d30:(00414d4c)<00a53af8> 00000000 00000000  00000000  00000000  004040b0 (00414e00)

00414d50:<00c1532a> 00005000  004040b0 00000000  00000000  00000000  00000000  00000000

00414d70: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414d90: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414db0: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414dd0: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414df0: 00000000  00000000  00000000 00000000 (00000000)<02eccbd0> 00414e24  00cd1488

00414e10: 00005000  00c9eedc  00000000 00000000  00000000  00bf4e24  002f6e24  00000000

00414e30: 00000000  00001406  00000258 00000063  00cd37e4  00000000  00000000  00000000

00414e50: 00000100  00000000  00000000 00000000  00000000  00000000  00414e6c  00000000

00414e70: 00414e74  00000000  00000000 00000000  005f2ce0  004040b0  80000000  00000000

00414e90: 00c188e6  00cd0b80  00cd1488 00c9ee48  005ed6a8  80000000  00000000  00c9ee74

00414eb0: 00c15e80  00e89138  00fdf30c 00c9ee78  00c15c90  00e89138  00fdf30c  00cd1488

00414ed0: 00e89138  00fdf30c  00c9eea4 00c9eea4 <02ef0c44> 00e89808  004040ac  00c9eea8

00414ef0: 00000000  00c9eebc  00c9eec0 00c15cb0  00c9eeb0  00000010  00000000  00000000

00414f10: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414f30: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414f50: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414f70: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414f90: 00000000  00000000  00000000  00000000 00000000  00000000  00000000  00000000

00414fb0: 00000000  00000000  00414e24 00000006  00000000  00000000  00000000  00000000

00414fd0: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00414ff0: 00000000  00000000  00000000 00000000

Return addresses in stack:

   frame  1 : <0x00a53af8> [ /root/audio + 0x53af8 ]

   frame  2 : <0x00c1532a> [ /lib/libpthread.so.0 + 0x532a ]

   frame  3 : <0x02eccbd0> [ /lib/libc.so.0 + 0xcbd0 ]

    address : <0x02ef0c44> [ /lib/libc.so.0 + 0x30c44 ]

Data access misaligned address violation

<5> - Attempted misaligned data memory or data cache access.

Deferred Exception context

CURRENT PROCESS:

COMM=audio PID=595  CPU=0

TEXT = 0x00a00000-0x00aa823c        DATA = 0x005f023c-0x005fc8b0

BSS = 0x005fc8b0-0x00c80000  USER-STACK = 0x00c9fe80

 

return address: [0x02ef10cc]; contents of:

0x02ef10a0:  05ec  3228  e800 0000  3039  6803  9169  2007

0x02ef10b0:  3041  6460  0a07 1c06  3259  ac49  0c41  17f9

0x02ef10c0:  2042  0c41  1840 6066  3069  50d7 [9109] 520e

0x02ef10d0:  5005  0a18  1438 504a  0818  1411  0c43  1830

 

ADSP-BF548-0.2 525(MHz CCLK) 131(MHz SCLK) (mpu off)

Linux version 3.0.8-ADI-2011R1-svn43 (mark@linux-hez9) (gcc version 4.3.5 (ADI-2011R1-RC4) ) #640 Thu Nov 29 11:12:05 EST 2012

 

SEQUENCER STATUS: Not tainted

SEQSTAT: 00060024  IPEND: 0008  IMASK: ffff SYSCFG: 0006

  EXCAUSE   : 0x24

  physical IVG3 asserted : <0xffa0077c> { _trap + 0x0 }

RETE: <0x00000000> /* Maybe null pointer? */

RETN: <0x00410000> [ audio + 0x0 ]

RETX: <0x00000480> /* Maybe fixed code section */

RETS: <0x02ef0d60> [ /lib/libc.so.0 + 0x30d60 ]

PC  : <0x02ef10cc> [ /lib/libc.so.0 + 0x310cc ]

DCPLB_FAULT_ADDR: <0xa0f01c34> /* reserved memory */

ICPLB_FAULT_ADDR: <0x02ef10cc> [ /lib/libc.so.0 + 0x310cc ]

PROCESSOR STATE:

R0 : a0f01c41    R1 : 00410000    R2 : 00005004    R3 : 00415004

R4 : 00000001    R5 : a0f01c35    R6 : 0000000c    R7 : 00410000

P0 : 00e89138    P1 : a0f01c35    P2 : 00000420    P3 : 00006db0

P4 : 00e89808    P5 : 00e89124    FP : 00409d64    SP : 0040ff24

LB0: 02ee155f    LT0: 02ee155e    LC0: 00000000

LB1: 00c155a1    LT1: 00c1559a    LC1: 00000000

B0 : 00535160    L0 : 00000000    M0 : ffffffff    I0 : 00000000

B1 : 00000007    L1 : 00000000    M1 : bca43b68    I1 : 00000001

B2 : 7f735e13    L2 : 00000000    M2 : 50916faf    I2 : 00c9f644

B3 : 3553f588    L3 : 00000000    M3 : 371bfd80    I3 : 00b88240

A0.w: 00000a3d   A0.x: 00000000   A1.w: 00000a3d   A1.x: 00000000

USP : 00409d64  ASTAT: 02000040

 

Hardware Trace:

   0 Target : <0x00003cf4> { _trap_c + 0x0 }

     Source : <0xffa00710> { _exception_to_level5 + 0xa4 } JUMP.L

   1 Target : <0xffa0066c> { _exception_to_level5 + 0x0 }

     Source : <0xffa00520> { _bfin_return_from_exception + 0x18 } RTX

   2 Target : <0xffa00508> { _bfin_return_from_exception + 0x0 }

     Source : <0xffa005c4> { _ex_trap_c + 0x74 } JUMP.S

   3 Target : <0xffa00550> { _ex_trap_c + 0x0 }

     Source : <0xffa007d6> { _trap + 0x5a } JUMP (P4)

   4 Target : <0xffa0077c> { _trap + 0x0 }

      FAULT : <0x02ef10cc> [ /lib/libc.so.0 + 0x310cc ] R1 = [P1]

     Source : <0x02ef10ca> [ /lib/libc.so.0 + 0x310ca ] 0x50d7

   5 Target : <0x02ef10c2> [ /lib/libc.so.0 + 0x310c2 ]

     Source : <0x02ef10b6> [ /lib/libc.so.0 + 0x310b6 ] IF CC JUMP pcrel (BP)

   6 Target : <0x02ef10b1> [ /lib/libc.so.0 + 0x310b1 ]

     Source : <0x02ef10be> [ /lib/libc.so.0 + 0x310be ] IF !CC JUMP pcrel (BP)

   7 Target : <0x02ef10bc> [ /lib/libc.so.0 + 0x310bc ]

     Source : <0x02ef10ae> [ /lib/libc.so.0 + 0x310ae ] JUMP.S

   8 Target : <0x02ef10a0> [ /lib/libc.so.0 + 0x310a0 ]

     Source : <0x02ecca68> [ /lib/libc.so.0 + 0xca68 ] JUMP (P1)

   9 Target : <0x02ecca60> [ /lib/libc.so.0 + 0xca60 ]

     Source : <0x02ef0d5c> [ /lib/libc.so.0 + 0x30d5c ] JUMP.L

  10 Target : <0x02ef0d54> [ /lib/libc.so.0 + 0x30d54 ]

     Source : <0x00c15edc> [ /lib/libpthread.so.0 + 0x5edc ] RTS

  11 Target : <0x00c15ed4> [ /lib/libpthread.so.0 + 0x5ed4 ]

     Source : <0x00c15e80> [ /lib/libpthread.so.0 + 0x5e80 ] JUMP.S

  12 Target : <0x00c15e80> [ /lib/libpthread.so.0 + 0x5e80 ]

     Source : <0x00c179e2> [ /lib/libpthread.so.0 + 0x79e2 ] RTS

  13 Target : <0x00c179dc> [ /lib/libpthread.so.0 + 0x79dc ]

     Source : <0x00c1797e> [ /lib/libpthread.so.0 + 0x797e ] JUMP.S

  14 Target : <0x00c1797a> [ /lib/libpthread.so.0 + 0x797a ]

     Source : <0x00000428> /* Maybe fixed code section */ RTS

  15 Target : <0x00000420> /* Maybe fixed code section */

     Source : <0x00c17978> [ /lib/libpthread.so.0 + 0x7978 ] CALL (P2)

Userspace Stack

Stack info:

SP: [0x00409d64] <0x00409d64> [ audio + 0x1d64 ]

FP: (0x00409fb8)

Memory from 0x00409d60 to 0040a000

00409d60: 00000000 [00409d8c] 02ef0d60  00410000 00e89808  00e89124  00005004  00e89128

00409d80: 00000001  00cd1488  00409da4 00409dc0  00c15408  00414e24  00cd1488  00000001

00409da0: 0000007f  0000000c  00000001 00000000  00409db8  00000000  00409dbc  00000007

00409dc0: 00409fb8  00c1560a  00409f30 00cd1488  ffffffff  00000000  00497008  0000000c

00409de0: 0000001f  00c73b98  00000000 00000000  00409fb0  00409e30  00409e1c  00000010

00409e00: 00409f30  00cd0b80  00fdee04 00000000  0000024f  00000000  00002c0c  00cd0b80

00409e20: 00000000  00c9ef78  00fdee04 00000000  80000000  00000000  00000000  00000000

00409e40: 000000d0  fffffffe  00c9ef5c  00c9ef98 00c9ef79  00c9ef5c  00c9ef5c  00c9ef98

00409e60: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00409e80: 00000000  00000000  00000000 00000000  00c9ef3c  00c9ef38  02ece3fa  00000000

00409ea0: 00000000  00000000  00c9ef4c 00c1432e  ffffffef  fffffffe  ffffffff  ffffffff

00409ec0: ffffffff  ffffffff  ffffffff ffffffff  ffffffff  ffffffff  ffffffff  ffffffff

00409ee0: ffffffff  ffffffff  ffffffff ffffffff  ffffffff  ffffffff  ffffffff  ffffffff

00409f00: ffffffff  ffffffff  ffffffff ffffffff  ffffffff  ffffffff  ffffffff  ffffffff

00409f20: ffffffff  ffffffff  ffffffff ffffffff  00000010  00000000  00000000  00000000

00409f40: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00409f60: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00409f80: 00000000  00000000  00000000 00000000  00000000  00000000  00000000  00000000

00409fa0: 00000000  00000000  00000000 00000000  00000002  00000000 (00000000)<02eccbd0>

00409fc0: 00cd1488  00cd374c  00c9eef8 005f2ce0  00c9eef4  00000001  00000004  00000001

00409fe0: 00000000  0000e438  00000000 00bbfc24  00000000  00002000  005edff4  00000000

Return addresses in stack:

   frame  1 : <0x02eccbd0> [ /lib/libc.so.0 + 0xcbd0 ]

Outcomes