Analog Devices VISUALDSP++ 3.5 Manuel utilisateur

W3.5
Linker and Utilities Manual
for 16-Bit Processors
Revision 1.0, October 2003
Part Number
82-000035-07
Analog Devices, Inc.
One Technology Way
Norwood, Mass. 02062-9106 a

Copyright Information
© 2003 Analog Devices, Inc., ALL RIGHTS RESERVED. This docu-
ment may not be reproduced in any form without prior, express written
consent from Analog Devices, Inc.
Printed in the USA.
Disclaimer
Analog Devices, Inc. reserves the right to change this product without
prior notice. Information furnished by Analog Devices is believed to be
accurate and reliable. However, no responsibility is assumed by Analog
Devices for its use; nor for any infringement of patents or other rights of
third parties which may result from its use. No license is granted by impli-
cation or otherwise under the patent rights of Analog Devices, Inc.
Trademark and Service Mark Notice
The Analog Devices logo, VisualDSP++, the VisualDSP++ logo, Blackfin,
and the Blackfin logo are registered trademarks of Analog Devices, Inc.
All other brand and product names are trademarks or service marks of
their respective owners.

VisualDSP++ 3.5 Linker and Utilities Manual iii
for 16-Bit Processors
CONTENTS
PREFACE
Purpose of This Manual .................................................................. xv
Intended Audience ......................................................................... xvi
Manual Contents ........................................................................... xvi
What’s New in This Manual .......................................................... xvii
Technical or Customer Support .................................................... xviii
Supported Processors ...................................................................... xix
Product Information ....................................................................... xx
MyAnalog.com .......................................................................... xx
DSP Product Information .......................................................... xx
Related Documents .................................................................. xxi
Online Technical Documentation ............................................ xxii
From VisualDSP++ ............................................................. xxii
From Windows ................................................................. xxiii
From the Web ................................................................... xxiii
Printed Manuals ..................................................................... xxiv
VisualDSP++ Documentation Set ....................................... xxiv
Hardware Manuals ............................................................. xxiv
Data Sheets ........................................................................ xxiv

CONTENTS
iv VisualDSP++ 3.5 Linker and Utilities Manual
for 16-Bit Processors
Contacting DSP Publications .................................................. xxv
Notation Conventions .................................................................. xxv
INTRODUCTION
Software Development Flow ......................................................... 1-2
Compiling and Assembling ........................................................... 1-3
Inputs – C/C++ and Assembly Sources .................................... 1-3
Input Section Directives in Assembly Code .............................. 1-4
Input Section Directives in C/C++ Source Files ........................ 1-4
Linking ........................................................................................ 1-6
Linker and Assembler Preprocessor .......................................... 1-7
Loading and Splitting ................................................................... 1-8
LINKER
Linker Operation .......................................................................... 2-2
Directing Linker Operation ..................................................... 2-3
Linking Process Rules .............................................................. 2-4
Linker Description File — Overview ....................................... 2-5
Linking Environment ................................................................... 2-6
Project Builds ......................................................................... 2-6
Expert Linker .......................................................................... 2-9
Linker Warning and Error Messages ...................................... 2-10
Link Target Description .............................................................. 2-11
Representing Memory Architecture ........................................ 2-11
ADSP-BF535 Processor Memory Architecture Overview .... 2-12

VisualDSP++ 3.5 Linker and Utilities Manual v
for 16-Bit Processors
CONTENTS
ADSP-218x DSP Core Architecture Overview ................... 2-15
ADSP-219x DSP Architecture Overview ............................ 2-17
Specifying the Memory Map .................................................. 2-18
Memory Usage .................................................................. 2-18
Memory Characteristics ..................................................... 2-20
Linker MEMORY{} Command in .LDF File ...................... 2-24
Placing Code on the Target .................................................... 2-26
Passing Arguments for Simulation or Emulation: Blackfin Processors ONLY
2-29
Linker Command-Line Reference ................................................ 2-30
Linker Command-Line Syntax ............................................... 2-30
Command-Line Object Files ............................................. 2-31
Command-Line File Names ............................................... 2-32
Object File Types .............................................................. 2-34
Linker Command-Line Switches ............................................ 2-34
Linker Switch Summary .................................................... 2-36
@filename ......................................................................... 2-38
-Dprocessor ...................................................................... 2-38
-L path ............................................................................. 2-39
-M .................................................................................... 2-39
-MM ................................................................................ 2-39
-Map filename .................................................................. 2-39
-MDmacro[=def] .............................................................. 2-39
-Ovcse .............................................................................. 2-40
-S ..................................................................................... 2-40

