Bit Manipulation Instructions; Table 2-5 Bit Manipulation Instructions - Motorola DSP56600 Manual

Application optimization for digital signal processors
Table of Contents

Advertisement

Data Operations

BIt manipulation instructions

2-10
Optimizing DSP56300/DSP56600 Applications
move
move
move
do
move
normf
normf
move
_ENDLOOP
move
2.5
BIT MANIPULATION INSTRUCTIONS
The data ALU has a special Bit Field Unit (BFU) that supports
powerful bit-manipulation instructions that enable an application to
insert/ extract a bit field of varying width and position to/from an
accumulator. These instructions are summarized in Table 2-5.

Table 2-5 Bit manipulation instructions

Mnemonic
Function
Extract a
EXTRACT
bit field
Extract an
EXTRACTU
unsigned
bit field
Insert a bit
INSERT
field
Merge
field &
width
MERGE
data to
one
register
The EXTRACT(U) and INSERT instruction use a control operand
(C) that specifies the bit field to be extracted or inserted. The bit field
#base-1,r4
a1,x1
x:(r0)+,a
#N/2,_ENDLOOP
x:(r0)+,b b,y:(r4)+; 1 x N/2
x1,a
; 1 x N/2
x1,b
; 1 x N/2
x:(r0)+,a a,y:(r4)+; 1 x N/2
b,y:(r4)+
; 1
;Total: 3N + 22
C,S,D
C: Source field position
& width
S: Data source
D: Data Destination
C,S,D
C: Destination field
position & width
S: Data source
D: Data Destination
S,D
S: Width Data Source.
D: Position data source
& merging destination
; 1
; 1
; 1
; 5
Operands
6-bit immediate, or:
X0,X1,Y0,Y1,A1,B1
A,B
A,B
6-bit immediate, or:
X0,X1,Y0,Y1,A1,B1
X0,X1,Y0,Y1,A1,B1
A,B
X0,X1,Y0,Y1,A1,B1
A,B
MOTOROLA

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dsp56300

Table of Contents