beautypg.com

Motorola DSP96002 User Manual

Page 628

background image

MOTOROLA

DSP96002 USER’S MANUAL

B-109

_clip2_znn

move d6.s,d0.s y:(r1),d6.s ;Zo 1 1

fsub.s d0,d6 d6.s,d0.s ; 1 1

fseedd d6,d4 ; 1 1

fmpy.s d6,d4,d6 d9.s,d2.s ; 1 1

fmpy d0,d4,d0 fsub.s d6,d2 d2.s,d3.s ; 1 1

fmpy.s d6,d2,d6 d2.s,d4.s ; 1 1

fmpy d0,d4,d0 fsub.s d6,d3 ; 1 1

fmpy.s d0,d3,d0 ; 1 1

fcmp d7,d0 ; 1 1

ftfr.s d0,d7 fflt ; 1 1

rts ; 2 2

B.1.45

Walsh-Hadamard Transforms

The Walsh-Hadamard transform (WHT) is an orthogonal transform requiring only additions and subtrac-

tions. The transform can be decomposed similar to the fast fourier transform (FFT) to yield a fast imple-

mentation of the WHT.

B.1.45.1 In-place WHT

Since the WHT requires 2 loads and 2 stores per butterfly, the maximum throughput for a WHT butterfly is

4 cycles. This implementation executes 2 butterflies in 8 cycles on the inner loop for a 4N per butterfly

execution speed. The last stage is split out and also executes 2 butterflies in 8 cycles for each pass of the

loop.

In this example, a 16 point transform is performed. The input data are in X:0-f and the output is in x:0-f in

bit reversed order.

Execution speed for a 1024 point WHT is 1.68 milliseconds at 13.5 MIPS.

page 132,60,1,1

;

; Implements the Walsh-Hadamard Transform

;

iord equ 4 ;order of transform=log2(npoints)

n equ 1<

org x:0

data