Coverage Report

Created: 2026-10-28 14:43

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
be/src/exprs/vcase_expr.h
Line
Count
Source
1
// Licensed to the Apache Software Foundation (ASF) under one
2
// or more contributor license agreements.  See the NOTICE file
3
// distributed with this work for additional information
4
// regarding copyright ownership.  The ASF licenses this file
5
// to you under the Apache License, Version 2.0 (the
6
// "License"); you may not use this file except in compliance
7
// with the License.  You may obtain a copy of the License at
8
//
9
//   http://www.apache.org/licenses/LICENSE-2.0
10
//
11
// Unless required by applicable law or agreed to in writing,
12
// software distributed under the License is distributed on an
13
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14
// KIND, either express or implied.  See the License for the
15
// specific language governing permissions and limitations
16
// under the License.
17
18
#pragma once
19
20
#include <string>
21
22
#include "common/exception.h"
23
#include "common/status.h"
24
#include "core/column/column_array.h"
25
#include "core/column/column_complex.h"
26
#include "core/column/column_const.h"
27
#include "core/column/column_decimal.h"
28
#include "core/column/column_map.h"
29
#include "core/column/column_nullable.h"
30
#include "core/column/column_struct.h"
31
#include "core/column/column_varbinary.h"
32
#include "core/column/variant_v2/column_variant_v2.h"
33
#include "core/data_type/data_type_nullable.h"
34
#include "core/data_type/data_type_variant_v2.h"
35
#include "core/data_type/define_primitive_type.h"
36
#include "core/data_type/primitive_type.h"
37
#include "exprs/function/function.h"
38
#include "exprs/function_context.h"
39
#include "exprs/vexpr.h"
40
41
namespace doris {
42
class RowDescriptor;
43
class RuntimeState;
44
class TExprNode;
45
46
class Block;
47
} // namespace doris
48
49
namespace doris {
50
51
class VCaseExpr final : public VExpr {
52
    ENABLE_FACTORY_CREATOR(VCaseExpr);
53
54
public:
55
    VCaseExpr(const TExprNode& node);
56
    ~VCaseExpr() override = default;
57
    Status execute_column_impl(VExprContext* context, const Block* block, const Selector* selector,
58
                               size_t count, ColumnPtr& result_column) const override;
59
    Status prepare(RuntimeState* state, const RowDescriptor& desc, VExprContext* context) override;
60
    Status open(RuntimeState* state, VExprContext* context,
61
                FunctionContext::FunctionStateScope scope) override;
62
    void close(VExprContext* context, FunctionContext::FunctionStateScope scope) override;
63
    const std::string& expr_name() const override;
64
    std::string debug_string() const override;
65
0
    bool has_else_expr() const { return _has_else_expr; }
66
1
    Status clone_node(VExprSPtr* cloned_expr) const override {
67
1
        DORIS_CHECK(cloned_expr != nullptr);
68
1
        auto node = clone_texpr_node();
69
1
        TCaseExpr case_node;
70
1
        case_node.__set_has_case_expr(false);
71
1
        case_node.__set_has_else_expr(_has_else_expr);
72
1
        node.__set_case_expr(case_node);
73
1
        *cloned_expr = VCaseExpr::create_shared(node);
74
1
        return Status::OK();
75
1
    }
76
77
private:
78
    template <typename IndexType, typename ColumnType>
79
    ColumnPtr _execute_update_result_impl(const IndexType* then_idx,
80
                                          std::vector<ColumnPtr>& then_columns,
81
876
                                          size_t rows_count) const {
82
876
        auto result_column_ptr = data_type()->create_column();
83
876
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
247
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
247
            if (data_type()->is_nullable()) {
99
157
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
157
                                                                  then_columns, rows_count);
101
157
            } else {
102
90
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
90
                                                                   then_columns, rows_count);
104
90
            }
105
629
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
73
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
73
                                                              then_columns, rows_count);
109
556
        } else {
110
556
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
556
                                                           then_columns, rows_count);
112
556
        }
113
876
        return result_column_ptr;
114
876
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE2EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE3EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE4EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE5EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE6EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE7EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE8EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE9EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_13ColumnDecimalILNS_13PrimitiveTypeE28EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_13ColumnDecimalILNS_13PrimitiveTypeE29EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_13ColumnDecimalILNS_13PrimitiveTypeE35EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_13ColumnDecimalILNS_13PrimitiveTypeE30EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_13ColumnDecimalILNS_13PrimitiveTypeE20EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_9ColumnStrIjEEEENS_3COWINS_7IColumnEE13immutable_ptrIS5_EEPKT_RSt6vectorIS8_SaIS8_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_15ColumnVarbinaryEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE11EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE12EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE25EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE26EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE43EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE42EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE37EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE44EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnVectorILNS_13PrimitiveTypeE36EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_11ColumnArrayEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_9ColumnMapEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_12ColumnStructEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE22EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE19EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE24EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implItNS_15ColumnVariantV2EEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE2EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE3EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
84
                                          size_t rows_count) const {
82
84
        auto result_column_ptr = data_type()->create_column();
83
84
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
84
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
1
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
1
                                                              then_columns, rows_count);
109
83
        } else {
110
83
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
83
                                                           then_columns, rows_count);
112
83
        }
113
84
        return result_column_ptr;
114
84
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE4EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE5EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
39
                                          size_t rows_count) const {
82
39
        auto result_column_ptr = data_type()->create_column();
83
39
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
39
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
34
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
34
                                                              then_columns, rows_count);
109
34
        } else {
110
5
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
5
                                                           then_columns, rows_count);
112
5
        }
113
39
        return result_column_ptr;
114
39
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE6EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
190
                                          size_t rows_count) const {
82
190
        auto result_column_ptr = data_type()->create_column();
83
190
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
190
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
28
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
28
                                                              then_columns, rows_count);
109
162
        } else {
110
162
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
162
                                                           then_columns, rows_count);
112
162
        }
113
190
        return result_column_ptr;
114
190
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE7EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE8EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
26
                                          size_t rows_count) const {
82
26
        auto result_column_ptr = data_type()->create_column();
83
26
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
26
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
1
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
1
                                                              then_columns, rows_count);
109
25
        } else {
110
25
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
25
                                                           then_columns, rows_count);
112
25
        }
113
26
        return result_column_ptr;
114
26
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE9EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
32
                                          size_t rows_count) const {
82
32
        auto result_column_ptr = data_type()->create_column();
83
32
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
32
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
5
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
5
                                                              then_columns, rows_count);
109
27
        } else {
110
27
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
27
                                                           then_columns, rows_count);
112
27
        }
113
32
        return result_column_ptr;
114
32
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_13ColumnDecimalILNS_13PrimitiveTypeE28EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_13ColumnDecimalILNS_13PrimitiveTypeE29EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
1
                                          size_t rows_count) const {
82
1
        auto result_column_ptr = data_type()->create_column();
83
1
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
1
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
1
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
1
                                                              then_columns, rows_count);
109
1
        } else {
110
0
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
0
                                                           then_columns, rows_count);
112
0
        }
113
1
        return result_column_ptr;
114
1
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_13ColumnDecimalILNS_13PrimitiveTypeE35EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
2
                                          size_t rows_count) const {
82
2
        auto result_column_ptr = data_type()->create_column();
83
2
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
2
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
2
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
2
                                                              then_columns, rows_count);
109
2
        } else {
110
0
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
0
                                                           then_columns, rows_count);
112
0
        }
113
2
        return result_column_ptr;
114
2
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_13ColumnDecimalILNS_13PrimitiveTypeE30EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
1
                                          size_t rows_count) const {
82
1
        auto result_column_ptr = data_type()->create_column();
83
1
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
1
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
1
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
1
                                                              then_columns, rows_count);
