Help needed to debug a thread

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Help needed to debug a thread

Jump to solution
681 Views
DavidA2012
Contributor III

Hi 

 

I am trying to debug the hello_reflector example provided in the P4080 Linux SDK. The example launches multiple threads from main() by calling pthread_create().

 

I can step through the code until the pthread_create() line but, if I set a breakpoint in the thread's function, and continue execution from the line of pthread_create(), the debugger termninates. The debugger does not stop at the breakpoint in the thread function.

 

If I run the code outside of the debugger it runs ok.

 

What is the proper procedure for running to, and stopping at, a line in a newly created thread please?

 

Best regards

 

David

Labels (1)
0 Kudos
1 Solution
409 Views
DavidA2012
Contributor III

Hi

 

Freescale informed me that In order to debug applications that use pthreads, it is necessary to compile unstripped versions of libraries libpthread.so.0 and ld.so.1. This fixed my problem.

 

David

View solution in original post

0 Kudos
1 Reply
410 Views
DavidA2012
Contributor III

Hi

 

Freescale informed me that In order to debug applications that use pthreads, it is necessary to compile unstripped versions of libraries libpthread.so.0 and ld.so.1. This fixed my problem.

 

David

0 Kudos