-PADDING


This option fills in data at the end of a section.

[Specification format]

-PADDING

 

-

Interpretation when omitted

None

[Detailed description]

-

This option fills in data at the end of a section so that the section size is a multiple of the alignment of the section.

[Example of use]

-

In the following case, 2 bytes of padding data are filled in the .const section, and linking is performed with a size of 0x08.

Alignment of the .const section: 4 bytes

Size of the .const section: 0x06 bytes

Alignment of the .text section: 2 byte

Size of the .text section: 0x02 bytes

>rlink a.obj b.obj -start=.const,.text/0 -padding

 

-

In the following case, if 2 bytes of padding data are filled in the .const section, and linking is performed with a size of 0x08, then an error will be output because it overlaps with the .text section.

Alignment of the .const section: 4 bytes

Size of the .const section: 0x06 bytes

Alignment of the .text section: 2 byte

Size of the .text section: 0x02 bytes

>rlink a.obj b.obj -start=.const/0,.text/6 -padding

[Remark]

-

The value of the generated padding data is 0x00.

-

Since padding is not performed to an absolute address section, the size of an absolute address section should be adjusted by the user.

-

Padding is performed only in the sections for text data, const variables, and initialized variables in V1.00.01. In V1.01.00 and later versions, however, padding is also done in the sections for uninitialized variables.