109
1
        } else {
110
0
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
0
                                                           then_columns, rows_count);
112
0
        }
113
1
        return result_column_ptr;
114
1
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_13ColumnDecimalILNS_13PrimitiveTypeE20EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_9ColumnStrIjEEEENS_3COWINS_7IColumnEE13immutable_ptrIS5_EEPKT_RSt6vectorIS8_SaIS8_EEm
Line
Count
Source
81
219
                                          size_t rows_count) const {
82
219
        auto result_column_ptr = data_type()->create_column();
83
219
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
219
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
219
            if (data_type()->is_nullable()) {
99
131
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
131
                                                                  then_columns, rows_count);
101
131
            } else {
102
88
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
88
                                                                   then_columns, rows_count);
104
88
            }
105
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
                                                              then_columns, rows_count);
109
        } else {
110
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
                                                           then_columns, rows_count);
112
        }
113
219
        return result_column_ptr;
114
219
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_15ColumnVarbinaryEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Line
Count
Source
81
12
                                          size_t rows_count) const {
82
12
        auto result_column_ptr = data_type()->create_column();
83
12
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
12
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
12
            if (data_type()->is_nullable()) {
99
10
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
10
                                                                  then_columns, rows_count);
101
10
            } else {
102
2
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
2
                                                                   then_columns, rows_count);
104
2
            }
105
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
                                                              then_columns, rows_count);
109
        } else {
110
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
                                                           then_columns, rows_count);
112
        }
113
12
        return result_column_ptr;
114
12
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE11EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE12EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE25EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
20
                                          size_t rows_count) const {
82
20
        auto result_column_ptr = data_type()->create_column();
83
20
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
20
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
20
        } else {
110
20
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
20
                                                           then_columns, rows_count);
112
20
        }
113
20
        return result_column_ptr;
114
20
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE26EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE43EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE42EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
18
                                          size_t rows_count) const {
82
18
        auto result_column_ptr = data_type()->create_column();
83
18
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
            if (data_type()->is_nullable()) {
99
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
                                                                  then_columns, rows_count);
101
            } else {
102
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
                                                                   then_columns, rows_count);
104
            }
105
18
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
0
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
0
                                                              then_columns, rows_count);
109
18
        } else {
110
18
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
18
                                                           then_columns, rows_count);
112
18
        }
113
18
        return result_column_ptr;
114
18
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE37EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE44EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
3
                                          size_t rows_count) const {
82
3
        auto result_column_ptr = data_type()->create_column();
83
3
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
3
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
3
            if (data_type()->is_nullable()) {
99
3
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
3
                                                                  then_columns, rows_count);
101
3
            } else {
102
0
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
0
                                                                   then_columns, rows_count);
104
0
            }
105
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
                                                              then_columns, rows_count);
109
        } else {
110
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
                                                           then_columns, rows_count);
112
        }
113
3
        return result_column_ptr;
114
3
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnVectorILNS_13PrimitiveTypeE36EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_11ColumnArrayEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Line
Count
Source
81
1
                                          size_t rows_count) const {
82
1
        auto result_column_ptr = data_type()->create_column();
83
1
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
1
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
1
            if (data_type()->is_nullable()) {
99
1
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
1
                                                                  then_columns, rows_count);
101
1
            } else {
102
0
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
0
                                                                   then_columns, rows_count);
104
0
            }
105
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
                                                              then_columns, rows_count);
109
        } else {
110
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
                                                           then_columns, rows_count);
112
        }
113
1
        return result_column_ptr;
114
1
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_9ColumnMapEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_12ColumnStructEEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE22EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Line
Count
Source
81
11
                                          size_t rows_count) const {
82
11
        auto result_column_ptr = data_type()->create_column();
83
11
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
11
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
11
            if (data_type()->is_nullable()) {
99
11
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
11
                                                                  then_columns, rows_count);
101
11
            } else {
102
0
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
0
                                                                   then_columns, rows_count);
104
0
            }
105
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
                                                              then_columns, rows_count);
109
        } else {
110
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
                                                           then_columns, rows_count);
112
        }
113
11
        return result_column_ptr;
114
11
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE19EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE24EEEEENS_3COWINS_7IColumnEE13immutable_ptrIS6_EEPKT_RSt6vectorIS9_SaIS9_EEm
_ZNK5doris9VCaseExpr27_execute_update_result_implIhNS_15ColumnVariantV2EEENS_3COWINS_7IColumnEE13immutable_ptrIS4_EEPKT_RSt6vectorIS7_SaIS7_EEm
Line
Count
Source
81
1
                                          size_t rows_count) const {
82
1
        auto result_column_ptr = data_type()->create_column();
83
1
        result_column_ptr->reserve(rows_count);
84
        if constexpr (std::is_same_v<ColumnType, ColumnString> ||
85
                      std::is_same_v<ColumnType, ColumnVarbinary> ||
86
                      std::is_same_v<ColumnType, ColumnBitmap> ||
87
                      std::is_same_v<ColumnType, ColumnArray> ||
88
                      std::is_same_v<ColumnType, ColumnMap> ||
89
                      std::is_same_v<ColumnType, ColumnStruct> ||
90
                      std::is_same_v<ColumnType, ColumnVariantV2> ||
91
                      std::is_same_v<ColumnType, ColumnHLL> ||
92
                      std::is_same_v<ColumnType, ColumnQuantileState> ||
93
                      std::is_same_v<ColumnType, ColumnIPv4> ||
94
                      std::is_same_v<ColumnType, ColumnIPv6> ||
95
1
                      std::is_same_v<ColumnType, ColumnUUID>) {
96
            // result_column and all then_column is not nullable.
97
            // can't simd when type is string.
98
1
            if (data_type()->is_nullable()) {
99
1
                update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
100
1
                                                                  then_columns, rows_count);
101
1
            } else {
102
0
                update_result_normal<IndexType, ColumnType, false>(result_column_ptr, then_idx,
103
0
                                                                   then_columns, rows_count);
104
0
            }
105
        } else if (data_type()->is_nullable()) {
106
            // result_column and all then_column is nullable.
107
            update_result_normal<IndexType, ColumnType, true>(result_column_ptr, then_idx,
108
                                                              then_columns, rows_count);
109
        } else {
110
            update_result_auto_simd<IndexType, ColumnType>(result_column_ptr, then_idx,
111
                                                           then_columns, rows_count);
112
        }
113
1
        return result_column_ptr;
114
1
    }
115
116
    template <typename IndexType>
