HD6417660 RENESAS [Renesas Technology Corp], HD6417660 Datasheet - Page 141

no-image

HD6417660

Manufacturer Part Number
HD6417660
Description
Renesas 32-Bit RISC Microcomputer
Manufacturer
RENESAS [Renesas Technology Corp]
Datasheet
3.4.3
In double data transfer instructions, a modulo addressing can be used. The modulo addressing
control instructions are listed in table 3.11. If the address pointer value reaches the preset modulo
end address while a modulo addressing mode is specified, the address pointer value becomes the
modulo start address.
To control modulo addressing, the modulo register (MOD) extended in the DSP mode and the
DMX and DMY bits of the SR register are used.
The MOD register is provided to set the start and end addresses of the modulo address area. The
upper and lower words of the MOD register store modulo start address (MS) and modulo end
address (ME), respectively. The LDC and STC instructions are extended for MOD register
handling.
If the DMX bit of the SR register is set, the modulo addressing is specified for the X address
register. If the DMY bit of the SR register is set, the modulo addressing is specified for the Y
address register. Modulo addressing is valid for either the X or the Y address register, only; it
cannot be set for both at the same time. Therefore, DMX and DMY cannot both be set
simultaneously (if they are, the DMY setting will be valid). (In the future, this specification may
be changed.) The DMX and MDY bits of the SR can be specified by the STC or LDC instruction
for the SR register.
If an exception is accepted during modulo addressing, the MDX and MDY bits of the SR and
MOD register must be saved. By restoring these register values, a control is returned to the
modulo addressing after an exception handling.
Table 3.11 Modulo Addressing Control Instructions
Instruction
STC
STC.L MOD,Rn
LDC
LDC
MOD,Rn
@Rn+,MOD
Rn+,MOD
Modulo Addressing
Operation
MOD → Rn
Rn – 4 → Rn, MOD → (Rn)
(Rn) → Rn, Rn + 4 → Rn
Rn → MOD
Rev. 1.00, 02/04, page 103 of 804
Execution States
1
1
4
4

Related parts for HD6417660