You use the ROM directive to specify the size of the program memory. This directive affects the coding of the JMP and CALL instructions.
Option
Description
SMALL
CALL and JMP instructions are coded as ACALL and AJMP. The maximum program size may be 2 KBytes. The entire program must be allocated within the 2 KByte program memory space.
COMPACT
CALL instructions are coded as LCALL. JMP instructions are coded asAJMP within a function. The size of a function must not exceed 2 KBytes. The entire program may, however, comprise a maximum of 64 KBytes. The type of application determines whether or not ROM (COMPACT) is more advantageous than ROM (LARGE). Any code space saving advantages in using ROM (COMPACT) must be empirically determined.
LARGE
CALL and JMP instructions are coded as LCALL and LJMP. This allows you to use the entire address space without any restrictions. Program size is limited to 64 KBytes. Function size is also limited to 64 KBytes.
D512K† (Dallas 390& variants)
19-bit ACALL and AJMP instructions are generated. The maximum program size may be 512 KBytes. This mode is available only for the Dallas 390 and compatible devices.
D16M† (Dallas 390& variants)
24-bit LCALL instructions and 19-bit AJMP instructions are generated. The maximum program size may be 16MBytes. This mode is available only for the Dallas 390 and compatible devices.
Note
The D512K and D16M options require the OMF2 directive.