117
    ColumnPtr _execute_update_result(const IndexType* then_idx,
118
                                     std::vector<ColumnPtr>& then_columns,
119
588
                                     size_t rows_count) const {
120
588
#define CASE_TYPE(ptype, coltype) \
121
588
    case PrimitiveType::ptype:    \
122
587
        return _execute_update_result_impl<IndexType, coltype>(then_idx, then_columns, rows_count);
123
124
588
        switch (data_type()->get_primitive_type()) {
125
0
            CASE_TYPE(TYPE_BOOLEAN, ColumnUInt8)
126
84
            CASE_TYPE(TYPE_TINYINT, ColumnInt8)
127
0
            CASE_TYPE(TYPE_SMALLINT, ColumnInt16)
128
39
            CASE_TYPE(TYPE_INT, ColumnInt32)
129
190
            CASE_TYPE(TYPE_BIGINT, ColumnInt64)
130
0
            CASE_TYPE(TYPE_LARGEINT, ColumnInt128)
131
8
            CASE_TYPE(TYPE_FLOAT, ColumnFloat32)
132
14
            CASE_TYPE(TYPE_DOUBLE, ColumnFloat64)
133
0
            CASE_TYPE(TYPE_DECIMAL32, ColumnDecimal32)
134
1
            CASE_TYPE(TYPE_DECIMAL64, ColumnDecimal64)
135
2
            CASE_TYPE(TYPE_DECIMAL256, ColumnDecimal256)
136
1
            CASE_TYPE(TYPE_DECIMAL128I, ColumnDecimal128V3)
137
0
            CASE_TYPE(TYPE_DECIMALV2, ColumnDecimal128V2)
138
114
            CASE_TYPE(TYPE_STRING, ColumnString)
139
0
            CASE_TYPE(TYPE_CHAR, ColumnString)
140
105
            CASE_TYPE(TYPE_VARCHAR, ColumnString)
141
0
            CASE_TYPE(TYPE_JSONB, ColumnString)
142
12
            CASE_TYPE(TYPE_VARBINARY, ColumnVarbinary)
143
0
            CASE_TYPE(TYPE_DATE, ColumnDate)
144
0
            CASE_TYPE(TYPE_DATETIME, ColumnDateTime)
145
2
            CASE_TYPE(TYPE_DATEV2, ColumnDateV2)
146
0
            CASE_TYPE(TYPE_DATETIMEV2, ColumnDateTimeV2)
147
0
            CASE_TYPE(TYPE_TIMESTAMP_NS, ColumnTimeStampNs)
148
0
            CASE_TYPE(TYPE_TIMESTAMPTZ, ColumnTimeStampTz)
149
0
            CASE_TYPE(TYPE_IPV6, ColumnIPv6)
150
3
            CASE_TYPE(TYPE_UUID, ColumnUUID)
151
0
            CASE_TYPE(TYPE_IPV4, ColumnIPv4)
152
1
            CASE_TYPE(TYPE_ARRAY, ColumnArray)
153
0
            CASE_TYPE(TYPE_MAP, ColumnMap)
154
0
            CASE_TYPE(TYPE_STRUCT, ColumnStruct)
155
11
            CASE_TYPE(TYPE_BITMAP, ColumnBitmap)
156
0
            CASE_TYPE(TYPE_HLL, ColumnHLL)
157
0
            CASE_TYPE(TYPE_QUANTILE_STATE, ColumnQuantileState)
158
1
        case PrimitiveType::TYPE_VARIANT: {
159
1
            const IDataType* variant_type = remove_nullable(data_type()).get();
160
1
            DORIS_CHECK(dynamic_cast<const DataTypeVariantV2*>(variant_type) != nullptr);
161
1
            return _execute_update_result_impl<IndexType, ColumnVariantV2>(then_idx, then_columns,
162
1
                                                                           rows_count);
163
0
        }
164
0
        default:
165
0
            throw Exception(ErrorCode::NOT_IMPLEMENTED_ERROR, "argument_type {} not supported",
166
0
                            data_type()->get_name());
167
588
        }
168
588
#undef CASE_TYPE
169
588
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr22_execute_update_resultItEENS_3COWINS_7IColumnEE13immutable_ptrIS3_EEPKT_RSt6vectorIS6_SaIS6_EEm
_ZNK5doris9VCaseExpr22_execute_update_resultIhEENS_3COWINS_7IColumnEE13immutable_ptrIS3_EEPKT_RSt6vectorIS6_SaIS6_EEm
Line
Count
Source
119
588
                                     size_t rows_count) const {
120
588
#define CASE_TYPE(ptype, coltype) \
121
588
    case PrimitiveType::ptype:    \
122
588
        return _execute_update_result_impl<IndexType, coltype>(then_idx, then_columns, rows_count);
123
124
588
        switch (data_type()->get_primitive_type()) {
125
0
            CASE_TYPE(TYPE_BOOLEAN, ColumnUInt8)
126
84
            CASE_TYPE(TYPE_TINYINT, ColumnInt8)
127
0
            CASE_TYPE(TYPE_SMALLINT, ColumnInt16)
128
39
            CASE_TYPE(TYPE_INT, ColumnInt32)
129
190
            CASE_TYPE(TYPE_BIGINT, ColumnInt64)
130
0
            CASE_TYPE(TYPE_LARGEINT, ColumnInt128)
131
8
            CASE_TYPE(TYPE_FLOAT, ColumnFloat32)
132
14
            CASE_TYPE(TYPE_DOUBLE, ColumnFloat64)
133
0
            CASE_TYPE(TYPE_DECIMAL32, ColumnDecimal32)
134
1
            CASE_TYPE(TYPE_DECIMAL64, ColumnDecimal64)
135
2
            CASE_TYPE(TYPE_DECIMAL256, ColumnDecimal256)
136
1
            CASE_TYPE(TYPE_DECIMAL128I, ColumnDecimal128V3)
137
0
            CASE_TYPE(TYPE_DECIMALV2, ColumnDecimal128V2)
138
114
            CASE_TYPE(TYPE_STRING, ColumnString)
139
0
            CASE_TYPE(TYPE_CHAR, ColumnString)
140
105
            CASE_TYPE(TYPE_VARCHAR, ColumnString)
141
0
            CASE_TYPE(TYPE_JSONB, ColumnString)
142
12
            CASE_TYPE(TYPE_VARBINARY, ColumnVarbinary)
143
0
            CASE_TYPE(TYPE_DATE, ColumnDate)
144
0
            CASE_TYPE(TYPE_DATETIME, ColumnDateTime)
145
2
            CASE_TYPE(TYPE_DATEV2, ColumnDateV2)
146
0
            CASE_TYPE(TYPE_DATETIMEV2, ColumnDateTimeV2)
147
0
            CASE_TYPE(TYPE_TIMESTAMP_NS, ColumnTimeStampNs)
148
0
            CASE_TYPE(TYPE_TIMESTAMPTZ, ColumnTimeStampTz)
149
0
            CASE_TYPE(TYPE_IPV6, ColumnIPv6)
150
3
            CASE_TYPE(TYPE_UUID, ColumnUUID)
151
0
            CASE_TYPE(TYPE_IPV4, ColumnIPv4)
152
1
            CASE_TYPE(TYPE_ARRAY, ColumnArray)
153
0
            CASE_TYPE(TYPE_MAP, ColumnMap)
154
0
            CASE_TYPE(TYPE_STRUCT, ColumnStruct)
155
11
            CASE_TYPE(TYPE_BITMAP, ColumnBitmap)
156
0
            CASE_TYPE(TYPE_HLL, ColumnHLL)
157
0
            CASE_TYPE(TYPE_QUANTILE_STATE, ColumnQuantileState)
158
1
        case PrimitiveType::TYPE_VARIANT: {
159
1
            const IDataType* variant_type = remove_nullable(data_type()).get();
160
1
            DORIS_CHECK(dynamic_cast<const DataTypeVariantV2*>(variant_type) != nullptr);
161
1
            return _execute_update_result_impl<IndexType, ColumnVariantV2>(then_idx, then_columns,
162
1
                                                                           rows_count);
163
0
        }
164
0
        default:
165
0
            throw Exception(ErrorCode::NOT_IMPLEMENTED_ERROR, "argument_type {} not supported",
166
0
                            data_type()->get_name());
167
588
        }
168
588
#undef CASE_TYPE
169
588
    }
170
171
    template <typename IndexType, typename ColumnType, bool then_null>
