Digital Signal Processing Reference
In-Depth Information
Fig. 17
A fixed-point
void
iir1(short argc, char * argv[])
{ gFix Xin(12,0);
gFix Yout(16,3);
gFix Ydly(16,3);
gFix Coeff(10,0);
Coeff = 0.9;
Ydly = 0.;
for( i = 0; i < 1000; i++ ) {
infile >> Xin ;
Yout = Coeff * Ydly + Xin ;
Ydly = Yout ;
outfile << Yout << '\n';
C
program for a first
order IIR filter
++
}
}
a part of a system set-up. The performance measurement block must generate a
positive result (or pass) when the quantization effects are acceptable. A hardware
cost library is also needed to estimate the total complexity when implementing the
system with the given word-length vector. Note that not only the algorithm but also
the system architecture affects the hardware cost.
In the simplest case, only one word-length is used for all arithmetic operations,
which is called the uniform word-length optimization. In the uniform word-length
optimization, fixed-point simulation with a shorter (or longer) word-length than the
optimum one should yield a fixed-point performance which is lower (or higher) than
the needed performance. Thus, it is possible to arrive at the optimum word-length by
increasing (or decreasing) the word-length when the obtained performance is lower
(or higher) than the needed fixed-point performance. In the case of linear time-
invariant systems, it is possible to reduce the number of simulations by considering
that the SQNR becomes higher by 6 dB with the word-length increase of one bit.
Usually, there are multiple word-lengths to optimize in implementing a fixed-
point system. As the number of word-lengths to optimize increases, optimization
of them should take a longer time. In other words, minimizing the number of
variables is very important for reducing the optimization time. In this optimization
method, the number of different word-lengths is reduced by signal grouping that
assigns the same word-length to signals, for example, connected with a delay or a
multiplexer block. The word-length sensitivity of a signal needs to be considered
for optimization. Some signals are very sensitive to quantization, thus they need a
long word-length. The minimum bound of the word-length for each signal group
is in inverse relation with the sensitivity, and can be used to reduce the search
space. Finally, the optimization of different word-lengths requires a hardware cost
model. The word-length optimization method in this section consists of four steps:
signal grouping, sign and integer word-length determination, minimum word-length
determination, and cost optimum word-length search.
As an example, Fig. 18 shows the setup for fixed-point optimization of a first
order filter. The SQNR is used as the measure of the fixed-point performance.
 
Search WWH ::




Custom Search