diff options
Diffstat (limited to 'libgloss/msp430/msp430-sim.ld')
-rw-r--r-- | libgloss/msp430/msp430-sim.ld | 33 |
1 files changed, 25 insertions, 8 deletions
diff --git a/libgloss/msp430/msp430-sim.ld b/libgloss/msp430/msp430-sim.ld index b01a35078..56bc8f80d 100644 --- a/libgloss/msp430/msp430-sim.ld +++ b/libgloss/msp430/msp430-sim.ld @@ -18,7 +18,10 @@ ENTRY(_start) /* Do we need any of these for elf? __DYNAMIC = 0; */ -MEMORY { +INCLUDE intr_vectors.ld + +MEMORY +{ RAM (w) : ORIGIN = 0x00200, LENGTH = 0x0ee00 RESETVEC (w) : ORIGIN = 0x0fffe, LENGTH = 0x00002 } @@ -77,7 +80,12 @@ SECTIONS { . = ALIGN(2); PROVIDE (_start = .); - *(.lowtext .text .stub .text.* .gnu.linkonce.t.* .text:*) + KEEP (*(.crt_init)) + KEEP (*(.crt_bss)) + KEEP (*(.crt_movedata)) + KEEP (*(.crt_main)) + KEEP (*(.lowtext)) + *(.text .stub .text.* .gnu.linkonce.t.* .text:*) KEEP (*(.text.*personality*)) /* .gnu.warning sections are handled specially by elf32.em. */ *(.gnu.warning) @@ -88,6 +96,7 @@ SECTIONS . = ALIGN(2); KEEP (*(.init)) KEEP (*(.fini)) + KEEP (*(.tm_clone_table)) } > RAM .data : { @@ -127,15 +136,23 @@ SECTIONS *(.dynbss) *(.sbss .sbss.*) *(.bss .bss.* .gnu.linkonce.b.*) - . = ALIGN(2); - *(COMMON) - . = ALIGN(2); PROVIDE (__bssend = .); - _end = .; - PROVIDE (end = .); } > RAM PROVIDE (__bsssize = SIZEOF(.bss)); + /* This section contains data that is not initialised at startup. */ + .noinit : { + . = ALIGN(2); + PROVIDE (__noinit_start = .); + *(.noinit) + . = ALIGN(2); + *(COMMON) + PROVIDE (__noinit_end = .); + } > RAM + + _end = .; + PROVIDE (end = .); + .stack (ORIGIN (RAM) + LENGTH(RAM)) : { PROVIDE (__stack = .); @@ -174,7 +191,7 @@ SECTIONS /* DWARF 2 */ .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) } .debug_abbrev 0 : { *(.debug_abbrev) } - .debug_line 0 : { *(.debug_line) } + .debug_line 0 : { *(.debug_line .debug_line.* .debug_line_end ) } .debug_frame 0 : { *(.debug_frame) } .debug_str 0 : { *(.debug_str) } .debug_loc 0 : { *(.debug_loc) } |