Merge "Add native memory accounting through custom allocator."