add memory allocator