Qualcomm Interview Question

Describe in detail how a memory allocator works (malloc).