DSP Implementation Lecture 3 - PowerPoint PPT Presentation

About This Presentation
Title:

DSP Implementation Lecture 3

Description:

This section must be in Program Memory, holds code, and is required by some ... all the program instructions that it generates when you compile your program. ... – PowerPoint PPT presentation

Number of Views:23
Avg rating:3.0/5.0
Slides: 11
Provided by: drj8
Learn more at: https://my.ece.utah.edu
Category:

less

Transcript and Presenter's Notes

Title: DSP Implementation Lecture 3


1
DSP Implementation Lecture 3
2
Anatomy of a DSP Project In VDSP
  • Linker Description File (.LDF)
  • Source Files (.asm,.c,.h,.cpp,.dat)
  • Object Files (.doj)
  • Library Files (.dlb)
  • Project File (.dpj)

3
Linker Description File
  • Provides link between hardware memory map and
    C/C Model
  • Basic Sections Required by C model.

4
Section seg_pmco
This section must be in Program Memory, holds
code, and is required by some functions in the
C/C run-time library. The Program Memory code
section, seg_pmco, is where the compiler puts all
the program instructions that it generates when
you compile your program. When linking, use your
linker description file to map this section to
Program Memory space.
5
Section seg_dmda
The Data Memory data section, seg_dmda, is where
the compiler puts global and static data in Data
Memory. When linking, use your linker description
file to map this section to Data Memory
space. By default, the compiler stores static
variables in the Data Memory data section. The
compilers dm and pm keywords (memory type
qualifiers) let you override this default. If a
memory type qualifier is not specified, the
compiler places static and global variables in
Data Memory. The following example allocates an
array of 10 integers in the Data Memory data
section static int data 10
6
Section seg_pmda
The Program Memory data section, seg_pmda, is
where the compiler puts global and static data in
Program Memory. When linking, use your linker
description file to map this section to Program
Memory space. By default, the compiler stores
static variables in the Data Memory data section.
The compiler's pm keyword (memory type qualifier)
lets you override this default and place
variables in the Program Memory data section. If
a memory type qualifier is not specified, the
compiler places static and global variables in
Data Memory. The following example allocates an
array of 10 integers in the Program Memory data
section static int pm coeffs10
7
Section seg_stak
The run-time stack section, seg_stak, is where
the compiler puts the run-time stack in Data
Memory. When linking, use your linker description
file to map this section to Data Memory
space. Because the run-time environment cannot
function without this section, you must define
it, and the section must be in Data Memory space.
A typical size for the run-time stack is 4K
32-bit words of Data Memory. The run-time stack
is a 32-bit wide structure, growing from high
memory to low memory. The compiler uses the
run-time stack as the storage area for local
variables and return addresses. During a function
call, the calling function pushes the return
address onto the stack.
8
Section seg_heap
The run-time heap section, seg_heap, is where the
compiler puts the run-time heap in Data Memory.
When linking, use your Linker Description File
(.ldf) to map the seg_heap section to Data Memory
space. A typical size for the run-time heap is
60K 32-bit words of Data Memory. To dynamically
allocate and deallocate memory at run-time, the C
or C run-time library includes five functions
malloc, calloc, realloc and free. These functions
allocate memory from the seg_heap section of
memory by default.
9
Section seg_init
The initialization section, seg_init, is where
the compiler puts the initialization data in
Program Memory. When linking, use your linker
description file to map this section to Program
Memory space.
10
Section seg_rth
The run-time header section, seg_rth, is where
the compiler puts the system initialization code
and interrupt table in Program Memory. When
linking, use your linker description file to map
this section to the interrupt vector table area
of Program Memory space. 161_hdr.doj or
161_cpp_hdr.doj
Write a Comment
User Comments (0)
About PowerShow.com