spaces-X commented on code in PR #11972: URL: https://github.com/apache/doris/pull/11972#discussion_r951560496
########## be/src/vec/core/block.cpp: ########## @@ -638,7 +624,7 @@ void filter_block_internal(Block* block, const IColumn::Filter& filter, uint32_t if (count != block->rows()) { for (size_t i = 0; i < column_to_keep; ++i) { block->get_by_position(i).column = - block->get_by_position(i).column->filter(filter, 0); + block->get_by_position(i).column->filter(filter, count); Review Comment: Please add UT for the new function call ########## be/src/vec/columns/columns_common.cpp: ########## @@ -106,14 +106,14 @@ struct ResultOffsetsBuilder { void insertOne(size_t array_size) { current_src_offset += array_size; - res_offsets.push_back(current_src_offset); + res_offsets.push_back_without_reserve(current_src_offset); } template <size_t SIMD_BYTES> void insertChunk(const IColumn::Offset* src_offsets_pos, bool first, IColumn::Offset chunk_offset, size_t chunk_size) { const auto offsets_size_old = res_offsets.size(); - res_offsets.resize(offsets_size_old + SIMD_BYTES); + res_offsets.resize_assume_reserved(offsets_size_old + SIMD_BYTES); Review Comment: Make sure that `reserve()` function has been called before here in all cases. -- 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