Everything
8.5.2 Function of Each Option

The following describes the options related to the PIC/PID function.

For details of each option function, refer to the respective option description of the COMMAND REFERENCE chapter.

(1)

Application Code Generation (pic and pid Options)

When the pic option is specified for compilation, the PIC function is enabled and the code in the code area (P section) becomes PIC. The PIC always uses PC relative mode to acquire branch destination addresses or function addresses, so it can be reallocated to any desired addresses even after linkage.

When the pid option is specified for compilation, the PID function is enabled and the data in ROM data areas (C_8, C, C_2, C_1, W, W_2, W_1, and L sections) becomes PID. A program executes relative access to the PID by using the register (PID register) that indicates the start address of the PID. The user can move the PID to any desired addresses by modifying the PID register value even after linkage.

Note that the PIC function (pic option) and PID function (pid option) are designed to operate independently. However, it is recommended to enable both functions and allocate the PIC and PID to adjacent areas. Support for independently using either the PIC or PID function and for debugging of applications where the distance between the PIC and PID is variable may or may not be available, depending on the version of the debugger. The examples described later assume that both PIC and PID functions are enabled together.

(2)

Shared Library Support (jump_entries_for_pic and nouse_pid_register Options)

These options provide a function for calling the libraries of the master from an application.

The nouse_pid_register option should be used for master compilation to generate a code that does not use the PID register.

When the jump_entries_for_pic option is specified in the optimizing linkage editor at master linkage, a jump table is created to be used to call library functions at fixed addresses from an application.

(3)

Sharing of RAM Area (Fsymbol Option)

This option enables variables in the master to be read or written from an application whose linkage unit differs from that of the master.

When the Fsymbol option is specified in the optimizing linkage editor at master linkage, a symbol table is created to be used to refer to variables at fixed addresses from an application.