172
    void update_result_normal(MutableColumnPtr& result_column_ptr,
173
                              const IndexType* __restrict then_idx,
174
320
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
320
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
320
        std::vector<uint8_t> is_consts(then_columns.size());
177
320
        std::vector<uint8_t> is_nullable(then_columns.size());
178
1.05k
        for (size_t i = 0; i < then_columns.size(); i++) {
179
736
            if (!then_columns[i]) {
180
31
                continue;
181
31
            }
182
705
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
705
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
705
        }
185
186
320
        auto* raw_result_column = result_column_ptr.get();
187
369k
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
368k
            if (!_has_else_expr && !then_idx[row_idx]) {
189
21
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
21
                        ->insert_default();
191
21
                continue;
192
21
            }
193
368k
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
368k
            if constexpr (then_null) {
195
117k
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
117k
                        result_column_ptr.get());
197
117k
                if (is_nullable[then_idx[row_idx]]) {
198
103k
                    nullable->insert_from_with_type<ColumnType>(
199
103k
                            *raw_then_columns[then_idx[row_idx]], target);
200
103k
                } else {
201
14.2k
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
14.2k
                            nullable->get_nested_column_ptr().get());
203
14.2k
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
14.2k
                    nullable->push_false_to_nullmap(1);
205
14.2k
                }
206
251k
            } else {
207
251k
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
251k
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
251k
            }
210
368k
        }
211
320
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE2EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE3EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE4EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE5EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE6EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE7EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE8EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE9EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_13ColumnDecimalILNS_13PrimitiveTypeE28EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_13ColumnDecimalILNS_13PrimitiveTypeE29EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_13ColumnDecimalILNS_13PrimitiveTypeE35EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_13ColumnDecimalILNS_13PrimitiveTypeE30EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_13ColumnDecimalILNS_13PrimitiveTypeE20EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_9ColumnStrIjEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS5_EEPKT_RSt6vectorINS6_13immutable_ptrIS5_EESaISF_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_9ColumnStrIjEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS5_EEPKT_RSt6vectorINS6_13immutable_ptrIS5_EESaISF_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_15ColumnVarbinaryELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_15ColumnVarbinaryELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE11EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE12EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE25EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE26EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE43EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE42EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE37EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE37EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE44EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE44EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE36EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnVectorILNS_13PrimitiveTypeE36EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_11ColumnArrayELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_11ColumnArrayELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_9ColumnMapELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_9ColumnMapELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnStructELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_12ColumnStructELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE22EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE22EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE19EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE19EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE24EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_17ColumnComplexTypeILNS_13PrimitiveTypeE24EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_15ColumnVariantV2ELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalItNS_15ColumnVariantV2ELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE2EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE3EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
1
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
1
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
1
        std::vector<uint8_t> is_consts(then_columns.size());
177
1
        std::vector<uint8_t> is_nullable(then_columns.size());
178
2
        for (size_t i = 0; i < then_columns.size(); i++) {
179
1
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
1
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
1
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
1
        }
185
186
1
        auto* raw_result_column = result_column_ptr.get();
187
2
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
1
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
1
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
1
            if constexpr (then_null) {
195
1
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
1
                        result_column_ptr.get());
197
1
                if (is_nullable[then_idx[row_idx]]) {
198
1
                    nullable->insert_from_with_type<ColumnType>(
199
1
                            *raw_then_columns[then_idx[row_idx]], target);
200
1
                } else {
201
0
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
0
                            nullable->get_nested_column_ptr().get());
203
0
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
0
                    nullable->push_false_to_nullmap(1);
205
0
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
1
        }
211
1
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE4EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE5EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
34
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
34
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
34
        std::vector<uint8_t> is_consts(then_columns.size());
177
34
        std::vector<uint8_t> is_nullable(then_columns.size());
178
79
        for (size_t i = 0; i < then_columns.size(); i++) {
179
45
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
45
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
45
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
45
        }
185
186
34
        auto* raw_result_column = result_column_ptr.get();
187
84
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
50
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
50
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
50
            if constexpr (then_null) {
195
50
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
50
                        result_column_ptr.get());
197
50
                if (is_nullable[then_idx[row_idx]]) {
198
50
                    nullable->insert_from_with_type<ColumnType>(
199
50
                            *raw_then_columns[then_idx[row_idx]], target);
200
50
                } else {
201
0
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
0
                            nullable->get_nested_column_ptr().get());
203
0
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
0
                    nullable->push_false_to_nullmap(1);
205
0
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
50
        }
211
34
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE6EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
28
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
28
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
28
        std::vector<uint8_t> is_consts(then_columns.size());
177
28
        std::vector<uint8_t> is_nullable(then_columns.size());
178
91
        for (size_t i = 0; i < then_columns.size(); i++) {
179
63
            if (!then_columns[i]) {
180
13
                continue;
181
13
            }
182
50
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
50
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
50
        }
185
186
28
        auto* raw_result_column = result_column_ptr.get();
187
100k
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
100k
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
100k
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
100k
            if constexpr (then_null) {
195
100k
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
100k
                        result_column_ptr.get());
197
100k
                if (is_nullable[then_idx[row_idx]]) {
198
100k
                    nullable->insert_from_with_type<ColumnType>(
199
100k
                            *raw_then_columns[then_idx[row_idx]], target);
200
100k
                } else {
201
0
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
0
                            nullable->get_nested_column_ptr().get());
203
0
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
0
                    nullable->push_false_to_nullmap(1);
205
0
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
100k
        }
211
28
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE7EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE8EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
1
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
1
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
1
        std::vector<uint8_t> is_consts(then_columns.size());
177
1
        std::vector<uint8_t> is_nullable(then_columns.size());
178
4
        for (size_t i = 0; i < then_columns.size(); i++) {
179
3
            if (!then_columns[i]) {
180
1
                continue;
181
1
            }
182
2
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
2
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
2
        }
185
186
1
        auto* raw_result_column = result_column_ptr.get();
187
4
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
3
            if (!_has_else_expr && !then_idx[row_idx]) {
189
1
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
1
                        ->insert_default();
191
1
                continue;
192
1
            }
193
2
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
2
            if constexpr (then_null) {
195
2
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
2
                        result_column_ptr.get());
197
2
                if (is_nullable[then_idx[row_idx]]) {
198
0
                    nullable->insert_from_with_type<ColumnType>(
199
0
                            *raw_then_columns[then_idx[row_idx]], target);
200
2
                } else {
201
2
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
2
                            nullable->get_nested_column_ptr().get());
203
2
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
2
                    nullable->push_false_to_nullmap(1);
205
2
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
2
        }
211
1
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE9EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
5
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
5
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
5
        std::vector<uint8_t> is_consts(then_columns.size());
177
5
        std::vector<uint8_t> is_nullable(then_columns.size());
178
25
        for (size_t i = 0; i < then_columns.size(); i++) {
179
20
            if (!then_columns[i]) {
180
2
                continue;
181
2
            }
182
18
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
18
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
18
        }
185
186
5
        auto* raw_result_column = result_column_ptr.get();
187
26
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
21
            if (!_has_else_expr && !then_idx[row_idx]) {
189
1
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
1
                        ->insert_default();
191
1
                continue;
192
1
            }
193
20
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
20
            if constexpr (then_null) {
195
20
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
20
                        result_column_ptr.get());
197
20
                if (is_nullable[then_idx[row_idx]]) {
198
7
                    nullable->insert_from_with_type<ColumnType>(
199
7
                            *raw_then_columns[then_idx[row_idx]], target);
200
13
                } else {
201
13
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
13
                            nullable->get_nested_column_ptr().get());
203
13
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
13
                    nullable->push_false_to_nullmap(1);
205
13
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
20
        }
211
5
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_13ColumnDecimalILNS_13PrimitiveTypeE28EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_13ColumnDecimalILNS_13PrimitiveTypeE29EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
1
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
1
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
1
        std::vector<uint8_t> is_consts(then_columns.size());
177
1
        std::vector<uint8_t> is_nullable(then_columns.size());
178
2
        for (size_t i = 0; i < then_columns.size(); i++) {
179
1
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
1
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
1
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
1
        }
185
186
1
        auto* raw_result_column = result_column_ptr.get();
