Texas Instruments TMS320C64X Programmer's Reference Manual page 121

Dsp little-endian dsp library
Hide thumbs Also See for TMS320C64X:
Table of Contents

Advertisement

DSP_radix2
Function
Arguments
Description
Algorithm
Complex Forward FFT (radix 2)
NOTE: This function is provided for backward compatibility with the C62x
DSPLIB. It has not been optimized for the C64x architecture. You are advised
to use one of the newly added FFT functions which have been optimized for the
C64x.
void DSP_radix2 (int nx, short * restrict x, const short * restrict w)
nx
Number of complex elements in vector x. Must be a power of 2
such that 4 ≤ nx ≤ 65536.
x[2*nx]
Pointer to input and output sequences. Size 2*nx elements.
w[nx]
Pointer to vector of FFT coefficients of size nx elements.
This routine is used to compute FFT of a complex sequence of size nx, a power
of 2, with "decimation-in-frequency decomposition" method. The output is in
bit-reversed order. Each complex value is with interleaved 16-bit real and
imaginary parts.
This is the C equivalent of the assembly code without restrictions. Note that
the assembly code is hand optimized and restrictions may apply.
void DSP_radix2 (short x[ ],short nx,short w[ ])
{
short n1,n2,ie,ia,i,j,k,l;
short xt,yt,c,s;
n2 = nx;
ie = 1;
for (k=nx; k > 1; k = (k >> 1) ) {
n1 = n2;
n2 = n2>>1;
ia = 0;
for (j=0; j < n2; j++) {
c = w[2*ia];
s = w[2*ia+1];
ia = ia + ie;
for (i=j; i < nx; i += n1) {
l = i + n2;
DSP_radix2
C64x+ DSPLIB Reference
4-93

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Tms320c64x+

Table of Contents