4 push and pop – ARM VERSION 1.2 User Manual

Page 205

Advertising
background image

Thumb Instruction Reference

ARM DUI 0068B

Copyright © 2000, 2001 ARM Limited. All rights reserved.

5-11

5.1.4

PUSH and POP

Push low registers, and optionally the lr, onto the stack.

Pop low registers, and optionally the pc, off the stack.

Syntax

PUSH {reglist}

POP {reglist}

PUSH {reglist, lr}

POP {reglist, pc}

where:

reglist

is a comma-separated list of low registers or low-register ranges.

Note

The braces in the syntax description are part of the instruction format.
They do not indicate that the register list is optional.

There must be at least one register in the list.

Usage

Thumb stacks are full, descending stacks. The stack grows downwards, and the sp
points to the last entry on the stack.

Registers are stored on the stack in numerical order, with the lowest numbered register
at the lowest address.

Advertising