Debugging with XCOMMON?

Technical questions regarding the XTC tools and programming with XMOS.
User avatar
Interactive_Matter
XCore Addict
Posts: 216
Joined: Wed Feb 10, 2010 10:26 am

Debugging with XCOMMON?

Post by Interactive_Matter »

Hi,

I am trying to debug the ap_led_tile in the XDE (did I tell you that I love this way of debugging).
Unfortunately I cannot inspect the code or set breakpoints since the code is already built with maximum optimization and no debug information:

Code: Select all

XCC_FLAGS = -O3 -g -report 
Is there a way to inculde the debug output into the binary to debug it in XDE? I tried it the dump way and just got the error 'multiple target patterns':

Code: Select all

../../xcommon/module_xcommon/build/Makefile.common:528: *** multiple target patterns.  Stop
This is presumably because the <name>.d files in the build directory confuse xmake??

Is there a debug configuration in xcommon? and how do I use it?

Thanks

Marcus


User avatar
Interactive_Matter
XCore Addict
Posts: 216
Joined: Wed Feb 10, 2010 10:26 am

Post by Interactive_Matter »

Oh,

solved it myself by poking around:

setting the compiler options in the Makefile to the following solved it completely without problems:

Code: Select all

XCC_FLAGS = -O0 -g -report 
I used the compiler options of the default eclipse build and the -MMD options are generating the .d files, which caused the probelm. Those files seem to contain the dependency information which is handled differently in xcommon (I think).

Now I can simply start the program in debugger (now I have to switch of the watchdig - since it cannot distiguish between a break point and a crash ;) )

Sorry for disturbing you. But perhaps it helps somebody else.

Marcus