MOTOROLA
11-10
DIGITAL SIGNAL PROCESSING
CPU16
REFERENCE MANUAL
11.7.5 Stacking Instructions
The PSHMAC and PULMAC instructions stack and restore all MAC resources.
11.7.5.1 PSHMAC — Push MAC Registers
PSHMAC stacks MAC registers in the sequence shown, beginning at the address
pointed to by the stack pointer.
The entire MAC unit internal state is saved on the system stack. Registers are stacked
from high to low address. The stack pointer is automatically decremented after each
save operation (the stack grows downward in memory). If SP overflow occurs as a re-
sult of operation, the SK field is decremented.
11.7.5.2 PULMAC — Pull MAC Registers
PULMAC restores MAC registers in the sequence shown, beginning at the address
pointed to by the stack pointer.
The entire MAC unit internal state is restored from the system stack. Registers are re-
stored in order from low to high address. The SP is incremented after each restoration
(stack shrinks upward in memory). If SP overflow occurs as a result of operation, the
SK field is incremented.
11.7.6 Branch Instructions
LBEV and LBMV are conditional long branch instructions associated with the EV and
MV bits in the CCR.
11.7.6.1 LBEV — Long Branch if EV Set
LBEV causes a long program branch if the EV bit in the condition code register has a
value of one. A 16-bit signed relative offset is added to the current value of the program
counter. When the operation causes PC overflow, the PK field is incremented or dec-
remented.
15
8
H REGISTER
I REGISTER
ACCUMULATOR M[15:0]
ACCUMULATOR M[31:16]
RESERVED
7
0
(SP)
(SP) – $0002
(SP) – $0004
(SP) – $0006
(SP) – $0008
(SP) – $000A
SL
AM[35:32]
IX ADDRESS MASK
IY ADDRESS MASK
15
8
7
0
(SP) + $000A
(SP) + $0008
(SP) + $0006
(SP) + $0004
(SP) + $0002
(SP)
IX ADDRESS MASK
IY ADDRESS MASK
SL
RESERVED
ACCUMULATOR M[31:16]
ACCUMULATOR M[15:0]
I REGISTER
H REGISTER
AM[35:32]
F
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
n
.