bmarcot / vega

vega -- The Unix-like Operating System for micro-controllers (ARM Cortex-M4)
6 stars 1 forks source link

Newlib's malloc() uses too much .data (~ 2 KiB) #9

Closed bmarcot closed 8 years ago

bmarcot commented 8 years ago
$ cat vega.map
.data.__malloc_av_
                0x0000000020000060      0x408 /usr/bin/../lib/gcc/arm-none-eabi/5.3.1/../../../../arm-none- .data.impure_data
                0x0000000020000470      0x428 /usr/bin/../lib/gcc/arm-none-eabi/5.3.1/../../../../arm-none-eabi/lib/armv7-m/libc.a(lib_a-impure.o)

Swap this malloc for something less greedy. Specifically, this blocks porting to ARMv6-M platforms (micro:bit has 16 KiB SRAM for instance).

bmarcot commented 8 years ago

Fixed by 3b5d69b61f