Replace malloc/free with a Fast Fixed Block Memory Allocator Replace malloc/free with xmalloc/xfree is faster than the global heap and prevents heap fragmentation faults. Click here to read the article