English
Language : 

SH-2A Datasheet, PDF (236/501 Pages) Renesas Technology Corp – Renesas 32-Bit RISC Microcomputer SuperH™ RISC engine Family
Section 6 Instruction Descriptions
6.4.32
MOV
MOVe peripheral Data
Peripheral Module
Data Transfer
Data Transfer Instruction
Format
Abstract
Code
MOV.B @(disp,GBR),R0 (disp + GBR) → sign extension → R0 11000100dddddddd
MOV.W @(disp,GBR),R0 (disp × 2 + GBR) → sign extension → R0 11000101dddddddd
MOV.L @(disp,GBR),R0 (disp × 4 + GBR) → R0
11000110dddddddd
MOV.B R0,@(disp,GBR) R0 → (disp + GBR)
11000000dddddddd
MOV.W R0,@(disp,GBR) R0 → (disp × 2 + GBR)
11000001dddddddd
MOV.L R0,@(disp,GBR) R0 → (disp × 4 + GBR)
11000010dddddddd
Cycle T Bit
1
—
1
—
1
—
1
—
1
—
1
—
Description
Transfers the source operand to the destination. This instruction is optimum for accessing data in
the peripheral module area. The data can be a byte, word, or longword, but only the R0 register
can be used.
A peripheral module base address is set to the GBR. When the peripheral module data is a byte,
the only change made is to zero-extend the 8-bit displacement. Consequently, an address within
+255 bytes can be specified. When the peripheral module data is a word, the 8-bit displacement is
zero-extended and doubled. Consequently, an address within +510 bytes can be specified. When
the peripheral module data is a longword, the 8-bit displacement is zero-extended and is
quadrupled. Consequently, an address within +1020 bytes can be specified. If the displacement is
too short to reach the memory operand, the above @(R0,Rn) mode must be used after the GBR
data is transferred to a general register. When the source operand is in memory, the loaded data is
stored in the register after it is sign-extended to a longword.
Note
The destination register of a data load is always R0. R0 cannot be accessed by the next instruction
until the load instruction is finished. The instruction order shown in figure 6.1 will give better
results.
MOV.B @(12, GBR), R0
AND #80, R0
ADD #20, R1
MOV.B @(12, GBR), R0
ADD #20, R1
AND #80, R0
Figure 6.1 Using R0 after MOV
Rev. 3.00 Jul 08, 2005 page 222 of 484
REJ09B0051-0300