be/src/exprs/aggregate/aggregate_function_reader_replace.cpp
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 | | // Self-contained implementation for replace/replace_if_not_null reader/load aggregation. |
19 | | // Deliberately does NOT include aggregate_function_reader_first_last.h to avoid pulling in |
20 | | // heavy template machinery shared with the window-function path. |
21 | | |
22 | | #include "core/column/column_nullable.h" |
23 | | #include "core/field.h" |
24 | | #include "exprs/aggregate/aggregate_function.h" |
25 | | #include "exprs/aggregate/aggregate_function_reader.h" |
26 | | #include "exprs/aggregate/aggregate_function_simple_factory.h" |
27 | | |
28 | | namespace doris { |
29 | | #include "common/compile_check_begin.h" |
30 | | |
31 | | // --------------------------------------------------------------------------- |
32 | | // Storage layer: PointerStore / CopyStore |
33 | | // Uniform interface: is_null(), set_value<SkipNull>(), insert_into(), reset(). |
34 | | // set_value returns false when SkipNull && the row is null (caller should not |
35 | | // update _has_value); returns true otherwise. |
36 | | // --------------------------------------------------------------------------- |
37 | | |
38 | | // Zero-copy storage: keeps a pointer into the source column (reader path). |
39 | | template <bool ArgIsNullable> |
40 | | struct PointerStore { |
41 | | const IColumn* _ptr = nullptr; |
42 | | size_t _offset = 0; |
43 | | |
44 | 21 | bool is_null() const { |
45 | 21 | if (_ptr == nullptr) { |
46 | 0 | return true; |
47 | 0 | } |
48 | 21 | if constexpr (ArgIsNullable) { |
49 | 21 | return assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(_ptr) |
50 | 21 | ->is_null_at(_offset); |
51 | 21 | } |
52 | 0 | return false; |
53 | 21 | } Unexecuted instantiation: _ZNK5doris12PointerStoreILb0EE7is_nullEv _ZNK5doris12PointerStoreILb1EE7is_nullEv Line | Count | Source | 44 | 21 | bool is_null() const { | 45 | 21 | if (_ptr == nullptr) { | 46 | 0 | return true; | 47 | 0 | } | 48 | 21 | if constexpr (ArgIsNullable) { | 49 | 21 | return assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(_ptr) | 50 | 21 | ->is_null_at(_offset); | 51 | 21 | } | 52 | 0 | return false; | 53 | 21 | } |
|
54 | | |
55 | | template <bool SkipNull> |
56 | 437 | bool set_value(const IColumn* column, size_t row) { |
57 | 437 | if constexpr (SkipNull && ArgIsNullable) { |
58 | 5 | const auto* nc = |
59 | 5 | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); |
60 | 5 | if (nc->is_null_at(row)) { |
61 | 1 | return false; |
62 | 1 | } |
63 | 5 | } |
64 | 4 | _ptr = column; |
65 | 437 | _offset = row; |
66 | 437 | return true; |
67 | 437 | } _ZN5doris12PointerStoreILb0EE9set_valueILb0EEEbPKNS_7IColumnEm Line | Count | Source | 56 | 223 | bool set_value(const IColumn* column, size_t row) { | 57 | | if constexpr (SkipNull && ArgIsNullable) { | 58 | | const auto* nc = | 59 | | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); | 60 | | if (nc->is_null_at(row)) { | 61 | | return false; | 62 | | } | 63 | | } | 64 | 223 | _ptr = column; | 65 | 223 | _offset = row; | 66 | 223 | return true; | 67 | 223 | } |
_ZN5doris12PointerStoreILb1EE9set_valueILb0EEEbPKNS_7IColumnEm Line | Count | Source | 56 | 209 | bool set_value(const IColumn* column, size_t row) { | 57 | | if constexpr (SkipNull && ArgIsNullable) { | 58 | | const auto* nc = | 59 | | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); | 60 | | if (nc->is_null_at(row)) { | 61 | | return false; | 62 | | } | 63 | | } | 64 | 209 | _ptr = column; | 65 | 209 | _offset = row; | 66 | 209 | return true; | 67 | 209 | } |
Unexecuted instantiation: _ZN5doris12PointerStoreILb0EE9set_valueILb1EEEbPKNS_7IColumnEm _ZN5doris12PointerStoreILb1EE9set_valueILb1EEEbPKNS_7IColumnEm Line | Count | Source | 56 | 5 | bool set_value(const IColumn* column, size_t row) { | 57 | 5 | if constexpr (SkipNull && ArgIsNullable) { | 58 | 5 | const auto* nc = | 59 | 5 | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); | 60 | 5 | if (nc->is_null_at(row)) { | 61 | 1 | return false; | 62 | 1 | } | 63 | 5 | } | 64 | 4 | _ptr = column; | 65 | 5 | _offset = row; | 66 | 5 | return true; | 67 | 5 | } |
|
68 | | |
69 | 51 | void insert_into(IColumn& to) const { |
70 | 51 | if constexpr (ArgIsNullable) { |
71 | 21 | const auto* nc = assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(_ptr); |
72 | 21 | to.insert_from(nc->get_nested_column(), _offset); |
73 | 30 | } else { |
74 | 30 | to.insert_from(*_ptr, _offset); |
75 | 30 | } |
76 | 51 | } _ZNK5doris12PointerStoreILb0EE11insert_intoERNS_7IColumnE Line | Count | Source | 69 | 30 | void insert_into(IColumn& to) const { | 70 | | if constexpr (ArgIsNullable) { | 71 | | const auto* nc = assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(_ptr); | 72 | | to.insert_from(nc->get_nested_column(), _offset); | 73 | 30 | } else { | 74 | 30 | to.insert_from(*_ptr, _offset); | 75 | 30 | } | 76 | 30 | } |
_ZNK5doris12PointerStoreILb1EE11insert_intoERNS_7IColumnE Line | Count | Source | 69 | 21 | void insert_into(IColumn& to) const { | 70 | 21 | if constexpr (ArgIsNullable) { | 71 | 21 | const auto* nc = assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(_ptr); | 72 | 21 | to.insert_from(nc->get_nested_column(), _offset); | 73 | | } else { | 74 | | to.insert_from(*_ptr, _offset); | 75 | | } | 76 | 21 | } |
|
77 | | |
78 | 0 | void reset() { |
79 | 0 | _ptr = nullptr; |
80 | 0 | _offset = 0; |
81 | 0 | } Unexecuted instantiation: _ZN5doris12PointerStoreILb0EE5resetEv Unexecuted instantiation: _ZN5doris12PointerStoreILb1EE5resetEv |
82 | | }; |
83 | | |
84 | | // Deep-copy storage: copies the value into a Field (load path). |
85 | | template <bool ArgIsNullable> |
86 | | struct CopyStore { |
87 | | Field _value; |
88 | | bool _is_null = true; |
89 | | |
90 | 20 | bool is_null() const { return _is_null; }Unexecuted instantiation: _ZNK5doris9CopyStoreILb0EE7is_nullEv _ZNK5doris9CopyStoreILb1EE7is_nullEv Line | Count | Source | 90 | 20 | bool is_null() const { return _is_null; } |
|
91 | | |
92 | | template <bool SkipNull> |
93 | 41 | bool set_value(const IColumn* column, size_t row) { |
94 | 41 | if constexpr (ArgIsNullable) { |
95 | 20 | const auto* nc = |
96 | 20 | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); |
97 | 20 | if (nc->is_null_at(row)) { |
98 | 0 | if constexpr (SkipNull) { |
99 | 0 | return false; |
100 | 0 | } |
101 | 0 | _is_null = true; |
102 | 0 | return true; |
103 | 0 | } |
104 | 20 | nc->get_nested_column().get(row, _value); |
105 | 21 | } else { |
106 | 21 | column->get(row, _value); |
107 | 21 | } |
108 | 0 | _is_null = false; |
109 | 41 | return true; |
110 | 41 | } _ZN5doris9CopyStoreILb0EE9set_valueILb0EEEbPKNS_7IColumnEm Line | Count | Source | 93 | 21 | bool set_value(const IColumn* column, size_t row) { | 94 | | if constexpr (ArgIsNullable) { | 95 | | const auto* nc = | 96 | | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); | 97 | | if (nc->is_null_at(row)) { | 98 | | if constexpr (SkipNull) { | 99 | | return false; | 100 | | } | 101 | | _is_null = true; | 102 | | return true; | 103 | | } | 104 | | nc->get_nested_column().get(row, _value); | 105 | 21 | } else { | 106 | 21 | column->get(row, _value); | 107 | 21 | } | 108 | 21 | _is_null = false; | 109 | 21 | return true; | 110 | 21 | } |
_ZN5doris9CopyStoreILb1EE9set_valueILb0EEEbPKNS_7IColumnEm Line | Count | Source | 93 | 20 | bool set_value(const IColumn* column, size_t row) { | 94 | 20 | if constexpr (ArgIsNullable) { | 95 | 20 | const auto* nc = | 96 | 20 | assert_cast<const ColumnNullable*, TypeCheckOnRelease::DISABLE>(column); | 97 | 20 | if (nc->is_null_at(row)) { | 98 | | if constexpr (SkipNull) { | 99 | | return false; | 100 | | } | 101 | 0 | _is_null = true; | 102 | 0 | return true; | 103 | 0 | } | 104 | 20 | nc->get_nested_column().get(row, _value); | 105 | | } else { | 106 | | column->get(row, _value); | 107 | | } | 108 | 0 | _is_null = false; | 109 | 20 | return true; | 110 | 20 | } |
Unexecuted instantiation: _ZN5doris9CopyStoreILb0EE9set_valueILb1EEEbPKNS_7IColumnEm Unexecuted instantiation: _ZN5doris9CopyStoreILb1EE9set_valueILb1EEEbPKNS_7IColumnEm |
111 | | |
112 | 41 | void insert_into(IColumn& to) const { to.insert(_value); }_ZNK5doris9CopyStoreILb0EE11insert_intoERNS_7IColumnE Line | Count | Source | 112 | 21 | void insert_into(IColumn& to) const { to.insert(_value); } |
_ZNK5doris9CopyStoreILb1EE11insert_intoERNS_7IColumnE Line | Count | Source | 112 | 20 | void insert_into(IColumn& to) const { to.insert(_value); } |
|
113 | | |
114 | 0 | void reset() { |
115 | 0 | _is_null = true; |
116 | 0 | _value = {}; |
117 | 0 | } Unexecuted instantiation: _ZN5doris9CopyStoreILb0EE5resetEv Unexecuted instantiation: _ZN5doris9CopyStoreILb1EE5resetEv |
118 | | }; |
119 | | |
120 | | // --------------------------------------------------------------------------- |
121 | | // Data layer: ReaderReplaceData |
122 | | // Template params: IsFirst, SkipNull, ArgIsNullable |
123 | | // IsCopy is derived: reader (IsFirst=true) deep-copies via Field because the source |
124 | | // column will be reused; load (IsFirst=false) keeps a zero-copy pointer because |
125 | | // insert_result_into is called while the column is still alive. |
126 | | // --------------------------------------------------------------------------- |
127 | | template <bool IsFirst, bool SkipNull, bool ArgIsNullable> |
128 | | struct ReaderReplaceData { |
129 | | static constexpr bool IsCopy = IsFirst; |
130 | | using Store = std::conditional_t<IsCopy, CopyStore<ArgIsNullable>, PointerStore<ArgIsNullable>>; |
131 | | |
132 | | Store _store; |
133 | | bool _has_value = false; |
134 | | |
135 | 865 | void add(int64_t row, const IColumn** columns) { |
136 | 865 | if constexpr (IsFirst) { |
137 | 428 | if (_has_value) { |
138 | 387 | return; |
139 | 387 | } |
140 | 428 | } |
141 | 865 | if (_store.template set_value<SkipNull>(columns[0], row)) { |
142 | 477 | _has_value = true; |
143 | 477 | } |
144 | 865 | } _ZN5doris17ReaderReplaceDataILb1ELb0ELb0EE3addElPPKNS_7IColumnE Line | Count | Source | 135 | 219 | void add(int64_t row, const IColumn** columns) { | 136 | 219 | if constexpr (IsFirst) { | 137 | 219 | if (_has_value) { | 138 | 198 | return; | 139 | 198 | } | 140 | 219 | } | 141 | 219 | if (_store.template set_value<SkipNull>(columns[0], row)) { | 142 | 21 | _has_value = true; | 143 | 21 | } | 144 | 219 | } |
_ZN5doris17ReaderReplaceDataILb1ELb0ELb1EE3addElPPKNS_7IColumnE Line | Count | Source | 135 | 209 | void add(int64_t row, const IColumn** columns) { | 136 | 209 | if constexpr (IsFirst) { | 137 | 209 | if (_has_value) { | 138 | 189 | return; | 139 | 189 | } | 140 | 209 | } | 141 | 209 | if (_store.template set_value<SkipNull>(columns[0], row)) { | 142 | 20 | _has_value = true; | 143 | 20 | } | 144 | 209 | } |
_ZN5doris17ReaderReplaceDataILb0ELb0ELb0EE3addElPPKNS_7IColumnE Line | Count | Source | 135 | 223 | void add(int64_t row, const IColumn** columns) { | 136 | | if constexpr (IsFirst) { | 137 | | if (_has_value) { | 138 | | return; | 139 | | } | 140 | | } | 141 | 223 | if (_store.template set_value<SkipNull>(columns[0], row)) { | 142 | 223 | _has_value = true; | 143 | 223 | } | 144 | 223 | } |
_ZN5doris17ReaderReplaceDataILb0ELb0ELb1EE3addElPPKNS_7IColumnE Line | Count | Source | 135 | 209 | void add(int64_t row, const IColumn** columns) { | 136 | | if constexpr (IsFirst) { | 137 | | if (_has_value) { | 138 | | return; | 139 | | } | 140 | | } | 141 | 209 | if (_store.template set_value<SkipNull>(columns[0], row)) { | 142 | 209 | _has_value = true; | 143 | 209 | } | 144 | 209 | } |
Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb1ELb1ELb0EE3addElPPKNS_7IColumnE Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb1ELb1ELb1EE3addElPPKNS_7IColumnE Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb0ELb1ELb0EE3addElPPKNS_7IColumnE _ZN5doris17ReaderReplaceDataILb0ELb1ELb1EE3addElPPKNS_7IColumnE Line | Count | Source | 135 | 5 | void add(int64_t row, const IColumn** columns) { | 136 | | if constexpr (IsFirst) { | 137 | | if (_has_value) { | 138 | | return; | 139 | | } | 140 | | } | 141 | 5 | if (_store.template set_value<SkipNull>(columns[0], row)) { | 142 | 4 | _has_value = true; | 143 | 4 | } | 144 | 5 | } |
|
145 | | |
146 | 92 | void insert_result_into(IColumn& to, bool result_is_nullable) const { |
147 | 92 | if (result_is_nullable) { |
148 | 41 | auto& nullable_col = assert_cast<ColumnNullable&>(to); |
149 | 41 | if (!_has_value || _store.is_null()) { |
150 | 0 | nullable_col.insert_default(); |
151 | 41 | } else { |
152 | 41 | nullable_col.get_null_map_data().push_back(0); |
153 | 41 | _store.insert_into(nullable_col.get_nested_column()); |
154 | 41 | } |
155 | 51 | } else { |
156 | 51 | _store.insert_into(to); |
157 | 51 | } |
158 | 92 | } _ZNK5doris17ReaderReplaceDataILb1ELb0ELb0EE18insert_result_intoERNS_7IColumnEb Line | Count | Source | 146 | 21 | void insert_result_into(IColumn& to, bool result_is_nullable) const { | 147 | 21 | if (result_is_nullable) { | 148 | 0 | auto& nullable_col = assert_cast<ColumnNullable&>(to); | 149 | 0 | if (!_has_value || _store.is_null()) { | 150 | 0 | nullable_col.insert_default(); | 151 | 0 | } else { | 152 | 0 | nullable_col.get_null_map_data().push_back(0); | 153 | 0 | _store.insert_into(nullable_col.get_nested_column()); | 154 | 0 | } | 155 | 21 | } else { | 156 | 21 | _store.insert_into(to); | 157 | 21 | } | 158 | 21 | } |
_ZNK5doris17ReaderReplaceDataILb1ELb0ELb1EE18insert_result_intoERNS_7IColumnEb Line | Count | Source | 146 | 20 | void insert_result_into(IColumn& to, bool result_is_nullable) const { | 147 | 20 | if (result_is_nullable) { | 148 | 20 | auto& nullable_col = assert_cast<ColumnNullable&>(to); | 149 | 20 | if (!_has_value || _store.is_null()) { | 150 | 0 | nullable_col.insert_default(); | 151 | 20 | } else { | 152 | 20 | nullable_col.get_null_map_data().push_back(0); | 153 | 20 | _store.insert_into(nullable_col.get_nested_column()); | 154 | 20 | } | 155 | 20 | } else { | 156 | 0 | _store.insert_into(to); | 157 | 0 | } | 158 | 20 | } |
_ZNK5doris17ReaderReplaceDataILb0ELb0ELb0EE18insert_result_intoERNS_7IColumnEb Line | Count | Source | 146 | 30 | void insert_result_into(IColumn& to, bool result_is_nullable) const { | 147 | 30 | if (result_is_nullable) { | 148 | 0 | auto& nullable_col = assert_cast<ColumnNullable&>(to); | 149 | 0 | if (!_has_value || _store.is_null()) { | 150 | 0 | nullable_col.insert_default(); | 151 | 0 | } else { | 152 | 0 | nullable_col.get_null_map_data().push_back(0); | 153 | 0 | _store.insert_into(nullable_col.get_nested_column()); | 154 | 0 | } | 155 | 30 | } else { | 156 | 30 | _store.insert_into(to); | 157 | 30 | } | 158 | 30 | } |
_ZNK5doris17ReaderReplaceDataILb0ELb0ELb1EE18insert_result_intoERNS_7IColumnEb Line | Count | Source | 146 | 20 | void insert_result_into(IColumn& to, bool result_is_nullable) const { | 147 | 20 | if (result_is_nullable) { | 148 | 20 | auto& nullable_col = assert_cast<ColumnNullable&>(to); | 149 | 20 | if (!_has_value || _store.is_null()) { | 150 | 0 | nullable_col.insert_default(); | 151 | 20 | } else { | 152 | 20 | nullable_col.get_null_map_data().push_back(0); | 153 | 20 | _store.insert_into(nullable_col.get_nested_column()); | 154 | 20 | } | 155 | 20 | } else { | 156 | 0 | _store.insert_into(to); | 157 | 0 | } | 158 | 20 | } |
Unexecuted instantiation: _ZNK5doris17ReaderReplaceDataILb1ELb1ELb0EE18insert_result_intoERNS_7IColumnEb Unexecuted instantiation: _ZNK5doris17ReaderReplaceDataILb1ELb1ELb1EE18insert_result_intoERNS_7IColumnEb Unexecuted instantiation: _ZNK5doris17ReaderReplaceDataILb0ELb1ELb0EE18insert_result_intoERNS_7IColumnEb _ZNK5doris17ReaderReplaceDataILb0ELb1ELb1EE18insert_result_intoERNS_7IColumnEb Line | Count | Source | 146 | 1 | void insert_result_into(IColumn& to, bool result_is_nullable) const { | 147 | 1 | if (result_is_nullable) { | 148 | 1 | auto& nullable_col = assert_cast<ColumnNullable&>(to); | 149 | 1 | if (!_has_value || _store.is_null()) { | 150 | 0 | nullable_col.insert_default(); | 151 | 1 | } else { | 152 | 1 | nullable_col.get_null_map_data().push_back(0); | 153 | 1 | _store.insert_into(nullable_col.get_nested_column()); | 154 | 1 | } | 155 | 1 | } else { | 156 | 0 | _store.insert_into(to); | 157 | 0 | } | 158 | 1 | } |
|
159 | | |
160 | 0 | void reset() { |
161 | 0 | _has_value = false; |
162 | 0 | _store.reset(); |
163 | 0 | } Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb1ELb0ELb0EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb1ELb0ELb1EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb0ELb0ELb0EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb0ELb0ELb1EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb1ELb1ELb0EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb1ELb1ELb1EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb0ELb1ELb0EE5resetEv Unexecuted instantiation: _ZN5doris17ReaderReplaceDataILb0ELb1ELb1EE5resetEv |
164 | | }; |
165 | | |
166 | | // --------------------------------------------------------------------------- |
167 | | // Aggregate function class |
168 | | // --------------------------------------------------------------------------- |
169 | | template <bool IsFirst, bool SkipNull, bool ArgIsNullable> |
170 | | class ReaderReplaceFunction final |
171 | | : public IAggregateFunctionDataHelper< |
172 | | ReaderReplaceData<IsFirst, SkipNull, ArgIsNullable>, |
173 | | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>> { |
174 | | using Data = ReaderReplaceData<IsFirst, SkipNull, ArgIsNullable>; |
175 | | |
176 | | public: |
177 | | ReaderReplaceFunction(const DataTypes& argument_types_, bool result_is_nullable) |
178 | 107 | : IAggregateFunctionDataHelper<Data, |
179 | 107 | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( |
180 | 107 | argument_types_), |
181 | 107 | _argument_type(argument_types_[0]), |
182 | 107 | _result_is_nullable(result_is_nullable) {}_ZN5doris21ReaderReplaceFunctionILb1ELb0ELb0EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Line | Count | Source | 178 | 21 | : IAggregateFunctionDataHelper<Data, | 179 | 21 | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 180 | 21 | argument_types_), | 181 | 21 | _argument_type(argument_types_[0]), | 182 | 21 | _result_is_nullable(result_is_nullable) {} |
_ZN5doris21ReaderReplaceFunctionILb1ELb0ELb1EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Line | Count | Source | 178 | 20 | : IAggregateFunctionDataHelper<Data, | 179 | 20 | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 180 | 20 | argument_types_), | 181 | 20 | _argument_type(argument_types_[0]), | 182 | 20 | _result_is_nullable(result_is_nullable) {} |
_ZN5doris21ReaderReplaceFunctionILb0ELb0ELb0EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Line | Count | Source | 178 | 45 | : IAggregateFunctionDataHelper<Data, | 179 | 45 | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 180 | 45 | argument_types_), | 181 | 45 | _argument_type(argument_types_[0]), | 182 | 45 | _result_is_nullable(result_is_nullable) {} |
_ZN5doris21ReaderReplaceFunctionILb0ELb0ELb1EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Line | Count | Source | 178 | 20 | : IAggregateFunctionDataHelper<Data, | 179 | 20 | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 180 | 20 | argument_types_), | 181 | 20 | _argument_type(argument_types_[0]), | 182 | 20 | _result_is_nullable(result_is_nullable) {} |
Unexecuted instantiation: _ZN5doris21ReaderReplaceFunctionILb1ELb1ELb0EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Unexecuted instantiation: _ZN5doris21ReaderReplaceFunctionILb1ELb1ELb1EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Unexecuted instantiation: _ZN5doris21ReaderReplaceFunctionILb0ELb1ELb0EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb _ZN5doris21ReaderReplaceFunctionILb0ELb1ELb1EEC2ERKSt6vectorISt10shared_ptrIKNS_9IDataTypeEESaIS6_EEb Line | Count | Source | 178 | 1 | : IAggregateFunctionDataHelper<Data, | 179 | 1 | ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 180 | 1 | argument_types_), | 181 | 1 | _argument_type(argument_types_[0]), | 182 | 1 | _result_is_nullable(result_is_nullable) {} |
|
183 | | |
184 | 0 | String get_name() const override { return "reader_replace"; }Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE8get_nameB5cxx11Ev Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE8get_nameB5cxx11Ev |
185 | | |
186 | 0 | DataTypePtr get_return_type() const override { |
187 | 0 | if (_result_is_nullable) { |
188 | 0 | return make_nullable(_argument_type); |
189 | 0 | } |
190 | 0 | return _argument_type; |
191 | 0 | } Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE15get_return_typeEv Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE15get_return_typeEv |
192 | | |
193 | | void add(AggregateDataPtr place, const IColumn** columns, ssize_t row_num, |
194 | 865 | Arena&) const override { |
195 | 865 | this->data(place).add(row_num, columns); |
196 | 865 | } _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Line | Count | Source | 194 | 219 | Arena&) const override { | 195 | 219 | this->data(place).add(row_num, columns); | 196 | 219 | } |
_ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Line | Count | Source | 194 | 209 | Arena&) const override { | 195 | 209 | this->data(place).add(row_num, columns); | 196 | 209 | } |
_ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Line | Count | Source | 194 | 223 | Arena&) const override { | 195 | 223 | this->data(place).add(row_num, columns); | 196 | 223 | } |
_ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Line | Count | Source | 194 | 209 | Arena&) const override { | 195 | 209 | this->data(place).add(row_num, columns); | 196 | 209 | } |
Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE3addEPcPPKNS_7IColumnElRNS_5ArenaE _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE3addEPcPPKNS_7IColumnElRNS_5ArenaE Line | Count | Source | 194 | 5 | Arena&) const override { | 195 | 5 | this->data(place).add(row_num, columns); | 196 | 5 | } |
|
197 | | |
198 | 92 | void insert_result_into(ConstAggregateDataPtr place, IColumn& to) const override { |
199 | 92 | this->data(place).insert_result_into(to, _result_is_nullable); |
200 | 92 | } _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE18insert_result_intoEPKcRNS_7IColumnE Line | Count | Source | 198 | 21 | void insert_result_into(ConstAggregateDataPtr place, IColumn& to) const override { | 199 | 21 | this->data(place).insert_result_into(to, _result_is_nullable); | 200 | 21 | } |
_ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE18insert_result_intoEPKcRNS_7IColumnE Line | Count | Source | 198 | 20 | void insert_result_into(ConstAggregateDataPtr place, IColumn& to) const override { | 199 | 20 | this->data(place).insert_result_into(to, _result_is_nullable); | 200 | 20 | } |
_ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE18insert_result_intoEPKcRNS_7IColumnE Line | Count | Source | 198 | 30 | void insert_result_into(ConstAggregateDataPtr place, IColumn& to) const override { | 199 | 30 | this->data(place).insert_result_into(to, _result_is_nullable); | 200 | 30 | } |
_ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE18insert_result_intoEPKcRNS_7IColumnE Line | Count | Source | 198 | 20 | void insert_result_into(ConstAggregateDataPtr place, IColumn& to) const override { | 199 | 20 | this->data(place).insert_result_into(to, _result_is_nullable); | 200 | 20 | } |
Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE18insert_result_intoEPKcRNS_7IColumnE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE18insert_result_intoEPKcRNS_7IColumnE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE18insert_result_intoEPKcRNS_7IColumnE _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE18insert_result_intoEPKcRNS_7IColumnE Line | Count | Source | 198 | 1 | void insert_result_into(ConstAggregateDataPtr place, IColumn& to) const override { | 199 | 1 | this->data(place).insert_result_into(to, _result_is_nullable); | 200 | 1 | } |
|
201 | | |
202 | 0 | void reset(AggregateDataPtr place) const override { this->data(place).reset(); }Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE5resetEPc Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE5resetEPc |
203 | | |
204 | | void add_range_single_place(int64_t, int64_t, int64_t, int64_t, AggregateDataPtr, |
205 | 0 | const IColumn**, Arena&, UInt8*, UInt8*) const override { |
206 | 0 | throw doris::Exception(Status::FatalError( |
207 | 0 | "ReaderReplaceFunction does not support add_range_single_place")); |
208 | 0 | } Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE22add_range_single_placeEllllPcPPKNS_7IColumnERNS_5ArenaEPhS9_ |
209 | 0 | void merge(AggregateDataPtr, ConstAggregateDataPtr, Arena&) const override { |
210 | 0 | throw doris::Exception(Status::FatalError("ReaderReplaceFunction does not support merge")); |
211 | 0 | } Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE5mergeEPcPKcRNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE5mergeEPcPKcRNS_5ArenaE |
212 | 0 | void serialize(ConstAggregateDataPtr, BufferWritable&) const override { |
213 | 0 | throw doris::Exception( |
214 | 0 | Status::FatalError("ReaderReplaceFunction does not support serialize")); |
215 | 0 | } Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE9serializeEPKcRNS_14BufferWritableE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE9serializeEPKcRNS_14BufferWritableE |
216 | 0 | void deserialize(AggregateDataPtr, BufferReadable&, Arena&) const override { |
217 | 0 | throw doris::Exception( |
218 | 0 | Status::FatalError("ReaderReplaceFunction does not support deserialize")); |
219 | 0 | } Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb0EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb0ELb1EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb0EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb0ELb1EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb0EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb1ELb1ELb1EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb0EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE Unexecuted instantiation: _ZNK5doris21ReaderReplaceFunctionILb0ELb1ELb1EE11deserializeEPcRNS_14BufferReadableERNS_5ArenaE |
220 | | |
221 | | private: |
222 | | DataTypePtr _argument_type; |
223 | | bool _result_is_nullable; |
224 | | }; |
225 | | |
226 | | // --------------------------------------------------------------------------- |
227 | | // Factory helpers |
228 | | // --------------------------------------------------------------------------- |
229 | | template <bool IsFirst, bool SkipNull, bool ArgIsNullable> |
230 | | static AggregateFunctionPtr create_reader_replace(const std::string& /*name*/, |
231 | | const DataTypes& argument_types_, |
232 | | const DataTypePtr& /*result_type*/, |
233 | | bool result_is_nullable, |
234 | 107 | const AggregateFunctionAttr& /*attr*/) { |
235 | 107 | return std::make_shared<ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( |
236 | 107 | argument_types_, result_is_nullable); |
237 | 107 | } aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb1ELb0ELb0EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Line | Count | Source | 234 | 21 | const AggregateFunctionAttr& /*attr*/) { | 235 | 21 | return std::make_shared<ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 236 | 21 | argument_types_, result_is_nullable); | 237 | 21 | } |
aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb1ELb0ELb1EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Line | Count | Source | 234 | 20 | const AggregateFunctionAttr& /*attr*/) { | 235 | 20 | return std::make_shared<ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 236 | 20 | argument_types_, result_is_nullable); | 237 | 20 | } |
aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb0ELb0ELb0EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Line | Count | Source | 234 | 45 | const AggregateFunctionAttr& /*attr*/) { | 235 | 45 | return std::make_shared<ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 236 | 45 | argument_types_, result_is_nullable); | 237 | 45 | } |
aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb0ELb0ELb1EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Line | Count | Source | 234 | 20 | const AggregateFunctionAttr& /*attr*/) { | 235 | 20 | return std::make_shared<ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 236 | 20 | argument_types_, result_is_nullable); | 237 | 20 | } |
Unexecuted instantiation: aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb1ELb1ELb0EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Unexecuted instantiation: aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb1ELb1ELb1EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Unexecuted instantiation: aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb0ELb1ELb0EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE aggregate_function_reader_replace.cpp:_ZN5dorisL21create_reader_replaceILb0ELb1ELb1EEESt10shared_ptrINS_18IAggregateFunctionEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIS1_IKNS_9IDataTypeEESaISF_EERKSF_bRKNS_21AggregateFunctionAttrE Line | Count | Source | 234 | 1 | const AggregateFunctionAttr& /*attr*/) { | 235 | 1 | return std::make_shared<ReaderReplaceFunction<IsFirst, SkipNull, ArgIsNullable>>( | 236 | 1 | argument_types_, result_is_nullable); | 237 | 1 | } |
|
238 | | |
239 | | // --------------------------------------------------------------------------- |
240 | | // Registration |
241 | | // --------------------------------------------------------------------------- |
242 | | |
243 | | // only replace function in load/reader do different agg operation. |
244 | | // because Doris can ensure that the data is globally ordered in reader, but cannot in load |
245 | | // 1. reader: get the first value of input data (IsFirst=true → CopyStore, deep copy) |
246 | | // 2. load: get the last value of input data (IsFirst=false → PointerStore, zero-copy) |
247 | 9 | void register_aggregate_function_replace_reader_load(AggregateFunctionSimpleFactory& factory) { |
248 | 9 | auto reg = [&](const std::string& name, const std::string& suffix, |
249 | 9 | const AggregateFunctionCreator& creator, |
250 | 72 | bool nullable) { factory.register_function(name + suffix, creator, nullable); }; |
251 | | |
252 | | // IsFirst SkipNull ArgNullable |
253 | | // replace – reader (first, pointer, accept null) |
254 | 9 | reg("replace", AGG_READER_SUFFIX, create_reader_replace<true, false, false>, false); |
255 | 9 | reg("replace", AGG_READER_SUFFIX, create_reader_replace<true, false, true>, true); |
256 | | |
257 | | // replace – load (last, copy, accept null) |
258 | 9 | reg("replace", AGG_LOAD_SUFFIX, create_reader_replace<false, false, false>, false); |
259 | 9 | reg("replace", AGG_LOAD_SUFFIX, create_reader_replace<false, false, true>, true); |
260 | | |
261 | | // replace_if_not_null – reader (first, pointer, skip null) |
262 | 9 | reg("replace_if_not_null", AGG_READER_SUFFIX, create_reader_replace<true, true, false>, false); |
263 | 9 | reg("replace_if_not_null", AGG_READER_SUFFIX, create_reader_replace<true, true, true>, true); |
264 | | |
265 | | // replace_if_not_null – load (last, copy, skip null) |
266 | 9 | reg("replace_if_not_null", AGG_LOAD_SUFFIX, create_reader_replace<false, true, false>, false); |
267 | 9 | reg("replace_if_not_null", AGG_LOAD_SUFFIX, create_reader_replace<false, true, true>, true); |
268 | 9 | } |
269 | | |
270 | | } // namespace doris |