abse/gameboy-advance

A tscircuit package created by abse.

Version
0.0.45
License
unset
Stars
0

firmware/game-console/linker/section_heap.incl

/* Defines the following symbols for use by code:
    __HeapLimit
*/

SECTIONS
{
    .dummy_pre_heap (NOLOAD):
    {
        /* Dummy section to make sure we're back in normal RAM for the heap when HEAP_LOC isn't defined */
        . = .;
    } > RAM
    .heap DEFINED(HEAP_LOC) ? HEAP_LOC : . (NOLOAD):
    {
        __end__ = .;
        end = __end__;
        KEEP(*(.heap*))
    } > RAM
    /* historically on GCC sbrk was growing past __HeapLimit to __StackLimit, however
       to be more compatible, we now set __HeapLimit explicitly to where the end of the heap is */
    __HeapLimit = ADDR(.stack_dummy);
}