dsp56800e Freescale Semiconductor, Inc, dsp56800e Datasheet - Page 227

no-image

dsp56800e

Manufacturer Part Number
dsp56800e
Description
16-bit Digital Signal Controller Core
Manufacturer
Freescale Semiconductor, Inc
Datasheet
6.8.8
Normally, when the absolute value of the offset register N, (|N|) used when performing modulo arithmetic
is less than or equal to M01, the primary address arithmetic unit automatically wraps the address pointer
around by the required amount. However, if |N| is greater than M01, the result is data-dependent and
unpredictable except for the special case where N is a multiple of the block size, 2
is a positive integer. In this special case, the pointer Rn is updated using linear arithmetic to the same
relative address that is L blocks forward in memory, as shown in Figure 6-10.
Freescale Semiconductor
5. Determine the upper boundary of the circular buffer:
6. Select a value for the offset register if it is used in modulo operations.
7. Perform the modulo arithmetic calculation.
In summary, the size and exact location of the circular buffer is defined once a value is assigned to
the M01 register and to the address pointer register (R0 or R1) that will be used in a modulo
arithmetic calculation.
upper boundary = lower boundary + number of locations – 1.
— If the offset register is used in a modulo arithmetic calculation, it must be selected as follows:
— The special case where N is a multiple of the block size, 2
— Once the appropriate registers are set up, the modulo arithmetic operation occurs when an
— If the result of the arithmetic calculation would exceed the upper or lower bound, wrapping
Wrapping to a Different Bank
|N| ≤ M01 + 1
|N| refers to the absolute value of the contents of the offset register.
“Wrapping to a Different Bank.”
instruction is executed that uses any of the addressing modes in Section 6.8.5, “Supported
Memory Access Instructions,” with the R0 (or R1, if enabled) register.
around is correctly performed.
2
2
k
k
Figure 6-10. Linear Addressing with a Modulo Modifier
Address Generation Unit
M
M
Linear and Modulo Address Arithmetic
k
(Rn) ± N MOD M01
where N = 2
, is discussed in Section 6.8.8,
k
: N = L × (2
k
(L = 1)
k
), where L
6-33

Related parts for dsp56800e