xinyiZzz commented on code in PR #13285: URL: https://github.com/apache/doris/pull/13285#discussion_r995444935
########## be/src/runtime/mem_pool.h: ########## @@ -231,9 +231,9 @@ class MemPool { // I refers to https://github.com/mcgov/asan_alignment_example. ChunkInfo& info = chunks_[current_chunk_idx_]; - int64_t aligned_allocated_bytes = - BitUtil::RoundUpToPowerOf2(info.allocated_bytes + DEFAULT_PADDING_SIZE, alignment); - if (aligned_allocated_bytes + size <= info.chunk.size) { + int64_t aligned_allocated_bytes = BitUtil::RoundUpToMultiplyOfFactor( + info.allocated_bytes + DEFAULT_PADDING_SIZE, alignment); + if (aligned_allocated_bytes + size + DEFAULT_PADDING_SIZE <= info.chunk.size) { Review Comment: I see wrong = = -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org