wangbo commented on code in PR #9157: URL: https://github.com/apache/incubator-doris/pull/9157#discussion_r858279785
########## be/src/olap/memtable.cpp: ########## @@ -145,38 +126,33 @@ void MemTable::insert(const vectorized::Block* block, size_t row_pos, size_t num _mem_tracker->consume(newsize - oldsize); for(int i = 0; i < num_rows; i++){ - RowInBlock* row_in_block_ptr = new RowInBlock(cursor_in_mutableblock + i); - rowInBlocks.push_back(row_in_block_ptr); - insert_one_row_from_block(row_in_block_ptr); + _row_in_blocks.emplace_back(new RowInBlock{cursor_in_mutableblock + i}); Review Comment: Why not allocate RowInBlock in stack here? -- 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