CONTENTS
vi VisualDSP++ 3.5 Linker and Utilities Manual
for 16-Bit Processors
-T filename ...................................................................... 2-40
-Wwarn [number] ............................................................ 2-40
-e ..................................................................................... 2-41
-es sectionName ............................................................... 2-41
-ev ................................................................................... 2-41
-flags-meminit -opt1[,-opt2... .......................................... 2-41
-flags-pp -opt1[,-opt2...] .................................................. 2-42
-h[elp] .............................................................................. 2-42
-i|I directory ..................................................................... 2-42
-ip .................................................................................... 2-42
-jcs2l ................................................................................ 2-43
-jcs2l+ .............................................................................. 2-44
-keep symbolName ........................................................... 2-44
-meminit .......................................................................... 2-44
-o filename ....................................................................... 2-44
-od directory .................................................................... 2-45
-pp ................................................................................... 2-45
-proc processor ................................................................. 2-45
-s ..................................................................................... 2-46
-save-temps ...................................................................... 2-46
-si-revision version ............................................................ 2-46
-sp ................................................................................... 2-48
-t ..................................................................................... 2-48
-v[erbose] ......................................................................... 2-48

VisualDSP++ 3.5 Linker and Utilities Manual vii
for 16-Bit Processors
CONTENTS
-version ............................................................................ 2-48
-warnonce ......................................................................... 2-48
-xref filename .................................................................... 2-49
LINKER DESCRIPTION FILE
LDF File Overview ....................................................................... 3-3
Example 1 – Basic .LDF File for Blackfin Processors ................. 3-4
Example 2 - Basic .LDF File for ADSP-218/9x DSPs ................ 3-6
Notes on Basic .LDF File Examples .......................................... 3-7
LDF Structure ............................................................................ 3-11
Command Scoping ................................................................ 3-12
LDF Expressions ......................................................................... 3-13
LDF Keywords, Commands, and Operators ................................. 3-14
Miscellaneous LDF Keywords ................................................ 3-15
LDF Operators ........................................................................... 3-16
ABSOLUTE() Operator ........................................................ 3-16
ADDR() Operator ................................................................. 3-17
DEFINED() Operator ........................................................... 3-18
MEMORY_SIZEOF() Operator ............................................ 3-18
SIZEOF() Operator ............................................................... 3-19
Location Counter (.) .............................................................. 3-19
LDF Macros ............................................................................... 3-20
Built-In LDF Macros ............................................................. 3-21
User-Declared Macros ........................................................... 3-22
LDF Macros and Command-Line Interaction ......................... 3-22

CONTENTS
viii VisualDSP++ 3.5 Linker and Utilities Manual
for 16-Bit Processors
LDF Commands ........................................................................ 3-23
ALIGN() .............................................................................. 3-24
ARCHITECTURE() ............................................................. 3-24
ELIMINATE() ...................................................................... 3-25
ELIMINATE_SECTIONS() ................................................. 3-26
INCLUDE() ......................................................................... 3-26
INPUT_SECTION_ALIGN() .............................................. 3-26
KEEP() ................................................................................. 3-27
LINK_AGAINST() ............................................................... 3-28
MAP() .................................................................................. 3-29
MEMORY{} ......................................................................... 3-29
Segment Declarations ....................................................... 3-30
MPMEMORY{} .................................................................... 3-32
OVERLAY_GROUP{} .......................................................... 3-33
PACKING() ......................................................................... 3-33
Packing in ADSP-218x and ADSP-219x DSPs ................. 3-34
Efficient Packing ........................................................... 3-35
Inefficient Packing: Null Bytes ...................................... 3-36
Overlay Packing Formats .............................................. 3-37
Trivial Packing: No Reordering ..................................... 3-37
PAGE_INPUT() ................................................................... 3-37
PAGE_OUTPUT() ............................................................... 3-38
PLIT{} .................................................................................. 3-38
PROCESSOR{} .................................................................... 3-39

VisualDSP++ 3.5 Linker and Utilities Manual ix
for 16-Bit Processors
CONTENTS
RESOLVE() .......................................................................... 3-40
SEARCH_DIR() ................................................................... 3-41
SECTIONS{} ........................................................................ 3-42
INPUT_SECTIONS() ...................................................... 3-45
expression ......................................................................... 3-45
FILL(hex number) ............................................................ 3-46
PLIT{plit_commands} ...................................................... 3-46
OVERLAY_INPUT{overlay_commands} ........................... 3-46
SHARED_MEMORY{} ......................................................... 3-48
EXPERT LINKER
Expert Linker Overview ................................................................ 4-2
Launching the Create LDF Wizard ................................................ 4-4
Step 1: Specifying Project Information ..................................... 4-5
Step 2: Specifying System Information ..................................... 4-6
Step 3: Completing the LDF Wizard ........................................ 4-9
Expert Linker Window Overview ................................................ 4-10
Input Sections Pane ..................................................................... 4-12
Input Sections Menu ............................................................. 4-12
Mapping an Input Section to an Output Section .................... 4-14
Viewing Icons and Colors ...................................................... 4-14
Sorting Objects ..................................................................... 4-17
Memory Map Pane ...................................................................... 4-18
Context Menu ....................................................................... 4-20
Tree View Memory Map Representation ................................. 4-22

CONTENTS
x VisualDSP++ 3.5 Linker and Utilities Manual
for 16-Bit Processors
Graphical View Memory Map Representation ........................ 4-23
Specifying Pre- and Post-Link Memory Map View ................. 4-27
Zooming In and Out on the Memory Map ............................ 4-28
Inserting a Gap into a Memory Segment ................................ 4-31
Working With Overlays ........................................................ 4-33
Viewing Section Contents ..................................................... 4-35
Viewing Symbols .................................................................. 4-39
Profiling Object Sections ....................................................... 4-40
Adding Shared Memory Segments and Linking Object Files ... 4-45
Managing Object Properties ........................................................ 4-50
Managing Global Properties .................................................. 4-51
Managing Processor Properties .............................................. 4-52
Managing PLIT Properties for Overlays ................................. 4-54
Managing Elimination Properties .......................................... 4-55
Managing Symbols Properties ................................................ 4-57
Managing Memory Segment Properties .................................. 4-61
Managing Output Section Properties ..................................... 4-62
Managing Packing Properties ................................................. 4-64
Managing Alignment and Fill Properties ................................ 4-65
Managing Overlay Properties ................................................. 4-67
Managing Stack and Heap in Processor Memory .................... 4-69
MEMORY OVERLAYS AND ADVANCED LDF
COMMANDS
Overview ...................................................................................... 5-2
Autres manuels pour VISUALDSP++ 3.5
2
Table des matières
Autres manuels Analog Devices Logiciel
Manuels Logiciel populaires d'autres marques

PS Audio
PS Audio PowerPlay Manuel du propriétaire

Brady
Brady LOCKOUT PRO 3.0 Manuel de service

Avaya
Avaya Interaction Center Manuel utilisateur

Texas Instruments
Texas Instruments TI-83 Plus Silver Edition Manuel

Novell
Novell GROUPWISE 8 - INTERNET AGENT Manuel utilisateur

Oracle
Oracle Application 9i Manuel utilisateur

Acer
Acer RDM Manuel utilisateur

Canon
Canon Vixia HF21 Manuel utilisateur

Canon
Canon ZR950 Manuel utilisateur

Samsung
Samsung Auto Backup Manuel utilisateur

Polycom
Polycom Vortex EF2201 Instructions d'installation et d'utilisation

Brocade Communications Systems
Brocade Communications Systems Brocade 8/12c Manuel utilisateur