187
2
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
1
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
1
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
1
            if constexpr (then_null) {
195
1
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
1
                        result_column_ptr.get());
197
1
                if (is_nullable[then_idx[row_idx]]) {
198
1
                    nullable->insert_from_with_type<ColumnType>(
199
1
                            *raw_then_columns[then_idx[row_idx]], target);
200
1
                } else {
201
0
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
0
                            nullable->get_nested_column_ptr().get());
203
0
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
0
                    nullable->push_false_to_nullmap(1);
205
0
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
1
        }
211
1
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_13ColumnDecimalILNS_13PrimitiveTypeE35EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
2
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
2
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
2
        std::vector<uint8_t> is_consts(then_columns.size());
177
2
        std::vector<uint8_t> is_nullable(then_columns.size());
178
8
        for (size_t i = 0; i < then_columns.size(); i++) {
179
6
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
6
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
6
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
6
        }
185
186
2
        auto* raw_result_column = result_column_ptr.get();
187
6
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
4
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
4
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
4
            if constexpr (then_null) {
195
4
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
4
                        result_column_ptr.get());
197
4
                if (is_nullable[then_idx[row_idx]]) {
198
4
                    nullable->insert_from_with_type<ColumnType>(
199
4
                            *raw_then_columns[then_idx[row_idx]], target);
200
4
                } else {
201
0
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
0
                            nullable->get_nested_column_ptr().get());
203
0
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
0
                    nullable->push_false_to_nullmap(1);
205
0
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
4
        }
211
2
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_13ColumnDecimalILNS_13PrimitiveTypeE30EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
1
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
1
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
1
        std::vector<uint8_t> is_consts(then_columns.size());
177
1
        std::vector<uint8_t> is_nullable(then_columns.size());
178
3
        for (size_t i = 0; i < then_columns.size(); i++) {
179
2
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
2
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
2
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
2
        }
185
186
1
        auto* raw_result_column = result_column_ptr.get();
187
2
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
1
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
1
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
1
            if constexpr (then_null) {
195
1
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
1
                        result_column_ptr.get());
197
1
                if (is_nullable[then_idx[row_idx]]) {
198
1
                    nullable->insert_from_with_type<ColumnType>(
199
1
                            *raw_then_columns[then_idx[row_idx]], target);
200
1
                } else {
201
0
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
0
                            nullable->get_nested_column_ptr().get());
203
0
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
0
                    nullable->push_false_to_nullmap(1);
205
0
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
1
        }
211
1
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_13ColumnDecimalILNS_13PrimitiveTypeE20EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_9ColumnStrIjEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS5_EEPKT_RSt6vectorINS6_13immutable_ptrIS5_EESaISF_EEm
Line
Count
Source
174
131
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
131
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
131
        std::vector<uint8_t> is_consts(then_columns.size());
177
131
        std::vector<uint8_t> is_nullable(then_columns.size());
178
432
        for (size_t i = 0; i < then_columns.size(); i++) {
179
301
            if (!then_columns[i]) {
180
11
                continue;
181
11
            }
182
290
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
290
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
290
        }
185
186
131
        auto* raw_result_column = result_column_ptr.get();
187
1.21k
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
1.08k
            if (!_has_else_expr && !then_idx[row_idx]) {
189
8
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
8
                        ->insert_default();
191
8
                continue;
192
8
            }
193
1.07k
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
1.07k
            if constexpr (then_null) {
195
1.07k
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
1.07k
                        result_column_ptr.get());
197
1.07k
                if (is_nullable[then_idx[row_idx]]) {
198
21
                    nullable->insert_from_with_type<ColumnType>(
199
21
                            *raw_then_columns[then_idx[row_idx]], target);
200
1.05k
                } else {
201
1.05k
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
1.05k
                            nullable->get_nested_column_ptr().get());
203
1.05k
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
1.05k
                    nullable->push_false_to_nullmap(1);
205
1.05k
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
1.07k
        }
211
131
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_9ColumnStrIjEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS5_EEPKT_RSt6vectorINS6_13immutable_ptrIS5_EESaISF_EEm
Line
Count
Source
174
88
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
88
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
88
        std::vector<uint8_t> is_consts(then_columns.size());
177
88
        std::vector<uint8_t> is_nullable(then_columns.size());
178
308
        for (size_t i = 0; i < then_columns.size(); i++) {
179
220
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
220
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
220
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
220
        }
185
186
88
        auto* raw_result_column = result_column_ptr.get();
187
251k
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
251k
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
251k
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
            if constexpr (then_null) {
195
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
                        result_column_ptr.get());
197
                if (is_nullable[then_idx[row_idx]]) {
198
                    nullable->insert_from_with_type<ColumnType>(
199
                            *raw_then_columns[then_idx[row_idx]], target);
200
                } else {
201
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
                            nullable->get_nested_column_ptr().get());
203
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
                    nullable->push_false_to_nullmap(1);
205
                }
206
251k
            } else {
207
251k
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
251k
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
251k
            }
210
251k
        }
211
88
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_15ColumnVarbinaryELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Line
Count
Source
174
10
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
10
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
10
        std::vector<uint8_t> is_consts(then_columns.size());
177
10
        std::vector<uint8_t> is_nullable(then_columns.size());
178
40
        for (size_t i = 0; i < then_columns.size(); i++) {
179
30
            if (!then_columns[i]) {
180
4
                continue;
181
4
            }
182
26
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
26
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
26
        }
185
186
10
        auto* raw_result_column = result_column_ptr.get();
187
88
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
78
            if (!_has_else_expr && !then_idx[row_idx]) {
189
11
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
11
                        ->insert_default();
191
11
                continue;
192
11
            }
193
67
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
67
            if constexpr (then_null) {
195
67
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
67
                        result_column_ptr.get());
197
67
                if (is_nullable[then_idx[row_idx]]) {
198
36
                    nullable->insert_from_with_type<ColumnType>(
199
36
                            *raw_then_columns[then_idx[row_idx]], target);
200
36
                } else {
201
31
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
31
                            nullable->get_nested_column_ptr().get());
203
31
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
31
                    nullable->push_false_to_nullmap(1);
205
31
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
67
        }
211
10
    }
_ZNK5doris9VCaseExpr20update_result_normalIhNS_15ColumnVarbinaryELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Line
Count
Source
174
2
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
2
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
2
        std::vector<uint8_t> is_consts(then_columns.size());
177
2
        std::vector<uint8_t> is_nullable(then_columns.size());
178
7
        for (size_t i = 0; i < then_columns.size(); i++) {
179
5
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
5
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
5
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
5
        }
185
186
2
        auto* raw_result_column = result_column_ptr.get();
187
9
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
7
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
7
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
            if constexpr (then_null) {
195
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
                        result_column_ptr.get());
197
                if (is_nullable[then_idx[row_idx]]) {
198
                    nullable->insert_from_with_type<ColumnType>(
199
                            *raw_then_columns[then_idx[row_idx]], target);
200
                } else {
201
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
                            nullable->get_nested_column_ptr().get());
203
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
                    nullable->push_false_to_nullmap(1);
205
                }
206
7
            } else {
207
7
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
7
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
7
            }
210
7
        }
211
2
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE11EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE12EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE25EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE26EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE43EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE42EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE37EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE37EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE44EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
3
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
3
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
3
        std::vector<uint8_t> is_consts(then_columns.size());
177
3
        std::vector<uint8_t> is_nullable(then_columns.size());
178
18
        for (size_t i = 0; i < then_columns.size(); i++) {
179
15
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
15
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
15
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
15
        }
185
186
3
        auto* raw_result_column = result_column_ptr.get();
187
16.3k
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
16.3k
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
16.3k
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
16.3k
            if constexpr (then_null) {
195
16.3k
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
16.3k
                        result_column_ptr.get());
