Implement minimal bump pointer allocator

Useful for MCUs, until a real garbage collector has been implemented.
This commit is contained in:
Ayke van Laethem
2018-06-03 16:18:40 +02:00
parent b45ea2deb9
commit e171f32493
4 changed files with 163 additions and 62 deletions
+5
View File
@@ -75,3 +75,8 @@ SECTIONS
__etext = _etext;
__data_start__ = _sdata;
__bss_start__ = _sbss;
/* For the memory allocator. */
_heap_start = _ebss;
_heap_end = ORIGIN(RAM) + LENGTH(RAM);
runtime.heapptr = _heap_start; /* necessary? */