SAM3N0B Atmel Corporation, SAM3N0B Datasheet - Page 90

no-image

SAM3N0B

Manufacturer Part Number
SAM3N0B
Description
Manufacturer
Atmel Corporation
Datasheets
10.12.2.5
10.12.2.6
10.12.2.7
90
SAM3N
Post-indexed addressing
Restrictions
Condition flags
The address obtained from the register Rn is used as the address for the memory access. The
offset value is added to or subtracted from the address, and written back into the register Rn.
The assembly language syntax for this mode is:
The value to load or store can be a byte, halfword, word, or two words. Bytes and halfwords can
either be signed or unsigned. See
Table 10-18
Table 10-18. Offset ranges
For load instructions:
When Rt is PC in a word load instruction:
For store instructions:
These instructions do not change the flags.
Instruction type
Word, halfword, signed
halfword, byte, or signed
byte
Two words
• Rt can be SP or PC for word loads only
• Rt must be different from Rt2 for two-word loads
• Rn must be different from Rt and Rt2 in the pre-indexed or post-indexed forms.
• bit[0] of the loaded value must be 1 for correct execution
• a branch occurs to the address created by changing bit[0] of the loaded value to 0
• if the instruction is conditional, it must be the last instruction in the IT block.
• Rt can be SP for word stores only
• Rt must not be PC
• Rn must not be PC
• Rn must be different from Rt and Rt2 in the pre-indexed or post-indexed forms.
[Rn, #offset]!
[Rn], #offset
shows the ranges of offset for immediate, pre-indexed and post-indexed forms.
Immediate offset
− 255 to 4095
multiple of 4 in the
range − 1020 to
1020
“Address alignment” on page
Pre-indexed
− 255 to 255
multiple of 4 in the
range − 1020 to
1020
83.
Post-indexed
− 255 to 255
multiple of 4 in the
range − 1020 to
1020
11011A–ATARM–04-Oct-10

Related parts for SAM3N0B