be/src/storage/segment/bitshuffle_page.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 <glog/logging.h> |
21 | | |
22 | | #include <algorithm> |
23 | | #include <cstddef> |
24 | | #include <cstdint> |
25 | | #include <cstring> |
26 | | #include <ostream> |
27 | | #include <type_traits> |
28 | | |
29 | | #include "common/cast_set.h" |
30 | | #include "common/compiler_util.h" // IWYU pragma: keep |
31 | | #include "common/status.h" |
32 | | #include "core/column/column.h" |
33 | | #include "core/data_type/data_type.h" |
34 | | #include "core/types.h" |
35 | | #include "storage/olap_common.h" |
36 | | #include "storage/segment/bitshuffle_wrapper.h" |
37 | | #include "storage/segment/common.h" |
38 | | #include "storage/segment/options.h" |
39 | | #include "storage/segment/page_builder.h" |
40 | | #include "storage/segment/page_decoder.h" |
41 | | #include "storage/types.h" |
42 | | #include "util/alignment.h" |
43 | | #include "util/coding.h" |
44 | | #include "util/faststring.h" |
45 | | #include "util/slice.h" |
46 | | |
47 | | namespace doris { |
48 | | namespace segment_v2 { |
49 | | #include "common/compile_check_begin.h" |
50 | | |
51 | | enum { BITSHUFFLE_PAGE_HEADER_SIZE = 16 }; |
52 | | |
53 | | void warn_with_bitshuffle_error(int64_t val); |
54 | | |
55 | | // BitshufflePageBuilder bitshuffles and compresses the bits of fixed |
56 | | // size type blocks with lz4. |
57 | | // |
58 | | // The page format is as follows: |
59 | | // |
60 | | // 1. Header: (16 bytes total) |
61 | | // |
62 | | // <num_elements> [32-bit] |
63 | | // The number of elements encoded in the page. |
64 | | // |
65 | | // <compressed_size> [32-bit] |
66 | | // The post-compression size of the page, including this header. |
67 | | // |
68 | | // <padded_num_elements> [32-bit] |
69 | | // Padding is needed to meet the requirements of the bitshuffle |
70 | | // library such that the input/output is a multiple of 8. Some |
71 | | // ignored elements are appended to the end of the page if necessary |
72 | | // to meet this requirement. |
73 | | // |
74 | | // This header field is the post-padding element count. |
75 | | // |
76 | | // <elem_size_bytes> [32-bit] |
77 | | // The size of the elements, in bytes, as actually encoded. In the |
78 | | // case that all of the data in a page can fit into a smaller |
79 | | // integer type, then we may choose to encode that smaller type |
80 | | // to save CPU costs. |
81 | | // |
82 | | // This is currently only implemented in the UINT32 page type. |
83 | | // |
84 | | // NOTE: all on-disk ints are encoded little-endian |
85 | | // |
86 | | // 2. Element data |
87 | | // |
88 | | // The header is followed by the bitshuffle-compressed element data. |
89 | | // |
90 | | template <FieldType Type> |
91 | | class BitshufflePageBuilder : public PageBuilderHelper<BitshufflePageBuilder<Type>> { |
92 | | public: |
93 | | using Self = BitshufflePageBuilder<Type>; |
94 | | friend class PageBuilderHelper<Self>; |
95 | | |
96 | 36.1k | Status init() override { return reset(); }_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE4initEv Line | Count | Source | 96 | 32.8k | Status init() override { return reset(); } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE4initEv Line | Count | Source | 96 | 1.24k | Status init() override { return reset(); } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE4initEv Line | Count | Source | 96 | 26 | Status init() override { return reset(); } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE4initEv Line | Count | Source | 96 | 1.28k | Status init() override { return reset(); } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE4initEv Line | Count | Source | 96 | 690 | Status init() override { return reset(); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE4initEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE4initEv Line | Count | Source | 96 | 4 | Status init() override { return reset(); } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE4initEv Line | Count | Source | 96 | 4 | Status init() override { return reset(); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE4initEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE4initEv Line | Count | Source | 96 | 8 | Status init() override { return reset(); } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE4initEv Line | Count | Source | 96 | 14 | Status init() override { return reset(); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE4initEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE4initEv Line | Count | Source | 96 | 22 | Status init() override { return reset(); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE4initEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE4initEv Line | Count | Source | 96 | 4 | Status init() override { return reset(); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE4initEv |
97 | | |
98 | 3.08M | bool is_page_full() override { return _remain_element_capacity == 0; }_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE12is_page_fullEv Line | Count | Source | 98 | 3.04M | bool is_page_full() override { return _remain_element_capacity == 0; } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE12is_page_fullEv Line | Count | Source | 98 | 2.80k | bool is_page_full() override { return _remain_element_capacity == 0; } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE12is_page_fullEv Line | Count | Source | 98 | 26 | bool is_page_full() override { return _remain_element_capacity == 0; } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE12is_page_fullEv Line | Count | Source | 98 | 34.5k | bool is_page_full() override { return _remain_element_capacity == 0; } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE12is_page_fullEv Line | Count | Source | 98 | 690 | bool is_page_full() override { return _remain_element_capacity == 0; } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE12is_page_fullEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE12is_page_fullEv Line | Count | Source | 98 | 4 | bool is_page_full() override { return _remain_element_capacity == 0; } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE12is_page_fullEv Line | Count | Source | 98 | 4 | bool is_page_full() override { return _remain_element_capacity == 0; } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE12is_page_fullEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE12is_page_fullEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE12is_page_fullEv Line | Count | Source | 98 | 8 | bool is_page_full() override { return _remain_element_capacity == 0; } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE12is_page_fullEv Line | Count | Source | 98 | 14 | bool is_page_full() override { return _remain_element_capacity == 0; } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE12is_page_fullEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE12is_page_fullEv Line | Count | Source | 98 | 22 | bool is_page_full() override { return _remain_element_capacity == 0; } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE12is_page_fullEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE12is_page_fullEv Line | Count | Source | 98 | 4 | bool is_page_full() override { return _remain_element_capacity == 0; } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE12is_page_fullEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE12is_page_fullEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE12is_page_fullEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE12is_page_fullEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE12is_page_fullEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE12is_page_fullEv |
99 | | |
100 | 1.36M | Status add(const uint8_t* vals, size_t* count) override { |
101 | 1.36M | return add_internal<false>(vals, count); |
102 | 1.36M | } _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE3addEPKhPm Line | Count | Source | 100 | 1.32M | Status add(const uint8_t* vals, size_t* count) override { | 101 | 1.32M | return add_internal<false>(vals, count); | 102 | 1.32M | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE3addEPKhPm Line | Count | Source | 100 | 2.80k | Status add(const uint8_t* vals, size_t* count) override { | 101 | 2.80k | return add_internal<false>(vals, count); | 102 | 2.80k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE3addEPKhPm Line | Count | Source | 100 | 26 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 26 | return add_internal<false>(vals, count); | 102 | 26 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE3addEPKhPm Line | Count | Source | 100 | 34.5k | Status add(const uint8_t* vals, size_t* count) override { | 101 | 34.5k | return add_internal<false>(vals, count); | 102 | 34.5k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE3addEPKhPm Line | Count | Source | 100 | 690 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 690 | return add_internal<false>(vals, count); | 102 | 690 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE3addEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE3addEPKhPm Line | Count | Source | 100 | 4 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 4 | return add_internal<false>(vals, count); | 102 | 4 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE3addEPKhPm Line | Count | Source | 100 | 4 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 4 | return add_internal<false>(vals, count); | 102 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE3addEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE3addEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE3addEPKhPm Line | Count | Source | 100 | 8 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 8 | return add_internal<false>(vals, count); | 102 | 8 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE3addEPKhPm Line | Count | Source | 100 | 14 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 14 | return add_internal<false>(vals, count); | 102 | 14 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE3addEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE3addEPKhPm Line | Count | Source | 100 | 22 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 22 | return add_internal<false>(vals, count); | 102 | 22 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE3addEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE3addEPKhPm Line | Count | Source | 100 | 4 | Status add(const uint8_t* vals, size_t* count) override { | 101 | 4 | return add_internal<false>(vals, count); | 102 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE3addEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE3addEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE3addEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE3addEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE3addEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE3addEPKhPm |
103 | | |
104 | 1.67M | Status single_add(const uint8_t* vals, size_t* count) { |
105 | 1.67M | return add_internal<true>(vals, count); |
106 | 1.67M | } |
107 | | |
108 | | template <bool single> |
109 | 3.04M | inline Status add_internal(const uint8_t* vals, size_t* num_written) { |
110 | 3.04M | DCHECK(!_finished); |
111 | 3.04M | if (_remain_element_capacity == 0) { |
112 | 0 | *num_written = 0; |
113 | 0 | return Status::OK(); |
114 | 0 | } |
115 | | |
116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. |
117 | | // the row count of a single men tbl could be very large. |
118 | | // a real log: |
119 | | /* |
120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 |
121 | | */ |
122 | | // This is not a very wide table, actually it just has two columns, int and array<float> |
123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. |
124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). |
125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. |
126 | 3.04M | uint32_t to_add = cast_set<UInt32>( |
127 | 3.04M | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); |
128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE |
129 | 3.04M | int to_add_size = to_add * SIZE_OF_TYPE; |
130 | 3.04M | size_t orig_size = _data.size(); |
131 | | // This may need a large memory, should return error if could not allocated |
132 | | // successfully, to avoid BE OOM. |
133 | 3.04M | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); |
134 | 3.04M | _count += to_add; |
135 | 3.04M | _remain_element_capacity -= to_add; |
136 | 3.04M | _raw_data_size += to_add_size; |
137 | | // return added number through count |
138 | 3.04M | *num_written = to_add; |
139 | 3.04M | if constexpr (single) { |
140 | | if constexpr (SIZE_OF_TYPE == 1) { |
141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; |
142 | | return Status::OK(); |
143 | | } else if constexpr (SIZE_OF_TYPE == 2) { |
144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = |
145 | | *reinterpret_cast<const uint16_t*>(vals); |
146 | | return Status::OK(); |
147 | 1.67M | } else if constexpr (SIZE_OF_TYPE == 4) { |
148 | 1.67M | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = |
149 | 1.67M | *reinterpret_cast<const uint32_t*>(vals); |
150 | 1.67M | return Status::OK(); |
151 | | } else if constexpr (SIZE_OF_TYPE == 8) { |
152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = |
153 | | *reinterpret_cast<const uint64_t*>(vals); |
154 | | return Status::OK(); |
155 | | } |
156 | 1.67M | } |
157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false |
158 | 0 | memcpy(&_data[orig_size], vals, to_add_size); |
159 | 3.04M | return Status::OK(); |
160 | 3.04M | } _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 1.32M | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 1.32M | DCHECK(!_finished); | 111 | 1.32M | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 1.32M | uint32_t to_add = cast_set<UInt32>( | 127 | 1.32M | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 1.32M | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 1.32M | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 1.32M | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 1.32M | _count += to_add; | 135 | 1.32M | _remain_element_capacity -= to_add; | 136 | 1.32M | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 1.32M | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 1.32M | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 1.32M | return Status::OK(); | 160 | 1.32M | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE12add_internalILb1EEENS_6StatusEPKhPm Line | Count | Source | 109 | 1.67M | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 1.67M | DCHECK(!_finished); | 111 | 1.67M | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 1.67M | uint32_t to_add = cast_set<UInt32>( | 127 | 1.67M | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 1.67M | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 1.67M | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 1.67M | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 1.67M | _count += to_add; | 135 | 1.67M | _remain_element_capacity -= to_add; | 136 | 1.67M | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 1.67M | *num_written = to_add; | 139 | 1.67M | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | 1.67M | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | 1.67M | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | 1.67M | *reinterpret_cast<const uint32_t*>(vals); | 150 | 1.67M | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | 1.67M | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 0 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 1.67M | return Status::OK(); | 160 | 1.67M | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 2.80k | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 2.80k | DCHECK(!_finished); | 111 | 2.80k | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 2.80k | uint32_t to_add = cast_set<UInt32>( | 127 | 2.80k | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 2.80k | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 2.80k | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 2.80k | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 2.80k | _count += to_add; | 135 | 2.80k | _remain_element_capacity -= to_add; | 136 | 2.80k | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 2.80k | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 2.80k | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 2.80k | return Status::OK(); | 160 | 2.80k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 26 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 26 | DCHECK(!_finished); | 111 | 26 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 26 | uint32_t to_add = cast_set<UInt32>( | 127 | 26 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 26 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 26 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 26 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 26 | _count += to_add; | 135 | 26 | _remain_element_capacity -= to_add; | 136 | 26 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 26 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 26 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 26 | return Status::OK(); | 160 | 26 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 34.5k | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 34.5k | DCHECK(!_finished); | 111 | 34.5k | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 34.5k | uint32_t to_add = cast_set<UInt32>( | 127 | 34.5k | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 34.5k | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 34.5k | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 34.5k | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 34.5k | _count += to_add; | 135 | 34.5k | _remain_element_capacity -= to_add; | 136 | 34.5k | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 34.5k | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 34.5k | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 34.5k | return Status::OK(); | 160 | 34.5k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 690 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 690 | DCHECK(!_finished); | 111 | 690 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 690 | uint32_t to_add = cast_set<UInt32>( | 127 | 690 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 690 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 690 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 690 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 690 | _count += to_add; | 135 | 690 | _remain_element_capacity -= to_add; | 136 | 690 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 690 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 690 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 690 | return Status::OK(); | 160 | 690 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE12add_internalILb0EEENS_6StatusEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 4 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 4 | DCHECK(!_finished); | 111 | 4 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 4 | uint32_t to_add = cast_set<UInt32>( | 127 | 4 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 4 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 4 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 4 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 4 | _count += to_add; | 135 | 4 | _remain_element_capacity -= to_add; | 136 | 4 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 4 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 4 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 4 | return Status::OK(); | 160 | 4 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 4 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 4 | DCHECK(!_finished); | 111 | 4 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 4 | uint32_t to_add = cast_set<UInt32>( | 127 | 4 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 4 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 4 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 4 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 4 | _count += to_add; | 135 | 4 | _remain_element_capacity -= to_add; | 136 | 4 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 4 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 4 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 4 | return Status::OK(); | 160 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE12add_internalILb0EEENS_6StatusEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE12add_internalILb0EEENS_6StatusEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 8 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 8 | DCHECK(!_finished); | 111 | 8 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 8 | uint32_t to_add = cast_set<UInt32>( | 127 | 8 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 8 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 8 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 8 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 8 | _count += to_add; | 135 | 8 | _remain_element_capacity -= to_add; | 136 | 8 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 8 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 8 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 8 | return Status::OK(); | 160 | 8 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 14 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 14 | DCHECK(!_finished); | 111 | 14 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 14 | uint32_t to_add = cast_set<UInt32>( | 127 | 14 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 14 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 14 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 14 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 14 | _count += to_add; | 135 | 14 | _remain_element_capacity -= to_add; | 136 | 14 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 14 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 14 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 14 | return Status::OK(); | 160 | 14 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE12add_internalILb0EEENS_6StatusEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 22 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 22 | DCHECK(!_finished); | 111 | 22 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 22 | uint32_t to_add = cast_set<UInt32>( | 127 | 22 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 22 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 22 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 22 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 22 | _count += to_add; | 135 | 22 | _remain_element_capacity -= to_add; | 136 | 22 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 22 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 22 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 22 | return Status::OK(); | 160 | 22 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE12add_internalILb0EEENS_6StatusEPKhPm _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE12add_internalILb0EEENS_6StatusEPKhPm Line | Count | Source | 109 | 4 | inline Status add_internal(const uint8_t* vals, size_t* num_written) { | 110 | 4 | DCHECK(!_finished); | 111 | 4 | if (_remain_element_capacity == 0) { | 112 | 0 | *num_written = 0; | 113 | 0 | return Status::OK(); | 114 | 0 | } | 115 | | | 116 | | // When increasing the size of the memtabl flush threshold to a very large value, for example 15GB. | 117 | | // the row count of a single men tbl could be very large. | 118 | | // a real log: | 119 | | /* | 120 | | I20250823 19:01:16.153575 2982018 memtable_flush_executor.cpp:185] begin to flush memtable for tablet: 1755915952737, memsize: 15.11 GB, rows: 3751968 | 121 | | */ | 122 | | // This is not a very wide table, actually it just has two columns, int and array<float> | 123 | | // The write process of column array has two steps: write nested column(column float here), and write offsets column. | 124 | | // The row count of column array is 3751968, which is not that big, but each row of column array has 768 float numbers (this is a common case in vector search scenario). | 125 | | // so the row num of nested column float will be 3751968 * 768 = 2,881,511,424, which is bigger than INT32_MAX. | 126 | 4 | uint32_t to_add = cast_set<UInt32>( | 127 | 4 | std::min(cast_set<size_t>(_remain_element_capacity), *num_written)); | 128 | | // Max value of to_add_size is less than STORAGE_PAGE_SIZE_DEFAULT_VALUE | 129 | 4 | int to_add_size = to_add * SIZE_OF_TYPE; | 130 | 4 | size_t orig_size = _data.size(); | 131 | | // This may need a large memory, should return error if could not allocated | 132 | | // successfully, to avoid BE OOM. | 133 | 4 | RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size)); | 134 | 4 | _count += to_add; | 135 | 4 | _remain_element_capacity -= to_add; | 136 | 4 | _raw_data_size += to_add_size; | 137 | | // return added number through count | 138 | 4 | *num_written = to_add; | 139 | | if constexpr (single) { | 140 | | if constexpr (SIZE_OF_TYPE == 1) { | 141 | | *reinterpret_cast<uint8_t*>(&_data[orig_size]) = *vals; | 142 | | return Status::OK(); | 143 | | } else if constexpr (SIZE_OF_TYPE == 2) { | 144 | | *reinterpret_cast<uint16_t*>(&_data[orig_size]) = | 145 | | *reinterpret_cast<const uint16_t*>(vals); | 146 | | return Status::OK(); | 147 | | } else if constexpr (SIZE_OF_TYPE == 4) { | 148 | | *reinterpret_cast<uint32_t*>(&_data[orig_size]) = | 149 | | *reinterpret_cast<const uint32_t*>(vals); | 150 | | return Status::OK(); | 151 | | } else if constexpr (SIZE_OF_TYPE == 8) { | 152 | | *reinterpret_cast<uint64_t*>(&_data[orig_size]) = | 153 | | *reinterpret_cast<const uint64_t*>(vals); | 154 | | return Status::OK(); | 155 | | } | 156 | | } | 157 | | // when single is true and SIZE_OF_TYPE > 8 or single is false | 158 | 4 | memcpy(&_data[orig_size], vals, to_add_size); | 159 | 4 | return Status::OK(); | 160 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE12add_internalILb0EEENS_6StatusEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE12add_internalILb0EEENS_6StatusEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE12add_internalILb0EEENS_6StatusEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE12add_internalILb0EEENS_6StatusEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE12add_internalILb0EEENS_6StatusEPKhPm Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE12add_internalILb0EEENS_6StatusEPKhPm |
161 | | |
162 | 37.1k | Status finish(OwnedSlice* slice) override { |
163 | 37.1k | if (_count > 0) { |
164 | 37.1k | _first_value = cell(0); |
165 | 37.1k | _last_value = cell(_count - 1); |
166 | 37.1k | } |
167 | 37.1k | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); |
168 | 37.1k | return Status::OK(); |
169 | 37.1k | } _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 33.8k | Status finish(OwnedSlice* slice) override { | 163 | 33.8k | if (_count > 0) { | 164 | 33.8k | _first_value = cell(0); | 165 | 33.8k | _last_value = cell(_count - 1); | 166 | 33.8k | } | 167 | 33.8k | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 33.8k | return Status::OK(); | 169 | 33.8k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 1.26k | Status finish(OwnedSlice* slice) override { | 163 | 1.26k | if (_count > 0) { | 164 | 1.26k | _first_value = cell(0); | 165 | 1.26k | _last_value = cell(_count - 1); | 166 | 1.26k | } | 167 | 1.26k | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 1.26k | return Status::OK(); | 169 | 1.26k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 26 | Status finish(OwnedSlice* slice) override { | 163 | 26 | if (_count > 0) { | 164 | 26 | _first_value = cell(0); | 165 | 26 | _last_value = cell(_count - 1); | 166 | 26 | } | 167 | 26 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 26 | return Status::OK(); | 169 | 26 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 1.23k | Status finish(OwnedSlice* slice) override { | 163 | 1.23k | if (_count > 0) { | 164 | 1.23k | _first_value = cell(0); | 165 | 1.23k | _last_value = cell(_count - 1); | 166 | 1.23k | } | 167 | 1.23k | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 1.23k | return Status::OK(); | 169 | 1.23k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 680 | Status finish(OwnedSlice* slice) override { | 163 | 680 | if (_count > 0) { | 164 | 680 | _first_value = cell(0); | 165 | 680 | _last_value = cell(_count - 1); | 166 | 680 | } | 167 | 680 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 680 | return Status::OK(); | 169 | 680 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE6finishEPNS_10OwnedSliceE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 4 | Status finish(OwnedSlice* slice) override { | 163 | 4 | if (_count > 0) { | 164 | 4 | _first_value = cell(0); | 165 | 4 | _last_value = cell(_count - 1); | 166 | 4 | } | 167 | 4 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 4 | return Status::OK(); | 169 | 4 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 4 | Status finish(OwnedSlice* slice) override { | 163 | 4 | if (_count > 0) { | 164 | 4 | _first_value = cell(0); | 165 | 4 | _last_value = cell(_count - 1); | 166 | 4 | } | 167 | 4 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 4 | return Status::OK(); | 169 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE6finishEPNS_10OwnedSliceE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE6finishEPNS_10OwnedSliceE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 8 | Status finish(OwnedSlice* slice) override { | 163 | 8 | if (_count > 0) { | 164 | 8 | _first_value = cell(0); | 165 | 8 | _last_value = cell(_count - 1); | 166 | 8 | } | 167 | 8 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 8 | return Status::OK(); | 169 | 8 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 14 | Status finish(OwnedSlice* slice) override { | 163 | 14 | if (_count > 0) { | 164 | 14 | _first_value = cell(0); | 165 | 14 | _last_value = cell(_count - 1); | 166 | 14 | } | 167 | 14 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 14 | return Status::OK(); | 169 | 14 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE6finishEPNS_10OwnedSliceE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 22 | Status finish(OwnedSlice* slice) override { | 163 | 22 | if (_count > 0) { | 164 | 22 | _first_value = cell(0); | 165 | 22 | _last_value = cell(_count - 1); | 166 | 22 | } | 167 | 22 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 22 | return Status::OK(); | 169 | 22 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE6finishEPNS_10OwnedSliceE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE6finishEPNS_10OwnedSliceE Line | Count | Source | 162 | 4 | Status finish(OwnedSlice* slice) override { | 163 | 4 | if (_count > 0) { | 164 | 4 | _first_value = cell(0); | 165 | 4 | _last_value = cell(_count - 1); | 166 | 4 | } | 167 | 4 | RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); }); | 168 | 4 | return Status::OK(); | 169 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE6finishEPNS_10OwnedSliceE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE6finishEPNS_10OwnedSliceE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE6finishEPNS_10OwnedSliceE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE6finishEPNS_10OwnedSliceE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE6finishEPNS_10OwnedSliceE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE6finishEPNS_10OwnedSliceE |
170 | | |
171 | 77.8k | Status reset() override { |
172 | 77.8k | RETURN_IF_CATCH_EXCEPTION({ |
173 | 77.8k | size_t block_size = _options.data_page_size; |
174 | 77.8k | _count = 0; |
175 | 77.8k | _raw_data_size = 0; |
176 | 77.8k | _data.clear(); |
177 | 77.8k | _data.reserve(block_size); |
178 | 77.8k | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) |
179 | 77.8k | << "buffer must be naturally-aligned"; |
180 | 77.8k | _buffer.clear(); |
181 | 77.8k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); |
182 | 77.8k | _finished = false; |
183 | 77.8k | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); |
184 | 77.8k | }); |
185 | 77.8k | return Status::OK(); |
186 | 77.8k | } _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE5resetEv Line | Count | Source | 171 | 71.2k | Status reset() override { | 172 | 71.2k | RETURN_IF_CATCH_EXCEPTION({ | 173 | 71.2k | size_t block_size = _options.data_page_size; | 174 | 71.2k | _count = 0; | 175 | 71.2k | _raw_data_size = 0; | 176 | 71.2k | _data.clear(); | 177 | 71.2k | _data.reserve(block_size); | 178 | 71.2k | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 71.2k | << "buffer must be naturally-aligned"; | 180 | 71.2k | _buffer.clear(); | 181 | 71.2k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 71.2k | _finished = false; | 183 | 71.2k | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 71.2k | }); | 185 | 71.2k | return Status::OK(); | 186 | 71.2k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE5resetEv Line | Count | Source | 171 | 2.51k | Status reset() override { | 172 | 2.51k | RETURN_IF_CATCH_EXCEPTION({ | 173 | 2.51k | size_t block_size = _options.data_page_size; | 174 | 2.51k | _count = 0; | 175 | 2.51k | _raw_data_size = 0; | 176 | 2.51k | _data.clear(); | 177 | 2.51k | _data.reserve(block_size); | 178 | 2.51k | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 2.51k | << "buffer must be naturally-aligned"; | 180 | 2.51k | _buffer.clear(); | 181 | 2.51k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 2.51k | _finished = false; | 183 | 2.51k | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 2.51k | }); | 185 | 2.51k | return Status::OK(); | 186 | 2.51k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE5resetEv Line | Count | Source | 171 | 52 | Status reset() override { | 172 | 52 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 52 | size_t block_size = _options.data_page_size; | 174 | 52 | _count = 0; | 175 | 52 | _raw_data_size = 0; | 176 | 52 | _data.clear(); | 177 | 52 | _data.reserve(block_size); | 178 | 52 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 52 | << "buffer must be naturally-aligned"; | 180 | 52 | _buffer.clear(); | 181 | 52 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 52 | _finished = false; | 183 | 52 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 52 | }); | 185 | 52 | return Status::OK(); | 186 | 52 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE5resetEv Line | Count | Source | 171 | 2.52k | Status reset() override { | 172 | 2.52k | RETURN_IF_CATCH_EXCEPTION({ | 173 | 2.52k | size_t block_size = _options.data_page_size; | 174 | 2.52k | _count = 0; | 175 | 2.52k | _raw_data_size = 0; | 176 | 2.52k | _data.clear(); | 177 | 2.52k | _data.reserve(block_size); | 178 | 2.52k | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 2.52k | << "buffer must be naturally-aligned"; | 180 | 2.52k | _buffer.clear(); | 181 | 2.52k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 2.52k | _finished = false; | 183 | 2.52k | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 2.52k | }); | 185 | 2.52k | return Status::OK(); | 186 | 2.52k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE5resetEv Line | Count | Source | 171 | 1.37k | Status reset() override { | 172 | 1.37k | RETURN_IF_CATCH_EXCEPTION({ | 173 | 1.37k | size_t block_size = _options.data_page_size; | 174 | 1.37k | _count = 0; | 175 | 1.37k | _raw_data_size = 0; | 176 | 1.37k | _data.clear(); | 177 | 1.37k | _data.reserve(block_size); | 178 | 1.37k | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 1.37k | << "buffer must be naturally-aligned"; | 180 | 1.37k | _buffer.clear(); | 181 | 1.37k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 1.37k | _finished = false; | 183 | 1.37k | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 1.37k | }); | 185 | 1.37k | return Status::OK(); | 186 | 1.37k | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE5resetEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE5resetEv Line | Count | Source | 171 | 8 | Status reset() override { | 172 | 8 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 8 | size_t block_size = _options.data_page_size; | 174 | 8 | _count = 0; | 175 | 8 | _raw_data_size = 0; | 176 | 8 | _data.clear(); | 177 | 8 | _data.reserve(block_size); | 178 | 8 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 8 | << "buffer must be naturally-aligned"; | 180 | 8 | _buffer.clear(); | 181 | 8 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 8 | _finished = false; | 183 | 8 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 8 | }); | 185 | 8 | return Status::OK(); | 186 | 8 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE5resetEv Line | Count | Source | 171 | 8 | Status reset() override { | 172 | 8 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 8 | size_t block_size = _options.data_page_size; | 174 | 8 | _count = 0; | 175 | 8 | _raw_data_size = 0; | 176 | 8 | _data.clear(); | 177 | 8 | _data.reserve(block_size); | 178 | 8 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 8 | << "buffer must be naturally-aligned"; | 180 | 8 | _buffer.clear(); | 181 | 8 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 8 | _finished = false; | 183 | 8 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 8 | }); | 185 | 8 | return Status::OK(); | 186 | 8 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE5resetEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE5resetEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE5resetEv Line | Count | Source | 171 | 16 | Status reset() override { | 172 | 16 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 16 | size_t block_size = _options.data_page_size; | 174 | 16 | _count = 0; | 175 | 16 | _raw_data_size = 0; | 176 | 16 | _data.clear(); | 177 | 16 | _data.reserve(block_size); | 178 | 16 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 16 | << "buffer must be naturally-aligned"; | 180 | 16 | _buffer.clear(); | 181 | 16 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 16 | _finished = false; | 183 | 16 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 16 | }); | 185 | 16 | return Status::OK(); | 186 | 16 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE5resetEv Line | Count | Source | 171 | 28 | Status reset() override { | 172 | 28 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 28 | size_t block_size = _options.data_page_size; | 174 | 28 | _count = 0; | 175 | 28 | _raw_data_size = 0; | 176 | 28 | _data.clear(); | 177 | 28 | _data.reserve(block_size); | 178 | 28 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 28 | << "buffer must be naturally-aligned"; | 180 | 28 | _buffer.clear(); | 181 | 28 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 28 | _finished = false; | 183 | 28 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 28 | }); | 185 | 28 | return Status::OK(); | 186 | 28 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE5resetEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE5resetEv Line | Count | Source | 171 | 44 | Status reset() override { | 172 | 44 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 44 | size_t block_size = _options.data_page_size; | 174 | 44 | _count = 0; | 175 | 44 | _raw_data_size = 0; | 176 | 44 | _data.clear(); | 177 | 44 | _data.reserve(block_size); | 178 | 44 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 44 | << "buffer must be naturally-aligned"; | 180 | 44 | _buffer.clear(); | 181 | 44 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 44 | _finished = false; | 183 | 44 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 44 | }); | 185 | 44 | return Status::OK(); | 186 | 44 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE5resetEv _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE5resetEv Line | Count | Source | 171 | 8 | Status reset() override { | 172 | 8 | RETURN_IF_CATCH_EXCEPTION({ | 173 | 8 | size_t block_size = _options.data_page_size; | 174 | 8 | _count = 0; | 175 | 8 | _raw_data_size = 0; | 176 | 8 | _data.clear(); | 177 | 8 | _data.reserve(block_size); | 178 | 8 | DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0) | 179 | 8 | << "buffer must be naturally-aligned"; | 180 | 8 | _buffer.clear(); | 181 | 8 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE); | 182 | 8 | _finished = false; | 183 | 8 | _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE); | 184 | 8 | }); | 185 | 8 | return Status::OK(); | 186 | 8 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE5resetEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE5resetEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE5resetEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE5resetEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE5resetEv Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE5resetEv |
187 | | |
188 | 32.6k | size_t count() const override { return _count; }_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE5countEv Line | Count | Source | 188 | 32.6k | size_t count() const override { return _count; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE5countEv |
189 | | |
190 | 15.8k | uint64_t size() const override { return _buffer.size(); }_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE4sizeEv Line | Count | Source | 190 | 14.2k | uint64_t size() const override { return _buffer.size(); } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE4sizeEv Line | Count | Source | 190 | 1.47k | uint64_t size() const override { return _buffer.size(); } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE4sizeEv Line | Count | Source | 190 | 26 | uint64_t size() const override { return _buffer.size(); } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE4sizeEv Line | Count | Source | 190 | 14 | uint64_t size() const override { return _buffer.size(); } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE4sizeEv Line | Count | Source | 190 | 8 | uint64_t size() const override { return _buffer.size(); } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE4sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE4sizeEv Line | Count | Source | 190 | 4 | uint64_t size() const override { return _buffer.size(); } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE4sizeEv Line | Count | Source | 190 | 4 | uint64_t size() const override { return _buffer.size(); } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE4sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE4sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE4sizeEv Line | Count | Source | 190 | 12 | uint64_t size() const override { return _buffer.size(); } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE4sizeEv Line | Count | Source | 190 | 14 | uint64_t size() const override { return _buffer.size(); } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE4sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE4sizeEv Line | Count | Source | 190 | 26 | uint64_t size() const override { return _buffer.size(); } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE4sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE4sizeEv Line | Count | Source | 190 | 4 | uint64_t size() const override { return _buffer.size(); } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE4sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE4sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE4sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE4sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE4sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE4sizeEv |
191 | | |
192 | 29.5k | uint64_t get_raw_data_size() const override { return _raw_data_size; }_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE17get_raw_data_sizeEv Line | Count | Source | 192 | 26.2k | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE17get_raw_data_sizeEv Line | Count | Source | 192 | 1.26k | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE17get_raw_data_sizeEv Line | Count | Source | 192 | 26 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE17get_raw_data_sizeEv Line | Count | Source | 192 | 1.23k | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE17get_raw_data_sizeEv Line | Count | Source | 192 | 680 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE17get_raw_data_sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE17get_raw_data_sizeEv Line | Count | Source | 192 | 4 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE17get_raw_data_sizeEv Line | Count | Source | 192 | 4 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE17get_raw_data_sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE17get_raw_data_sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE17get_raw_data_sizeEv Line | Count | Source | 192 | 8 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE17get_raw_data_sizeEv Line | Count | Source | 192 | 14 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE17get_raw_data_sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE17get_raw_data_sizeEv Line | Count | Source | 192 | 22 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE17get_raw_data_sizeEv _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE17get_raw_data_sizeEv Line | Count | Source | 192 | 4 | uint64_t get_raw_data_size() const override { return _raw_data_size; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE17get_raw_data_sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE17get_raw_data_sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE17get_raw_data_sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE17get_raw_data_sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE17get_raw_data_sizeEv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE17get_raw_data_sizeEv |
193 | | |
194 | 0 | Status get_first_value(void* value) const override { |
195 | 0 | DCHECK(_finished); |
196 | 0 | if (_count == 0) { |
197 | 0 | return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty"); |
198 | 0 | } |
199 | 0 | memcpy(value, &_first_value, SIZE_OF_TYPE); |
200 | 0 | return Status::OK(); |
201 | 0 | } Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE15get_first_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE15get_first_valueEPv |
202 | 6 | Status get_last_value(void* value) const override { |
203 | 6 | DCHECK(_finished); |
204 | 6 | if (_count == 0) { |
205 | 0 | return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty"); |
206 | 0 | } |
207 | 6 | memcpy(value, &_last_value, SIZE_OF_TYPE); |
208 | 6 | return Status::OK(); |
209 | 6 | } _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE14get_last_valueEPv Line | Count | Source | 202 | 6 | Status get_last_value(void* value) const override { | 203 | 6 | DCHECK(_finished); | 204 | 6 | if (_count == 0) { | 205 | 0 | return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty"); | 206 | 0 | } | 207 | 6 | memcpy(value, &_last_value, SIZE_OF_TYPE); | 208 | 6 | return Status::OK(); | 209 | 6 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE14get_last_valueEPv Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE14get_last_valueEPv |
210 | | |
211 | | private: |
212 | | BitshufflePageBuilder(const PageBuilderOptions& options) |
213 | 36.1k | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 32.8k | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 1.24k | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 26 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 1.28k | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 690 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EEC2ERKNS0_18PageBuilderOptionsE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 4 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 4 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EEC2ERKNS0_18PageBuilderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EEC2ERKNS0_18PageBuilderOptionsE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 8 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 14 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EEC2ERKNS0_18PageBuilderOptionsE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 22 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EEC2ERKNS0_18PageBuilderOptionsE _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EEC2ERKNS0_18PageBuilderOptionsE Line | Count | Source | 213 | 4 | : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EEC2ERKNS0_18PageBuilderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EEC2ERKNS0_18PageBuilderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EEC2ERKNS0_18PageBuilderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EEC2ERKNS0_18PageBuilderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EEC2ERKNS0_18PageBuilderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EEC2ERKNS0_18PageBuilderOptionsE |
214 | | |
215 | 37.1k | OwnedSlice _finish(int final_size_of_type) { |
216 | 37.1k | _data.resize(final_size_of_type * _count); |
217 | | |
218 | | // Do padding so that the input num of element is multiple of 8. |
219 | 37.1k | int num_elems_after_padding = ALIGN_UP(_count, 8); |
220 | 37.1k | int padding_elems = num_elems_after_padding - _count; |
221 | 37.1k | int padding_bytes = padding_elems * final_size_of_type; |
222 | 224k | for (int i = 0; i < padding_bytes; i++) { |
223 | 187k | _data.push_back(0); |
224 | 187k | } |
225 | | |
226 | | // reserve enough place for compression |
227 | 37.1k | _buffer.resize( |
228 | 37.1k | BITSHUFFLE_PAGE_HEADER_SIZE + |
229 | 37.1k | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); |
230 | | |
231 | 37.1k | int64_t bytes = |
232 | 37.1k | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], |
233 | 37.1k | num_elems_after_padding, final_size_of_type, 0); |
234 | 37.1k | if (bytes < 0) [[unlikely]] { |
235 | | // This means the bitshuffle function fails. |
236 | | // Ideally, this should not happen. |
237 | 0 | warn_with_bitshuffle_error(bytes); |
238 | | // It does not matter what will be returned here, |
239 | | // since we have logged fatal in warn_with_bitshuffle_error(). |
240 | 0 | return OwnedSlice(); |
241 | 0 | } |
242 | | // update header |
243 | 37.1k | encode_fixed32_le(&_buffer[0], _count); |
244 | 37.1k | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); |
245 | 37.1k | encode_fixed32_le(&_buffer[8], num_elems_after_padding); |
246 | 37.1k | encode_fixed32_le(&_buffer[12], final_size_of_type); |
247 | 37.1k | _finished = true; |
248 | | // before build(), update buffer length to the actual compressed size |
249 | 37.1k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); |
250 | 37.1k | return _buffer.build(); |
251 | 37.1k | } _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE7_finishEi Line | Count | Source | 215 | 33.8k | OwnedSlice _finish(int final_size_of_type) { | 216 | 33.8k | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 33.8k | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 33.8k | int padding_elems = num_elems_after_padding - _count; | 221 | 33.8k | int padding_bytes = padding_elems * final_size_of_type; | 222 | 201k | for (int i = 0; i < padding_bytes; i++) { | 223 | 167k | _data.push_back(0); | 224 | 167k | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 33.8k | _buffer.resize( | 228 | 33.8k | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 33.8k | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 33.8k | int64_t bytes = | 232 | 33.8k | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 33.8k | num_elems_after_padding, final_size_of_type, 0); | 234 | 33.8k | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 33.8k | encode_fixed32_le(&_buffer[0], _count); | 244 | 33.8k | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 33.8k | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 33.8k | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 33.8k | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 33.8k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 33.8k | return _buffer.build(); | 251 | 33.8k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE7_finishEi Line | Count | Source | 215 | 1.26k | OwnedSlice _finish(int final_size_of_type) { | 216 | 1.26k | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 1.26k | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 1.26k | int padding_elems = num_elems_after_padding - _count; | 221 | 1.26k | int padding_bytes = padding_elems * final_size_of_type; | 222 | 2.53k | for (int i = 0; i < padding_bytes; i++) { | 223 | 1.26k | _data.push_back(0); | 224 | 1.26k | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 1.26k | _buffer.resize( | 228 | 1.26k | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 1.26k | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 1.26k | int64_t bytes = | 232 | 1.26k | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 1.26k | num_elems_after_padding, final_size_of_type, 0); | 234 | 1.26k | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 1.26k | encode_fixed32_le(&_buffer[0], _count); | 244 | 1.26k | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 1.26k | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 1.26k | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 1.26k | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 1.26k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 1.26k | return _buffer.build(); | 251 | 1.26k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE7_finishEi Line | Count | Source | 215 | 26 | OwnedSlice _finish(int final_size_of_type) { | 216 | 26 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 26 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 26 | int padding_elems = num_elems_after_padding - _count; | 221 | 26 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 370 | for (int i = 0; i < padding_bytes; i++) { | 223 | 344 | _data.push_back(0); | 224 | 344 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 26 | _buffer.resize( | 228 | 26 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 26 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 26 | int64_t bytes = | 232 | 26 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 26 | num_elems_after_padding, final_size_of_type, 0); | 234 | 26 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 26 | encode_fixed32_le(&_buffer[0], _count); | 244 | 26 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 26 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 26 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 26 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 26 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 26 | return _buffer.build(); | 251 | 26 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE7_finishEi Line | Count | Source | 215 | 1.23k | OwnedSlice _finish(int final_size_of_type) { | 216 | 1.23k | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 1.23k | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 1.23k | int padding_elems = num_elems_after_padding - _count; | 221 | 1.23k | int padding_bytes = padding_elems * final_size_of_type; | 222 | 16.4k | for (int i = 0; i < padding_bytes; i++) { | 223 | 15.2k | _data.push_back(0); | 224 | 15.2k | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 1.23k | _buffer.resize( | 228 | 1.23k | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 1.23k | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 1.23k | int64_t bytes = | 232 | 1.23k | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 1.23k | num_elems_after_padding, final_size_of_type, 0); | 234 | 1.23k | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 1.23k | encode_fixed32_le(&_buffer[0], _count); | 244 | 1.23k | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 1.23k | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 1.23k | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 1.23k | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 1.23k | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 1.23k | return _buffer.build(); | 251 | 1.23k | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE7_finishEi Line | Count | Source | 215 | 680 | OwnedSlice _finish(int final_size_of_type) { | 216 | 680 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 680 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 680 | int padding_elems = num_elems_after_padding - _count; | 221 | 680 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 1.32k | for (int i = 0; i < padding_bytes; i++) { | 223 | 640 | _data.push_back(0); | 224 | 640 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 680 | _buffer.resize( | 228 | 680 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 680 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 680 | int64_t bytes = | 232 | 680 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 680 | num_elems_after_padding, final_size_of_type, 0); | 234 | 680 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 680 | encode_fixed32_le(&_buffer[0], _count); | 244 | 680 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 680 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 680 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 680 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 680 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 680 | return _buffer.build(); | 251 | 680 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE7_finishEi _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE7_finishEi Line | Count | Source | 215 | 4 | OwnedSlice _finish(int final_size_of_type) { | 216 | 4 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 4 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 4 | int padding_elems = num_elems_after_padding - _count; | 221 | 4 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 452 | for (int i = 0; i < padding_bytes; i++) { | 223 | 448 | _data.push_back(0); | 224 | 448 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 4 | _buffer.resize( | 228 | 4 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 4 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 4 | int64_t bytes = | 232 | 4 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 4 | num_elems_after_padding, final_size_of_type, 0); | 234 | 4 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 4 | encode_fixed32_le(&_buffer[0], _count); | 244 | 4 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 4 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 4 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 4 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 4 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 4 | return _buffer.build(); | 251 | 4 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE7_finishEi Line | Count | Source | 215 | 4 | OwnedSlice _finish(int final_size_of_type) { | 216 | 4 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 4 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 4 | int padding_elems = num_elems_after_padding - _count; | 221 | 4 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 4 | for (int i = 0; i < padding_bytes; i++) { | 223 | 0 | _data.push_back(0); | 224 | 0 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 4 | _buffer.resize( | 228 | 4 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 4 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 4 | int64_t bytes = | 232 | 4 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 4 | num_elems_after_padding, final_size_of_type, 0); | 234 | 4 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 4 | encode_fixed32_le(&_buffer[0], _count); | 244 | 4 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 4 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 4 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 4 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 4 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 4 | return _buffer.build(); | 251 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE7_finishEi Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE7_finishEi _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE7_finishEi Line | Count | Source | 215 | 8 | OwnedSlice _finish(int final_size_of_type) { | 216 | 8 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 8 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 8 | int padding_elems = num_elems_after_padding - _count; | 221 | 8 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 164 | for (int i = 0; i < padding_bytes; i++) { | 223 | 156 | _data.push_back(0); | 224 | 156 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 8 | _buffer.resize( | 228 | 8 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 8 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 8 | int64_t bytes = | 232 | 8 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 8 | num_elems_after_padding, final_size_of_type, 0); | 234 | 8 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 8 | encode_fixed32_le(&_buffer[0], _count); | 244 | 8 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 8 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 8 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 8 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 8 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 8 | return _buffer.build(); | 251 | 8 | } |
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE7_finishEi Line | Count | Source | 215 | 14 | OwnedSlice _finish(int final_size_of_type) { | 216 | 14 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 14 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 14 | int padding_elems = num_elems_after_padding - _count; | 221 | 14 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 366 | for (int i = 0; i < padding_bytes; i++) { | 223 | 352 | _data.push_back(0); | 224 | 352 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 14 | _buffer.resize( | 228 | 14 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 14 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 14 | int64_t bytes = | 232 | 14 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 14 | num_elems_after_padding, final_size_of_type, 0); | 234 | 14 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 14 | encode_fixed32_le(&_buffer[0], _count); | 244 | 14 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 14 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 14 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 14 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 14 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 14 | return _buffer.build(); | 251 | 14 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE7_finishEi _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE7_finishEi Line | Count | Source | 215 | 22 | OwnedSlice _finish(int final_size_of_type) { | 216 | 22 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 22 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 22 | int padding_elems = num_elems_after_padding - _count; | 221 | 22 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 1.14k | for (int i = 0; i < padding_bytes; i++) { | 223 | 1.12k | _data.push_back(0); | 224 | 1.12k | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 22 | _buffer.resize( | 228 | 22 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 22 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 22 | int64_t bytes = | 232 | 22 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 22 | num_elems_after_padding, final_size_of_type, 0); | 234 | 22 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 22 | encode_fixed32_le(&_buffer[0], _count); | 244 | 22 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 22 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 22 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 22 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 22 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 22 | return _buffer.build(); | 251 | 22 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE7_finishEi _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE7_finishEi Line | Count | Source | 215 | 4 | OwnedSlice _finish(int final_size_of_type) { | 216 | 4 | _data.resize(final_size_of_type * _count); | 217 | | | 218 | | // Do padding so that the input num of element is multiple of 8. | 219 | 4 | int num_elems_after_padding = ALIGN_UP(_count, 8); | 220 | 4 | int padding_elems = num_elems_after_padding - _count; | 221 | 4 | int padding_bytes = padding_elems * final_size_of_type; | 222 | 340 | for (int i = 0; i < padding_bytes; i++) { | 223 | 336 | _data.push_back(0); | 224 | 336 | } | 225 | | | 226 | | // reserve enough place for compression | 227 | 4 | _buffer.resize( | 228 | 4 | BITSHUFFLE_PAGE_HEADER_SIZE + | 229 | 4 | bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0)); | 230 | | | 231 | 4 | int64_t bytes = | 232 | 4 | bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE], | 233 | 4 | num_elems_after_padding, final_size_of_type, 0); | 234 | 4 | if (bytes < 0) [[unlikely]] { | 235 | | // This means the bitshuffle function fails. | 236 | | // Ideally, this should not happen. | 237 | 0 | warn_with_bitshuffle_error(bytes); | 238 | | // It does not matter what will be returned here, | 239 | | // since we have logged fatal in warn_with_bitshuffle_error(). | 240 | 0 | return OwnedSlice(); | 241 | 0 | } | 242 | | // update header | 243 | 4 | encode_fixed32_le(&_buffer[0], _count); | 244 | 4 | encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes)); | 245 | 4 | encode_fixed32_le(&_buffer[8], num_elems_after_padding); | 246 | 4 | encode_fixed32_le(&_buffer[12], final_size_of_type); | 247 | 4 | _finished = true; | 248 | | // before build(), update buffer length to the actual compressed size | 249 | 4 | _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes); | 250 | 4 | return _buffer.build(); | 251 | 4 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE7_finishEi Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE7_finishEi Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE7_finishEi Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE7_finishEi Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE7_finishEi Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE7_finishEi |
252 | | |
253 | | using CppType = typename TypeTraits<Type>::CppType; |
254 | | |
255 | 74.2k | CppType cell(int idx) const { |
256 | 74.2k | DCHECK_GE(idx, 0); |
257 | 74.2k | CppType ret; |
258 | 74.2k | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); |
259 | 74.2k | return ret; |
260 | 74.2k | } _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE4cellEi Line | Count | Source | 255 | 67.7k | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 67.7k | CppType ret; | 258 | 67.7k | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 67.7k | return ret; | 260 | 67.7k | } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE4cellEi Line | Count | Source | 255 | 2.53k | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 2.53k | CppType ret; | 258 | 2.53k | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 2.53k | return ret; | 260 | 2.53k | } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE4cellEi Line | Count | Source | 255 | 52 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 52 | CppType ret; | 258 | 52 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 52 | return ret; | 260 | 52 | } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE4cellEi Line | Count | Source | 255 | 2.47k | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 2.47k | CppType ret; | 258 | 2.47k | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 2.47k | return ret; | 260 | 2.47k | } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE4cellEi Line | Count | Source | 255 | 1.36k | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 1.36k | CppType ret; | 258 | 1.36k | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 1.36k | return ret; | 260 | 1.36k | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE4cellEi _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE4cellEi Line | Count | Source | 255 | 8 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 8 | CppType ret; | 258 | 8 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 8 | return ret; | 260 | 8 | } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE4cellEi Line | Count | Source | 255 | 8 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 8 | CppType ret; | 258 | 8 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 8 | return ret; | 260 | 8 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE4cellEi Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE4cellEi _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE4cellEi Line | Count | Source | 255 | 16 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 16 | CppType ret; | 258 | 16 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 16 | return ret; | 260 | 16 | } |
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE4cellEi Line | Count | Source | 255 | 28 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 28 | CppType ret; | 258 | 28 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 28 | return ret; | 260 | 28 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE4cellEi _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE4cellEi Line | Count | Source | 255 | 44 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 44 | CppType ret; | 258 | 44 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 44 | return ret; | 260 | 44 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE4cellEi _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE4cellEi Line | Count | Source | 255 | 8 | CppType cell(int idx) const { | 256 | | DCHECK_GE(idx, 0); | 257 | 8 | CppType ret; | 258 | 8 | memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE); | 259 | 8 | return ret; | 260 | 8 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE4cellEi Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE4cellEi Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE4cellEi Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE4cellEi Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE4cellEi Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE4cellEi |
261 | | |
262 | | enum { SIZE_OF_TYPE = TypeTraits<Type>::size }; |
263 | | PageBuilderOptions _options; |
264 | | uint32_t _count; |
265 | | uint32_t _remain_element_capacity; |
266 | | bool _finished; |
267 | | faststring _data; |
268 | | faststring _buffer; |
269 | | CppType _first_value; |
270 | | CppType _last_value; |
271 | | uint64_t _raw_data_size = 0; |
272 | | }; |
273 | | |
274 | | inline Status parse_bit_shuffle_header(const Slice& data, size_t& num_elements, |
275 | | size_t& compressed_size, size_t& num_element_after_padding, |
276 | 56.6k | int& size_of_element) { |
277 | 56.6k | if (data.size < BITSHUFFLE_PAGE_HEADER_SIZE) { |
278 | 0 | return Status::InternalError("file corruption: invalid data size:{}, header size:{}", |
279 | 0 | data.size, BITSHUFFLE_PAGE_HEADER_SIZE); |
280 | 0 | } |
281 | | |
282 | 56.6k | num_elements = decode_fixed32_le((const uint8_t*)&data[0]); |
283 | 56.6k | compressed_size = decode_fixed32_le((const uint8_t*)&data[4]); |
284 | 56.6k | num_element_after_padding = decode_fixed32_le((const uint8_t*)&data[8]); |
285 | 56.6k | size_of_element = decode_fixed32_le((const uint8_t*)&data[12]); |
286 | 56.6k | if (num_element_after_padding != ALIGN_UP(num_elements, 8)) { |
287 | 0 | return Status::InternalError( |
288 | 0 | "num of element information corrupted," |
289 | 0 | " _num_element_after_padding:{}, _num_elements:{}, expected_padding:{}," |
290 | 0 | " compressed_size:{}, size_of_element:{}, data_size:{}", |
291 | 0 | num_element_after_padding, num_elements, ALIGN_UP(num_elements, 8), compressed_size, |
292 | 0 | size_of_element, data.size); |
293 | 0 | } |
294 | 56.6k | switch (size_of_element) { |
295 | 1.34k | case 1: |
296 | 1.36k | case 2: |
297 | 1.36k | case 3: |
298 | 54.9k | case 4: |
299 | 56.6k | case 8: |
300 | 56.6k | case 12: |
301 | 56.6k | case 16: |
302 | 56.6k | case 32: |
303 | 56.6k | break; |
304 | 0 | default: |
305 | 0 | return Status::InternalError("invalid size_of_elem:{}", size_of_element); |
306 | 56.6k | } |
307 | 56.6k | return Status::OK(); |
308 | 56.6k | } |
309 | | |
310 | | template <FieldType Type> |
311 | | class BitShufflePageDecoder : public PageDecoder { |
312 | | public: |
313 | | BitShufflePageDecoder(Slice data, const PageDecoderOptions& options) |
314 | 28.3k | : _data(data), |
315 | 28.3k | _options(options), |
316 | 28.3k | _parsed(false), |
317 | 28.3k | _num_elements(0), |
318 | 28.3k | _num_element_after_padding(0), |
319 | 28.3k | _size_of_element(0), |
320 | 28.3k | _cur_index(0) {}_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 26.7k | : _data(data), | 315 | 26.7k | _options(options), | 316 | 26.7k | _parsed(false), | 317 | 26.7k | _num_elements(0), | 318 | 26.7k | _num_element_after_padding(0), | 319 | 26.7k | _size_of_element(0), | 320 | 26.7k | _cur_index(0) {} |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 670 | : _data(data), | 315 | 670 | _options(options), | 316 | 670 | _parsed(false), | 317 | 670 | _num_elements(0), | 318 | 670 | _num_element_after_padding(0), | 319 | 670 | _size_of_element(0), | 320 | 670 | _cur_index(0) {} |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 10 | : _data(data), | 315 | 10 | _options(options), | 316 | 10 | _parsed(false), | 317 | 10 | _num_elements(0), | 318 | 10 | _num_element_after_padding(0), | 319 | 10 | _size_of_element(0), | 320 | 10 | _cur_index(0) {} |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 440 | : _data(data), | 315 | 440 | _options(options), | 316 | 440 | _parsed(false), | 317 | 440 | _num_elements(0), | 318 | 440 | _num_element_after_padding(0), | 319 | 440 | _size_of_element(0), | 320 | 440 | _cur_index(0) {} |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 382 | : _data(data), | 315 | 382 | _options(options), | 316 | 382 | _parsed(false), | 317 | 382 | _num_elements(0), | 318 | 382 | _num_element_after_padding(0), | 319 | 382 | _size_of_element(0), | 320 | 382 | _cur_index(0) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 2 | : _data(data), | 315 | 2 | _options(options), | 316 | 2 | _parsed(false), | 317 | 2 | _num_elements(0), | 318 | 2 | _num_element_after_padding(0), | 319 | 2 | _size_of_element(0), | 320 | 2 | _cur_index(0) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 10 | : _data(data), | 315 | 10 | _options(options), | 316 | 10 | _parsed(false), | 317 | 10 | _num_elements(0), | 318 | 10 | _num_element_after_padding(0), | 319 | 10 | _size_of_element(0), | 320 | 10 | _cur_index(0) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Line | Count | Source | 314 | 10 | : _data(data), | 315 | 10 | _options(options), | 316 | 10 | _parsed(false), | 317 | 10 | _num_elements(0), | 318 | 10 | _num_element_after_padding(0), | 319 | 10 | _size_of_element(0), | 320 | 10 | _cur_index(0) {} |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE |
321 | | |
322 | 28.3k | Status init() override { |
323 | 28.3k | CHECK(!_parsed); |
324 | 28.3k | size_t unused; |
325 | 28.3k | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, |
326 | 28.3k | _num_element_after_padding, _size_of_element)); |
327 | | |
328 | 28.3k | if (_data.size != |
329 | 28.3k | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { |
330 | 0 | std::stringstream ss; |
331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size |
332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " |
333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; |
334 | 0 | return Status::InternalError(ss.str()); |
335 | 0 | } |
336 | | |
337 | | // Currently, only the UINT32 block encoder supports expanding size: |
338 | 28.3k | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && |
339 | 28.3k | _size_of_element != SIZE_OF_TYPE)) { |
340 | 0 | return Status::InternalError( |
341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", |
342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); |
343 | 0 | } |
344 | 28.3k | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { |
345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", |
346 | 0 | _size_of_element, SIZE_OF_TYPE); |
347 | 0 | } |
348 | 28.3k | _parsed = true; |
349 | 28.3k | return Status::OK(); |
350 | 28.3k | } _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE4initEv Line | Count | Source | 322 | 26.7k | Status init() override { | 323 | 26.7k | CHECK(!_parsed); | 324 | 26.7k | size_t unused; | 325 | 26.7k | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 26.7k | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 26.7k | if (_data.size != | 329 | 26.7k | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 26.7k | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 26.7k | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 26.7k | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 26.7k | _parsed = true; | 349 | 26.7k | return Status::OK(); | 350 | 26.7k | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE4initEv Line | Count | Source | 322 | 670 | Status init() override { | 323 | 670 | CHECK(!_parsed); | 324 | 670 | size_t unused; | 325 | 670 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 670 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 670 | if (_data.size != | 329 | 670 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 670 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 670 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 670 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 670 | _parsed = true; | 349 | 670 | return Status::OK(); | 350 | 670 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE4initEv Line | Count | Source | 322 | 10 | Status init() override { | 323 | 10 | CHECK(!_parsed); | 324 | 10 | size_t unused; | 325 | 10 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 10 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 10 | if (_data.size != | 329 | 10 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 10 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 10 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 10 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 10 | _parsed = true; | 349 | 10 | return Status::OK(); | 350 | 10 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE4initEv Line | Count | Source | 322 | 440 | Status init() override { | 323 | 440 | CHECK(!_parsed); | 324 | 440 | size_t unused; | 325 | 440 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 440 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 440 | if (_data.size != | 329 | 440 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 440 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 440 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 440 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 440 | _parsed = true; | 349 | 440 | return Status::OK(); | 350 | 440 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE4initEv Line | Count | Source | 322 | 382 | Status init() override { | 323 | 382 | CHECK(!_parsed); | 324 | 382 | size_t unused; | 325 | 382 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 382 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 382 | if (_data.size != | 329 | 382 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 382 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 382 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 382 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 382 | _parsed = true; | 349 | 382 | return Status::OK(); | 350 | 382 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE4initEv _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE4initEv Line | Count | Source | 322 | 2 | Status init() override { | 323 | 2 | CHECK(!_parsed); | 324 | 2 | size_t unused; | 325 | 2 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 2 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 2 | if (_data.size != | 329 | 2 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 2 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 2 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 2 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 2 | _parsed = true; | 349 | 2 | return Status::OK(); | 350 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE4initEv _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE4initEv Line | Count | Source | 322 | 10 | Status init() override { | 323 | 10 | CHECK(!_parsed); | 324 | 10 | size_t unused; | 325 | 10 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 10 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 10 | if (_data.size != | 329 | 10 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 10 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 10 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 10 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 10 | _parsed = true; | 349 | 10 | return Status::OK(); | 350 | 10 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE4initEv _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE4initEv Line | Count | Source | 322 | 10 | Status init() override { | 323 | 10 | CHECK(!_parsed); | 324 | 10 | size_t unused; | 325 | 10 | RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused, | 326 | 10 | _num_element_after_padding, _size_of_element)); | 327 | | | 328 | 10 | if (_data.size != | 329 | 10 | _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) { | 330 | 0 | std::stringstream ss; | 331 | 0 | ss << "Size information unmatched, _data.size:" << _data.size | 332 | 0 | << ", _num_elements:" << _num_elements << ", expected size is " | 333 | 0 | << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE; | 334 | 0 | return Status::InternalError(ss.str()); | 335 | 0 | } | 336 | | | 337 | | // Currently, only the UINT32 block encoder supports expanding size: | 338 | 10 | if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT && | 339 | 10 | _size_of_element != SIZE_OF_TYPE)) { | 340 | 0 | return Status::InternalError( | 341 | 0 | "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}", | 342 | 0 | _size_of_element, SIZE_OF_TYPE, Type); | 343 | 0 | } | 344 | 10 | if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) { | 345 | 0 | return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}", | 346 | 0 | _size_of_element, SIZE_OF_TYPE); | 347 | 0 | } | 348 | 10 | _parsed = true; | 349 | 10 | return Status::OK(); | 350 | 10 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE4initEv Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE4initEv |
351 | | |
352 | | // If the page only contains null, then _num_elements == 0, and the nullmap has |
353 | | // some value. But in _seek_columns --> seek_to_ordinal --> _seek_to_pos_in_page |
354 | | // in this call stack it will pass pos == 0 to this method. Although we can add some |
355 | | // code such as check if the count == 0, then skip seek, but there are other method such |
356 | | // as init will also call seek with pos == 0. And the seek is useless when _num_elements |
357 | | // == 0, because next batch will return empty in this method. |
358 | 10.8k | Status seek_to_position_in_page(size_t pos) override { |
359 | 10.8k | DCHECK(_parsed) << "Must call init()"; |
360 | 10.8k | if (_num_elements == 0) [[unlikely]] { |
361 | 0 | if (pos != 0) { |
362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( |
363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); |
364 | 0 | } |
365 | 0 | } |
366 | | |
367 | 10.8k | DCHECK_LE(pos, _num_elements); |
368 | 10.8k | _cur_index = pos; |
369 | 10.8k | return Status::OK(); |
370 | 10.8k | } _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 8.93k | Status seek_to_position_in_page(size_t pos) override { | 359 | 8.93k | DCHECK(_parsed) << "Must call init()"; | 360 | 8.93k | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 8.93k | DCHECK_LE(pos, _num_elements); | 368 | 8.93k | _cur_index = pos; | 369 | 8.93k | return Status::OK(); | 370 | 8.93k | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 1.18k | Status seek_to_position_in_page(size_t pos) override { | 359 | 1.18k | DCHECK(_parsed) << "Must call init()"; | 360 | 1.18k | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 1.18k | DCHECK_LE(pos, _num_elements); | 368 | 1.18k | _cur_index = pos; | 369 | 1.18k | return Status::OK(); | 370 | 1.18k | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 2 | Status seek_to_position_in_page(size_t pos) override { | 359 | 2 | DCHECK(_parsed) << "Must call init()"; | 360 | 2 | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 2 | DCHECK_LE(pos, _num_elements); | 368 | 2 | _cur_index = pos; | 369 | 2 | return Status::OK(); | 370 | 2 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 714 | Status seek_to_position_in_page(size_t pos) override { | 359 | 714 | DCHECK(_parsed) << "Must call init()"; | 360 | 714 | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 714 | DCHECK_LE(pos, _num_elements); | 368 | 714 | _cur_index = pos; | 369 | 714 | return Status::OK(); | 370 | 714 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 62 | Status seek_to_position_in_page(size_t pos) override { | 359 | 62 | DCHECK(_parsed) << "Must call init()"; | 360 | 62 | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 62 | DCHECK_LE(pos, _num_elements); | 368 | 62 | _cur_index = pos; | 369 | 62 | return Status::OK(); | 370 | 62 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE24seek_to_position_in_pageEm _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 2 | Status seek_to_position_in_page(size_t pos) override { | 359 | 2 | DCHECK(_parsed) << "Must call init()"; | 360 | 2 | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 2 | DCHECK_LE(pos, _num_elements); | 368 | 2 | _cur_index = pos; | 369 | 2 | return Status::OK(); | 370 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE24seek_to_position_in_pageEm _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE24seek_to_position_in_pageEm Line | Count | Source | 358 | 2 | Status seek_to_position_in_page(size_t pos) override { | 359 | 2 | DCHECK(_parsed) << "Must call init()"; | 360 | 2 | if (_num_elements == 0) [[unlikely]] { | 361 | 0 | if (pos != 0) { | 362 | 0 | return Status::Error<ErrorCode::INTERNAL_ERROR, false>( | 363 | 0 | "seek pos {} is larger than total elements {}", pos, _num_elements); | 364 | 0 | } | 365 | 0 | } | 366 | | | 367 | 2 | DCHECK_LE(pos, _num_elements); | 368 | 2 | _cur_index = pos; | 369 | 2 | return Status::OK(); | 370 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE24seek_to_position_in_pageEm Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE24seek_to_position_in_pageEm |
371 | | |
372 | 0 | Status seek_at_or_after_value(const void* value, bool* exact_match) override { |
373 | 0 | DCHECK(_parsed) << "Must call init() firstly"; |
374 | |
|
375 | 0 | if (_num_elements == 0) { |
376 | 0 | return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty"); |
377 | 0 | } |
378 | | |
379 | 0 | size_t left = 0; |
380 | 0 | size_t right = _num_elements; |
381 | |
|
382 | 0 | void* mid_value = nullptr; |
383 | | |
384 | | // find the first value >= target. after loop, |
385 | | // - left == index of first value >= target when found |
386 | | // - left == _num_elements when not found (all values < target) |
387 | 0 | while (left < right) { |
388 | 0 | size_t mid = left + (right - left) / 2; |
389 | 0 | mid_value = get_data(mid); |
390 | 0 | if (TypeTraits<Type>::cmp(mid_value, value) < 0) { |
391 | 0 | left = mid + 1; |
392 | 0 | } else { |
393 | 0 | right = mid; |
394 | 0 | } |
395 | 0 | } |
396 | 0 | if (left >= _num_elements) { |
397 | 0 | return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("all value small than the value"); |
398 | 0 | } |
399 | 0 | void* find_value = get_data(left); |
400 | 0 | if (TypeTraits<Type>::cmp(find_value, value) == 0) { |
401 | 0 | *exact_match = true; |
402 | 0 | } else { |
403 | 0 | *exact_match = false; |
404 | 0 | } |
405 | |
|
406 | 0 | _cur_index = left; |
407 | 0 | return Status::OK(); |
408 | 0 | } Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE22seek_at_or_after_valueEPKvPb Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE22seek_at_or_after_valueEPKvPb |
409 | | |
410 | | template <bool forward_index = true> |
411 | 65.6k | Status next_batch(size_t* n, MutableColumnPtr& dst) { |
412 | 65.6k | DCHECK(_parsed); |
413 | 65.6k | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { |
414 | 0 | *n = 0; |
415 | 0 | return Status::OK(); |
416 | 0 | } |
417 | | |
418 | 65.6k | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); |
419 | | |
420 | 65.6k | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); |
421 | 65.6k | *n = max_fetch; |
422 | 65.6k | if constexpr (forward_index) { |
423 | 65.2k | _cur_index += max_fetch; |
424 | 65.2k | } |
425 | | |
426 | 65.6k | return Status::OK(); |
427 | 65.6k | } _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 49.2k | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 49.2k | DCHECK(_parsed); | 413 | 49.2k | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 49.2k | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 49.2k | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 49.2k | *n = max_fetch; | 422 | 49.2k | if constexpr (forward_index) { | 423 | 49.2k | _cur_index += max_fetch; | 424 | 49.2k | } | 425 | | | 426 | 49.2k | return Status::OK(); | 427 | 49.2k | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 3.13k | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 3.13k | DCHECK(_parsed); | 413 | 3.13k | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 3.13k | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 3.13k | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 3.13k | *n = max_fetch; | 422 | 3.13k | if constexpr (forward_index) { | 423 | 3.13k | _cur_index += max_fetch; | 424 | 3.13k | } | 425 | | | 426 | 3.13k | return Status::OK(); | 427 | 3.13k | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 2 | DCHECK(_parsed); | 413 | 2 | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 2 | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 2 | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 2 | *n = max_fetch; | 422 | 2 | if constexpr (forward_index) { | 423 | 2 | _cur_index += max_fetch; | 424 | 2 | } | 425 | | | 426 | 2 | return Status::OK(); | 427 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 12.4k | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 12.4k | DCHECK(_parsed); | 413 | 12.4k | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 12.4k | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 12.4k | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 12.4k | *n = max_fetch; | 422 | 12.4k | if constexpr (forward_index) { | 423 | 12.4k | _cur_index += max_fetch; | 424 | 12.4k | } | 425 | | | 426 | 12.4k | return Status::OK(); | 427 | 12.4k | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 386 | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 386 | DCHECK(_parsed); | 413 | 386 | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 386 | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 386 | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 386 | *n = max_fetch; | 422 | 386 | if constexpr (forward_index) { | 423 | 386 | _cur_index += max_fetch; | 424 | 386 | } | 425 | | | 426 | 386 | return Status::OK(); | 427 | 386 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 388 | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 388 | DCHECK(_parsed); | 413 | 388 | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 388 | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 388 | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 388 | *n = max_fetch; | 422 | | if constexpr (forward_index) { | 423 | | _cur_index += max_fetch; | 424 | | } | 425 | | | 426 | 388 | return Status::OK(); | 427 | 388 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 2 | DCHECK(_parsed); | 413 | 2 | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 2 | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 2 | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 2 | *n = max_fetch; | 422 | 2 | if constexpr (forward_index) { | 423 | 2 | _cur_index += max_fetch; | 424 | 2 | } | 425 | | | 426 | 2 | return Status::OK(); | 427 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 2 | DCHECK(_parsed); | 413 | 2 | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 2 | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 2 | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 2 | *n = max_fetch; | 422 | 2 | if constexpr (forward_index) { | 423 | 2 | _cur_index += max_fetch; | 424 | 2 | } | 425 | | | 426 | 2 | return Status::OK(); | 427 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 411 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) { | 412 | 2 | DCHECK(_parsed); | 413 | 2 | if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] { | 414 | 0 | *n = 0; | 415 | 0 | return Status::OK(); | 416 | 0 | } | 417 | | | 418 | 2 | size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elements - _cur_index)); | 419 | | | 420 | 2 | dst->insert_many_fix_len_data(get_data(_cur_index), max_fetch); | 421 | 2 | *n = max_fetch; | 422 | 2 | if constexpr (forward_index) { | 423 | 2 | _cur_index += max_fetch; | 424 | 2 | } | 425 | | | 426 | 2 | return Status::OK(); | 427 | 2 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE |
428 | | |
429 | 65.2k | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 49.2k | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 3.13k | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 12.4k | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 386 | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 429 | 2 | Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE |
430 | | |
431 | | Status read_by_rowids(const rowid_t* rowids, ordinal_t page_first_ordinal, size_t* n, |
432 | 9.82k | MutableColumnPtr& dst) override { |
433 | 9.82k | DCHECK(_parsed); |
434 | 9.82k | if (*n == 0) [[unlikely]] { |
435 | 0 | *n = 0; |
436 | 0 | return Status::OK(); |
437 | 0 | } |
438 | | |
439 | 9.82k | auto total = *n; |
440 | 9.82k | auto read_count = 0; |
441 | 9.82k | _buffer.resize(total); |
442 | 6.64M | for (size_t i = 0; i < total; ++i) { |
443 | 6.63M | ordinal_t ord = rowids[i] - page_first_ordinal; |
444 | 6.63M | if (UNLIKELY(ord >= _num_elements)) { |
445 | 18 | break; |
446 | 18 | } |
447 | | |
448 | 6.63M | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); |
449 | 6.63M | } |
450 | | |
451 | 9.82k | if (LIKELY(read_count > 0)) { |
452 | 9.82k | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); |
453 | 9.82k | } |
454 | | |
455 | 9.82k | *n = read_count; |
456 | 9.82k | return Status::OK(); |
457 | 9.82k | } _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 7.89k | MutableColumnPtr& dst) override { | 433 | 7.89k | DCHECK(_parsed); | 434 | 7.89k | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 7.89k | auto total = *n; | 440 | 7.89k | auto read_count = 0; | 441 | 7.89k | _buffer.resize(total); | 442 | 5.52M | for (size_t i = 0; i < total; ++i) { | 443 | 5.52M | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 5.52M | if (UNLIKELY(ord >= _num_elements)) { | 445 | 18 | break; | 446 | 18 | } | 447 | | | 448 | 5.52M | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 5.52M | } | 450 | | | 451 | 7.89k | if (LIKELY(read_count > 0)) { | 452 | 7.89k | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 7.89k | } | 454 | | | 455 | 7.89k | *n = read_count; | 456 | 7.89k | return Status::OK(); | 457 | 7.89k | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 1.31k | MutableColumnPtr& dst) override { | 433 | 1.31k | DCHECK(_parsed); | 434 | 1.31k | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 1.31k | auto total = *n; | 440 | 1.31k | auto read_count = 0; | 441 | 1.31k | _buffer.resize(total); | 442 | 1.09M | for (size_t i = 0; i < total; ++i) { | 443 | 1.09M | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 1.09M | if (UNLIKELY(ord >= _num_elements)) { | 445 | 0 | break; | 446 | 0 | } | 447 | | | 448 | 1.09M | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 1.09M | } | 450 | | | 451 | 1.31k | if (LIKELY(read_count > 0)) { | 452 | 1.31k | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 1.31k | } | 454 | | | 455 | 1.31k | *n = read_count; | 456 | 1.31k | return Status::OK(); | 457 | 1.31k | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 8 | MutableColumnPtr& dst) override { | 433 | 8 | DCHECK(_parsed); | 434 | 8 | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 8 | auto total = *n; | 440 | 8 | auto read_count = 0; | 441 | 8 | _buffer.resize(total); | 442 | 16 | for (size_t i = 0; i < total; ++i) { | 443 | 8 | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 8 | if (UNLIKELY(ord >= _num_elements)) { | 445 | 0 | break; | 446 | 0 | } | 447 | | | 448 | 8 | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 8 | } | 450 | | | 451 | 8 | if (LIKELY(read_count > 0)) { | 452 | 8 | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 8 | } | 454 | | | 455 | 8 | *n = read_count; | 456 | 8 | return Status::OK(); | 457 | 8 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 536 | MutableColumnPtr& dst) override { | 433 | 536 | DCHECK(_parsed); | 434 | 536 | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 536 | auto total = *n; | 440 | 536 | auto read_count = 0; | 441 | 536 | _buffer.resize(total); | 442 | 2.60k | for (size_t i = 0; i < total; ++i) { | 443 | 2.06k | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 2.06k | if (UNLIKELY(ord >= _num_elements)) { | 445 | 0 | break; | 446 | 0 | } | 447 | | | 448 | 2.06k | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 2.06k | } | 450 | | | 451 | 536 | if (LIKELY(read_count > 0)) { | 452 | 536 | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 536 | } | 454 | | | 455 | 536 | *n = read_count; | 456 | 536 | return Status::OK(); | 457 | 536 | } |
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 52 | MutableColumnPtr& dst) override { | 433 | 52 | DCHECK(_parsed); | 434 | 52 | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 52 | auto total = *n; | 440 | 52 | auto read_count = 0; | 441 | 52 | _buffer.resize(total); | 442 | 13.7k | for (size_t i = 0; i < total; ++i) { | 443 | 13.7k | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 13.7k | if (UNLIKELY(ord >= _num_elements)) { | 445 | 0 | break; | 446 | 0 | } | 447 | | | 448 | 13.7k | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 13.7k | } | 450 | | | 451 | 52 | if (LIKELY(read_count > 0)) { | 452 | 52 | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 52 | } | 454 | | | 455 | 52 | *n = read_count; | 456 | 52 | return Status::OK(); | 457 | 52 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 8 | MutableColumnPtr& dst) override { | 433 | 8 | DCHECK(_parsed); | 434 | 8 | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 8 | auto total = *n; | 440 | 8 | auto read_count = 0; | 441 | 8 | _buffer.resize(total); | 442 | 16 | for (size_t i = 0; i < total; ++i) { | 443 | 8 | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 8 | if (UNLIKELY(ord >= _num_elements)) { | 445 | 0 | break; | 446 | 0 | } | 447 | | | 448 | 8 | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 8 | } | 450 | | | 451 | 8 | if (LIKELY(read_count > 0)) { | 452 | 8 | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 8 | } | 454 | | | 455 | 8 | *n = read_count; | 456 | 8 | return Status::OK(); | 457 | 8 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Line | Count | Source | 432 | 8 | MutableColumnPtr& dst) override { | 433 | 8 | DCHECK(_parsed); | 434 | 8 | if (*n == 0) [[unlikely]] { | 435 | 0 | *n = 0; | 436 | 0 | return Status::OK(); | 437 | 0 | } | 438 | | | 439 | 8 | auto total = *n; | 440 | 8 | auto read_count = 0; | 441 | 8 | _buffer.resize(total); | 442 | 16 | for (size_t i = 0; i < total; ++i) { | 443 | 8 | ordinal_t ord = rowids[i] - page_first_ordinal; | 444 | 8 | if (UNLIKELY(ord >= _num_elements)) { | 445 | 0 | break; | 446 | 0 | } | 447 | | | 448 | 8 | _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord)); | 449 | 8 | } | 450 | | | 451 | 8 | if (LIKELY(read_count > 0)) { | 452 | 8 | dst->insert_many_fix_len_data((char*)_buffer.data(), read_count); | 453 | 8 | } | 454 | | | 455 | 8 | *n = read_count; | 456 | 8 | return Status::OK(); | 457 | 8 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE |
458 | | |
459 | 388 | Status peek_next_batch(size_t* n, MutableColumnPtr& dst) override { |
460 | 388 | return next_batch<false>(n, dst); |
461 | 388 | } Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Line | Count | Source | 459 | 388 | Status peek_next_batch(size_t* n, MutableColumnPtr& dst) override { | 460 | 388 | return next_batch<false>(n, dst); | 461 | 388 | } |
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE |
462 | | |
463 | 6 | size_t count() const override { return _num_elements; }_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE5countEv Line | Count | Source | 463 | 6 | size_t count() const override { return _num_elements; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE5countEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE5countEv |
464 | | |
465 | 1.79k | size_t current_index() const override { return _cur_index; }_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE13current_indexEv Line | Count | Source | 465 | 398 | size_t current_index() const override { return _cur_index; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE13current_indexEv _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE13current_indexEv Line | Count | Source | 465 | 1.39k | size_t current_index() const override { return _cur_index; } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE13current_indexEv Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE13current_indexEv |
466 | | |
467 | 6.71M | char* get_data(size_t index) const { |
468 | 6.71M | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; |
469 | 6.71M | } _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE8get_dataEm Line | Count | Source | 467 | 5.58M | char* get_data(size_t index) const { | 468 | 5.58M | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 5.58M | } |
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE8get_dataEm Line | Count | Source | 467 | 1.09M | char* get_data(size_t index) const { | 468 | 1.09M | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 1.09M | } |
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE8get_dataEm Line | Count | Source | 467 | 10 | char* get_data(size_t index) const { | 468 | 10 | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 10 | } |
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE8get_dataEm Line | Count | Source | 467 | 14.5k | char* get_data(size_t index) const { | 468 | 14.5k | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 14.5k | } |
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE8get_dataEm Line | Count | Source | 467 | 14.4k | char* get_data(size_t index) const { | 468 | 14.4k | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 14.4k | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE8get_dataEm _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE8get_dataEm Line | Count | Source | 467 | 2 | char* get_data(size_t index) const { | 468 | 2 | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 2 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE8get_dataEm _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE8get_dataEm Line | Count | Source | 467 | 10 | char* get_data(size_t index) const { | 468 | 10 | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 10 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE8get_dataEm _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE8get_dataEm Line | Count | Source | 467 | 10 | char* get_data(size_t index) const { | 468 | 10 | return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE]; | 469 | 10 | } |
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE8get_dataEm Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE8get_dataEm |
470 | | |
471 | | private: |
472 | | void _copy_next_values(size_t n, void* data) { |
473 | | memcpy(data, get_data(_cur_index), n * SIZE_OF_TYPE); |
474 | | } |
475 | | |
476 | | using CppType = typename TypeTraits<Type>::CppType; |
477 | | |
478 | | enum { SIZE_OF_TYPE = TypeTraits<Type>::size }; |
479 | | |
480 | | Slice _data; |
481 | | PageDecoderOptions _options; |
482 | | bool _parsed; |
483 | | size_t _num_elements; |
484 | | size_t _num_element_after_padding; |
485 | | |
486 | | int _size_of_element; |
487 | | size_t _cur_index; |
488 | | |
489 | | std::vector<std::conditional_t<std::is_same_v<CppType, bool>, uint8_t, CppType>> _buffer; |
490 | | |
491 | | friend class BinaryDictPageDecoder; |
492 | | }; |
493 | | |
494 | | #include "common/compile_check_end.h" |
495 | | } // namespace segment_v2 |
496 | | } // namespace doris |