Keil Logo

Register Usage

Assembler functions may destroy the contents of R0-R3, R8-R12, and R14. When invoking a C function from assembly, you must assume that these registers are destroyed.

Registers R4-R7 may be used but their contents must be saved (on entry) and restored (before returning).

The following registers have special meaning and must be preserved by all assembler routines.

Register Description
R13 = SP R13 is the stack pointer.
R14 = LR R14 is the link register that holds the function return value. It may be destroyed by the assembly function.
R15 = PC R15 may be used but its contents must be saved (on entry) and restored (before returning).
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.