Debugging Issue on imx6UL

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

Debugging Issue on imx6UL

1,499 Views
enginfirat
Contributor I

Hello all,

We have a Qt based application and it compiles and runs successfully on target board. However, when we try to debug the application, SEGV signal got from the application and application stops running. Below please find the output:

0x76fcfac0 in ?? () from /toolchain/sysroots/cortexa7hf-vfp-neon-dey-linux-gnueabi/lib/ld-linux-armhf.so.3
The target endianness is set automatically (currently little endian)

Program received signal SIGSEGV, Segmentation fault.
0x76fdfa98 in ?? () from /toolchain/sysroots/cortexa7hf-vfp-neon-dey-linux-gnueabi/lib/ld-linux-armhf.so.3

To debug the application, we start the gdbserver in target platform and we simply start the gdb (compiled within the cross tool chain).

However the same application runs without any problems when we simply run the application from the console. 

Please find below the used Ecplise debugger settings for debugging the application:

GDB Debugger: /toolchain/sysroots/x86_64-deysdk-linux/usr/bin/arm-dey-linux-gnueabi/arm-dey-linux-gnueabi-gdb

GDB Command Line: (Below is the file content)

set sysroot /toolchain/sysroots/cortexa7hf-vfp-neon-dey-linux-gnueabi
set auto-load safe-path /

Using GDB (DSF) Manual Remote Debugger Launcher

Why there is such problem?

Sincerely.

Labels (1)
0 Kudos
Reply
4 Replies

1,173 Views
igorpadykov
NXP Employee
NXP Employee

Hi Engin

please check AN5229 ARM DS-5 Development Studio Debug i.MX6UL-EVK
http://www.nxp.com/assets/documents/data/en/application-notes/AN5229.pdf
AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors
http://www.nxp.com/assets/documents/data/en/application-notes/AN4553.pdf

Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply

1,173 Views
enginfirat
Contributor I

Hello Igor,

Actually, I setup an environment like mentioned in Document AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors. However as I have mentioned, whenever the debugging starts immediately SIGSEGV is thrown and debugging stops. Program does not break at any break point.

Sincerely.

0 Kudos
Reply

1,173 Views
igorpadykov
NXP Employee
NXP Employee

Hi Engin

is it working without Qt, just linux.

Best regards
igor

0 Kudos
Reply

1,173 Views
enginfirat
Contributor I

Hello Igor, 

I have tried with two simple projects, one with Qt and one without Qt. For both tries, I was able to debug the application without any problems.

As an another try, I have moved the application to QtCreator IDE and built and compiled it. The debugging attempt with Qt also produces a SIGSEGV however this time I was able to see where the executable access to invalid memory. Please see the attached screenshots: 

SEGV.png

dl_debug_source.png

(Ps. Above the line 55 is where the cursor hangs)

After a little search on problem I have found a stackoverflow thread:

boost - Segmentation fault only during GDB debugging - Stack Overflow 

Were you or any people from community faced this problem before? What is your opinion about the problem?

Sincerely.

0 Kudos
Reply