Closed baloo closed 3 years ago
I believe the implementation made in https://github.com/fitzgen/bumpalo/pull/92 could use a specific grow_zeroed implementation
grow_zeroed
If I read https://github.com/rust-lang/rust/blob/ee88f46bb5e27c4d9f30326e69ff2298dcbeecb1/library/core/src/alloc/mod.rs#L253-L277 correctly, that could use more effective one. As currently implemented, it grows by new_layout.size() where it could grow by only new_layout.size()-old_layout.size().
new_layout.size()
new_layout.size()-old_layout.size()
I believe the implementation made in https://github.com/fitzgen/bumpalo/pull/92 could use a specific
grow_zeroed
implementationIf I read https://github.com/rust-lang/rust/blob/ee88f46bb5e27c4d9f30326e69ff2298dcbeecb1/library/core/src/alloc/mod.rs#L253-L277 correctly, that could use more effective one. As currently implemented, it grows by
new_layout.size()
where it could grow by onlynew_layout.size()-old_layout.size()
.