flowrs-engine/tools/qemu-mips-wasm/fixtures/baremetal/link.ld
flowRS 49c9d04fbc flowRS engine, cut from flowRS bd343e051a2e
Built alone from an empty CARGO_HOME, its tests passed, and flowrsc checked, ran and exported a
document from the conformance corpus; the export built alone.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-05 13:37:09 -05:00

23 lines
1,012 B
Text

/*
* A whole-chip image for the PIC32MX3xx-7xx (512 KB flash, 32 KB RAM or more): reset code in
* boot flash at the reset vector, the configuration words at 0xBFC02FF0 (DS61143H Section 26),
* the exception base at the start of program flash.
*/
MEMORY {
boot (rx) : ORIGIN = 0xBFC00000, LENGTH = 0x2FF0
config : ORIGIN = 0xBFC02FF0, LENGTH = 0x10
flash (rx) : ORIGIN = 0x9D000000, LENGTH = 0x80000
ram (rwx) : ORIGIN = 0x80000000, LENGTH = 0x8000
}
ENTRY(_reset)
SECTIONS {
.reset : { KEEP(*(.reset)) } > boot
.config : { KEEP(*(.config)) } > config
.vectors : { KEEP(*(.vectors)) } > flash
.text : { *(.text*) *(.rodata*) } > flash
.data : { _data = .; *(.data*) *(.sdata*) . = ALIGN(4); _edata = .; } > ram AT> flash
_data_load = LOADADDR(.data);
.bss (NOLOAD) : { _bss = .; *(.bss*) *(.sbss*) *(COMMON) . = ALIGN(4); _ebss = .; } > ram
_stack = ORIGIN(ram) + LENGTH(ram) - 16;
/DISCARD/ : { *(.MIPS.abiflags) *(.reginfo) *(.comment) *(.pdr) *(.gnu.attributes) }
}