Technical discussions related to Analog Devices DSPs (including Blackfin, TigerSHARC, SHARC and ADSP-21xx DSPs).
HI
I am using ADSP-21065L and encounter with the following error
/////////////// ERROR DURING COMPILATION /////////////////
24467 bytes eliminated in processor 'p0'
For more details, see 'linker_log.xml' in the output directory.
[Error li1040] ".\INS30.LDF":149 Out of memory in output section 'seg_imu' in
processor 'p0'
Total of 0x2a5 word(s) were not mapped.
For more details, see 'linker_log.xml' in the output directory.
Linker finished with 1 error
cc3089: fatal error: Link failed
Tool failed with exit/exception code: 1.
Build was unsuccessful.
/////////////////////////////////////////////
Whereas i have the following setting in my LDF file
//////////////// SETTING IN LDF FILE ////////////////////////////
// the first 512 words are reserved for BIOS code
// the remaining ext. SRAM can be used for data and program code.
// to link data to ext. memory, use the segment directive, e.g.
// static segment ("ext_dmda") int ext_var[..];
// to link a function to ext. memory, use the segment directive, e.g.
// segment ("ext_pmco") int ext_func (int..)
// { ... }
// please note that an external code section cannot exceed 64K
// you may however specify multiple external code sections
// ( this is important only for larger SRAM: 256K x 32 )
//
// each external program word requires two 32 bit memory locations
// the following definitions allocate
// 15872 words external program code
// 16384 words external data
// 16384 words heap
ext_bios { TYPE(PM RAM) START(0x00020000) END(0x000201FF) WIDTH(32) }
ext_pmco { TYPE(PM RAM) START(0x00020200) END(0x00023FFF) WIDTH(32) }
ext_dmda { TYPE(DM RAM) START(0x00028000) END(0x0002BFFF) WIDTH(32) }
seg_imu
{
INPUT_SECTIONS( $LIBRARIES(seg_pmco))
} >imu
////////////////////////////////////////////////////////////////
if any body knows that kindly help me
Rain
------------------------------------
Hello Rain (I suppose that is your name, out of your signature)
The messages say that your section IMU was not allocated enough memory for the amount of
memory.
It seems to me that the snippet of the LDF that you attached does not have enough information
for one to advice what to do next, since you are not showing how big are seg_imu and seg_pmco.
But in any case, you will have to modify the LDF to allocate more memory for those segments,
which you can do either on the source code of the LDF itself or using the ExpertLinker.
You needed 677 words for this kind of memory (0x2A5), which you did not seem to have.
Regards
Jaime Andrés Aranguren Cardona
j...@ieee.org
j...@computer.org
----- Original Message ----
From: "m...@yahoo.com" <m...@yahoo.com>
To: a...@yahoogroups.com
Sent: Tuesday, May 20, 2008 1:08:29 AM
Subject: [adsp] Out of memory in output section 'seg_imu' in processor 'p0'
HI
I am using ADSP-21065L and encounter with the following error
//////////// /// ERROR DURING COMPILATION //////////// /////
24467 bytes eliminated in processor 'p0'
For more details, see 'linker_log. xml' in the output directory.
[Error li1040] ".\INS30.LDF" :149 Out of memory in output section 'seg_imu' in
processor 'p0'
Total of 0x2a5 word(s) were not mapped.
For more details, see 'linker_log. xml' in the output directory.
Linker finished with 1 error
cc3089: fatal error: Link failed
Tool failed with exit/exception code: 1.
Build was unsuccessful.
//////////// ///////// ///////// ///////// //////
Whereas i have the following setting in my LDF file
//////////// //// SETTING IN LDF FILE //////////// ///////// ///////
// the first 512 words are reserved for BIOS code
// the remaining ext. SRAM can be used for data and program code.
// to link data to ext. memory, use the segment directive, e.g.
// static segment ("ext_dmda") int ext_var[..];
// to link a function to ext. memory, use the segment directive, e.g.
// segment ("ext_pmco") int ext_func (int..)
// { ... }
// please note that an external code section cannot exceed 64K
// you may however specify multiple external code sections
// ( this is important only for larger SRAM: 256K x 32 )
//
// each external program word requires two 32 bit memory locations
// the following definitions allocate
// 15872 words external program code
// 16384 words external data
// 16384 words heap
ext_bios { TYPE(PM RAM) START(0x00020000) END(0x000201FF) WIDTH(32) }
ext_pmco { TYPE(PM RAM) START(0x00020200) END(0x00023FFF) WIDTH(32) }
ext_dmda { TYPE(DM RAM) START(0x00028000) END(0x0002BFFF) WIDTH(32) }
seg_imu
{
INPUT_SECTIONS( $LIBRARIES(seg_ pmco))
} >imu
//////////// ///////// ///////// ///////// ///////// ///////// ///////
if any body knows that kindly help me
Rain
First of all I would like to say thank to you that yo= u show interest in that problem. Basically DSP code was developed by another person who is not access= ible now. And now my task is to add some more functionality in previous dev= eloped code. So I developed some code (which is working fine) and when I ad= d my new code in previous developed cod&n= bsp; so I face the following problems. I paste the whole LDF file here. ARCHITECTURE(ADSP-21065L) // // ADSP-21065L Memory Map: // ------------= ------------------------------------ // Internal mem= ory 0x0000 0000 to 0x0007 ff= ff // ------------= ------------------------------------ // &n= bsp;  = ; 0x0000 0000 to 0x0000 00ff= IOP Regs // &n= bsp;  = ; 0x0000 0100 to 0x0000 01ff= IOP Regs of Processor ID 001 //  = ; 0x0000 0200 to 0x00= 00 02ff IOP Regs of Processo= r ID 002 // &n= bsp;  = ; 0x0000 0300 to 0x0000 07ff= Reserved // &n= bsp; Block 0 Normal Word (32/48) Addresses // &n= bsp;  = ; (0x0000 8000 to 0x0000 97ff) 48-bit words // &n= bsp;  = ; (0x0000 8000 to 0x0000 9fff) 32-bit words // &nb= sp; = &nb= sp; = &nb= sp; = 0x0000 A000 to 0x0000 Bfff Reserved // &n= bsp; Block 1 Normal Word (32/48) Addresses // &n= bsp;  = ; (0x0000 C000 to 0x0000 Cfff) 48-bit words // &n= bsp;  = ; (0x0000 C000 to 0x0000 Dfff) 32-bit words // &nb= sp; = &nb= sp; = &nb= sp; = 0x0000 E000 to 0x0000 ffff Reserved // &n= bsp; Block 0 Short Word (16) Addresses // &nb= sp; = &nb= sp; = &nb= sp; = 0x0001 4000 to 0x0001 7fff Reserved // <= /SPAN> Block 1 0x0001 8000 to 0x0= 001 Bfff Short Word (16) Add= resses // &nb= sp; = &nb= sp; = &nb= sp; = 0x0001 C000 to 0x0001 ffff Reserved // ------------= ------------------------------------ // External mem= ory 0x0002 0000 to 0x03ff ff= ff // ------------= ------------------------------------ // External Ban= k 0 0x0002 0000 to 0x00ff ff= ff // External Ban= k 1 0x0100 0000 to 0x01ff ff= ff // External Ban= k 2 0x0200 0000 to 0x02ff ff= ff // External Ban= k 3 0x0300 0000 to 0x03ff ff= ff // // This architecture file allocates: // Internal = 256 words of run-time header in memory block 0 // &n= bsp;  = ; 16 words of initialization code in memory block 0 // &n= bsp; 3.8= K words of C code space in memory block 0 // &n= bsp;  = ; 2K words of C PM data space in memory block 0 // &n= bsp;  = ; 4K words of C DM data space in memory block 1 // &n= bsp; 1.25K wor= ds of C heap space in memory block 1 // &n= bsp; 2.75K wor= ds of C stack space in memory block 1 SEARCH_DIR( $ADI_DSP\21k\lib ) #ifdef _ADI_THREADS #ifdef __ADI_LIBEH__ $LIBRARIES =3D libehmt.dlb, libcmt.dlb, libdsp.dlb, libiomt.dlb; #else $LIBRARIES =3D libcmt.dlb, libdsp.dlb, libiomt.dlb; #endif #else #ifdef __ADI_LIBEH__ $LIBRARIES =3D libeh.dlb, libc.dlb, libdsp.dlb, libio.dlb; #else $LIBRARIES =3D libc.dlb, libdsp.dlb, libio.dlb; #endif #endif // Libraries from the command line are included in COMMAND_LINE_OBJE= CTS. #ifndef EZKIT_MONITOR #ifdef __ADI_LIBEH__ #define CRT_HDR 065L_hdr_adamagic.doj #else #define CRT_HDR 065L_hdr.doj #endif #else #define CRT_HDR 065L_hdr_ezkit.doj #endif $OBJECTS =3D CRT_HDR, $COMMAND_LINE_OBJECTS; MEMORY { seg_rth<= SPAN style=3D"mso-spacerun: yes"> { TYPE(PM RAM) START(0x00008= 000) END(0x000080ff) WIDTH(48) } int_bios= { TYPE(PM RAM) START(0x00008100) END(0x000081af) WIDTH(48) }= seg_init= { TYPE(PM RAM) START(0x000081b0) END(0x000081bf) WIDTH(48) }=  = ; seg_in= t_code { TYPE(PM RAM) START(0x000081c0) END(0x00008297) WIDTH(48) }<= /FONT> bdf { TYPE(P= M RAM) START(0x000082c0) END(0x000097ff) WIDTH(48) }  =
; imu  = ; filter= { TYPE(PM RAM) START(= 0x0000d4e6) END(0x0000d537) WIDTH(32) } // &nb= sp; seg_dmda { TYPE(DM RAM) START(0x00= 00d538) END(0x0000Ddff) WIDTH(32) }  = ; seg_dm= da { TYPE(DM RAM) START(0x0000d538) END(0x0000Dd4f) WIDTH(32) } // &nb= sp; seg_stak { TYPE(DM RAM) START(0x00= 00De00) END(0x0000Dffd) WIDTH(32) }  = ; seg_st= ak { TYPE(DM RAM) START(0x0000Dd50) END(0x0000Dffd) WIDTH(32) }  = ; seg_he= ap { TYPE(DM RAM) START(0x0000Dffe) END(0x0000Dfff) WIDTH(32) } // *****************************************************************= ********* // EXTERNAL SRAM (64K x 32 bits) // *****************************************************************= ********* //= the first 512 words are reserved for BIOS code //= the remaining ext. SRAM can be used for data and program code. //= to link data to ext. memory, use the segment directive, e.g.= //= static segment ("ext_= dmda") int ext_var[..]; //= to link a function to ext. memory, use the segment directive, e.g.<= /FONT> //= segment ("ext_pmco") = int ext_func (int..) //= { ... } //= please note that an e= xternal code section cannot exceed 64K //= you may however speci= fy multiple external code sections //= ( this is important o= nly for larger SRAM: 256K x 32 ) //= //= each external program= word requires two 32 bit memory locations //= the following definitions allocate //= 15872 words external progra= m code //= 16384 words external data= FONT> //= 16384 words heap ex= t_bios { TYPE(PM RAM) START(= 0x00020000) END(0x000201FF) WIDTH(32) } ex= t_pmco { TYPE(PM RAM) START(= 0x00020200) END(0x00023FFF) WIDTH(32) } ex= t_dmda { TYPE(DM RAM) START(= 0x00028000) END(0x0002BFFF) WIDTH(32) } // seg_heap { T= YPE(DM RAM) START(0x0002C000= ) END(0x0002FFFF) WIDTH(32) } } PROCESSOR p0 { // KEEP( = _main,___ctor_NULL_marker,___lib_end_of_heap_descriptions ) LI= NK_AGAINST( $COMMAND_LINE_LINK_AGAINST) OU= TPUT( $COMMAND_LINE_OUTPUT_FILE ) SE= CTIONS {<= /FONT>  = ; &n= bsp;  = ; // .text output section  = ; &n= bsp;  = ; seg_rth  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; INPUT_SECTIONS( $OBJECTS(seg_rth) $LIBR= ARIES(seg_rth))  = ; &n= bsp;  = ; } >seg_rth  = ; &n= bsp;  = ; seg_init  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; INPUT_SECTIONS( $OBJECTS(seg_init) $LIB= RARIES(seg_init))  = ; &n= bsp;  = ; } >seg_init  = ; &n= bsp;  = ; seg_int_code  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; INPUT_SECTIONS( $OBJECTS(seg_int_code) = $LIBRARIES(seg_int_code))  = ; &n= bsp;  = ; } >seg_int_code  = ; &n= bsp;  = ; seg_bdf  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; INPUT_SECTIONS( bdf.doj(seg_pmco))  = ; &n= bsp;  = ; } >bdf  = ; seg_imu  = ; {  = ; &n= bsp;  = ; INPUT_= SECTIONS( $LIBRARIES(seg_pmco))  = ; } >imu  = ; &n= bsp;  = ; seg_dmda  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; INPUT_SECTIONS( $OBJECTS(seg_dmda) $LIB= RARIES(seg_dmda))  = ; &n= bsp;  = ; } > seg_dmda  = ; seg_filter  = ; {  = ; &n= bsp;  = ; INPUT_= SECTIONS( $OBJECTS(filter) $LIBRARIES(filter))  = ; } >filter<= /P> &nbs= p; ext_code &nbs= p; { &nbs= p; INPUT_SECTIONS( $OBJECTS(ext_pmco) $LIBRARIES(e= xt_pmco)) &nbs= p; } > ext_pmco &nbs= p; ext_data &nbs= p; { &nbs= p; INPUT_SECTIONS( $OBJECTS(ext_dmda) $LIBRARIES(e= xt_dmda)) &nbs= p; } > ext_dmda  = ; &n= bsp;  = ; stackseg  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; // allocate a stack for the application=  = ; &n= bsp;  = ; &n= bsp; ldf_stack_space =3D .;  = ; &n= bsp;  = ; &n= bsp; ldf_stack_length =3D MEMORY_SIZEOF(seg_= stak);  = ; &n= bsp;  = ; } > seg_stak  = ; &n= bsp;  = ; heap  = ; &n= bsp;  = ; {  = ; &n= bsp;  = ; &n= bsp; // allocate a heap for the application<= /FONT>  = ; &n= bsp;  = ; &n= bsp; ldf_heap_space =3D .;  = ; &n= bsp;  = ; &n= bsp; ldf_heap_length =3D MEMORY_SIZEOF(seg_h= eap);  = ; &n= bsp;  = ; &n= bsp; ldf_heap_end =3D ldf_heap_space + ldf_h= eap_length - 1; &n= bsp;  = ; &n= bsp;  = ; } > seg_heap  = ; &n= bsp;  = ; }<= /FONT> } If you have any helpful tutorial or material or link about LDF file = setting so kindly tell me. Warm regards Rain --- On Tue, 5/20/08, Jaime Andres Arangure= n Cardona <j...@computer.org> wrote: From: Jaime Andres Aranguren Cardona <jaime.arangu= r...@computer.org> |