FPGA Central - World's 1st FPGA / CPLD Portal

FPGA Central

World's 1st FPGA Portal

 

Go Back   FPGA Groups > NewsGroup > FPGA

FPGA comp.arch.fpga newsgroup (usenet)

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 11-07-2007, 02:51 PM
Pasacco
Guest
 
Posts: n/a
Default [Linker script : EDK6.3 -> EDK 8.2] Parse error

Dear

I used to EDK 6.3 for multiprocessor system implementation.
The system worked fine.
But, when I upgraded to EDK 8.2, "parse error" occurs in the following
linker script.

------------------------------------------------------------------------
..init : { KEEP(*(.init)) } >
..fini : { KEEP(*(.fini)) } >
------------------------------------------------------------------------

Does anyone have this experience? If yes, let me know how to fix this
problem.

Thank you in advance.

Entire linker script is below.
----------------------------------------------------------------------------------------------------------------------
/* Linker Script automatically rev'ed up using XPS 8.2 */
/* Define default stack and heap sizes */
_START_ADDR = 0xFFFF8000; /*DEFINED(_START_ADDR) ? _START_ADDR :
0xFFFF0000;*/
_STACK_SIZE = 60k; /*DEFINED(_STACK_SIZE) ? _STACK_SIZE : 4k;*/
_HEAP_SIZE = 60k; /*DEFINED(_HEAP_SIZE) ? _HEAP_SIZE : 4k;*/

/* Define boot.o to be the first file for linking. This statement is
mandatory. */
STARTUP(boot.o)

/* Specify the default entry point to the program */
ENTRY(_boot)

/* Define the Memory layout, specifying the start address and size of
the different memory locations */
MEMORY
{
dRAM : ORIGIN = 0x040E0000, LENGTH = 0x20000 /*(128K)*/
pRAM : ORIGIN = 0xFFFF8000, LENGTH = 0x8000-4 /*32K-4*/
boot : ORIGIN = 0xFFFFFFFC, LENGTH = 4
}

/* Define the sections and where they are mapped in memory */

