5.7.1.13 Malloc-variant Option

The -mmalloc-variant=scheme option indicates to the compiler the scheme of dynamic memory allocation that should be employed for the program. See 9.6 Dynamic Memory Allocation for more information on this type of memory allocation and the heap, from which allocation takes place.

The -mmalloc-variant=lite form of this option selects a simple scheme that will yield the smallest code size. It might, however, result in a fragmented heap when freeing allocated memory, preventing further memory from being allocated at runtime. This is the default scheme if no option is specified.

The -mmalloc-variant=binned option uses a more sophisticated allocation scheme that will result in less fragmentation, but at the expense of increased code size.