1 /******************************************************************
2 *******************************************************************
4 *** Linker script for xstormy16-elf-gcc ***
5 *** For SID RAM=0x7E00 ***
8 *******************************************************************
9 ******************************************************************/
11 OUTPUT_FORMAT("elf32-xstormy16", "elf32-xstormy16", "elf32-xstormy16")
12 OUTPUT_ARCH(xstormy16)
15 GROUP(-lc -lsim -lgcc)
16 PROVIDE( __target_package = 0xff);
18 __malloc_start = 0x7E00;
22 RAM (w) : ORIGIN = 0x00000, LENGTH = 0x07E00
23 CHIP (r) : ORIGIN = 0x07f00, LENGTH = 0x00100
24 ROM (!w) : ORIGIN = 0x08000, LENGTH = 0x78000
29 /* Zero initialized data with the below100 attribute. */
38 /* Non-zero initialized data with the below100 attribute. */
39 .data_below100 : AT ( __rdata ) {
47 /* Normal non-zero initialized data. */
48 .data : AT ( __rdata + SIZEOF(.data_below100) ) {
57 /* Normal zero initialized data. */
58 .bss : AT (LOADADDR(.data) + SIZEOF(.data)) {
68 /* The top of stack. */
71 /* Target chip info. */
76 /* Reset and interrupt vectors at 8000. */
88 /* C++ Construcrtors and destructors. */
90 KEEP (*crtbegin.o(.ctors))
91 KEEP (*(EXCLUDE_FILE (*crtend.o ) .ctors))
92 KEEP (*(SORT(.ctors.*)))
97 KEEP (*crtbegin.o(.dtors))
98 KEEP (*(EXCLUDE_FILE (*crtend.o ) .dtors))
99 KEEP (*(SORT(.dtors.*)))
103 /* Pointer lookup table.. */
108 /* Other information. */
117 .gcc_except_table : {
118 KEEP (*(.gcc_except_table))
121 /* Initialization values for data. */
122 .data_init (NOLOAD) : {
124 . += SIZEOF(.data_below100);
129 /* Executable code. */
138 /* Startup/finish code. */
140 KEEP (*crti.o(.init))
141 KEEP (*(EXCLUDE_FILE (*crtn.o ) .init))
142 KEEP (*(SORT(.init.*)))
147 KEEP (*crti.o(.fini))
148 KEEP (*(EXCLUDE_FILE (*crtn.o ) .fini))
149 KEEP (*(SORT(.fini.*)))
153 /* Stab debugging sections. */
154 .stab 0 : { *(.stab) }
155 .stabstr 0 : { *(.stabstr) }
156 .stab.excl 0 : { *(.stab.excl) }
157 .stab.exclstr 0 : { *(.stab.exclstr) }
158 .stab.index 0 : { *(.stab.index) }
159 .stab.indexstr 0 : { *(.stab.indexstr) }
160 .comment 0 : { *(.comment) }
162 /* DWARF debug sections. */
163 /* Symbols in the DWARF debugging sections are relative to
164 the beginning of the section so we begin them at 0. */
167 .debug 0 : { *(.debug) }
168 .line 0 : { *(.line) }
170 /* GNU DWARF 1 extensions. */
171 .debug_srcinfo 0 : { *(.debug_srcinfo) }
172 .debug_sfnames 0 : { *(.debug_sfnames) }
174 /* DWARF 1.1 and DWARF 2. */
175 .debug_aranges 0 : { *(.debug_aranges) }
176 .debug_pubnames 0 : { *(.debug_pubnames) }
179 .debug_info 0 : { *(.debug_info) *(.gnu.linkonce.wi.*) }
180 .debug_abbrev 0 : { *(.debug_abbrev) }
181 .debug_line 0 : { *(.debug_line) }
182 .debug_frame 0 : { *(.debug_frame) }
183 .debug_str 0 : { *(.debug_str) }
184 .debug_loc 0 : { *(.debug_loc) }
185 .debug_macinfo 0 : { *(.debug_macinfo) }
187 /* SGI/MIPS DWARF 2 extensions. */
188 .debug_weaknames 0 : { *(.debug_weaknames) }
189 .debug_funcnames 0 : { *(.debug_funcnames) }
190 .debug_typenames 0 : { *(.debug_typenames) }
191 .debug_varnames 0 : { *(.debug_varnames) }