197
16.3k
                if (is_nullable[then_idx[row_idx]]) {
198
3.27k
                    nullable->insert_from_with_type<ColumnType>(
199
3.27k
                            *raw_then_columns[then_idx[row_idx]], target);
200
13.1k
                } else {
201
13.1k
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
13.1k
                            nullable->get_nested_column_ptr().get());
203
13.1k
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
13.1k
                    nullable->push_false_to_nullmap(1);
205
13.1k
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
16.3k
        }
211
3
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE44EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE36EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnVectorILNS_13PrimitiveTypeE36EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_11ColumnArrayELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Line
Count
Source
174
1
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
1
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
1
        std::vector<uint8_t> is_consts(then_columns.size());
177
1
        std::vector<uint8_t> is_nullable(then_columns.size());
178
4
        for (size_t i = 0; i < then_columns.size(); i++) {
179
3
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
3
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
3
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
3
        }
185
186
1
        auto* raw_result_column = result_column_ptr.get();
187
4
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
3
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
3
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
3
            if constexpr (then_null) {
195
3
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
3
                        result_column_ptr.get());
197
3
                if (is_nullable[then_idx[row_idx]]) {
198
1
                    nullable->insert_from_with_type<ColumnType>(
199
1
                            *raw_then_columns[then_idx[row_idx]], target);
200
2
                } else {
201
2
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
2
                            nullable->get_nested_column_ptr().get());
203
2
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
2
                    nullable->push_false_to_nullmap(1);
205
2
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
3
        }
211
1
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_11ColumnArrayELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_9ColumnMapELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_9ColumnMapELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnStructELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_12ColumnStructELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE22EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
174
11
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
11
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
11
        std::vector<uint8_t> is_consts(then_columns.size());
177
11
        std::vector<uint8_t> is_nullable(then_columns.size());
178
28
        for (size_t i = 0; i < then_columns.size(); i++) {
179
17
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
17
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
17
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
17
        }
185
186
11
        auto* raw_result_column = result_column_ptr.get();
187
23
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
12
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
12
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
12
            if constexpr (then_null) {
195
12
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
12
                        result_column_ptr.get());
197
12
                if (is_nullable[then_idx[row_idx]]) {
198
6
                    nullable->insert_from_with_type<ColumnType>(
199
6
                            *raw_then_columns[then_idx[row_idx]], target);
200
6
                } else {
201
6
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
6
                            nullable->get_nested_column_ptr().get());
203
6
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
6
                    nullable->push_false_to_nullmap(1);
205
6
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
12
        }
211
11
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE22EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE19EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE19EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE24EEELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_17ColumnComplexTypeILNS_13PrimitiveTypeE24EEELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr20update_result_normalIhNS_15ColumnVariantV2ELb1EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
Line
Count
Source
174
1
                              std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
175
1
        std::vector<ColumnPtr> raw_then_columns(then_columns.size());
176
1
        std::vector<uint8_t> is_consts(then_columns.size());
177
1
        std::vector<uint8_t> is_nullable(then_columns.size());
178
5
        for (size_t i = 0; i < then_columns.size(); i++) {
179
4
            if (!then_columns[i]) {
180
0
                continue;
181
0
            }
182
4
            std::tie(raw_then_columns[i], is_consts[i]) = unpack_if_const(then_columns[i]);
183
4
            is_nullable[i] = is_column_nullable(*raw_then_columns[i]);
184
4
        }
185
186
1
        auto* raw_result_column = result_column_ptr.get();
187
5
        for (int row_idx = 0; row_idx < rows_count; row_idx++) {
188
4
            if (!_has_else_expr && !then_idx[row_idx]) {
189
0
                assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(raw_result_column)
190
0
                        ->insert_default();
191
0
                continue;
192
0
            }
193
4
            size_t target = is_consts[then_idx[row_idx]] ? 0 : row_idx;
194
4
            if constexpr (then_null) {
195
4
                auto* nullable = assert_cast<ColumnNullable*, TypeCheckOnRelease::DISABLE>(
196
4
                        result_column_ptr.get());
197
4
                if (is_nullable[then_idx[row_idx]]) {
198
1
                    nullable->insert_from_with_type<ColumnType>(
199
1
                            *raw_then_columns[then_idx[row_idx]], target);
200
3
                } else {
201
3
                    auto* nested = assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(
202
3
                            nullable->get_nested_column_ptr().get());
203
3
                    nested->insert_from(*raw_then_columns[then_idx[row_idx]], target);
204
3
                    nullable->push_false_to_nullmap(1);
205
3
                }
206
            } else {
207
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
208
                        ->insert_from(*raw_then_columns[then_idx[row_idx]], target);
209
            }
210
4
        }
211
1
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr20update_result_normalIhNS_15ColumnVariantV2ELb0EEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS4_EEPKT_RSt6vectorINS5_13immutable_ptrIS4_EESaISE_EEm
212
213
    template <typename IndexType, typename ColumnType>
214
    void update_result_auto_simd(MutableColumnPtr& result_column_ptr,
215
                                 const IndexType* __restrict then_idx,
216
557
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
10.9k
        for (auto& then_ptr : then_columns) {
218
10.9k
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
10.9k
        }
220
221
557
        result_column_ptr->resize(rows_count);
222
557
        auto* __restrict result_raw_data =
223
557
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
557
                        ->get_data()
225
557
                        .data();
226
227
        // set default value
228
405k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
297k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
297k
                result_raw_data[i] = ColumnType::default_value();
236
297k
            } else {
237
108k
                result_raw_data[i] = {};
238
108k
            }
239
405k
        }
240
241
11.5k
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
10.9k
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
10.9k
            const auto* __restrict column_raw_data =
246
10.9k
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
10.9k
                            then_columns[i].get())
248
10.9k
                            ->get_data()
249
10.9k
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
10.5k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
36.0M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
35.9M
                    if (then_idx[row_idx] == i) {
263
404k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
404k
                    }
265
35.9M
                }
266
10.5k
            } else {
267
1.26k
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
842
                    result_raw_data[row_idx] +=
269
842
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
842
                            column_raw_data[row_idx];
271
842
                }
272
426
            }
273
10.9k
        }
274
557
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE2EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE3EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE4EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE5EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE6EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE7EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE8EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
24.7k
            } else {
237
24.7k
                result_raw_data[i] = {};
238
24.7k
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE9EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
24.7k
            } else {
237
24.7k
                result_raw_data[i] = {};
238
24.7k
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_13ColumnDecimalILNS_13PrimitiveTypeE28EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_13ColumnDecimalILNS_13PrimitiveTypeE29EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_13ColumnDecimalILNS_13PrimitiveTypeE35EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_13ColumnDecimalILNS_13PrimitiveTypeE30EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdItNS_13ColumnDecimalILNS_13PrimitiveTypeE20EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE11EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE12EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE25EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE26EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE43EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdItNS_12ColumnVectorILNS_13PrimitiveTypeE42EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
658
        for (auto& then_ptr : then_columns) {
218
658
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
658
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
676
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
658
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
658
            const auto* __restrict column_raw_data =
246
658
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
658
                            then_columns[i].get())
248
658
                            ->get_data()
249
658
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
658
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
658
        }
274
18
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE2EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE3EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
83
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
167
        for (auto& then_ptr : then_columns) {
218
167
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
167
        }
220
221
83
        result_column_ptr->resize(rows_count);
222
83
        auto* __restrict result_raw_data =
223
83
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
83
                        ->get_data()
225
83
                        .data();
226
227
        // set default value
228
170
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
87
            } else {
237
87
                result_raw_data[i] = {};
238
87
            }
