Table of Contents Previous topic Next topic
ASSEMBLER DIRECTIVES->Other Assembler Directives->COMMON
COMMON Specify common section
The COMMON directive causes the statements following it to be relocatably assembled into the named common section. This directive remains in effect until another absolute or relocatable section is specified.
Only data and romable data can be common. As a common section, the data space will be shared by other data using a common section.
The formats for the directive are:
[label] | COMMON[.S] | <section name>[,type][,relocation type] |
COMMON[.S] | <section number>[,type][,relocation type] | |
[label] | COMMON[.S] | <section number>[,type][,relocation type] |
'P' or 'POSTPONE' | This specifies that the segment should be relocated to an address higher than all other segments in the same address space except segments with the relocation type HIGH. This type is only valid in data segments. Typically this should be used for the heap segment which grows upwards during run time. |
'H' or 'HIGH' | This specifies that the segment should be relocated as high as possible in the available address space. This type is only valid in data segments. Typically this should be used for the stack segment which grows downwards during run time. |
'I' or 'INPAGE' | This specifies that the segment should be relocated into a single page of memory. Segments must have this relocation type if they are to be addressed using the direct addressing mode. See section for an example of the use of this relocation type. |