SummerCart64/sw/n64/N64.ld

51 lines
1.1 KiB
Plaintext
Raw Normal View History

MEMORY {
2022-01-07 15:01:43 +01:00
rdram (rwx) : org = 0x80300000, len = 1M
flash (r) : org = 0xB0000000, len = 90k
}
ENTRY(entry_handler)
2022-01-07 15:01:43 +01:00
__exception_stack_size = 8k;
__stack_size = 64k;
SECTIONS {
.flash : {
KEEP(*(.text.rom_header));
KEEP(*(.text.ipl3));
__ipl3_font = LOADADDR(.flash) + 0xB70;
} > flash
.text : {
*(.text.entry_handler)
*(.text .text.* .gnu.linkonce.t.*)
*(.rodata .rodata.* .gnu.linkonce.r.*)
*(.data .data.* .gnu.linkonce.d.*)
_gp = . + 0x8000;
*(.sdata .sdata.* .gnu.linkonce.s.*)
*(.lit8 .lit4)
2022-01-07 15:01:43 +01:00
. = ALIGN(8);
} > rdram AT > flash
.bss : {
*(.sbss .sbss.* .gnu.linkonce.sb.*)
*(.scommon .scommon.*)
*(.bss .bss.* .gnu.linkonce.b.*)
*(COMMON)
2022-01-07 15:01:43 +01:00
. = ALIGN(8);
} > rdram
_sheap = .;
2022-01-07 15:01:43 +01:00
. = ORIGIN(rdram) + LENGTH(rdram) - __exception_stack_size - __stack_size;
_eheap = .;
2022-01-07 15:01:43 +01:00
. += __exception_stack_size;
_esp = .;
. += __stack_size;
_sp = .;
/DISCARD/ : {
*(.MIPS.*)
}
}