7.10.3.1 Initialization Tables
The tables in the .cinit section consist of variable-size initialization records. Each variable that must be autoinitialized has a record in the .cinit section. Figure 7-2 shows the format of the .cinit section and the initialization records.
The fields of an initialization record contain the following information:
- The first field of an initialization record contains the size (in words) of the initialization data. That is, this field contains the size of the third field. The size is specified as a negative value; this is legacy behavior, and the absolute value of this field is the size of the data.
- The second field contains the starting address of the area within the .ebss (or .bss) section where the initialization data must be copied. The second field requires two words to hold the address.
- The third field contains the data that is copied into the .ebss (or .bss) section to initialize the variable. The width of this field is variable.
Each variable that must be autoinitialized has an initialization record in the .cinit section.
Example 7 shows initialized global variables defined in C. Example 8 shows the corresponding initialization table.