BiteTheDDDDt commented on code in PR #31913:
URL: https://github.com/apache/doris/pull/31913#discussion_r1522900947


##########
be/src/vec/aggregate_functions/aggregate_function_collect.h:
##########
@@ -362,12 +364,55 @@ struct AggregateFunctionArrayAggData {
         }
         to_arr.get_offsets().push_back(to_nested_col.size());
     }
+
+    void write(BufferWritable& buf) const {
+        const size_t size = null_map->size();
+        write_binary(size, buf);
+
+        for (size_t i = 0; i < size; i++) {
+            write_binary(null_map->data()[i], buf);
+        }
+
+        for (size_t i = 0; i < size; i++) {
+            write_binary(nested_column->get_data()[i], buf);
+        }
+    }
+
+    void read(BufferReadable& buf) {
+        DCHECK(null_map);
+        DCHECK(null_map->empty());
+        size_t size = 0;
+        read_binary(size, buf);
+
+        NullMap::value_type null_value;

Review Comment:
   maybe we can reserve or resize column at first?



-- 
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

Reply via email to