SECTIONS
{
. = _START_ADDR;

/* .vectors section must be aligned on a 64k boundary
* Hence should be the first section definition as bram start
location
* is 64k aligned */
.vectors : /*BLOCK (64k):*/
{
*(.vectors)
} > pRAM


.boot0 : { *(.boot0)} > pRAM
.text : { *(.text)
*(.text.*)
*(.gnu.linkonce.t.*)
} > pRAM

/**********************************************/
/* Parse error */
/**********************************************/
..init : { KEEP(*(.init)) } >

..fini : { KEEP(*(.fini)) } >

.boot : { *(.boot) } > boot
.data :
{
*(.data)
*(.data.*)
*(.gnu.linkonce.d.*)
CONSTRUCTORS
*(.got2)
*(.rodata)
*(.fixup)
*(.rodata.*)
*(.gnu.linkonce.r.*)
} > pRAM


..dtors : {
__DTOR_LIST__ = .;
___DTORS_LIST___ = .;
KEEP (*crtbegin.o(.dtors))
KEEP (*(EXCLUDE_FILE(*crtend.o) .dtors))
KEEP (*(SORT(.dtors.*)))
KEEP (*(.dtors))
__DTOR_END__ = .;
___DTORS_END___ = .;
} > pRAM

..eh_frame : { *(.eh_frame) } > pRAM

..jcr : { *(.jcr) } > pRAM

..gcc_except_table : { *(.gcc_except_table) } > pRAM

..got : { *(.got) } > pRAM

..tdata : {
*(.tdata)
*(.gnu.linkonce.td.*)
} > pRAM

..tbss : {
*(.tbss)
*(.gnu.linkonce.tb.*)
} > pRAM

/* .data1 : { *(.data1) } > ram
.got1 : { *(.got1) } > ram

.got2 : { *(.got2) } > ram

.got1 : { *(.got1) } > ram

.dynamic : { *(.dynamic) } > ram
*/

.ctors :
{
/* __CTOR_LIST__ = .;
LONG((__CTOR_END__ - __CTOR_LIST__) / 4 - 2)
*(.ctors)
LONG(0)
__CTOR_END__ = .;*/

KEEP (*crtbegin.o(.ctors))
KEEP (*(EXCLUDE_FILE (*crtend.o) .ctors))
KEEP (*(SORT(.ctors.*)))
KEEP (*(.ctors))
} > pRAM
__CTOR_LIST__ = ADDR(.ctors);
__CTOR_END__ = ADDR(.ctors) + SIZEOF(.ctors);


/* small data area (read/write): keep together! */
.sdata : { *(.sdata)
*(.gnu.linkonce.s.*) } > pRAM

.sbss :
{
. = ALIGN(4);
*(.sbss)
*(.gnu.linkonce.sb.*)
. = ALIGN(4);
} > pRAM

__sbss_start = ADDR(.sbss);
__sbss_end = ADDR(.sbss) + SIZEOF(.sbss);

/* small data area 2 (read only) */
.sdata2 : { *(.sdata2)
*(.gnu.linkonce.s2.*) } > pRAM

__SDATA2_START__ = ADDR(.sdata2);
__SDATA2_END__ = ADDR(.sdata2) + SIZEOF(.sdata2);

.sbss2 : { *(.sbss2)
*(.gnu.linkonce.sb2.*)
} > pRAM

__SBSS2_START__ = ADDR(.sbss2);
__SBSS2_END__ = ADDR(.sbss2) + SIZEOF(.sbss2);

.bss :
{
. = ALIGN(4);
*(.bss)
*(.gnu.linkonce.b.*)
*(COMMON)
. = ALIGN(4);
__bss_end = .;

/* add stack and align to 16 byte boundary */
_stack_end = .;
. = . + _STACK_SIZE;
. = ALIGN(16);
__stack = .;

/* add heap and align to 16 byte boundary */
_heap_start = .;
. = . + _HEAP_SIZE;
. = ALIGN (16);
_heap_end = .;
} > dRAM

__bss_start = ADDR(.bss);

}

ODY></HTML>

Reply With Quote
  #2 (permalink)  
Old 11-08-2007, 11:59 PM
Minh Nguyen
Guest
 
Posts: n/a
Default Re: [Linker script : EDK6.3 -> EDK 8.2] Parse error

On Wed 07 Nov 2007 15:51 Pasacco wrote:

> Dear
>
> I used to EDK 6.3 for multiprocessor system implementation.
> The system worked fine.
> But, when I upgraded to EDK 8.2, "parse error" occurs in the following
> linker script.
>
> ------------------------------------------------------------------------
> .init : { KEEP(*(.init)) } >
> .fini : { KEEP(*(.fini)) } >

^
Here is the full syntax of a section definition:
SECTION [ADDRESS] [(TYPE)] :
[AT(LMA)] [ALIGN(SECTION_ALIGN)] [SUBALIGN(SUBSECTION_ALIGN)]
{
OUTPUT-SECTION-COMMAND
OUTPUT-SECTION-COMMAND
...
} [>REGION] [AT>LMA_REGION] [:PHDR :PHDR ...] [=FILLEXP]

You need to specify a region or just delete the '>'s.
HTH

> ------------------------------------------------------------------------
>
> Does anyone have this experience? If yes, let me know how to fix this
> problem.
>
> Thank you in advance.
>
> Entire linker script is below.


[snip]
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
linker script!!! [email protected] FPGA 2 06-13-2005 11:46 PM
linker script [email protected] FPGA 1 06-08-2005 11:02 PM
linker script Tom FPGA 1 11-13-2003 05:26 PM


All times are GMT +1. The time now is 09:46 AM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Copyright 2008 @ FPGA Central. All rights reserved