This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Making the segment size multiple of 16

Hi,

using scatter loader file, I want to align my ELF segment aligned at 16 byte boundary (secondary requirement). Also, I want that the size of segment become multiple of 16 (primary requirement).

I am using "ALIGN 16" to do this. It places segments aligned to 16 in ELF but the size of segment does not change to multiple of 16.

For example:

Suppose there are 3 segments (LR).

LR1 is of size 12.
LR2 is of size 8.
LR3 is of size 30.

I want to make the size of these segments multiple of 16 in ELF file. I use ALIGN 16.

LR1 RAM_ADD1 ALIGN 16 12
LR2 RAM_ADD2 ALIGN 16 8
LR3 RAM_ADD3 ALIGN 16 30

The out come I expect is that in ELF file, all three should have size multiple of 16.
Size of LR1 should become 16 (from 12)
Size of LR2 should become 16 (from 8)
Size of LR3 should become 32 (from 30).