EmilyMatt commented on code in PR #11524:
URL: https://github.com/apache/arrow-rs/pull/11524#discussion_r4371032841
##########
parquet/tests/arrow_writer/mod.rs:
##########
Review Comment:
Got annoyed by why running the tests on this PR is so slow, asked a Clanker,
he said that it's because every alloc_zeroed call falls back to default, which
is alloc, and then zeroize the buffer, which doesn't let us lazily alloc the
memory, and also means we use so much more memory at peak.
added an alloc_zeroed impl here and it did fucking wonders:
```
unsafe fn alloc_zeroed(&self, layout: Layout) -> *mut u8 {
let ptr = unsafe { self.inner.alloc_zeroed(layout) };
if !ptr.is_null() {
add_live_bytes(layout.size());
}
ptr
}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]