artiq/artiq/firmware/runtime/runtime.ld

98 lines
1.8 KiB
Plaintext
Raw Normal View History

INCLUDE generated/output_format.ld
2016-10-17 00:24:25 +08:00
STARTUP(crt0-or1k.o)
ENTRY(_start)
INCLUDE generated/regions.ld
/* Assume ORIGIN(main_ram) = 0x40000000. Unfortunately,
* ld does not allow this expression here.
*/
MEMORY {
2016-10-07 02:05:38 +08:00
runtime (RWX) : ORIGIN = 0x40000000, LENGTH = 0x400000 /* 4M */
}
SECTIONS
{
2016-10-07 02:05:38 +08:00
.text :
{
_ftext = .;
*(.text .stub .text.* .gnu.linkonce.t.*)
_etext = .;
} > runtime
.eh_frame :
{
__eh_frame_start = .;
KEEP(*(.eh_frame))
__eh_frame_end = .;
} > runtime
.eh_frame_hdr :
{
KEEP(*(.eh_frame_hdr))
} > runtime
__eh_frame_hdr_start = SIZEOF(.eh_frame_hdr) > 0 ? ADDR(.eh_frame_hdr) : 0;
__eh_frame_hdr_end = SIZEOF(.eh_frame_hdr) > 0 ? . : 0;
2016-10-07 02:05:38 +08:00
/* https://sourceware.org/bugzilla/show_bug.cgi?id=20475 */
2017-01-19 07:09:49 +08:00
.got :
{
2016-10-07 02:05:38 +08:00
_GLOBAL_OFFSET_TABLE_ = .;
*(.got)
} > runtime
2017-01-19 07:09:49 +08:00
.got.plt :
{
2016-10-07 02:05:38 +08:00
*(.got.plt)
} > runtime
2016-08-30 19:20:04 +08:00
2016-10-07 02:05:38 +08:00
.rodata :
{
. = ALIGN(4);
_frodata = .;
*(.rodata .rodata.* .gnu.linkonce.r.*)
*(.rodata1)
_erodata = .;
} > runtime
2016-08-30 19:20:04 +08:00
2016-10-07 02:05:38 +08:00
.data :
{
. = ALIGN(4);
_fdata = .;
*(.data .data.* .gnu.linkonce.d.*)
*(.data1)
*(.sdata .sdata.* .gnu.linkonce.s.*)
_edata = .;
} > runtime
2016-10-07 02:05:38 +08:00
.bss :
{
. = ALIGN(4);
_fbss = .;
*(.dynsbss)
*(.sbss .sbss.* .gnu.linkonce.sb.*)
*(.scommon)
*(.dynbss)
*(.bss .bss.* .gnu.linkonce.b.*)
*(COMMON)
. = ALIGN(4);
_ebss = .;
} > runtime
2016-10-07 02:05:38 +08:00
.stack :
{
. = ALIGN(0x1000);
_estack = .;
. += 0x4000;
_fstack = . - 4;
} > runtime
2016-10-07 02:05:38 +08:00
.heap :
{
_fheap = .;
. = ORIGIN(runtime) + LENGTH(runtime);
2016-10-07 02:05:38 +08:00
_eheap = .;
} > runtime
}