239
87
        }
240
241
250
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
167
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
167
            const auto* __restrict column_raw_data =
246
167
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
167
                            then_columns[i].get())
248
167
                            ->get_data()
249
167
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
                    if (then_idx[row_idx] == i) {
263
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
                    }
265
                }
266
167
            } else {
267
339
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
172
                    result_raw_data[row_idx] +=
269
172
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
172
                            column_raw_data[row_idx];
271
172
                }
272
167
            }
273
167
        }
274
83
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE4EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE5EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
6
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
18
        for (auto& then_ptr : then_columns) {
218
18
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
18
        }
220
221
6
        result_column_ptr->resize(rows_count);
222
6
        auto* __restrict result_raw_data =
223
6
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
6
                        ->get_data()
225
6
                        .data();
226
227
        // set default value
228
24
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
18
            } else {
237
18
                result_raw_data[i] = {};
238
18
            }
239
18
        }
240
241
24
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
18
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
18
            const auto* __restrict column_raw_data =
246
18
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
18
                            then_columns[i].get())
248
18
                            ->get_data()
249
18
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
                    if (then_idx[row_idx] == i) {
263
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
                    }
265
                }
266
18
            } else {
267
72
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
54
                    result_raw_data[row_idx] +=
269
54
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
54
                            column_raw_data[row_idx];
271
54
                }
272
18
            }
273
18
        }
274
6
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE6EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
162
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
241
        for (auto& then_ptr : then_columns) {
218
241
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
241
        }
220
221
162
        result_column_ptr->resize(rows_count);
222
162
        auto* __restrict result_raw_data =
223
162
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
162
                        ->get_data()
225
162
                        .data();
226
227
        // set default value
228
512
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
350
            } else {
237
350
                result_raw_data[i] = {};
238
350
            }
239
350
        }
240
241
403
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
241
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
241
            const auto* __restrict column_raw_data =
246
241
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
241
                            then_columns[i].get())
248
241
                            ->get_data()
249
241
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
                    if (then_idx[row_idx] == i) {
263
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
                    }
265
                }
266
241
            } else {
267
857
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
616
                    result_raw_data[row_idx] +=
269
616
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
616
                            column_raw_data[row_idx];
271
616
                }
272
241
            }
273
241
        }
274
162
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE7EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE8EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
25
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
675
        for (auto& then_ptr : then_columns) {
218
675
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
675
        }
220
221
25
        result_column_ptr->resize(rows_count);
222
25
        auto* __restrict result_raw_data =
223
25
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
25
                        ->get_data()
225
25
                        .data();
226
227
        // set default value
228
28.9k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
28.8k
            } else {
237
28.8k
                result_raw_data[i] = {};
238
28.8k
            }
239
28.8k
        }
240
241
700
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
675
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
675
            const auto* __restrict column_raw_data =
246
675
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
675
                            then_columns[i].get())
248
675
                            ->get_data()
249
675
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
675
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
28.8k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
28.8k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
675
        }
274
25
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE9EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
27
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
691
        for (auto& then_ptr : then_columns) {
218
691
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
691
        }
220
221
27
        result_column_ptr->resize(rows_count);
222
27
        auto* __restrict result_raw_data =
223
27
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
27
                        ->get_data()
225
27
                        .data();
226
227
        // set default value
228
29.1k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
                result_raw_data[i] = ColumnType::default_value();
236
29.1k
            } else {
237
29.1k
                result_raw_data[i] = {};
238
29.1k
            }
239
29.1k
        }
240
241
718
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
691
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
691
            const auto* __restrict column_raw_data =
246
691
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
691
                            then_columns[i].get())
248
691
                            ->get_data()
249
691
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
691
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.25M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.25M
                    if (then_idx[row_idx] == i) {
263
29.1k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
29.1k
                    }
265
2.25M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
691
        }
274
27
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_13ColumnDecimalILNS_13PrimitiveTypeE28EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_13ColumnDecimalILNS_13PrimitiveTypeE29EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_13ColumnDecimalILNS_13PrimitiveTypeE35EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_13ColumnDecimalILNS_13PrimitiveTypeE30EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Unexecuted instantiation: _ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_13ColumnDecimalILNS_13PrimitiveTypeE20EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE11EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
654
        for (auto& then_ptr : then_columns) {
218
654
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
654
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
672
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
654
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
654
            const auto* __restrict column_raw_data =
246
654
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
654
                            then_columns[i].get())
248
654
                            ->get_data()
249
654
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
654
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.24M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.23M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.23M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
654
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE12EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
654
        for (auto& then_ptr : then_columns) {
218
654
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
654
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
672
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
654
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
654
            const auto* __restrict column_raw_data =
246
654
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
654
                            then_columns[i].get())
248
654
                            ->get_data()
249
654
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
654
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.24M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.23M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.23M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
654
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE25EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
20
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
660
        for (auto& then_ptr : then_columns) {
218
660
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
660
        }
220
221
20
        result_column_ptr->resize(rows_count);
222
20
        auto* __restrict result_raw_data =
223
20
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
20
                        ->get_data()
225
20
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
680
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
660
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
660
            const auto* __restrict column_raw_data =
246
660
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
660
                            then_columns[i].get())
248
660
                            ->get_data()
249
660
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
660
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.24M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.23M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.23M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
660
        }
274
20
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE26EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
654
        for (auto& then_ptr : then_columns) {
218
654
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
654
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
672
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
654
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
654
            const auto* __restrict column_raw_data =
246
654
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
654
                            then_columns[i].get())
248
654
                            ->get_data()
249
654
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
654
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.24M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.23M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.23M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
654
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE43EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
654
        for (auto& then_ptr : then_columns) {
218
654
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
654
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
672
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
654
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
654
            const auto* __restrict column_raw_data =
246
654
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
654
                            then_columns[i].get())
248
654
                            ->get_data()
249
654
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
654
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.24M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.23M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.23M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
654
        }
274
18
    }
_ZNK5doris9VCaseExpr23update_result_auto_simdIhNS_12ColumnVectorILNS_13PrimitiveTypeE42EEEEEvRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EEPKT_RSt6vectorINS7_13immutable_ptrIS6_EESaISG_EEm
Line
Count
Source
216
18
                                 std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
217
654
        for (auto& then_ptr : then_columns) {
218
654
            then_ptr = then_ptr->convert_to_full_column_if_const();
219
654
        }
220
221
18
        result_column_ptr->resize(rows_count);
222
18
        auto* __restrict result_raw_data =
223
18
                assert_cast<ColumnType*, TypeCheckOnRelease::DISABLE>(result_column_ptr.get())
224
18
                        ->get_data()
225
18
                        .data();
226
227
        // set default value
228
24.7k
        for (int i = 0; i < rows_count; i++) {
229
            if constexpr (std::is_same_v<ColumnType, ColumnDate> ||
230
                          std::is_same_v<ColumnType, ColumnDateTime> ||
231
                          std::is_same_v<ColumnType, ColumnDateV2> ||
232
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
233
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
234
24.7k
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
235
24.7k
                result_raw_data[i] = ColumnType::default_value();
236
            } else {
237
                result_raw_data[i] = {};
238
            }
239
24.7k
        }
