Compact Opcode Use
Special Instructions
MOTOROLA Optimizing DSP56300/DSP56600 Applications 7-9
7.4.3 Clearing Registers
It is often needed to clear a certain register or accumulator in the
code. Optimization can be accomplished in this area, also. Example:
move r1,r0
move #0,a
move y0,a0
This example can be optimized by using the CLR instructions and
by combining a move instruction with the CLR to a parallel opcode:
clr a r1,r0
move y0,a0
Another example:
add x0,a
clr b
move y0,b0
This can be optimized by:
add x0,a #0,b
move y0,b0
Commentaires sur ces manuels