[Improvement](execute) optimize for ColumnNullable's serialize_vec/deserialize_vec (#28788)

optimize for ColumnNullable's serialize_vec/deserialize_vec
This commit is contained in:
Pxl
2024-01-11 11:19:15 +08:00
committed by yiguolei
parent e93a16ac6e
commit 3cf95d0fdf
44 changed files with 334 additions and 393 deletions

View File

@ -700,12 +700,7 @@ Status execute_bitmap_op_count_null_to_zero(
size_t input_rows_count,
const std::function<Status(FunctionContext*, Block&, const ColumnNumbers&, size_t, size_t)>&
exec_impl_func) {
NullPresence null_presence = get_null_presence(block, arguments);
if (null_presence.has_null_constant) {
block.get_by_position(result).column =
block.get_by_position(result).type->create_column_const(input_rows_count, 0);
} else if (null_presence.has_nullable) {
if (get_null_presence(block, arguments)) {
auto [temporary_block, new_args, new_result] =
create_block_with_nested_columns(block, arguments, result);
RETURN_IF_ERROR(exec_impl_func(context, temporary_block, new_args, new_result,