
REV. B
–4–
ADDS-210xx-TOOLS
For code portability and development platform flexibility, the
G21K C Compiler conforms to ANSI Standard X 3J11. Its
optimizing features include the following:
Constant folding
Common subexpression elimination
Loop unrolling and strength reduction
Global and local register allocation
Flow Analysis
Pattern combining
Instruction scheduling
Global and local register allocation
Parallelization
NUME RICAL C
Numerical C—extensions to the G21K ANSI C compiler—
requires fewer lines of code to perform vector and matrix
operations. Developed with the ANSI Numerical C Extensions
Group (NCEG), a working committee reporting to ANSI
X 3J11, Numerical C lets the compiler perform more powerful
optimizations. T hese Numerical C extensions have been
adapted by the Free Software Foundation for GNU C compilers
(version 2.4).
Numerical C supports iterators used for generating one or more
loops out of a single statement. T his Numerical C code frag-
ment for DSP application:
iter i = N;
A [i] = sin (2
×
PI
×
i/N);
is equivalent to this C Code:
int i,_ilimit_I = N;
for (i=0; i<_ilimit_I; i++)
{
A[i] = sin(2*PI*i/N);
}
A FIR filter with k taps on the array of n numbers notated as
follows:
y
i
=
x
i
±
j
a
j
j
=
0
∑
is coded as this equation:
iter I = n, j = k;
y[i] = sum (x [i-j] * a [j]);
CBUG C Source-Level Debugger
CBUG, a full-featured C source-level debugger, is fully
integrated with the ADSP-21000 Family Simulator and EZ-ICE
Emulator. It performs the following functions:
Displays Variables and Expressions (Automatically Updated)
Evaluates Standard ANSI C Expressions
Stepping and Various other Program Execution Commands
Breakpoints and Conditional Breaks Based on Expression
Evaluation
Displays Symbol Definition and Values
Displays Function Calling T ree
Uses Same Friendly User Interface as the EZ-ICE Simulator
C Runtime Library
T he C Compiler has a set of ANSI-standard functions that ease
program development. T hese library routines include ANSI-
standard functions commonly used in digital signal processing.
T he table below contains all the C Runtime Library functions
and macros that perform digital signal processing operations.
T he ADSP-21000 Family Runtime Library includes the
following ANSI-standard function categories:
Standard Library
Mathematics
Signal, Variable and Character Handling
T he library also includes signal processing functions in the
following categories developed by Analog Devices:
DSP Filters
Fast Fourier T ransforms
Matrix Operations
Interrupt Servicing
PROM Splitter
T he PROM splitter translates an ADSP-21000 Family executable
program into one of several formats for different PROM con-
figurations or to be downloaded to the target system. T he
PROM Splitter’s output file is generated as a Motorola S
Record, Intel Hex Record format, or a stacked format used by
the emulators.