When allocating a chunk of memory with malloc(), there is always some memory overhead associated with the heap control structures. Also, the minimum memory allocation unit is typically larger then one byte.
Because of that, sometimes it could be more efficient to allocate a static data of the maximum size rather then a dynamic data of the required size.
I understand that those things are implementation dependent. However, from the common sense standpoint, it shouldn't be too different for the MCUs and C/C++ compilers of the same class.
Is it possible to make any general assumptions about the behavior of malloc for, say, 8-bitters?
VLV