what does Linker error "cannot bind symbol" mean? TX387, Triboard, TASKING,

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
User17628
Level 1
Level 1
Hello,

I'm using the VX-Toolset TASKING environment to build an app for the TX387 target to a TriBoard. I'm getting the following error:

Linking to xxx.elf
ltc E132: cannot bind symbol "_lc_ub_heap": cannot find section or group to bind to
ltc E132: cannot bind symbol "_lc_ue_heap": cannot find section or group to bind to
amk E452: ["makefile" 113/0] target 'xxx.elf' returned exit code 1
amk E451: make stopped

I'm a 'newby' to this chip and its toolsets: what is this error trying to tell me?

Might anyone have any info/hints/suggestions on how to address this?

Thanks in advance,

Malcolm
0 Likes
2 Replies
cwunder
Employee
Employee
5 likes given 50 likes received 50 solutions authored
It is complaining that it can't find "beginning" and "end" of the heap in your lsl file and you are assigning it in your source file somewhere.

For example in user stack in cstart.c
/* linker definitions */
extern __far void _lc_ue_ustack[]; /* user stack end */
/*in your code you assign the user stack*/
void * sp = (void *)((unsigned int)(_lc_ue_ustack) & STACK_ALIGN);
__set_sp( sp );

Then in the lsl file you have a section definition
section_layout :tc0:linear
{
"_lc_ue_ustack" := "_lc_ue_ustack_tc0"; /* common cstart interface for first or single core */
"_lc_ue_istack" := "_lc_ue_istack_tc0"; /* common cstart interface for first or single core */
}
0 Likes
User17628
Level 1
Level 1
Thanks!

Just an FYI for anyone else that might come across this thread, I got this from TASKING support, and this also works to solve my issue:
-------------
do you use the Infineon iLLD drivers and a linker LSL file provided by Infineon?

The error indicates that your application seems to use dynamic memory allocation but the heap section was not defined. You can add an entry like:

#define HEAP 16k

section_setup :vtc:linear
{
heap "heap"
(
min_size = (HEAP),
fixed,
align = 8
);
}

to the LSL file to define a heap section of 16k.

-------------
0 Likes