Hi all. I have noticed that if change just a little the code I compile and link, the generated section allocation map can change a lot. This seems to be due to the fact the linker attempts to minimize memory fragmentation (From section 7.12.2 of SPRU186m (TMS320C6000 Assembly Language Tools User's Guide)). Does anybody know a way to disable this memory fragmentation reduction algorithm? I am using cl6x version 4.36. Hugo |
|
Annoying section and symbols shuffling in image
Started by ●June 30, 2004
Reply by ●June 30, 20042004-06-30
Hi Hugo, As you say, the algorithm is well described in spru186m, 7.12.2 You should certainly make intensive use of #pragma CODE_SECTION and #pragma DATA_SECTION directives for every function and variable, and define the corresponding sections in the cmd file, with eventually a fixed binding address (rule 1 of the allocation algorithm in 7.12.2). This can also be useful to manage efficiently L1P and L1D cache hits and misses, by grouping code and data accordingly. I don't think that there is a way to "disconnect" this algorithm. If you remove it, what should the linker do ? It is comfortable to have a deterministic behavior of the linker, and by using the above-mentionned pragmas, you can have full control of the memory map. Regards J-F --- In , "Hugo Jacques" <hugojacques1@y...> wrote: > Hi all. > > I have noticed that if change just a little the code I compile and > link, the generated section allocation map can change a lot. > > This seems to be due to the fact the linker attempts to minimize > memory fragmentation (From section 7.12.2 of SPRU186m (TMS320C6000 > Assembly Language Tools User's Guide)). > > Does anybody know a way to disable this memory fragmentation > reduction algorithm? > > I am using cl6x version 4.36. > > Hugo |