Hello,
I am having some problems with source level debugging with my custom XDC modules. The behavior is quite odd. In one instance, when I openned the source files, and placed breakpoints it could find the proper mem addresses, but some of my switch statement jump tables were all zeros. Then I changed a few things, and my switch jump tables are there, but the debugger can no longer connect a source line to an address when I place a break point. Below are the vitals for the last case.
config.bld:
var Build = xdc.useModule('xdc.bld.BuildEnvironment');
var C64P = xdc.useModule('ti.targets.C64P');
var C66 = xdc.useModule('ti.targets.elf.C66');
C64P.rootDir = "" + java.lang.System.getenv("TIDSP_REPO_ROOT") + '/compilers/' + java.lang.System.getenv("BUILD_TOOLS_PLAT").toLowerCase() + '/TI_CGT_C6000_7.3.0/';
C66.rootDir = "" + java.lang.System.getenv("TIDSP_REPO_ROOT") + '/compilers/' + java.lang.System.getenv("BUILD_TOOLS_PLAT").toLowerCase() + '/TI_CGT_C6000_7.3.0/';
C66.platform = 'ti.platforms.evm6678';
C64P.platform = 'ti.platforms.evm6472';
Build.targets = [C64P];
module repo package.bld:
var Build = xdc.useModule('xdc.bld.BuildEnvironment');
var Pkg = xdc.useModule('xdc.bld.PackageContents');
var LIB_NAME = "lib/" + Pkg.name;
var LIB_SRCS = ["moda.c", "modb.c", "modc.c", "modd.c", "mode.c"];
var ROOT = java.lang.System.getenv("TIDSP_REPO_ROOT");
var DSPLIBINC = ROOT + "/ti_libs/c64plus-dsplib/include/"
var AESLIBINC = ROOT + "/ti_libs/AES64plus_v1_00/"
Pkg.attrs.profile = 'debug';
Pkg.attrs.copts = '-g -mv6400';
//Pkg.attrs.profile = 'release';
//Pkg.attrs.copts = '-O3 --opt_for_speed=5 -s -k -al -mw -os -mv6400';
Pkg.attrs.incs = '-I"' + DSPLIBINC + '" ' +
'-I"' + AESLIBINC + '"';
for each (var targ in Build.targets)
{
Pkg.addLibrary(LIB_NAME, targ).addObjects(LIB_SRCS);
}
binary package.bld:
var Build = xdc.useModule('xdc.bld.BuildEnvironment');
var Pkg = xdc.useModule('xdc.bld.PackageContents');
var EXECUTABLE_NAME = "core3";
var ROOT = java.lang.System.getenv("TIDSP_REPO_ROOT");
var DSPLIB = ROOT + "/ti_libs/c64plus-dsplib/lib/dsplib64plus.lib"
Pkg.attrs.lopts = ' -l "' + DSPLIB + '"' +
' --reread_libs -x'
for each (var targ in Build.targets)
{
var progAttrs = {profile: "debug"};
//var progAttrs = {profile: "whole_program"};
Pkg.addExecutable(EXECUTABLE_NAME, targ, targ.platform, progAttrs).addObjects([EXECUTABLE_NAME + ".c"]);
}
environment vars:
export BUILD_TOOLS_PLAT=LIN
export PATH=$PATH:$TIDSP_REPO_ROOT/ti_rtsc/lin/xdctools_3_22_04_46
export XDCPATH=$TIDSP_REPO_ROOT/ti_rtsc/bios_6_32_01_38/packages\;$TIDSP_REPO_ROOT/ti_rtsc/ipc_1_23_01_26/packages
export XDCBUILDCFG=`pwd`/Config_Bld/tms320c6472.bld
I have attempted this with both CCSv4.2 and CCSv5.1.0.09000