refactor buddy allocator