Skip to main content

IAR Embedded Workbench for RH850 3.20.x

Register locking

In this section:

Register locking means that the compiler can be instructed never to touch some processor registers. This can be useful in a number of situations. For example:

  • Some parts of a system could be written in assembler language to improve execution speed. These parts could be given dedicated processor registers.

  • The register could be used by an operating system, or by other third-party software.

Register locking is performed using the compiler option --lock_10_regs on a predefined group of registers. See --lock_10_regs.

Note

The compiler never uses the processor register R2.