--lock
In this section:
Syntax
--lock={Ri|Rj,Rk|Rm-Rp}Parameters
| The register(s) to lock |
Description
Use this option to lock one or several of the registers R8–R13 so that they cannot be used by the compiler but can be used for global register variables. To maintain module consistency, make sure you lock the same registers in all modules. By default, no registers are locked.
Example
--lock=R10 --lock=R8,R12,R13 --lock=R10-R13 --lock=R8,R11-R13
See also
Caution
Project>Options>C/C++ Compiler>Code>Lock registers