cancel
Showing results for 
Search instead for 
Did you mean: 

Archives Discussions

gregcouch
Journeyman III

CodeXL fails to debug on Ubuntu 15.04

I have some partial workarounds.  I installed CodeXL from the debian package, amdcodexl_1.7-7300_amd64.deb.

When I first debug my application I get:

/opt/AMD/CodeXL_1.7-7300/x86_64/libstdc++.so.6: version `CXXABI_1.3.8' not found

It turns out that the libstdc++.so distributed with CodeXL is older than the version that comes with Ubuntu 15.04.  So removing those files gets farther.  The right fix is for CodeXL to remove its additions to LD_LIBRARY_PATH before debugging the application.

Next, when I try to debug my application, I get:

/opt/AMD/CodeXL_1.7-7300/libAMDTOSWrappers.so: undefined symbol: XFree

And sure enough, it refers to XFree but isn't linked against libX11.so.  To workaround that CodeXL bug, I added LD_PRELOAD=/usr/lib/x86_64-linux-gnu/libX11.so.6 to the Project Settings.  My guess is the right fix is to use free() instead of XFree(), but linking with -lX11 would be okay.

But debugging still doesn't work.  When debugging, the application splash screen comes up (not OpenGL), then in the Debugged Process Events window, I get:

GDB String:  [Thread debugging using libthread_db enabled]

GDB String:  Using host libthread_db library  /lib/x86_64-linux-gnu/libthread_db.so.1 .

API Connection Established: CodeXL Servers Manager

API Connection Established: CodeXL OpenGL Server

Thread Created: 140736789042944 (LWP: 15076)

Thread Created: 140736797435648 (LWP: 15075)

Thread Created: 140736805828352 (LWP: 15074)

Thread Created: 140736896771840 (LWP: 15073)

Thread Created: 140736905164544 (LWP: 15072)

Thread Created: 140737175557888 (LWP: 15071)

GDB String:   Program received signal

GDB String:  SIGSEGV, Segmentation fault.

GDB String:  0x0000000000000000 in ?? ()

Signal: SIGPIPE

Now, I could use some help.  I'm attaching the corresponding CodeXL-gregc.log in case it helps.

   -- Greg

0 Likes
8 Replies
pinform
Staff

Hi Greg,

Thanks for your question. I am moving your post to the CodeXL forum so that the CodeXL experts can respond. You should be able to post CodeXL-related queries directly in the CodeXL forum--your queries should appear there instantly.
Let me know if you have any problems posting.

--Prasad

0 Likes

Hello Prasad,

It appears as if there are no CodeXL experts. Or perhaps there is only

one and he/she is on vacation. Is there an alternative place to file

bug reports?

Many thanks,

Greg

0 Likes

Hi Greg,

Sorry for the delayed response.

Ubuntu 15.04 is not formally supported by CodeXL. We'll be adding support for this version in a future release.

To overcome the libstd conflict - did you remove the libstdc++.so.6 module from the CodeXL folder or did you modify the CodeXL launch script? Do not modify the CodeXL launch script that sets LD_LIBRARY_PATH because it will prevent the debugger from loading the CodeXL custom OpenCL/OpenGL runtime wrappers. This is a possible cause for a crash during the debug session.

Can you upload the CodeXL log files so we can investigate further? They should be stored under /tmp/ Look for 2 files: CodeXL-your_login_name.log and CodeXLServers-your_login_name.log (the log file you uploaded before is no longer attached to the thread, probably got lost in the move to the CodeXL forum )

Doron Ofek

0 Likes

As mentioned in my original post, I worked around the libstdc++.so.6 bug

and the libAMDTOSWrappers.so bugs.

An alternate and possibly better fix for the LD_LIBRARY_PATH bug would

be to link CodeXL-bin with "-Wl,-rpath,'$ORIGIN/applib/'" where applib

has all of the libraries needed for the CodeXL-bin program. That way

LD_LIBRARY_PATH is just for libraries that need to replace the user's

application libraries since the libraries needed for CodeXL-bin are keep

in a separate directory.

Attached are CodeXL-gregc.log and CodeXLServers-gregc.log.

I am using the fglrx-updates drivers from Ubuntu 15.04. The OpenGL

version is 4.4.13374.

Thank you for looking into this,

Greg

0 Likes

Hi Greg,

Sorry to ask again, could you change the CodeXL log level to 'Extensive' (Tools->Options, General tab, see below), repeat the crash scenario and upload the log files?

Set_CodeXL_Extensive_Log.PNG

Thanks,

Doron

0 Likes

Attached are the Extensive logs.

Thanks for looking into this,

Greg

0 Likes

Hey Greg,

The engineers have the logs, but they are currently focused on the next release. I expect it to be a couple weeks before they can review the logs and respond. Thanks for your patience and understanding.

--Prasad

0 Likes

Hi Greg,

Thanks for uploading the extensive log file.

I have reviewed the logs but it is not clear why the segmentation fault is happening when your app is running inside a CodeXL debug session.

I have some good news too. The 2 issues you reported above (libstdc++ conflict and link with X11) are fixed in CodeXL 1.8 which was released Aug-20.

CodeXL 1.8 also includes several debugger bug fixes, mostly having to do with edge case scenarios.

Could you upgrade CodeXL to release 1.8 and try to debug again?

Also, is your application making large memory allocations?

Doron

0 Likes