dsp56800e Freescale Semiconductor, Inc, dsp56800e Datasheet - Page 221

no-image

dsp56800e

Manufacturer Part Number
dsp56800e
Description
16-bit Digital Signal Controller Core
Manufacturer
Freescale Semiconductor, Inc
Datasheet
The following four instructions will not perform modulo arithmetic because R0 and R1 are not source
operands for the instruction. As a result, there are no restrictions on which operand is used as pointer and
which is used as offset.
6.8.4.2
Using the above table, we can see that the example below incorrectly uses the modulo addressing
mode because the pointer and offset are not mapped to the correct operands.
Freescale Semiconductor
X:(Rn+>>xxxxxx)
ADDA Rx,Ry
ADDA Rx,Ry,N
ADDA #x,Rx
ADDA #x,Rx,N
ADDA #>xxxx,Rx,Ry
ADDA #>xxxx,Rx,Ry
ADDA #>>xxxxxx,Rx,Ry
ADDA #>>xxxxxx,Rx,Ry
ADDA.L Rx,Ry
ADDA.L Rx,Ry,N
ADDA.L #>xxxx,Rx,Ry
ADDA.L #>>xxxxxx,Rx,Ry
DECA Rx
DECA.L Rx
DECTSTA Rx
SUBA Rx,Ry
TSTDECA.W Rx
ADDA
ADDA
ADDA.L #>xxxx,HHH,Rx
ADDA.L #>>xxxxxx,HHH,Rx
Addressing Mode
Example of Incorrect Modulo Operation
or Instruction
Table 6-8. Base Pointer and Offset/Update for DSP56800E Instructions
#>xxxx,HHH,Rx
#>>xxxxxx,HHH,Rx
Address Generation Unit
Base Pointer
#>>xxxxxx
#>>xxxxxx
>>xxxxxx
#>xxxx
#>xxxx
Ry
Ry
Rx
Rx
Rx
Rx
Ry
Ry
Rx
Rx
Rx
Ry
Rx
(Update Value)
Offset Value
#>>xxxxxx
Linear and Modulo Address Arithmetic
#>xxxx
Rn
Rx
Rx
Rx
Rx
Rx
Rx
Rx
Rx
Rx
#x
#x
-1
-2
-1
-1
Alternate use for this
addressing mode. Rn
must be positive for
correct modulo oper-
ation.
See Section 6.8.4.3
for the case where
the immediate value
is negative.
See Section 6.8.4.3
for the case where
the immediate value
is negative.
Comments
6-27

Related parts for dsp56800e