previous | start | next

Explicit Free List

The implicit free list requires looking at all blocks in order, not just the free ones, when searching for a free block.

Adding an explicit link in a free block to the next free block could avoid this.

As for the implicit list of all blocks, this list should be doubly linked.

That is, you need to be able to get to the previous free block as well as the next free block.

... and you need to know when you are at the end or beginning of the list.

Does this require more OVERHEAD per block?

Allocation is better.

The balanced performance of malloc/free will also depend on the order of blocks on the free list.

The free list could be kept in address order.

Alternatively, a newly free block could just be placed at the beginning of the the free list.

The choice will either increase effective use of memory or be faster.



previous | start | next