Tool/software: TI C/C++ Compiler
Can the linker palign directive be used on a GROUP of sections?
The documentation describes the handling of alignment for a GROUP:
You can use binding, alignment, or named memory to allocate a GROUP in the same manner as a single
output section.
...
When you use the GROUP option, binding, alignment, or allocation into named memory can
be specified for the group only. You cannot use binding, named memory, or alignment for
sections within a group.
I don't see any place where it specifically describes alignment-with-padding for a GROUP. I had assumed that the palign directive would be applicable, but in my testing with TI v17.3.0.STS and TI v5.2.8 I'm not seeing any padding for the GROUP I'm defining when using the following in the linker .cmd file:
SECTIONS
{
mysolosection0 : > FLASH0, palign(8), crc_table(crcTable, algorithm=TMS570_CRC64_ISO)
GROUP (group1) {
mysection*
} > FLASH0, palign(8), crc_table(crcTable, algorithm=TMS570_CRC64_ISO)
}
Specifically, I'm seeing the following in the .map file:
output attributes/
section page origin length input sections
-------- ---- ---------- ---------- ----------------
mysection*
* 0 00000020 00000005
00000020 00000001 sections.obj (mysection1:retain)
00000021 00000001 sections.obj (mysection2:retain)
00000022 00000001 sections.obj (mysection3:retain)
00000023 00000001 sections.obj (mysection4:retain)
00000024 00000001 sections.obj (mysection5:retain)
mysolosection0
* 0 00000028 00000008
00000028 00000001 sections.obj (mysolosection0:retain)
00000029 00000007 --HOLE-- [fill = 0]
...
LINKER GENERATED CRC TABLES
crcTable @ 000003c8 records: 2, size/record: 24, table size: 56
mysection*: algorithm=TMS570_CRC64_ISO(ID=10), load addr=00000020, size=00000005, CRC=8d8d8da38e000003
mysolosection0: algorithm=TMS570_CRC64_ISO(ID=10), load addr=00000028, size=00000008, CRC=8e00000000000003
What I'm hoping to see in first that each entry in the CRC table has a size that is a multiple of 64 bits, for ease when computing the CRC64 in our code, and second that there are well-defined HOLEs covering any needed padding.
--thx