240
241
672
        for (IndexType i = 0; i < then_columns.size(); i++) {
242
654
            if (!then_columns[i]) {
243
0
                continue;
244
0
            }
245
654
            const auto* __restrict column_raw_data =
246
654
                    assert_cast<const ColumnType*, TypeCheckOnRelease::DISABLE>(
247
654
                            then_columns[i].get())
248
654
                            ->get_data()
249
654
                            .data();
250
            if constexpr (std::is_same_v<ColumnType, ColumnFloat32> ||
251
                          std::is_same_v<ColumnType, ColumnFloat64> ||
252
                          std::is_same_v<ColumnType, ColumnDate> ||
253
                          std::is_same_v<ColumnType, ColumnDateTime> ||
254
                          std::is_same_v<ColumnType, ColumnDateV2> ||
255
                          std::is_same_v<ColumnType, ColumnDateTimeV2> ||
256
                          std::is_same_v<ColumnType, ColumnTimeStampNs> ||
257
654
                          std::is_same_v<ColumnType, ColumnTimeStampTz>) {
258
                // Arithmetic masking propagates unselected NaN/Infinity and loses signed zero.
259
                // Conditional stores also let the compiler vectorize without loading from a
260
                // selected source/destination pointer, as a ternary assignment can do.
261
2.24M
                for (size_t row_idx = 0; row_idx < rows_count; row_idx++) {
262
2.23M
                    if (then_idx[row_idx] == i) {
263
24.7k
                        result_raw_data[row_idx] = column_raw_data[row_idx];
264
24.7k
                    }
265
2.23M
                }
266
            } else {
267
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
268
                    result_raw_data[row_idx] +=
269
                            typename ColumnType::value_type(then_idx[row_idx] == i) *
270
                            column_raw_data[row_idx];
271
                }
272
            }
273
654
        }
274
18
    }
275
276
    template <typename IndexType>
277
    ColumnPtr _execute_impl(const std::vector<ColumnPtr>& when_columns,
278
587
                            std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
279
587
        std::vector<IndexType> then_idx(rows_count, 0);
280
587
        IndexType* __restrict then_idx_ptr = then_idx.data();
281
1.08k
        for (IndexType i = 0; i < when_columns.size(); i++) {
282
609
            IndexType column_idx = i + 1;
283
609
            auto [raw_when_column, is_consts] = unpack_if_const(when_columns[i]);
284
285
609
            if (is_consts) {
286
115
                if (raw_when_column->get_bool(0)) {
287
1.07k
                    for (int row_idx = 0; row_idx < rows_count; row_idx++) {
288
964
                        then_idx_ptr[row_idx] |= (!then_idx_ptr[row_idx]) * column_idx;
289
964
                    }
290
115
                    break;
291
115
                }
292
0
                continue;
293
115
            }
294
295
494
            if (is_column_nullable(*raw_when_column)) {
296
357
                const auto* column_nullable_ptr =
297
357
                        assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
298
357
                                raw_when_column.get());
299
357
                const auto* __restrict cond_raw_data =
300
357
                        assert_cast<const ColumnUInt8*, TypeCheckOnRelease::DISABLE>(
301
357
                                column_nullable_ptr->get_nested_column_ptr().get())
302
357
                                ->get_data()
303
357
                                .data();
304
357
                if (!column_nullable_ptr->has_null()) {
305
530k
                    for (int row_idx = 0; row_idx < rows_count; row_idx++) {
306
530k
                        then_idx_ptr[row_idx] |=
307
530k
                                (!then_idx_ptr[row_idx]) * cond_raw_data[row_idx] * column_idx;
308
530k
                    }
309
285
                    continue;
310
285
                }
311
72
                const auto* __restrict cond_raw_nullmap =
312
72
                        column_nullable_ptr->get_null_map_column_ptr()->get_data().data();
313
200k
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
314
200k
                    then_idx_ptr[row_idx] |= (!then_idx_ptr[row_idx] * cond_raw_data[row_idx] *
315
200k
                                              !cond_raw_nullmap[row_idx]) *
316
200k
                                             column_idx;
317
200k
                }
318
137
            } else {
319
137
                const auto* __restrict cond_raw_data =
320
137
                        assert_cast<const ColumnUInt8*, TypeCheckOnRelease::DISABLE>(
321
137
                                raw_when_column.get())
322
137
                                ->get_data()
323
137
                                .data();
324
33.2k
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
325
33.1k
                    then_idx_ptr[row_idx] |=
326
33.1k
                            (!then_idx_ptr[row_idx]) * cond_raw_data[row_idx] * column_idx;
327
33.1k
                }
328
137
            }
329
494
        }
330
331
587
        return _execute_update_result<IndexType>(then_idx_ptr, then_columns, rows_count);
332
587
    }
Unexecuted instantiation: _ZNK5doris9VCaseExpr13_execute_implItEENS_3COWINS_7IColumnEE13immutable_ptrIS3_EERKSt6vectorIS6_SaIS6_EERS9_m
_ZNK5doris9VCaseExpr13_execute_implIhEENS_3COWINS_7IColumnEE13immutable_ptrIS3_EERKSt6vectorIS6_SaIS6_EERS9_m
Line
Count
Source
278
587
                            std::vector<ColumnPtr>& then_columns, size_t rows_count) const {
279
587
        std::vector<IndexType> then_idx(rows_count, 0);
280
587
        IndexType* __restrict then_idx_ptr = then_idx.data();
281
1.08k
        for (IndexType i = 0; i < when_columns.size(); i++) {
282
609
            IndexType column_idx = i + 1;
283
609
            auto [raw_when_column, is_consts] = unpack_if_const(when_columns[i]);
284
285
609
            if (is_consts) {
286
115
                if (raw_when_column->get_bool(0)) {
287
1.07k
                    for (int row_idx = 0; row_idx < rows_count; row_idx++) {
288
964
                        then_idx_ptr[row_idx] |= (!then_idx_ptr[row_idx]) * column_idx;
289
964
                    }
290
115
                    break;
291
115
                }
292
0
                continue;
293
115
            }
294
295
494
            if (is_column_nullable(*raw_when_column)) {
296
357
                const auto* column_nullable_ptr =
297
357
                        assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(
298
357
                                raw_when_column.get());
299
357
                const auto* __restrict cond_raw_data =
300
357
                        assert_cast<const ColumnUInt8*, TypeCheckOnRelease::DISABLE>(
301
357
                                column_nullable_ptr->get_nested_column_ptr().get())
302
357
                                ->get_data()
303
357
                                .data();
304
357
                if (!column_nullable_ptr->has_null()) {
305
530k
                    for (int row_idx = 0; row_idx < rows_count; row_idx++) {
306
530k
                        then_idx_ptr[row_idx] |=
307
530k
                                (!then_idx_ptr[row_idx]) * cond_raw_data[row_idx] * column_idx;
308
530k
                    }
309
285
                    continue;
310
285
                }
311
72
                const auto* __restrict cond_raw_nullmap =
312
72
                        column_nullable_ptr->get_null_map_column_ptr()->get_data().data();
313
200k
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
314
200k
                    then_idx_ptr[row_idx] |= (!then_idx_ptr[row_idx] * cond_raw_data[row_idx] *
315
200k
                                              !cond_raw_nullmap[row_idx]) *
316
200k
                                             column_idx;
317
200k
                }
318
137
            } else {
319
137
                const auto* __restrict cond_raw_data =
320
137
                        assert_cast<const ColumnUInt8*, TypeCheckOnRelease::DISABLE>(
321
137
                                raw_when_column.get())
322
137
                                ->get_data()
323
137
                                .data();
324
33.2k
                for (int row_idx = 0; row_idx < rows_count; row_idx++) {
325
33.1k
                    then_idx_ptr[row_idx] |=
326
33.1k
                            (!then_idx_ptr[row_idx]) * cond_raw_data[row_idx] * column_idx;
327
33.1k
                }
328
137
            }
329
494
        }
330
331
587
        return _execute_update_result<IndexType>(then_idx_ptr, then_columns, rows_count);
332
587
    }
333
334
    bool _has_else_expr;
335
336
    inline static const std::string FUNCTION_NAME = "case";
337
    inline static const std::string EXPR_NAME = "vcase expr";
338
};
339
} // namespace doris