Coverage Report

Created: 2026-10-29 13:02

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
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/storage_layout.h"
42
#include "storage/types.h"
43
#include "util/alignment.h"
44
#include "util/coding.h"
45
#include "util/faststring.h"
46
#include "util/slice.h"
47
48
namespace doris {
49
namespace segment_v2 {
50
51
static constexpr size_t 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
705k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE4initEv
Line
Count
Source
96
50.9k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE4initEv
Line
Count
Source
96
11.3k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE4initEv
Line
Count
Source
96
362k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE4initEv
Line
Count
Source
96
50.5k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE4initEv
Line
Count
Source
96
14.6k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE4initEv
Line
Count
Source
96
64.9k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE4initEv
Line
Count
Source
96
1
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE4initEv
Line
Count
Source
96
8.30k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE4initEv
Line
Count
Source
96
9.81k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE4initEv
Line
Count
Source
96
2
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE4initEv
Line
Count
Source
96
678
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE4initEv
Line
Count
Source
96
37.1k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE4initEv
Line
Count
Source
96
44.4k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE4initEv
Line
Count
Source
96
337
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE4initEv
Line
Count
Source
96
439
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE4initEv
Line
Count
Source
96
7.68k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE4initEv
Line
Count
Source
96
336
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE4initEv
Line
Count
Source
96
9.70k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE4initEv
Line
Count
Source
96
12.0k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE4initEv
Line
Count
Source
96
16.9k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE4initEv
Line
Count
Source
96
1.21k
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE4initEv
Line
Count
Source
96
669
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE4initEv
Line
Count
Source
96
667
    Status init() override { return reset(); }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE4initEv
Line
Count
Source
96
587
    Status init() override { return reset(); }
97
98
150M
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE12is_page_fullEv
Line
Count
Source
98
63.2k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE12is_page_fullEv
Line
Count
Source
98
15.9k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE12is_page_fullEv
Line
Count
Source
98
149M
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE12is_page_fullEv
Line
Count
Source
98
257k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE12is_page_fullEv
Line
Count
Source
98
13.9k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE12is_page_fullEv
Line
Count
Source
98
65.2k
    bool is_page_full() override { return _remain_element_capacity == 0; }
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE12is_page_fullEv
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE12is_page_fullEv
Line
Count
Source
98
7.58k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE12is_page_fullEv
Line
Count
Source
98
21.2k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE12is_page_fullEv
Line
Count
Source
98
194
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE12is_page_fullEv
Line
Count
Source
98
765
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE12is_page_fullEv
Line
Count
Source
98
43.8k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE12is_page_fullEv
Line
Count
Source
98
44.3k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE12is_page_fullEv
Line
Count
Source
98
335
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE12is_page_fullEv
Line
Count
Source
98
569
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE12is_page_fullEv
Line
Count
Source
98
7.72k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE12is_page_fullEv
Line
Count
Source
98
312
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE12is_page_fullEv
Line
Count
Source
98
5.26k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE12is_page_fullEv
Line
Count
Source
98
26.5k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE12is_page_fullEv
Line
Count
Source
98
17.9k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE12is_page_fullEv
Line
Count
Source
98
1.47k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE12is_page_fullEv
Line
Count
Source
98
628
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE12is_page_fullEv
Line
Count
Source
98
651
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE12is_page_fullEv
Line
Count
Source
98
26.5k
    bool is_page_full() override { return _remain_element_capacity == 0; }
99
100
1.37M
    Status add(const uint8_t* vals, size_t* count) override {
101
1.37M
        return add_internal<false>(vals, count);
102
1.37M
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE3addEPKhPm
Line
Count
Source
100
63.2k
    Status add(const uint8_t* vals, size_t* count) override {
101
63.2k
        return add_internal<false>(vals, count);
102
63.2k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE3addEPKhPm
Line
Count
Source
100
15.9k
    Status add(const uint8_t* vals, size_t* count) override {
101
15.9k
        return add_internal<false>(vals, count);
102
15.9k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE3addEPKhPm
Line
Count
Source
100
750k
    Status add(const uint8_t* vals, size_t* count) override {
101
750k
        return add_internal<false>(vals, count);
102
750k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE3addEPKhPm
Line
Count
Source
100
257k
    Status add(const uint8_t* vals, size_t* count) override {
101
257k
        return add_internal<false>(vals, count);
102
257k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE3addEPKhPm
Line
Count
Source
100
13.9k
    Status add(const uint8_t* vals, size_t* count) override {
101
13.9k
        return add_internal<false>(vals, count);
102
13.9k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE3addEPKhPm
Line
Count
Source
100
65.2k
    Status add(const uint8_t* vals, size_t* count) override {
101
65.2k
        return add_internal<false>(vals, count);
102
65.2k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE3addEPKhPm
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE3addEPKhPm
Line
Count
Source
100
7.59k
    Status add(const uint8_t* vals, size_t* count) override {
101
7.59k
        return add_internal<false>(vals, count);
102
7.59k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE3addEPKhPm
Line
Count
Source
100
21.2k
    Status add(const uint8_t* vals, size_t* count) override {
101
21.2k
        return add_internal<false>(vals, count);
102
21.2k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE3addEPKhPm
Line
Count
Source
100
194
    Status add(const uint8_t* vals, size_t* count) override {
101
194
        return add_internal<false>(vals, count);
102
194
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE3addEPKhPm
Line
Count
Source
100
767
    Status add(const uint8_t* vals, size_t* count) override {
101
767
        return add_internal<false>(vals, count);
102
767
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE3addEPKhPm
Line
Count
Source
100
43.8k
    Status add(const uint8_t* vals, size_t* count) override {
101
43.8k
        return add_internal<false>(vals, count);
102
43.8k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE3addEPKhPm
Line
Count
Source
100
44.3k
    Status add(const uint8_t* vals, size_t* count) override {
101
44.3k
        return add_internal<false>(vals, count);
102
44.3k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE3addEPKhPm
Line
Count
Source
100
335
    Status add(const uint8_t* vals, size_t* count) override {
101
335
        return add_internal<false>(vals, count);
102
335
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE3addEPKhPm
Line
Count
Source
100
569
    Status add(const uint8_t* vals, size_t* count) override {
101
569
        return add_internal<false>(vals, count);
102
569
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE3addEPKhPm
Line
Count
Source
100
7.72k
    Status add(const uint8_t* vals, size_t* count) override {
101
7.72k
        return add_internal<false>(vals, count);
102
7.72k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE3addEPKhPm
Line
Count
Source
100
313
    Status add(const uint8_t* vals, size_t* count) override {
101
313
        return add_internal<false>(vals, count);
102
313
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE3addEPKhPm
Line
Count
Source
100
5.26k
    Status add(const uint8_t* vals, size_t* count) override {
101
5.26k
        return add_internal<false>(vals, count);
102
5.26k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE3addEPKhPm
Line
Count
Source
100
26.5k
    Status add(const uint8_t* vals, size_t* count) override {
101
26.5k
        return add_internal<false>(vals, count);
102
26.5k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE3addEPKhPm
Line
Count
Source
100
17.9k
    Status add(const uint8_t* vals, size_t* count) override {
101
17.9k
        return add_internal<false>(vals, count);
102
17.9k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE3addEPKhPm
Line
Count
Source
100
1.47k
    Status add(const uint8_t* vals, size_t* count) override {
101
1.47k
        return add_internal<false>(vals, count);
102
1.47k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE3addEPKhPm
Line
Count
Source
100
628
    Status add(const uint8_t* vals, size_t* count) override {
101
628
        return add_internal<false>(vals, count);
102
628
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE3addEPKhPm
Line
Count
Source
100
651
    Status add(const uint8_t* vals, size_t* count) override {
101
651
        return add_internal<false>(vals, count);
102
651
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE3addEPKhPm
Line
Count
Source
100
26.5k
    Status add(const uint8_t* vals, size_t* count) override {
101
26.5k
        return add_internal<false>(vals, count);
102
26.5k
    }
103
104
149M
    Status single_add(const uint8_t* vals, size_t* count) {
105
149M
        return add_internal<true>(vals, count);
106
149M
    }
107
108
    template <bool single>
109
147M
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
147M
        DCHECK(!_finished);
111
147M
        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
147M
        uint32_t to_add = cast_set<UInt32>(
127
147M
                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
147M
        int to_add_size = to_add * SIZE_OF_TYPE;
130
147M
        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
147M
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
150M
        _count += to_add;
135
150M
        _remain_element_capacity -= to_add;
136
150M
        _raw_data_size += to_add_size;
137
        // return added number through count
138
150M
        *num_written = to_add;
139
150M
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
149M
            } else if constexpr (SIZE_OF_TYPE == 4) {
148
149M
                *reinterpret_cast<uint32_t*>(&_data[orig_size]) =
149
149M
                        *reinterpret_cast<const uint32_t*>(vals);
150
149M
                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
149M
        }
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
150M
        return Status::OK();
160
147M
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
63.2k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
63.2k
        DCHECK(!_finished);
111
63.2k
        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
63.2k
        uint32_t to_add = cast_set<UInt32>(
127
63.2k
                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
63.2k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
63.2k
        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
63.2k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
63.2k
        _count += to_add;
135
63.2k
        _remain_element_capacity -= to_add;
136
63.2k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
63.2k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
63.2k
        memcpy(&_data[orig_size], vals, to_add_size);
159
63.2k
        return Status::OK();
160
63.2k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
15.9k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
15.9k
        DCHECK(!_finished);
111
15.9k
        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
15.9k
        uint32_t to_add = cast_set<UInt32>(
127
15.9k
                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
15.9k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
15.9k
        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
15.9k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
15.9k
        _count += to_add;
135
15.9k
        _remain_element_capacity -= to_add;
136
15.9k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
15.9k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
15.9k
        memcpy(&_data[orig_size], vals, to_add_size);
159
15.9k
        return Status::OK();
160
15.9k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
750k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
750k
        DCHECK(!_finished);
111
750k
        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
750k
        uint32_t to_add = cast_set<UInt32>(
127
750k
                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
750k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
750k
        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
750k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
750k
        _count += to_add;
135
750k
        _remain_element_capacity -= to_add;
136
750k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
750k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
750k
        memcpy(&_data[orig_size], vals, to_add_size);
159
750k
        return Status::OK();
160
750k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
257k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
257k
        DCHECK(!_finished);
111
257k
        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
257k
        uint32_t to_add = cast_set<UInt32>(
127
257k
                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
257k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
257k
        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
257k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
257k
        _count += to_add;
135
257k
        _remain_element_capacity -= to_add;
136
257k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
257k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
257k
        memcpy(&_data[orig_size], vals, to_add_size);
159
257k
        return Status::OK();
160
257k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
13.9k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
13.9k
        DCHECK(!_finished);
111
13.9k
        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
13.9k
        uint32_t to_add = cast_set<UInt32>(
127
13.9k
                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
13.9k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
13.9k
        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
13.9k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
13.9k
        _count += to_add;
135
13.9k
        _remain_element_capacity -= to_add;
136
13.9k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
13.9k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
13.9k
        memcpy(&_data[orig_size], vals, to_add_size);
159
13.9k
        return Status::OK();
160
13.9k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
65.2k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
65.2k
        DCHECK(!_finished);
111
65.2k
        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
65.2k
        uint32_t to_add = cast_set<UInt32>(
127
65.2k
                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
65.2k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
65.2k
        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
65.2k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
65.2k
        _count += to_add;
135
65.2k
        _remain_element_capacity -= to_add;
136
65.2k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
65.2k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
65.2k
        memcpy(&_data[orig_size], vals, to_add_size);
159
65.2k
        return Status::OK();
160
65.2k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE12add_internalILb0EEENS_6StatusEPKhPm
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
7.58k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
7.58k
        DCHECK(!_finished);
111
7.58k
        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
7.58k
        uint32_t to_add = cast_set<UInt32>(
127
7.58k
                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
7.58k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
7.58k
        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
7.58k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
7.59k
        _count += to_add;
135
7.59k
        _remain_element_capacity -= to_add;
136
7.59k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
7.59k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
7.59k
        memcpy(&_data[orig_size], vals, to_add_size);
159
7.59k
        return Status::OK();
160
7.58k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
21.2k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
21.2k
        DCHECK(!_finished);
111
21.2k
        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
21.2k
        uint32_t to_add = cast_set<UInt32>(
127
21.2k
                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
21.2k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
21.2k
        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
21.2k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
21.2k
        _count += to_add;
135
21.2k
        _remain_element_capacity -= to_add;
136
21.2k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
21.2k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
21.2k
        memcpy(&_data[orig_size], vals, to_add_size);
159
21.2k
        return Status::OK();
160
21.2k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
194
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
194
        DCHECK(!_finished);
111
194
        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
194
        uint32_t to_add = cast_set<UInt32>(
127
194
                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
194
        int to_add_size = to_add * SIZE_OF_TYPE;
130
194
        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
194
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
194
        _count += to_add;
135
194
        _remain_element_capacity -= to_add;
136
194
        _raw_data_size += to_add_size;
137
        // return added number through count
138
194
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
194
        memcpy(&_data[orig_size], vals, to_add_size);
159
194
        return Status::OK();
160
194
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
767
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
767
        DCHECK(!_finished);
111
767
        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
767
        uint32_t to_add = cast_set<UInt32>(
127
767
                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
767
        int to_add_size = to_add * SIZE_OF_TYPE;
130
767
        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
767
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
767
        _count += to_add;
135
767
        _remain_element_capacity -= to_add;
136
767
        _raw_data_size += to_add_size;
137
        // return added number through count
138
767
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
767
        memcpy(&_data[orig_size], vals, to_add_size);
159
767
        return Status::OK();
160
767
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
43.8k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
43.8k
        DCHECK(!_finished);
111
43.8k
        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
43.8k
        uint32_t to_add = cast_set<UInt32>(
127
43.8k
                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
43.8k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
43.8k
        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
43.8k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
43.8k
        _count += to_add;
135
43.8k
        _remain_element_capacity -= to_add;
136
43.8k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
43.8k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
43.8k
        memcpy(&_data[orig_size], vals, to_add_size);
159
43.8k
        return Status::OK();
160
43.8k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
44.3k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
44.3k
        DCHECK(!_finished);
111
44.3k
        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
44.3k
        uint32_t to_add = cast_set<UInt32>(
127
44.3k
                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
44.3k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
44.3k
        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
44.3k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
44.3k
        _count += to_add;
135
44.3k
        _remain_element_capacity -= to_add;
136
44.3k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
44.3k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
44.3k
        memcpy(&_data[orig_size], vals, to_add_size);
159
44.3k
        return Status::OK();
160
44.3k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
335
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
335
        DCHECK(!_finished);
111
335
        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
335
        uint32_t to_add = cast_set<UInt32>(
127
335
                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
335
        int to_add_size = to_add * SIZE_OF_TYPE;
130
335
        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
335
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
335
        _count += to_add;
135
335
        _remain_element_capacity -= to_add;
136
335
        _raw_data_size += to_add_size;
137
        // return added number through count
138
335
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
335
        memcpy(&_data[orig_size], vals, to_add_size);
159
335
        return Status::OK();
160
335
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
569
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
569
        DCHECK(!_finished);
111
569
        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
569
        uint32_t to_add = cast_set<UInt32>(
127
569
                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
569
        int to_add_size = to_add * SIZE_OF_TYPE;
130
569
        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
569
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
569
        _count += to_add;
135
569
        _remain_element_capacity -= to_add;
136
569
        _raw_data_size += to_add_size;
137
        // return added number through count
138
569
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
569
        memcpy(&_data[orig_size], vals, to_add_size);
159
569
        return Status::OK();
160
569
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
7.72k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
7.72k
        DCHECK(!_finished);
111
7.72k
        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
7.72k
        uint32_t to_add = cast_set<UInt32>(
127
7.72k
                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
7.72k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
7.72k
        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
7.72k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
7.71k
        _count += to_add;
135
7.71k
        _remain_element_capacity -= to_add;
136
7.71k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
7.71k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
7.71k
        memcpy(&_data[orig_size], vals, to_add_size);
159
7.71k
        return Status::OK();
160
7.72k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
313
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
313
        DCHECK(!_finished);
111
313
        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
313
        uint32_t to_add = cast_set<UInt32>(
127
313
                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
313
        int to_add_size = to_add * SIZE_OF_TYPE;
130
313
        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
313
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
313
        _count += to_add;
135
313
        _remain_element_capacity -= to_add;
136
313
        _raw_data_size += to_add_size;
137
        // return added number through count
138
313
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
313
        memcpy(&_data[orig_size], vals, to_add_size);
159
313
        return Status::OK();
160
313
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
5.26k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
5.26k
        DCHECK(!_finished);
111
5.26k
        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
5.26k
        uint32_t to_add = cast_set<UInt32>(
127
5.26k
                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
5.26k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
5.26k
        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
5.26k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
5.26k
        _count += to_add;
135
5.26k
        _remain_element_capacity -= to_add;
136
5.26k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
5.26k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
5.26k
        memcpy(&_data[orig_size], vals, to_add_size);
159
5.26k
        return Status::OK();
160
5.26k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
26.5k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
26.5k
        DCHECK(!_finished);
111
26.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
26.5k
        uint32_t to_add = cast_set<UInt32>(
127
26.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
26.5k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
26.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
26.5k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
26.5k
        _count += to_add;
135
26.5k
        _remain_element_capacity -= to_add;
136
26.5k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
26.5k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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.5k
        memcpy(&_data[orig_size], vals, to_add_size);
159
26.5k
        return Status::OK();
160
26.5k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
17.9k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
17.9k
        DCHECK(!_finished);
111
17.9k
        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
17.9k
        uint32_t to_add = cast_set<UInt32>(
127
17.9k
                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
17.9k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
17.9k
        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
17.9k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
18.0k
        _count += to_add;
135
18.0k
        _remain_element_capacity -= to_add;
136
18.0k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
18.0k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
18.0k
        memcpy(&_data[orig_size], vals, to_add_size);
159
18.0k
        return Status::OK();
160
17.9k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
1.47k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
1.47k
        DCHECK(!_finished);
111
1.47k
        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.47k
        uint32_t to_add = cast_set<UInt32>(
127
1.47k
                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.47k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
1.47k
        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.47k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
1.47k
        _count += to_add;
135
1.47k
        _remain_element_capacity -= to_add;
136
1.47k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
1.47k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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.47k
        memcpy(&_data[orig_size], vals, to_add_size);
159
1.47k
        return Status::OK();
160
1.47k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
628
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
628
        DCHECK(!_finished);
111
628
        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
628
        uint32_t to_add = cast_set<UInt32>(
127
628
                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
628
        int to_add_size = to_add * SIZE_OF_TYPE;
130
628
        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
628
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
628
        _count += to_add;
135
628
        _remain_element_capacity -= to_add;
136
628
        _raw_data_size += to_add_size;
137
        // return added number through count
138
628
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
628
        memcpy(&_data[orig_size], vals, to_add_size);
159
628
        return Status::OK();
160
628
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
651
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
651
        DCHECK(!_finished);
111
651
        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
651
        uint32_t to_add = cast_set<UInt32>(
127
651
                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
651
        int to_add_size = to_add * SIZE_OF_TYPE;
130
651
        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
651
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
651
        _count += to_add;
135
651
        _remain_element_capacity -= to_add;
136
651
        _raw_data_size += to_add_size;
137
        // return added number through count
138
651
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
651
        memcpy(&_data[orig_size], vals, to_add_size);
159
651
        return Status::OK();
160
651
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE12add_internalILb0EEENS_6StatusEPKhPm
Line
Count
Source
109
26.5k
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
26.5k
        DCHECK(!_finished);
111
26.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
26.5k
        uint32_t to_add = cast_set<UInt32>(
127
26.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
26.5k
        int to_add_size = to_add * SIZE_OF_TYPE;
130
26.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
26.5k
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
26.5k
        _count += to_add;
135
26.5k
        _remain_element_capacity -= to_add;
136
26.5k
        _raw_data_size += to_add_size;
137
        // return added number through count
138
26.5k
        *num_written = to_add;
139
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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.5k
        memcpy(&_data[orig_size], vals, to_add_size);
159
26.5k
        return Status::OK();
160
26.5k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE12add_internalILb1EEENS_6StatusEPKhPm
Line
Count
Source
109
146M
    inline Status add_internal(const uint8_t* vals, size_t* num_written) {
110
146M
        DCHECK(!_finished);
111
146M
        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
146M
        uint32_t to_add = cast_set<UInt32>(
127
146M
                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
146M
        int to_add_size = to_add * SIZE_OF_TYPE;
130
146M
        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
146M
        RETURN_IF_CATCH_EXCEPTION(_data.resize(orig_size + to_add_size));
134
149M
        _count += to_add;
135
149M
        _remain_element_capacity -= to_add;
136
149M
        _raw_data_size += to_add_size;
137
        // return added number through count
138
149M
        *num_written = to_add;
139
149M
        if constexpr (single) {
140
            if constexpr (SIZE_OF_TYPE == 1) {
141
                _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
149M
            } else if constexpr (SIZE_OF_TYPE == 4) {
148
149M
                *reinterpret_cast<uint32_t*>(&_data[orig_size]) =
149
149M
                        *reinterpret_cast<const uint32_t*>(vals);
150
149M
                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
149M
        }
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
149M
        return Status::OK();
160
146M
    }
161
162
701k
    Status finish(OwnedSlice* slice) override {
163
701k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
701k
        return Status::OK();
165
701k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
50.0k
    Status finish(OwnedSlice* slice) override {
163
50.0k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
50.0k
        return Status::OK();
165
50.0k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
10.4k
    Status finish(OwnedSlice* slice) override {
163
10.4k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
10.4k
        return Status::OK();
165
10.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
353k
    Status finish(OwnedSlice* slice) override {
163
353k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
353k
        return Status::OK();
165
353k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
52.1k
    Status finish(OwnedSlice* slice) override {
163
52.1k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
52.1k
        return Status::OK();
165
52.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
14.1k
    Status finish(OwnedSlice* slice) override {
163
14.1k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
14.1k
        return Status::OK();
165
14.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
64.5k
    Status finish(OwnedSlice* slice) override {
163
64.5k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
64.5k
        return Status::OK();
165
64.5k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE6finishEPNS_10OwnedSliceE
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
7.53k
    Status finish(OwnedSlice* slice) override {
163
7.53k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
7.53k
        return Status::OK();
165
7.53k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
10.6k
    Status finish(OwnedSlice* slice) override {
163
10.6k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
10.6k
        return Status::OK();
165
10.6k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
6
    Status finish(OwnedSlice* slice) override {
163
6
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
6
        return Status::OK();
165
6
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
709
    Status finish(OwnedSlice* slice) override {
163
709
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
709
        return Status::OK();
165
709
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
37.6k
    Status finish(OwnedSlice* slice) override {
163
37.6k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
37.6k
        return Status::OK();
165
37.6k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
43.4k
    Status finish(OwnedSlice* slice) override {
163
43.4k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
43.4k
        return Status::OK();
165
43.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
277
    Status finish(OwnedSlice* slice) override {
163
277
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
277
        return Status::OK();
165
277
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
606
    Status finish(OwnedSlice* slice) override {
163
606
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
606
        return Status::OK();
165
606
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
7.76k
    Status finish(OwnedSlice* slice) override {
163
7.76k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
7.76k
        return Status::OK();
165
7.76k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
262
    Status finish(OwnedSlice* slice) override {
163
262
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
262
        return Status::OK();
165
262
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
9.71k
    Status finish(OwnedSlice* slice) override {
163
9.71k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
9.71k
        return Status::OK();
165
9.71k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
18.5k
    Status finish(OwnedSlice* slice) override {
163
18.5k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
18.5k
        return Status::OK();
165
18.5k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
17.1k
    Status finish(OwnedSlice* slice) override {
163
17.1k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
17.1k
        return Status::OK();
165
17.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
1.14k
    Status finish(OwnedSlice* slice) override {
163
1.14k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
1.14k
        return Status::OK();
165
1.14k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
582
    Status finish(OwnedSlice* slice) override {
163
582
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
582
        return Status::OK();
165
582
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
589
    Status finish(OwnedSlice* slice) override {
163
589
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
589
        return Status::OK();
165
589
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE6finishEPNS_10OwnedSliceE
Line
Count
Source
162
691
    Status finish(OwnedSlice* slice) override {
163
691
        RETURN_IF_CATCH_EXCEPTION({ *slice = _finish(SIZE_OF_TYPE); });
164
691
        return Status::OK();
165
691
    }
166
167
1.69M
    Status reset() override {
168
1.69M
        RETURN_IF_CATCH_EXCEPTION({
169
1.69M
            size_t block_size = _options.data_page_size;
170
1.69M
            _count = 0;
171
1.69M
            _raw_data_size = 0;
172
1.69M
            _data.clear();
173
1.69M
            _data.reserve(block_size);
174
1.69M
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.69M
                    << "buffer must be naturally-aligned";
176
1.69M
            _buffer.clear();
177
1.69M
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.69M
            _finished = false;
179
1.69M
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.69M
        });
181
1.69M
        return Status::OK();
182
1.69M
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE5resetEv
Line
Count
Source
167
100k
    Status reset() override {
168
100k
        RETURN_IF_CATCH_EXCEPTION({
169
100k
            size_t block_size = _options.data_page_size;
170
100k
            _count = 0;
171
100k
            _raw_data_size = 0;
172
100k
            _data.clear();
173
100k
            _data.reserve(block_size);
174
100k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
100k
                    << "buffer must be naturally-aligned";
176
100k
            _buffer.clear();
177
100k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
100k
            _finished = false;
179
100k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
100k
        });
181
100k
        return Status::OK();
182
100k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE5resetEv
Line
Count
Source
167
21.7k
    Status reset() override {
168
21.7k
        RETURN_IF_CATCH_EXCEPTION({
169
21.7k
            size_t block_size = _options.data_page_size;
170
21.7k
            _count = 0;
171
21.7k
            _raw_data_size = 0;
172
21.7k
            _data.clear();
173
21.7k
            _data.reserve(block_size);
174
21.7k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
21.7k
                    << "buffer must be naturally-aligned";
176
21.7k
            _buffer.clear();
177
21.7k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
21.7k
            _finished = false;
179
21.7k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
21.7k
        });
181
21.7k
        return Status::OK();
182
21.7k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE5resetEv
Line
Count
Source
167
1.00M
    Status reset() override {
168
1.00M
        RETURN_IF_CATCH_EXCEPTION({
169
1.00M
            size_t block_size = _options.data_page_size;
170
1.00M
            _count = 0;
171
1.00M
            _raw_data_size = 0;
172
1.00M
            _data.clear();
173
1.00M
            _data.reserve(block_size);
174
1.00M
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.00M
                    << "buffer must be naturally-aligned";
176
1.00M
            _buffer.clear();
177
1.00M
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.00M
            _finished = false;
179
1.00M
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.00M
        });
181
1.00M
        return Status::OK();
182
1.00M
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE5resetEv
Line
Count
Source
167
102k
    Status reset() override {
168
102k
        RETURN_IF_CATCH_EXCEPTION({
169
102k
            size_t block_size = _options.data_page_size;
170
102k
            _count = 0;
171
102k
            _raw_data_size = 0;
172
102k
            _data.clear();
173
102k
            _data.reserve(block_size);
174
102k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
102k
                    << "buffer must be naturally-aligned";
176
102k
            _buffer.clear();
177
102k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
102k
            _finished = false;
179
102k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
102k
        });
181
102k
        return Status::OK();
182
102k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE5resetEv
Line
Count
Source
167
28.7k
    Status reset() override {
168
28.7k
        RETURN_IF_CATCH_EXCEPTION({
169
28.7k
            size_t block_size = _options.data_page_size;
170
28.7k
            _count = 0;
171
28.7k
            _raw_data_size = 0;
172
28.7k
            _data.clear();
173
28.7k
            _data.reserve(block_size);
174
28.7k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
28.7k
                    << "buffer must be naturally-aligned";
176
28.7k
            _buffer.clear();
177
28.7k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
28.7k
            _finished = false;
179
28.7k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
28.7k
        });
181
28.8k
        return Status::OK();
182
28.7k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE5resetEv
Line
Count
Source
167
129k
    Status reset() override {
168
129k
        RETURN_IF_CATCH_EXCEPTION({
169
129k
            size_t block_size = _options.data_page_size;
170
129k
            _count = 0;
171
129k
            _raw_data_size = 0;
172
129k
            _data.clear();
173
129k
            _data.reserve(block_size);
174
129k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
129k
                    << "buffer must be naturally-aligned";
176
129k
            _buffer.clear();
177
129k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
129k
            _finished = false;
179
129k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
129k
        });
181
129k
        return Status::OK();
182
129k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE5resetEv
Line
Count
Source
167
1
    Status reset() override {
168
1
        RETURN_IF_CATCH_EXCEPTION({
169
1
            size_t block_size = _options.data_page_size;
170
1
            _count = 0;
171
1
            _raw_data_size = 0;
172
1
            _data.clear();
173
1
            _data.reserve(block_size);
174
1
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1
                    << "buffer must be naturally-aligned";
176
1
            _buffer.clear();
177
1
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1
            _finished = false;
179
1
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1
        });
181
1
        return Status::OK();
182
1
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE5resetEv
Line
Count
Source
167
15.8k
    Status reset() override {
168
15.8k
        RETURN_IF_CATCH_EXCEPTION({
169
15.8k
            size_t block_size = _options.data_page_size;
170
15.8k
            _count = 0;
171
15.8k
            _raw_data_size = 0;
172
15.8k
            _data.clear();
173
15.8k
            _data.reserve(block_size);
174
15.8k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
15.8k
                    << "buffer must be naturally-aligned";
176
15.8k
            _buffer.clear();
177
15.8k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
15.8k
            _finished = false;
179
15.8k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
15.8k
        });
181
15.8k
        return Status::OK();
182
15.8k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE5resetEv
Line
Count
Source
167
20.4k
    Status reset() override {
168
20.4k
        RETURN_IF_CATCH_EXCEPTION({
169
20.4k
            size_t block_size = _options.data_page_size;
170
20.4k
            _count = 0;
171
20.4k
            _raw_data_size = 0;
172
20.4k
            _data.clear();
173
20.4k
            _data.reserve(block_size);
174
20.4k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
20.4k
                    << "buffer must be naturally-aligned";
176
20.4k
            _buffer.clear();
177
20.4k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
20.4k
            _finished = false;
179
20.4k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
20.4k
        });
181
20.4k
        return Status::OK();
182
20.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE5resetEv
Line
Count
Source
167
8
    Status reset() override {
168
8
        RETURN_IF_CATCH_EXCEPTION({
169
8
            size_t block_size = _options.data_page_size;
170
8
            _count = 0;
171
8
            _raw_data_size = 0;
172
8
            _data.clear();
173
8
            _data.reserve(block_size);
174
8
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
8
                    << "buffer must be naturally-aligned";
176
8
            _buffer.clear();
177
8
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
8
            _finished = false;
179
8
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
8
        });
181
8
        return Status::OK();
182
8
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE5resetEv
Line
Count
Source
167
1.38k
    Status reset() override {
168
1.38k
        RETURN_IF_CATCH_EXCEPTION({
169
1.38k
            size_t block_size = _options.data_page_size;
170
1.38k
            _count = 0;
171
1.38k
            _raw_data_size = 0;
172
1.38k
            _data.clear();
173
1.38k
            _data.reserve(block_size);
174
1.38k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.38k
                    << "buffer must be naturally-aligned";
176
1.38k
            _buffer.clear();
177
1.38k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.38k
            _finished = false;
179
1.38k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.38k
        });
181
1.38k
        return Status::OK();
182
1.38k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE5resetEv
Line
Count
Source
167
74.8k
    Status reset() override {
168
74.8k
        RETURN_IF_CATCH_EXCEPTION({
169
74.8k
            size_t block_size = _options.data_page_size;
170
74.8k
            _count = 0;
171
74.8k
            _raw_data_size = 0;
172
74.8k
            _data.clear();
173
74.8k
            _data.reserve(block_size);
174
74.8k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
74.8k
                    << "buffer must be naturally-aligned";
176
74.8k
            _buffer.clear();
177
74.8k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
74.8k
            _finished = false;
179
74.8k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
74.8k
        });
181
74.8k
        return Status::OK();
182
74.8k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE5resetEv
Line
Count
Source
167
87.8k
    Status reset() override {
168
87.8k
        RETURN_IF_CATCH_EXCEPTION({
169
87.8k
            size_t block_size = _options.data_page_size;
170
87.8k
            _count = 0;
171
87.8k
            _raw_data_size = 0;
172
87.8k
            _data.clear();
173
87.8k
            _data.reserve(block_size);
174
87.8k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
87.8k
                    << "buffer must be naturally-aligned";
176
87.8k
            _buffer.clear();
177
87.8k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
87.8k
            _finished = false;
179
87.8k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
87.8k
        });
181
87.9k
        return Status::OK();
182
87.8k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE5resetEv
Line
Count
Source
167
614
    Status reset() override {
168
614
        RETURN_IF_CATCH_EXCEPTION({
169
614
            size_t block_size = _options.data_page_size;
170
614
            _count = 0;
171
614
            _raw_data_size = 0;
172
614
            _data.clear();
173
614
            _data.reserve(block_size);
174
614
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
614
                    << "buffer must be naturally-aligned";
176
614
            _buffer.clear();
177
614
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
614
            _finished = false;
179
614
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
614
        });
181
614
        return Status::OK();
182
614
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE5resetEv
Line
Count
Source
167
1.04k
    Status reset() override {
168
1.04k
        RETURN_IF_CATCH_EXCEPTION({
169
1.04k
            size_t block_size = _options.data_page_size;
170
1.04k
            _count = 0;
171
1.04k
            _raw_data_size = 0;
172
1.04k
            _data.clear();
173
1.04k
            _data.reserve(block_size);
174
1.04k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.04k
                    << "buffer must be naturally-aligned";
176
1.04k
            _buffer.clear();
177
1.04k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.04k
            _finished = false;
179
1.04k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.04k
        });
181
1.04k
        return Status::OK();
182
1.04k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE5resetEv
Line
Count
Source
167
15.4k
    Status reset() override {
168
15.4k
        RETURN_IF_CATCH_EXCEPTION({
169
15.4k
            size_t block_size = _options.data_page_size;
170
15.4k
            _count = 0;
171
15.4k
            _raw_data_size = 0;
172
15.4k
            _data.clear();
173
15.4k
            _data.reserve(block_size);
174
15.4k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
15.4k
                    << "buffer must be naturally-aligned";
176
15.4k
            _buffer.clear();
177
15.4k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
15.4k
            _finished = false;
179
15.4k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
15.4k
        });
181
15.5k
        return Status::OK();
182
15.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE5resetEv
Line
Count
Source
167
597
    Status reset() override {
168
597
        RETURN_IF_CATCH_EXCEPTION({
169
597
            size_t block_size = _options.data_page_size;
170
597
            _count = 0;
171
597
            _raw_data_size = 0;
172
597
            _data.clear();
173
597
            _data.reserve(block_size);
174
597
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
597
                    << "buffer must be naturally-aligned";
176
597
            _buffer.clear();
177
597
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
597
            _finished = false;
179
597
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
597
        });
181
597
        return Status::OK();
182
597
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE5resetEv
Line
Count
Source
167
19.4k
    Status reset() override {
168
19.4k
        RETURN_IF_CATCH_EXCEPTION({
169
19.4k
            size_t block_size = _options.data_page_size;
170
19.4k
            _count = 0;
171
19.4k
            _raw_data_size = 0;
172
19.4k
            _data.clear();
173
19.4k
            _data.reserve(block_size);
174
19.4k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
19.4k
                    << "buffer must be naturally-aligned";
176
19.4k
            _buffer.clear();
177
19.4k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
19.4k
            _finished = false;
179
19.4k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
19.4k
        });
181
19.4k
        return Status::OK();
182
19.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE5resetEv
Line
Count
Source
167
30.6k
    Status reset() override {
168
30.6k
        RETURN_IF_CATCH_EXCEPTION({
169
30.6k
            size_t block_size = _options.data_page_size;
170
30.6k
            _count = 0;
171
30.6k
            _raw_data_size = 0;
172
30.6k
            _data.clear();
173
30.6k
            _data.reserve(block_size);
174
30.6k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
30.6k
                    << "buffer must be naturally-aligned";
176
30.6k
            _buffer.clear();
177
30.6k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
30.6k
            _finished = false;
179
30.6k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
30.6k
        });
181
30.6k
        return Status::OK();
182
30.6k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE5resetEv
Line
Count
Source
167
34.1k
    Status reset() override {
168
34.1k
        RETURN_IF_CATCH_EXCEPTION({
169
34.1k
            size_t block_size = _options.data_page_size;
170
34.1k
            _count = 0;
171
34.1k
            _raw_data_size = 0;
172
34.1k
            _data.clear();
173
34.1k
            _data.reserve(block_size);
174
34.1k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
34.1k
                    << "buffer must be naturally-aligned";
176
34.1k
            _buffer.clear();
177
34.1k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
34.1k
            _finished = false;
179
34.1k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
34.1k
        });
181
34.1k
        return Status::OK();
182
34.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE5resetEv
Line
Count
Source
167
2.35k
    Status reset() override {
168
2.35k
        RETURN_IF_CATCH_EXCEPTION({
169
2.35k
            size_t block_size = _options.data_page_size;
170
2.35k
            _count = 0;
171
2.35k
            _raw_data_size = 0;
172
2.35k
            _data.clear();
173
2.35k
            _data.reserve(block_size);
174
2.35k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
2.35k
                    << "buffer must be naturally-aligned";
176
2.35k
            _buffer.clear();
177
2.35k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
2.35k
            _finished = false;
179
2.35k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
2.35k
        });
181
2.36k
        return Status::OK();
182
2.35k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE5resetEv
Line
Count
Source
167
1.25k
    Status reset() override {
168
1.25k
        RETURN_IF_CATCH_EXCEPTION({
169
1.25k
            size_t block_size = _options.data_page_size;
170
1.25k
            _count = 0;
171
1.25k
            _raw_data_size = 0;
172
1.25k
            _data.clear();
173
1.25k
            _data.reserve(block_size);
174
1.25k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.25k
                    << "buffer must be naturally-aligned";
176
1.25k
            _buffer.clear();
177
1.25k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.25k
            _finished = false;
179
1.25k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.25k
        });
181
1.25k
        return Status::OK();
182
1.25k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE5resetEv
Line
Count
Source
167
1.25k
    Status reset() override {
168
1.25k
        RETURN_IF_CATCH_EXCEPTION({
169
1.25k
            size_t block_size = _options.data_page_size;
170
1.25k
            _count = 0;
171
1.25k
            _raw_data_size = 0;
172
1.25k
            _data.clear();
173
1.25k
            _data.reserve(block_size);
174
1.25k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.25k
                    << "buffer must be naturally-aligned";
176
1.25k
            _buffer.clear();
177
1.25k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.25k
            _finished = false;
179
1.25k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.25k
        });
181
1.25k
        return Status::OK();
182
1.25k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE5resetEv
Line
Count
Source
167
1.27k
    Status reset() override {
168
1.27k
        RETURN_IF_CATCH_EXCEPTION({
169
1.27k
            size_t block_size = _options.data_page_size;
170
1.27k
            _count = 0;
171
1.27k
            _raw_data_size = 0;
172
1.27k
            _data.clear();
173
1.27k
            _data.reserve(block_size);
174
1.27k
            DCHECK_EQ(reinterpret_cast<uintptr_t>(_data.data()) & (alignof(CppType) - 1), 0)
175
1.27k
                    << "buffer must be naturally-aligned";
176
1.27k
            _buffer.clear();
177
1.27k
            _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE);
178
1.27k
            _finished = false;
179
1.27k
            _remain_element_capacity = cast_set<UInt32>(block_size / SIZE_OF_TYPE);
180
1.27k
        });
181
1.27k
        return Status::OK();
182
1.27k
    }
183
184
667
    size_t count() const override { return _count; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE5countEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE5countEv
Line
Count
Source
184
8
    size_t count() const override { return _count; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE5countEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE5countEv
Line
Count
Source
184
10
    size_t count() const override { return _count; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE5countEv
Line
Count
Source
184
628
    size_t count() const override { return _count; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE5countEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE5countEv
Line
Count
Source
184
10
    size_t count() const override { return _count; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE5countEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE5countEv
Line
Count
Source
184
6
    size_t count() const override { return _count; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE5countEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE5countEv
Line
Count
Source
184
5
    size_t count() const override { return _count; }
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
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE5countEv
185
186
37.4k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE4sizeEv
Line
Count
Source
186
3.38k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE4sizeEv
Line
Count
Source
186
981
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE4sizeEv
Line
Count
Source
186
20.4k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE4sizeEv
Line
Count
Source
186
2.48k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE4sizeEv
Line
Count
Source
186
1.68k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE4sizeEv
Line
Count
Source
186
972
    uint64_t size() const override { return _buffer.size(); }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE4sizeEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE4sizeEv
Line
Count
Source
186
380
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE4sizeEv
Line
Count
Source
186
362
    uint64_t size() const override { return _buffer.size(); }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE4sizeEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE4sizeEv
Line
Count
Source
186
112
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE4sizeEv
Line
Count
Source
186
1.67k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE4sizeEv
Line
Count
Source
186
2.35k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE4sizeEv
Line
Count
Source
186
10
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE4sizeEv
Line
Count
Source
186
119
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE4sizeEv
Line
Count
Source
186
126
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE4sizeEv
Line
Count
Source
186
104
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE4sizeEv
Line
Count
Source
186
237
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE4sizeEv
Line
Count
Source
186
393
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE4sizeEv
Line
Count
Source
186
1.20k
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE4sizeEv
Line
Count
Source
186
106
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE4sizeEv
Line
Count
Source
186
128
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE4sizeEv
Line
Count
Source
186
112
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE4sizeEv
Line
Count
Source
186
12
    uint64_t size() const override { return _buffer.size(); }
187
188
422k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE17get_raw_data_sizeEv
Line
Count
Source
188
50.0k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE17get_raw_data_sizeEv
Line
Count
Source
188
10.4k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE17get_raw_data_sizeEv
Line
Count
Source
188
74.5k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE17get_raw_data_sizeEv
Line
Count
Source
188
52.1k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE17get_raw_data_sizeEv
Line
Count
Source
188
14.1k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE17get_raw_data_sizeEv
Line
Count
Source
188
64.5k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE17get_raw_data_sizeEv
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE17get_raw_data_sizeEv
Line
Count
Source
188
7.52k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE17get_raw_data_sizeEv
Line
Count
Source
188
10.0k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE17get_raw_data_sizeEv
Line
Count
Source
188
6
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE17get_raw_data_sizeEv
Line
Count
Source
188
698
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE17get_raw_data_sizeEv
Line
Count
Source
188
37.6k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE17get_raw_data_sizeEv
Line
Count
Source
188
43.4k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE17get_raw_data_sizeEv
Line
Count
Source
188
277
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE17get_raw_data_sizeEv
Line
Count
Source
188
601
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE17get_raw_data_sizeEv
Line
Count
Source
188
7.76k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE17get_raw_data_sizeEv
Line
Count
Source
188
257
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE17get_raw_data_sizeEv
Line
Count
Source
188
9.70k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE17get_raw_data_sizeEv
Line
Count
Source
188
18.5k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE17get_raw_data_sizeEv
Line
Count
Source
188
17.1k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE17get_raw_data_sizeEv
Line
Count
Source
188
1.14k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE17get_raw_data_sizeEv
Line
Count
Source
188
582
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE17get_raw_data_sizeEv
Line
Count
Source
188
589
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE17get_raw_data_sizeEv
Line
Count
Source
188
691
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
189
190
private:
191
    BitshufflePageBuilder(const PageBuilderOptions& options)
192
703k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
50.9k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
11.2k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
360k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
50.3k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
14.6k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
64.8k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
1
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
8.30k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
9.81k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
2
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
677
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
37.1k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
44.4k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
336
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
438
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
7.64k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
336
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
9.70k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
12.0k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
16.9k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
1.20k
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
668
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
666
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
192
586
            : _options(options), _count(0), _remain_element_capacity(0), _finished(false) {}
193
194
701k
    OwnedSlice _finish(int final_size_of_type) {
195
701k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
701k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
701k
        int padding_elems = num_elems_after_padding - _count;
200
701k
        int padding_bytes = padding_elems * final_size_of_type;
201
19.1M
        for (int i = 0; i < padding_bytes; i++) {
202
18.4M
            _data.push_back(0);
203
18.4M
        }
204
205
        // reserve enough place for compression
206
701k
        _buffer.resize(
207
701k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
701k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
701k
        int64_t bytes =
211
701k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
701k
                                         num_elems_after_padding, final_size_of_type, 0);
213
701k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
701k
        encode_fixed32_le(&_buffer[0], _count);
223
701k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
701k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
701k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
701k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
701k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
701k
        return _buffer.build();
230
701k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE1EE7_finishEi
Line
Count
Source
194
50.0k
    OwnedSlice _finish(int final_size_of_type) {
195
50.0k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
50.0k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
50.0k
        int padding_elems = num_elems_after_padding - _count;
200
50.0k
        int padding_bytes = padding_elems * final_size_of_type;
201
314k
        for (int i = 0; i < padding_bytes; i++) {
202
264k
            _data.push_back(0);
203
264k
        }
204
205
        // reserve enough place for compression
206
50.0k
        _buffer.resize(
207
50.0k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
50.0k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
50.0k
        int64_t bytes =
211
50.0k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
50.0k
                                         num_elems_after_padding, final_size_of_type, 0);
213
50.0k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
50.0k
        encode_fixed32_le(&_buffer[0], _count);
223
50.0k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
50.0k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
50.0k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
50.0k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
50.0k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
50.0k
        return _buffer.build();
230
50.0k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE3EE7_finishEi
Line
Count
Source
194
10.4k
    OwnedSlice _finish(int final_size_of_type) {
195
10.4k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
10.4k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
10.4k
        int padding_elems = num_elems_after_padding - _count;
200
10.4k
        int padding_bytes = padding_elems * final_size_of_type;
201
107k
        for (int i = 0; i < padding_bytes; i++) {
202
97.1k
            _data.push_back(0);
203
97.1k
        }
204
205
        // reserve enough place for compression
206
10.4k
        _buffer.resize(
207
10.4k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
10.4k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
10.4k
        int64_t bytes =
211
10.4k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
10.4k
                                         num_elems_after_padding, final_size_of_type, 0);
213
10.4k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
10.4k
        encode_fixed32_le(&_buffer[0], _count);
223
10.4k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
10.4k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
10.4k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
10.4k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
10.4k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
10.4k
        return _buffer.build();
230
10.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE5EE7_finishEi
Line
Count
Source
194
353k
    OwnedSlice _finish(int final_size_of_type) {
195
353k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
353k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
353k
        int padding_elems = num_elems_after_padding - _count;
200
353k
        int padding_bytes = padding_elems * final_size_of_type;
201
6.87M
        for (int i = 0; i < padding_bytes; i++) {
202
6.51M
            _data.push_back(0);
203
6.51M
        }
204
205
        // reserve enough place for compression
206
353k
        _buffer.resize(
207
353k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
353k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
353k
        int64_t bytes =
211
353k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
353k
                                         num_elems_after_padding, final_size_of_type, 0);
213
353k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
353k
        encode_fixed32_le(&_buffer[0], _count);
223
353k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
353k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
353k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
353k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
353k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
353k
        return _buffer.build();
230
353k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE7EE7_finishEi
Line
Count
Source
194
52.1k
    OwnedSlice _finish(int final_size_of_type) {
195
52.1k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
52.1k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
52.1k
        int padding_elems = num_elems_after_padding - _count;
200
52.1k
        int padding_bytes = padding_elems * final_size_of_type;
201
2.07M
        for (int i = 0; i < padding_bytes; i++) {
202
2.02M
            _data.push_back(0);
203
2.02M
        }
204
205
        // reserve enough place for compression
206
52.1k
        _buffer.resize(
207
52.1k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
52.1k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
52.1k
        int64_t bytes =
211
52.1k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
52.1k
                                         num_elems_after_padding, final_size_of_type, 0);
213
52.1k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
52.1k
        encode_fixed32_le(&_buffer[0], _count);
223
52.1k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
52.1k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
52.1k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
52.1k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
52.1k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
52.1k
        return _buffer.build();
230
52.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE9EE7_finishEi
Line
Count
Source
194
14.1k
    OwnedSlice _finish(int final_size_of_type) {
195
14.1k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
14.1k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
14.1k
        int padding_elems = num_elems_after_padding - _count;
200
14.1k
        int padding_bytes = padding_elems * final_size_of_type;
201
956k
        for (int i = 0; i < padding_bytes; i++) {
202
942k
            _data.push_back(0);
203
942k
        }
204
205
        // reserve enough place for compression
206
14.1k
        _buffer.resize(
207
14.1k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
14.1k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
14.1k
        int64_t bytes =
211
14.1k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
14.1k
                                         num_elems_after_padding, final_size_of_type, 0);
213
14.1k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
14.1k
        encode_fixed32_le(&_buffer[0], _count);
223
14.1k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
14.1k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
14.1k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
14.1k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
14.1k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
14.1k
        return _buffer.build();
230
14.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE8EE7_finishEi
Line
Count
Source
194
64.5k
    OwnedSlice _finish(int final_size_of_type) {
195
64.5k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
64.5k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
64.5k
        int padding_elems = num_elems_after_padding - _count;
200
64.5k
        int padding_bytes = padding_elems * final_size_of_type;
201
3.10M
        for (int i = 0; i < padding_bytes; i++) {
202
3.04M
            _data.push_back(0);
203
3.04M
        }
204
205
        // reserve enough place for compression
206
64.5k
        _buffer.resize(
207
64.5k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
64.5k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
64.5k
        int64_t bytes =
211
64.5k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
64.5k
                                         num_elems_after_padding, final_size_of_type, 0);
213
64.5k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
64.5k
        encode_fixed32_le(&_buffer[0], _count);
223
64.5k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
64.5k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
64.5k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
64.5k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
64.5k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
64.5k
        return _buffer.build();
230
64.5k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE6EE7_finishEi
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE10EE7_finishEi
Line
Count
Source
194
7.53k
    OwnedSlice _finish(int final_size_of_type) {
195
7.53k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
7.53k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
7.53k
        int padding_elems = num_elems_after_padding - _count;
200
7.53k
        int padding_bytes = padding_elems * final_size_of_type;
201
164k
        for (int i = 0; i < padding_bytes; i++) {
202
156k
            _data.push_back(0);
203
156k
        }
204
205
        // reserve enough place for compression
206
7.53k
        _buffer.resize(
207
7.53k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
7.53k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
7.53k
        int64_t bytes =
211
7.53k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
7.53k
                                         num_elems_after_padding, final_size_of_type, 0);
213
7.53k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
7.53k
        encode_fixed32_le(&_buffer[0], _count);
223
7.53k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
7.53k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
7.53k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
7.53k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
7.53k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
7.53k
        return _buffer.build();
230
7.53k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE11EE7_finishEi
Line
Count
Source
194
10.6k
    OwnedSlice _finish(int final_size_of_type) {
195
10.6k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
10.6k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
10.6k
        int padding_elems = num_elems_after_padding - _count;
200
10.6k
        int padding_bytes = padding_elems * final_size_of_type;
201
401k
        for (int i = 0; i < padding_bytes; i++) {
202
390k
            _data.push_back(0);
203
390k
        }
204
205
        // reserve enough place for compression
206
10.6k
        _buffer.resize(
207
10.6k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
10.6k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
10.6k
        int64_t bytes =
211
10.6k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
10.6k
                                         num_elems_after_padding, final_size_of_type, 0);
213
10.6k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
10.6k
        encode_fixed32_le(&_buffer[0], _count);
223
10.6k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
10.6k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
10.6k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
10.6k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
10.6k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
10.6k
        return _buffer.build();
230
10.6k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE24EE7_finishEi
Line
Count
Source
194
6
    OwnedSlice _finish(int final_size_of_type) {
195
6
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
6
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
6
        int padding_elems = num_elems_after_padding - _count;
200
6
        int padding_bytes = padding_elems * final_size_of_type;
201
18
        for (int i = 0; i < padding_bytes; i++) {
202
12
            _data.push_back(0);
203
12
        }
204
205
        // reserve enough place for compression
206
6
        _buffer.resize(
207
6
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
6
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
6
        int64_t bytes =
211
6
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
6
                                         num_elems_after_padding, final_size_of_type, 0);
213
6
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
6
        encode_fixed32_le(&_buffer[0], _count);
223
6
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
6
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
6
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
6
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
6
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
6
        return _buffer.build();
230
6
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE14EE7_finishEi
Line
Count
Source
194
709
    OwnedSlice _finish(int final_size_of_type) {
195
709
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
709
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
709
        int padding_elems = num_elems_after_padding - _count;
200
709
        int padding_bytes = padding_elems * final_size_of_type;
201
12.3k
        for (int i = 0; i < padding_bytes; i++) {
202
11.6k
            _data.push_back(0);
203
11.6k
        }
204
205
        // reserve enough place for compression
206
709
        _buffer.resize(
207
709
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
709
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
709
        int64_t bytes =
211
709
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
709
                                         num_elems_after_padding, final_size_of_type, 0);
213
709
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
709
        encode_fixed32_le(&_buffer[0], _count);
223
709
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
709
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
709
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
709
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
709
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
709
        return _buffer.build();
230
709
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE28EE7_finishEi
Line
Count
Source
194
37.6k
    OwnedSlice _finish(int final_size_of_type) {
195
37.6k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
37.6k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
37.6k
        int padding_elems = num_elems_after_padding - _count;
200
37.6k
        int padding_bytes = padding_elems * final_size_of_type;
201
799k
        for (int i = 0; i < padding_bytes; i++) {
202
762k
            _data.push_back(0);
203
762k
        }
204
205
        // reserve enough place for compression
206
37.6k
        _buffer.resize(
207
37.6k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
37.6k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
37.6k
        int64_t bytes =
211
37.6k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
37.6k
                                         num_elems_after_padding, final_size_of_type, 0);
213
37.6k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
37.6k
        encode_fixed32_le(&_buffer[0], _count);
223
37.6k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
37.6k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
37.6k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
37.6k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
37.6k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
37.6k
        return _buffer.build();
230
37.6k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE29EE7_finishEi
Line
Count
Source
194
43.4k
    OwnedSlice _finish(int final_size_of_type) {
195
43.4k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
43.4k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
43.4k
        int padding_elems = num_elems_after_padding - _count;
200
43.4k
        int padding_bytes = padding_elems * final_size_of_type;
201
1.83M
        for (int i = 0; i < padding_bytes; i++) {
202
1.79M
            _data.push_back(0);
203
1.79M
        }
204
205
        // reserve enough place for compression
206
43.4k
        _buffer.resize(
207
43.4k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
43.4k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
43.4k
        int64_t bytes =
211
43.4k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
43.4k
                                         num_elems_after_padding, final_size_of_type, 0);
213
43.4k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
43.4k
        encode_fixed32_le(&_buffer[0], _count);
223
43.4k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
43.4k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
43.4k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
43.4k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
43.4k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
43.4k
        return _buffer.build();
230
43.4k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE41EE7_finishEi
Line
Count
Source
194
277
    OwnedSlice _finish(int final_size_of_type) {
195
277
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
277
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
277
        int padding_elems = num_elems_after_padding - _count;
200
277
        int padding_bytes = padding_elems * final_size_of_type;
201
11.7k
        for (int i = 0; i < padding_bytes; i++) {
202
11.4k
            _data.push_back(0);
203
11.4k
        }
204
205
        // reserve enough place for compression
206
277
        _buffer.resize(
207
277
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
277
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
277
        int64_t bytes =
211
277
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
277
                                         num_elems_after_padding, final_size_of_type, 0);
213
277
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
277
        encode_fixed32_le(&_buffer[0], _count);
223
277
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
277
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
277
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
277
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
277
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
277
        return _buffer.build();
230
277
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE15EE7_finishEi
Line
Count
Source
194
606
    OwnedSlice _finish(int final_size_of_type) {
195
606
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
606
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
606
        int padding_elems = num_elems_after_padding - _count;
200
606
        int padding_bytes = padding_elems * final_size_of_type;
201
13.5k
        for (int i = 0; i < padding_bytes; i++) {
202
12.9k
            _data.push_back(0);
203
12.9k
        }
204
205
        // reserve enough place for compression
206
606
        _buffer.resize(
207
606
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
606
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
606
        int64_t bytes =
211
606
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
606
                                         num_elems_after_padding, final_size_of_type, 0);
213
606
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
606
        encode_fixed32_le(&_buffer[0], _count);
223
606
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
606
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
606
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
606
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
606
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
606
        return _buffer.build();
230
606
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE40EE7_finishEi
Line
Count
Source
194
7.76k
    OwnedSlice _finish(int final_size_of_type) {
195
7.76k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
7.76k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
7.76k
        int padding_elems = num_elems_after_padding - _count;
200
7.76k
        int padding_bytes = padding_elems * final_size_of_type;
201
404k
        for (int i = 0; i < padding_bytes; i++) {
202
396k
            _data.push_back(0);
203
396k
        }
204
205
        // reserve enough place for compression
206
7.76k
        _buffer.resize(
207
7.76k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
7.76k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
7.76k
        int64_t bytes =
211
7.76k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
7.76k
                                         num_elems_after_padding, final_size_of_type, 0);
213
7.76k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
7.76k
        encode_fixed32_le(&_buffer[0], _count);
223
7.76k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
7.76k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
7.76k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
7.76k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
7.76k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
7.76k
        return _buffer.build();
230
7.76k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE16EE7_finishEi
Line
Count
Source
194
262
    OwnedSlice _finish(int final_size_of_type) {
195
262
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
262
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
262
        int padding_elems = num_elems_after_padding - _count;
200
262
        int padding_bytes = padding_elems * final_size_of_type;
201
16.5k
        for (int i = 0; i < padding_bytes; i++) {
202
16.2k
            _data.push_back(0);
203
16.2k
        }
204
205
        // reserve enough place for compression
206
262
        _buffer.resize(
207
262
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
262
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
262
        int64_t bytes =
211
262
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
262
                                         num_elems_after_padding, final_size_of_type, 0);
213
262
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
262
        encode_fixed32_le(&_buffer[0], _count);
223
262
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
262
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
262
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
262
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
262
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
262
        return _buffer.build();
230
262
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE31EE7_finishEi
Line
Count
Source
194
9.71k
    OwnedSlice _finish(int final_size_of_type) {
195
9.71k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
9.71k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
9.71k
        int padding_elems = num_elems_after_padding - _count;
200
9.71k
        int padding_bytes = padding_elems * final_size_of_type;
201
117k
        for (int i = 0; i < padding_bytes; i++) {
202
107k
            _data.push_back(0);
203
107k
        }
204
205
        // reserve enough place for compression
206
9.71k
        _buffer.resize(
207
9.71k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
9.71k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
9.71k
        int64_t bytes =
211
9.71k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
9.71k
                                         num_elems_after_padding, final_size_of_type, 0);
213
9.71k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
9.71k
        encode_fixed32_le(&_buffer[0], _count);
223
9.71k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
9.71k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
9.71k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
9.71k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
9.71k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
9.71k
        return _buffer.build();
230
9.71k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE32EE7_finishEi
Line
Count
Source
194
18.5k
    OwnedSlice _finish(int final_size_of_type) {
195
18.5k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
18.5k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
18.5k
        int padding_elems = num_elems_after_padding - _count;
200
18.5k
        int padding_bytes = padding_elems * final_size_of_type;
201
489k
        for (int i = 0; i < padding_bytes; i++) {
202
470k
            _data.push_back(0);
203
470k
        }
204
205
        // reserve enough place for compression
206
18.5k
        _buffer.resize(
207
18.5k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
18.5k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
18.5k
        int64_t bytes =
211
18.5k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
18.5k
                                         num_elems_after_padding, final_size_of_type, 0);
213
18.5k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
18.5k
        encode_fixed32_le(&_buffer[0], _count);
223
18.5k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
18.5k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
18.5k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
18.5k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
18.5k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
18.5k
        return _buffer.build();
230
18.5k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE33EE7_finishEi
Line
Count
Source
194
17.1k
    OwnedSlice _finish(int final_size_of_type) {
195
17.1k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
17.1k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
17.1k
        int padding_elems = num_elems_after_padding - _count;
200
17.1k
        int padding_bytes = padding_elems * final_size_of_type;
201
1.14M
        for (int i = 0; i < padding_bytes; i++) {
202
1.13M
            _data.push_back(0);
203
1.13M
        }
204
205
        // reserve enough place for compression
206
17.1k
        _buffer.resize(
207
17.1k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
17.1k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
17.1k
        int64_t bytes =
211
17.1k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
17.1k
                                         num_elems_after_padding, final_size_of_type, 0);
213
17.1k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
17.1k
        encode_fixed32_le(&_buffer[0], _count);
223
17.1k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
17.1k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
17.1k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
17.1k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
17.1k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
17.1k
        return _buffer.build();
230
17.1k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE37EE7_finishEi
Line
Count
Source
194
1.14k
    OwnedSlice _finish(int final_size_of_type) {
195
1.14k
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
1.14k
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
1.14k
        int padding_elems = num_elems_after_padding - _count;
200
1.14k
        int padding_bytes = padding_elems * final_size_of_type;
201
174k
        for (int i = 0; i < padding_bytes; i++) {
202
173k
            _data.push_back(0);
203
173k
        }
204
205
        // reserve enough place for compression
206
1.14k
        _buffer.resize(
207
1.14k
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
1.14k
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
1.14k
        int64_t bytes =
211
1.14k
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
1.14k
                                         num_elems_after_padding, final_size_of_type, 0);
213
1.14k
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
1.14k
        encode_fixed32_le(&_buffer[0], _count);
223
1.14k
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
1.14k
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
1.14k
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
1.14k
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
1.14k
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
1.14k
        return _buffer.build();
230
1.14k
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE38EE7_finishEi
Line
Count
Source
194
582
    OwnedSlice _finish(int final_size_of_type) {
195
582
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
582
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
582
        int padding_elems = num_elems_after_padding - _count;
200
582
        int padding_bytes = padding_elems * final_size_of_type;
201
11.8k
        for (int i = 0; i < padding_bytes; i++) {
202
11.2k
            _data.push_back(0);
203
11.2k
        }
204
205
        // reserve enough place for compression
206
582
        _buffer.resize(
207
582
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
582
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
582
        int64_t bytes =
211
582
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
582
                                         num_elems_after_padding, final_size_of_type, 0);
213
582
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
582
        encode_fixed32_le(&_buffer[0], _count);
223
582
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
582
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
582
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
582
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
582
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
582
        return _buffer.build();
230
582
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE39EE7_finishEi
Line
Count
Source
194
589
    OwnedSlice _finish(int final_size_of_type) {
195
589
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
589
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
589
        int padding_elems = num_elems_after_padding - _count;
200
589
        int padding_bytes = padding_elems * final_size_of_type;
201
47.0k
        for (int i = 0; i < padding_bytes; i++) {
202
46.4k
            _data.push_back(0);
203
46.4k
        }
204
205
        // reserve enough place for compression
206
589
        _buffer.resize(
207
589
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
589
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
589
        int64_t bytes =
211
589
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
589
                                         num_elems_after_padding, final_size_of_type, 0);
213
589
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
589
        encode_fixed32_le(&_buffer[0], _count);
223
589
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
589
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
589
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
589
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
589
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
589
        return _buffer.build();
230
589
    }
_ZN5doris10segment_v221BitshufflePageBuilderILNS_9FieldTypeE42EE7_finishEi
Line
Count
Source
194
691
    OwnedSlice _finish(int final_size_of_type) {
195
691
        _data.resize(final_size_of_type * _count);
196
197
        // Do padding so that the input num of element is multiple of 8.
198
691
        int num_elems_after_padding = ALIGN_UP(_count, 8);
199
691
        int padding_elems = num_elems_after_padding - _count;
200
691
        int padding_bytes = padding_elems * final_size_of_type;
201
50.3k
        for (int i = 0; i < padding_bytes; i++) {
202
49.6k
            _data.push_back(0);
203
49.6k
        }
204
205
        // reserve enough place for compression
206
691
        _buffer.resize(
207
691
                BITSHUFFLE_PAGE_HEADER_SIZE +
208
691
                bitshuffle::compress_lz4_bound(num_elems_after_padding, final_size_of_type, 0));
209
210
691
        int64_t bytes =
211
691
                bitshuffle::compress_lz4(_data.data(), &_buffer[BITSHUFFLE_PAGE_HEADER_SIZE],
212
691
                                         num_elems_after_padding, final_size_of_type, 0);
213
691
        if (bytes < 0) [[unlikely]] {
214
            // This means the bitshuffle function fails.
215
            // Ideally, this should not happen.
216
0
            warn_with_bitshuffle_error(bytes);
217
            // It does not matter what will be returned here,
218
            // since we have logged fatal in warn_with_bitshuffle_error().
219
0
            return OwnedSlice();
220
0
        }
221
        // update header
222
691
        encode_fixed32_le(&_buffer[0], _count);
223
691
        encode_fixed32_le(&_buffer[4], cast_set<uint32_t>(BITSHUFFLE_PAGE_HEADER_SIZE + bytes));
224
691
        encode_fixed32_le(&_buffer[8], num_elems_after_padding);
225
691
        encode_fixed32_le(&_buffer[12], final_size_of_type);
226
691
        _finished = true;
227
        // before build(), update buffer length to the actual compressed size
228
691
        _buffer.resize(BITSHUFFLE_PAGE_HEADER_SIZE + bytes);
229
691
        return _buffer.build();
230
691
    }
231
232
    using CppType = typename TypeTraits<Type>::CppType;
233
234
    CppType cell(int idx) const {
235
        DCHECK_GE(idx, 0);
236
        CppType ret;
237
        memcpy(&ret, &_data[idx * SIZE_OF_TYPE], SIZE_OF_TYPE);
238
        return ret;
239
    }
240
241
    static constexpr size_t SIZE_OF_TYPE = TypeTraits<Type>::size;
242
    PageBuilderOptions _options;
243
    uint32_t _count;
244
    uint32_t _remain_element_capacity;
245
    bool _finished;
246
    faststring _data;
247
    faststring _buffer;
248
    uint64_t _raw_data_size = 0;
249
};
250
251
inline Status parse_bit_shuffle_header(const Slice& data, size_t& num_elements,
252
                                       size_t& compressed_size, size_t& num_element_after_padding,
253
2.19M
                                       int& size_of_element) {
254
2.19M
    if (data.size < BITSHUFFLE_PAGE_HEADER_SIZE) {
255
0
        return Status::InternalError("file corruption: invalid data size:{}, header size:{}",
256
0
                                     data.size, BITSHUFFLE_PAGE_HEADER_SIZE);
257
0
    }
258
259
2.19M
    num_elements = decode_fixed32_le((const uint8_t*)&data[0]);
260
2.19M
    compressed_size = decode_fixed32_le((const uint8_t*)&data[4]);
261
2.19M
    num_element_after_padding = decode_fixed32_le((const uint8_t*)&data[8]);
262
2.19M
    size_of_element = decode_fixed32_le((const uint8_t*)&data[12]);
263
2.19M
    if (num_element_after_padding != ALIGN_UP(num_elements, 8)) {
264
0
        return Status::InternalError(
265
0
                "num of element information corrupted,"
266
0
                " _num_element_after_padding:{}, _num_elements:{}, expected_padding:{},"
267
0
                " compressed_size:{}, size_of_element:{}, data_size:{}",
268
0
                num_element_after_padding, num_elements, ALIGN_UP(num_elements, 8), compressed_size,
269
0
                size_of_element, data.size);
270
0
    }
271
2.19M
    switch (size_of_element) {
272
159k
    case 1:
273
184k
    case 2:
274
188k
    case 3:
275
1.47M
    case 4:
276
2.08M
    case 8:
277
2.08M
    case 12:
278
2.19M
    case 16:
279
2.19M
    case 32:
280
2.19M
        break;
281
0
    default:
282
0
        return Status::InternalError("invalid size_of_elem:{}", size_of_element);
283
2.19M
    }
284
2.19M
    return Status::OK();
285
2.19M
}
286
287
template <FieldType Type>
288
class BitShufflePageDecoder : public PageDecoder {
289
public:
290
    BitShufflePageDecoder(Slice data, const PageDecoderOptions& options)
291
1.09M
            : _data(data),
292
1.09M
              _options(options),
293
1.09M
              _parsed(false),
294
1.09M
              _num_elements(0),
295
1.09M
              _num_element_after_padding(0),
296
1.09M
              _size_of_element(0),
297
1.09M
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
79.4k
            : _data(data),
292
79.4k
              _options(options),
293
79.4k
              _parsed(false),
294
79.4k
              _num_elements(0),
295
79.4k
              _num_element_after_padding(0),
296
79.4k
              _size_of_element(0),
297
79.4k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
12.8k
            : _data(data),
292
12.8k
              _options(options),
293
12.8k
              _parsed(false),
294
12.8k
              _num_elements(0),
295
12.8k
              _num_element_after_padding(0),
296
12.8k
              _size_of_element(0),
297
12.8k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
558k
            : _data(data),
292
558k
              _options(options),
293
558k
              _parsed(false),
294
558k
              _num_elements(0),
295
558k
              _num_element_after_padding(0),
296
558k
              _size_of_element(0),
297
558k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
60.8k
            : _data(data),
292
60.8k
              _options(options),
293
60.8k
              _parsed(false),
294
60.8k
              _num_elements(0),
295
60.8k
              _num_element_after_padding(0),
296
60.8k
              _size_of_element(0),
297
60.8k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
17.9k
            : _data(data),
292
17.9k
              _options(options),
293
17.9k
              _parsed(false),
294
17.9k
              _num_elements(0),
295
17.9k
              _num_element_after_padding(0),
296
17.9k
              _size_of_element(0),
297
17.9k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
91.5k
            : _data(data),
292
91.5k
              _options(options),
293
91.5k
              _parsed(false),
294
91.5k
              _num_elements(0),
295
91.5k
              _num_element_after_padding(0),
296
91.5k
              _size_of_element(0),
297
91.5k
              _cur_index(0) {}
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
9.85k
            : _data(data),
292
9.85k
              _options(options),
293
9.85k
              _parsed(false),
294
9.85k
              _num_elements(0),
295
9.85k
              _num_element_after_padding(0),
296
9.85k
              _size_of_element(0),
297
9.85k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
16.4k
            : _data(data),
292
16.4k
              _options(options),
293
16.4k
              _parsed(false),
294
16.4k
              _num_elements(0),
295
16.4k
              _num_element_after_padding(0),
296
16.4k
              _size_of_element(0),
297
16.4k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
6
            : _data(data),
292
6
              _options(options),
293
6
              _parsed(false),
294
6
              _num_elements(0),
295
6
              _num_element_after_padding(0),
296
6
              _size_of_element(0),
297
6
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
1.82k
            : _data(data),
292
1.82k
              _options(options),
293
1.82k
              _parsed(false),
294
1.82k
              _num_elements(0),
295
1.82k
              _num_element_after_padding(0),
296
1.82k
              _size_of_element(0),
297
1.82k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
59.1k
            : _data(data),
292
59.1k
              _options(options),
293
59.1k
              _parsed(false),
294
59.1k
              _num_elements(0),
295
59.1k
              _num_element_after_padding(0),
296
59.1k
              _size_of_element(0),
297
59.1k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
67.2k
            : _data(data),
292
67.2k
              _options(options),
293
67.2k
              _parsed(false),
294
67.2k
              _num_elements(0),
295
67.2k
              _num_element_after_padding(0),
296
67.2k
              _size_of_element(0),
297
67.2k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
3.14k
            : _data(data),
292
3.14k
              _options(options),
293
3.14k
              _parsed(false),
294
3.14k
              _num_elements(0),
295
3.14k
              _num_element_after_padding(0),
296
3.14k
              _size_of_element(0),
297
3.14k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
2.30k
            : _data(data),
292
2.30k
              _options(options),
293
2.30k
              _parsed(false),
294
2.30k
              _num_elements(0),
295
2.30k
              _num_element_after_padding(0),
296
2.30k
              _size_of_element(0),
297
2.30k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
15.9k
            : _data(data),
292
15.9k
              _options(options),
293
15.9k
              _parsed(false),
294
15.9k
              _num_elements(0),
295
15.9k
              _num_element_after_padding(0),
296
15.9k
              _size_of_element(0),
297
15.9k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
1.36k
            : _data(data),
292
1.36k
              _options(options),
293
1.36k
              _parsed(false),
294
1.36k
              _num_elements(0),
295
1.36k
              _num_element_after_padding(0),
296
1.36k
              _size_of_element(0),
297
1.36k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
15.5k
            : _data(data),
292
15.5k
              _options(options),
293
15.5k
              _parsed(false),
294
15.5k
              _num_elements(0),
295
15.5k
              _num_element_after_padding(0),
296
15.5k
              _size_of_element(0),
297
15.5k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
43.7k
            : _data(data),
292
43.7k
              _options(options),
293
43.7k
              _parsed(false),
294
43.7k
              _num_elements(0),
295
43.7k
              _num_element_after_padding(0),
296
43.7k
              _size_of_element(0),
297
43.7k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
31.2k
            : _data(data),
292
31.2k
              _options(options),
293
31.2k
              _parsed(false),
294
31.2k
              _num_elements(0),
295
31.2k
              _num_element_after_padding(0),
296
31.2k
              _size_of_element(0),
297
31.2k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
1.77k
            : _data(data),
292
1.77k
              _options(options),
293
1.77k
              _parsed(false),
294
1.77k
              _num_elements(0),
295
1.77k
              _num_element_after_padding(0),
296
1.77k
              _size_of_element(0),
297
1.77k
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
885
            : _data(data),
292
885
              _options(options),
293
885
              _parsed(false),
294
885
              _num_elements(0),
295
885
              _num_element_after_padding(0),
296
885
              _size_of_element(0),
297
885
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
944
            : _data(data),
292
944
              _options(options),
293
944
              _parsed(false),
294
944
              _num_elements(0),
295
944
              _num_element_after_padding(0),
296
944
              _size_of_element(0),
297
944
              _cur_index(0) {}
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
291
5.26k
            : _data(data),
292
5.26k
              _options(options),
293
5.26k
              _parsed(false),
294
5.26k
              _num_elements(0),
295
5.26k
              _num_element_after_padding(0),
296
5.26k
              _size_of_element(0),
297
5.26k
              _cur_index(0) {}
298
299
1.09M
    Status init() override {
300
1.09M
        CHECK(!_parsed);
301
1.09M
        size_t unused;
302
1.09M
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
1.09M
                                                 _num_element_after_padding, _size_of_element));
304
305
1.09M
        if (_data.size !=
306
1.09M
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
13
            std::stringstream ss;
308
13
            ss << "Size information unmatched, _data.size:" << _data.size
309
13
               << ", _num_elements:" << _num_elements << ", expected size is "
310
13
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
13
            return Status::InternalError(ss.str());
312
13
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
1.09M
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
1.09M
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
1.09M
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
1.09M
        _parsed = true;
326
1.09M
        return Status::OK();
327
1.09M
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE4initEv
Line
Count
Source
299
79.3k
    Status init() override {
300
79.3k
        CHECK(!_parsed);
301
79.3k
        size_t unused;
302
79.3k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
79.3k
                                                 _num_element_after_padding, _size_of_element));
304
305
79.3k
        if (_data.size !=
306
79.3k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
79.3k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
79.3k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
79.3k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
79.3k
        _parsed = true;
326
79.3k
        return Status::OK();
327
79.3k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE4initEv
Line
Count
Source
299
12.8k
    Status init() override {
300
12.8k
        CHECK(!_parsed);
301
12.8k
        size_t unused;
302
12.8k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
12.8k
                                                 _num_element_after_padding, _size_of_element));
304
305
12.8k
        if (_data.size !=
306
12.8k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
12.8k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
12.8k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
12.8k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
12.8k
        _parsed = true;
326
12.8k
        return Status::OK();
327
12.8k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE4initEv
Line
Count
Source
299
558k
    Status init() override {
300
558k
        CHECK(!_parsed);
301
558k
        size_t unused;
302
558k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
558k
                                                 _num_element_after_padding, _size_of_element));
304
305
558k
        if (_data.size !=
306
558k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
5
            std::stringstream ss;
308
5
            ss << "Size information unmatched, _data.size:" << _data.size
309
5
               << ", _num_elements:" << _num_elements << ", expected size is "
310
5
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
5
            return Status::InternalError(ss.str());
312
5
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
558k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
558k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
558k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
558k
        _parsed = true;
326
558k
        return Status::OK();
327
558k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE4initEv
Line
Count
Source
299
60.7k
    Status init() override {
300
60.7k
        CHECK(!_parsed);
301
60.7k
        size_t unused;
302
60.7k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
60.7k
                                                 _num_element_after_padding, _size_of_element));
304
305
60.7k
        if (_data.size !=
306
60.7k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
1
            std::stringstream ss;
308
1
            ss << "Size information unmatched, _data.size:" << _data.size
309
1
               << ", _num_elements:" << _num_elements << ", expected size is "
310
1
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
1
            return Status::InternalError(ss.str());
312
1
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
60.7k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
60.7k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
60.7k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
60.7k
        _parsed = true;
326
60.7k
        return Status::OK();
327
60.7k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE4initEv
Line
Count
Source
299
17.9k
    Status init() override {
300
17.9k
        CHECK(!_parsed);
301
17.9k
        size_t unused;
302
17.9k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
17.9k
                                                 _num_element_after_padding, _size_of_element));
304
305
17.9k
        if (_data.size !=
306
17.9k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
17.9k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
17.9k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
17.9k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
17.9k
        _parsed = true;
326
17.9k
        return Status::OK();
327
17.9k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE4initEv
Line
Count
Source
299
91.4k
    Status init() override {
300
91.4k
        CHECK(!_parsed);
301
91.4k
        size_t unused;
302
91.4k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
91.4k
                                                 _num_element_after_padding, _size_of_element));
304
305
91.4k
        if (_data.size !=
306
91.4k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
91.4k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
91.4k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
91.4k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
91.4k
        _parsed = true;
326
91.4k
        return Status::OK();
327
91.4k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE4initEv
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE4initEv
Line
Count
Source
299
9.85k
    Status init() override {
300
9.85k
        CHECK(!_parsed);
301
9.85k
        size_t unused;
302
9.85k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
9.85k
                                                 _num_element_after_padding, _size_of_element));
304
305
9.85k
        if (_data.size !=
306
9.85k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
2
            std::stringstream ss;
308
2
            ss << "Size information unmatched, _data.size:" << _data.size
309
2
               << ", _num_elements:" << _num_elements << ", expected size is "
310
2
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
2
            return Status::InternalError(ss.str());
312
2
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
9.85k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
9.85k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
9.85k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
9.85k
        _parsed = true;
326
9.85k
        return Status::OK();
327
9.85k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE4initEv
Line
Count
Source
299
16.4k
    Status init() override {
300
16.4k
        CHECK(!_parsed);
301
16.4k
        size_t unused;
302
16.4k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
16.4k
                                                 _num_element_after_padding, _size_of_element));
304
305
16.4k
        if (_data.size !=
306
16.4k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
4
            std::stringstream ss;
308
4
            ss << "Size information unmatched, _data.size:" << _data.size
309
4
               << ", _num_elements:" << _num_elements << ", expected size is "
310
4
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
4
            return Status::InternalError(ss.str());
312
4
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
16.4k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
16.4k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
16.4k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
16.4k
        _parsed = true;
326
16.4k
        return Status::OK();
327
16.4k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE4initEv
Line
Count
Source
299
6
    Status init() override {
300
6
        CHECK(!_parsed);
301
6
        size_t unused;
302
6
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
6
                                                 _num_element_after_padding, _size_of_element));
304
305
6
        if (_data.size !=
306
6
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
6
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
6
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
6
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
6
        _parsed = true;
326
6
        return Status::OK();
327
6
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE4initEv
Line
Count
Source
299
1.81k
    Status init() override {
300
1.81k
        CHECK(!_parsed);
301
1.81k
        size_t unused;
302
1.81k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
1.81k
                                                 _num_element_after_padding, _size_of_element));
304
305
1.81k
        if (_data.size !=
306
1.81k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
1.81k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
1.81k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
1.81k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
1.81k
        _parsed = true;
326
1.81k
        return Status::OK();
327
1.81k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE4initEv
Line
Count
Source
299
59.0k
    Status init() override {
300
59.0k
        CHECK(!_parsed);
301
59.0k
        size_t unused;
302
59.0k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
59.0k
                                                 _num_element_after_padding, _size_of_element));
304
305
59.0k
        if (_data.size !=
306
59.0k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
59.0k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
59.0k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
59.0k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
59.0k
        _parsed = true;
326
59.0k
        return Status::OK();
327
59.0k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE4initEv
Line
Count
Source
299
67.2k
    Status init() override {
300
67.2k
        CHECK(!_parsed);
301
67.2k
        size_t unused;
302
67.2k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
67.2k
                                                 _num_element_after_padding, _size_of_element));
304
305
67.2k
        if (_data.size !=
306
67.2k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
67.2k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
67.2k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
67.2k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
67.2k
        _parsed = true;
326
67.2k
        return Status::OK();
327
67.2k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE4initEv
Line
Count
Source
299
3.14k
    Status init() override {
300
3.14k
        CHECK(!_parsed);
301
3.14k
        size_t unused;
302
3.14k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
3.14k
                                                 _num_element_after_padding, _size_of_element));
304
305
3.14k
        if (_data.size !=
306
3.14k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
3.14k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
3.14k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
3.14k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
3.14k
        _parsed = true;
326
3.14k
        return Status::OK();
327
3.14k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE4initEv
Line
Count
Source
299
2.30k
    Status init() override {
300
2.30k
        CHECK(!_parsed);
301
2.30k
        size_t unused;
302
2.30k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
2.30k
                                                 _num_element_after_padding, _size_of_element));
304
305
2.30k
        if (_data.size !=
306
2.30k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
2.30k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
2.30k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
2.30k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
2.30k
        _parsed = true;
326
2.30k
        return Status::OK();
327
2.30k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE4initEv
Line
Count
Source
299
15.9k
    Status init() override {
300
15.9k
        CHECK(!_parsed);
301
15.9k
        size_t unused;
302
15.9k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
15.9k
                                                 _num_element_after_padding, _size_of_element));
304
305
15.9k
        if (_data.size !=
306
15.9k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
15.9k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
15.9k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
15.9k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
15.9k
        _parsed = true;
326
15.9k
        return Status::OK();
327
15.9k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE4initEv
Line
Count
Source
299
1.35k
    Status init() override {
300
1.35k
        CHECK(!_parsed);
301
1.35k
        size_t unused;
302
1.35k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
1.35k
                                                 _num_element_after_padding, _size_of_element));
304
305
1.35k
        if (_data.size !=
306
1.35k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
1
            std::stringstream ss;
308
1
            ss << "Size information unmatched, _data.size:" << _data.size
309
1
               << ", _num_elements:" << _num_elements << ", expected size is "
310
1
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
1
            return Status::InternalError(ss.str());
312
1
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
1.35k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
1.35k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
1.35k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
1.35k
        _parsed = true;
326
1.35k
        return Status::OK();
327
1.35k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE4initEv
Line
Count
Source
299
15.5k
    Status init() override {
300
15.5k
        CHECK(!_parsed);
301
15.5k
        size_t unused;
302
15.5k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
15.5k
                                                 _num_element_after_padding, _size_of_element));
304
305
15.5k
        if (_data.size !=
306
15.5k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
15.5k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
15.5k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
15.5k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
15.5k
        _parsed = true;
326
15.5k
        return Status::OK();
327
15.5k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE4initEv
Line
Count
Source
299
43.7k
    Status init() override {
300
43.7k
        CHECK(!_parsed);
301
43.7k
        size_t unused;
302
43.7k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
43.7k
                                                 _num_element_after_padding, _size_of_element));
304
305
43.7k
        if (_data.size !=
306
43.7k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
43.7k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
43.7k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
43.7k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
43.7k
        _parsed = true;
326
43.7k
        return Status::OK();
327
43.7k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE4initEv
Line
Count
Source
299
31.2k
    Status init() override {
300
31.2k
        CHECK(!_parsed);
301
31.2k
        size_t unused;
302
31.2k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
31.2k
                                                 _num_element_after_padding, _size_of_element));
304
305
31.2k
        if (_data.size !=
306
31.2k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
31.2k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
31.2k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
31.2k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
31.2k
        _parsed = true;
326
31.2k
        return Status::OK();
327
31.2k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE4initEv
Line
Count
Source
299
1.77k
    Status init() override {
300
1.77k
        CHECK(!_parsed);
301
1.77k
        size_t unused;
302
1.77k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
1.77k
                                                 _num_element_after_padding, _size_of_element));
304
305
1.77k
        if (_data.size !=
306
1.77k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
1.77k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
1.77k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
1.77k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
1.77k
        _parsed = true;
326
1.77k
        return Status::OK();
327
1.77k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE4initEv
Line
Count
Source
299
885
    Status init() override {
300
885
        CHECK(!_parsed);
301
885
        size_t unused;
302
885
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
885
                                                 _num_element_after_padding, _size_of_element));
304
305
885
        if (_data.size !=
306
885
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
885
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
885
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
885
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
885
        _parsed = true;
326
885
        return Status::OK();
327
885
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE4initEv
Line
Count
Source
299
943
    Status init() override {
300
943
        CHECK(!_parsed);
301
943
        size_t unused;
302
943
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
943
                                                 _num_element_after_padding, _size_of_element));
304
305
943
        if (_data.size !=
306
943
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
943
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
943
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
943
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
943
        _parsed = true;
326
943
        return Status::OK();
327
943
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE4initEv
Line
Count
Source
299
5.25k
    Status init() override {
300
5.25k
        CHECK(!_parsed);
301
5.25k
        size_t unused;
302
5.25k
        RETURN_IF_ERROR(parse_bit_shuffle_header(_data, _num_elements, unused,
303
5.25k
                                                 _num_element_after_padding, _size_of_element));
304
305
5.25k
        if (_data.size !=
306
5.25k
            _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE) {
307
0
            std::stringstream ss;
308
0
            ss << "Size information unmatched, _data.size:" << _data.size
309
0
               << ", _num_elements:" << _num_elements << ", expected size is "
310
0
               << _num_element_after_padding * _size_of_element + BITSHUFFLE_PAGE_HEADER_SIZE;
311
0
            return Status::InternalError(ss.str());
312
0
        }
313
314
        // Currently, only the UINT32 block encoder supports expanding size:
315
5.25k
        if (UNLIKELY(Type != FieldType::OLAP_FIELD_TYPE_UNSIGNED_INT &&
316
5.25k
                     _size_of_element != SIZE_OF_TYPE)) {
317
0
            return Status::InternalError(
318
0
                    "invalid size info. size of element:{}, SIZE_OF_TYPE:{}, type:{}",
319
0
                    _size_of_element, SIZE_OF_TYPE, Type);
320
0
        }
321
5.25k
        if (UNLIKELY(_size_of_element > SIZE_OF_TYPE)) {
322
0
            return Status::InternalError("invalid size info. size of element:{}, SIZE_OF_TYPE:{}",
323
0
                                         _size_of_element, SIZE_OF_TYPE);
324
0
        }
325
5.25k
        _parsed = true;
326
5.25k
        return Status::OK();
327
5.25k
    }
328
329
    // If the page only contains null, then _num_elements == 0, and the nullmap has
330
    // some value. But in _seek_columns --> seek_to_ordinal --> _seek_to_pos_in_page
331
    // in this call stack it will pass pos == 0 to this method. Although we can add some
332
    // code such as check if the count == 0, then skip seek, but there are other method such
333
    // as init will also call seek with pos == 0. And the seek is useless when _num_elements
334
    // == 0, because next batch will return empty in this method.
335
3.99M
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
3.99M
        if (_num_elements == 0) [[unlikely]] {
338
12.8k
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
12.8k
        }
343
344
3.99M
        DCHECK_LE(pos, _num_elements);
345
3.99M
        _cur_index = pos;
346
3.99M
        return Status::OK();
347
3.99M
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE24seek_to_position_in_pageEm
Line
Count
Source
335
307k
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
307k
        if (_num_elements == 0) [[unlikely]] {
338
352
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
352
        }
343
344
307k
        DCHECK_LE(pos, _num_elements);
345
307k
        _cur_index = pos;
346
307k
        return Status::OK();
347
307k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE24seek_to_position_in_pageEm
Line
Count
Source
335
227k
    Status seek_to_position_in_page(size_t pos) override {
336
227k
        DCHECK(_parsed) << "Must call init()";
337
227k
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
227k
        DCHECK_LE(pos, _num_elements);
345
227k
        _cur_index = pos;
346
227k
        return Status::OK();
347
227k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE24seek_to_position_in_pageEm
Line
Count
Source
335
1.61M
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
1.61M
        if (_num_elements == 0) [[unlikely]] {
338
6.90k
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
6.90k
        }
343
344
1.61M
        DCHECK_LE(pos, _num_elements);
345
1.61M
        _cur_index = pos;
346
1.61M
        return Status::OK();
347
1.61M
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE24seek_to_position_in_pageEm
Line
Count
Source
335
120k
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
120k
        if (_num_elements == 0) [[unlikely]] {
338
505
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
505
        }
343
344
120k
        DCHECK_LE(pos, _num_elements);
345
120k
        _cur_index = pos;
346
120k
        return Status::OK();
347
120k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE24seek_to_position_in_pageEm
Line
Count
Source
335
119k
    Status seek_to_position_in_page(size_t pos) override {
336
119k
        DCHECK(_parsed) << "Must call init()";
337
119k
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
119k
        DCHECK_LE(pos, _num_elements);
345
119k
        _cur_index = pos;
346
119k
        return Status::OK();
347
119k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE24seek_to_position_in_pageEm
Line
Count
Source
335
15.5k
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
15.5k
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
15.5k
        DCHECK_LE(pos, _num_elements);
345
15.5k
        _cur_index = pos;
346
15.5k
        return Status::OK();
347
15.5k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE24seek_to_position_in_pageEm
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE24seek_to_position_in_pageEm
Line
Count
Source
335
232k
    Status seek_to_position_in_page(size_t pos) override {
336
232k
        DCHECK(_parsed) << "Must call init()";
337
232k
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
232k
        DCHECK_LE(pos, _num_elements);
345
232k
        _cur_index = pos;
346
232k
        return Status::OK();
347
232k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE24seek_to_position_in_pageEm
Line
Count
Source
335
207k
    Status seek_to_position_in_page(size_t pos) override {
336
207k
        DCHECK(_parsed) << "Must call init()";
337
207k
        if (_num_elements == 0) [[unlikely]] {
338
5
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
5
        }
343
344
207k
        DCHECK_LE(pos, _num_elements);
345
207k
        _cur_index = pos;
346
207k
        return Status::OK();
347
207k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE24seek_to_position_in_pageEm
Line
Count
Source
335
94
    Status seek_to_position_in_page(size_t pos) override {
336
94
        DCHECK(_parsed) << "Must call init()";
337
94
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
94
        DCHECK_LE(pos, _num_elements);
345
94
        _cur_index = pos;
346
94
        return Status::OK();
347
94
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE24seek_to_position_in_pageEm
Line
Count
Source
335
219k
    Status seek_to_position_in_page(size_t pos) override {
336
219k
        DCHECK(_parsed) << "Must call init()";
337
219k
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
219k
        DCHECK_LE(pos, _num_elements);
345
219k
        _cur_index = pos;
346
219k
        return Status::OK();
347
219k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE24seek_to_position_in_pageEm
Line
Count
Source
335
510k
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
510k
        if (_num_elements == 0) [[unlikely]] {
338
197
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
197
        }
343
344
510k
        DCHECK_LE(pos, _num_elements);
345
510k
        _cur_index = pos;
346
510k
        return Status::OK();
347
510k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE24seek_to_position_in_pageEm
Line
Count
Source
335
53.5k
    Status seek_to_position_in_page(size_t pos) override {
336
53.5k
        DCHECK(_parsed) << "Must call init()";
337
53.5k
        if (_num_elements == 0) [[unlikely]] {
338
14
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
14
        }
343
344
53.5k
        DCHECK_LE(pos, _num_elements);
345
53.5k
        _cur_index = pos;
346
53.5k
        return Status::OK();
347
53.5k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE24seek_to_position_in_pageEm
Line
Count
Source
335
968
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
968
        if (_num_elements == 0) [[unlikely]] {
338
8
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
8
        }
343
344
968
        DCHECK_LE(pos, _num_elements);
345
968
        _cur_index = pos;
346
968
        return Status::OK();
347
968
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE24seek_to_position_in_pageEm
Line
Count
Source
335
205k
    Status seek_to_position_in_page(size_t pos) override {
336
205k
        DCHECK(_parsed) << "Must call init()";
337
205k
        if (_num_elements == 0) [[unlikely]] {
338
16
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
16
        }
343
344
205k
        DCHECK_LE(pos, _num_elements);
345
205k
        _cur_index = pos;
346
205k
        return Status::OK();
347
205k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE24seek_to_position_in_pageEm
Line
Count
Source
335
6.92k
    Status seek_to_position_in_page(size_t pos) override {
336
6.92k
        DCHECK(_parsed) << "Must call init()";
337
6.92k
        if (_num_elements == 0) [[unlikely]] {
338
354
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
354
        }
343
344
6.92k
        DCHECK_LE(pos, _num_elements);
345
6.92k
        _cur_index = pos;
346
6.92k
        return Status::OK();
347
6.92k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE24seek_to_position_in_pageEm
Line
Count
Source
335
55
    Status seek_to_position_in_page(size_t pos) override {
336
55
        DCHECK(_parsed) << "Must call init()";
337
55
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
55
        DCHECK_LE(pos, _num_elements);
345
55
        _cur_index = pos;
346
55
        return Status::OK();
347
55
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE24seek_to_position_in_pageEm
Line
Count
Source
335
884
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
884
        if (_num_elements == 0) [[unlikely]] {
338
34
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
34
        }
343
344
884
        DCHECK_LE(pos, _num_elements);
345
884
        _cur_index = pos;
346
884
        return Status::OK();
347
884
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE24seek_to_position_in_pageEm
Line
Count
Source
335
20.0k
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
20.0k
        if (_num_elements == 0) [[unlikely]] {
338
3.40k
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
3.40k
        }
343
344
20.0k
        DCHECK_LE(pos, _num_elements);
345
20.0k
        _cur_index = pos;
346
20.0k
        return Status::OK();
347
20.0k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE24seek_to_position_in_pageEm
Line
Count
Source
335
122k
    Status seek_to_position_in_page(size_t pos) override {
336
122k
        DCHECK(_parsed) << "Must call init()";
337
122k
        if (_num_elements == 0) [[unlikely]] {
338
1.08k
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
1.08k
        }
343
344
122k
        DCHECK_LE(pos, _num_elements);
345
122k
        _cur_index = pos;
346
122k
        return Status::OK();
347
122k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE24seek_to_position_in_pageEm
Line
Count
Source
335
2.01k
    Status seek_to_position_in_page(size_t pos) override {
336
2.01k
        DCHECK(_parsed) << "Must call init()";
337
2.01k
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
2.01k
        DCHECK_LE(pos, _num_elements);
345
2.01k
        _cur_index = pos;
346
2.01k
        return Status::OK();
347
2.01k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE24seek_to_position_in_pageEm
Line
Count
Source
335
53
    Status seek_to_position_in_page(size_t pos) override {
336
53
        DCHECK(_parsed) << "Must call init()";
337
53
        if (_num_elements == 0) [[unlikely]] {
338
0
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
0
        }
343
344
53
        DCHECK_LE(pos, _num_elements);
345
53
        _cur_index = pos;
346
53
        return Status::OK();
347
53
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE24seek_to_position_in_pageEm
Line
Count
Source
335
62
    Status seek_to_position_in_page(size_t pos) override {
336
62
        DCHECK(_parsed) << "Must call init()";
337
62
        if (_num_elements == 0) [[unlikely]] {
338
1
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
1
        }
343
344
62
        DCHECK_LE(pos, _num_elements);
345
62
        _cur_index = pos;
346
62
        return Status::OK();
347
62
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE24seek_to_position_in_pageEm
Line
Count
Source
335
9.59k
    Status seek_to_position_in_page(size_t pos) override {
336
18.4E
        DCHECK(_parsed) << "Must call init()";
337
9.59k
        if (_num_elements == 0) [[unlikely]] {
338
18
            if (pos != 0) {
339
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
340
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elements);
341
0
            }
342
18
        }
343
344
9.59k
        DCHECK_LE(pos, _num_elements);
345
9.59k
        _cur_index = pos;
346
9.59k
        return Status::OK();
347
9.59k
    }
348
349
15
    Status seek_at_or_after_value(const void* value, bool* exact_match) override {
350
15
        DCHECK(_parsed) << "Must call init() firstly";
351
352
15
        if (_num_elements == 0) {
353
0
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty");
354
0
        }
355
356
15
        size_t left = 0;
357
15
        size_t right = _num_elements;
358
359
15
        void* mid_value = nullptr;
360
361
        // find the first value >= target. after loop,
362
        // - left == index of first value >= target when found
363
        // - left == _num_elements when not found (all values < target)
364
162
        while (left < right) {
365
147
            size_t mid = left + (right - left) / 2;
366
147
            mid_value = get_data(mid);
367
147
            if (TypeTraits<Type>::cmp(mid_value, value) < 0) {
368
70
                left = mid + 1;
369
77
            } else {
370
77
                right = mid;
371
77
            }
372
147
        }
373
15
        if (left >= _num_elements) {
374
3
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("all value small than the value");
375
3
        }
376
12
        void* find_value = get_data(left);
377
12
        if (TypeTraits<Type>::cmp(find_value, value) == 0) {
378
9
            *exact_match = true;
379
9
        } else {
380
3
            *exact_match = false;
381
3
        }
382
383
12
        _cur_index = left;
384
12
        return Status::OK();
385
15
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE22seek_at_or_after_valueEPKvPb
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE22seek_at_or_after_valueEPKvPb
Line
Count
Source
349
5
    Status seek_at_or_after_value(const void* value, bool* exact_match) override {
350
5
        DCHECK(_parsed) << "Must call init() firstly";
351
352
5
        if (_num_elements == 0) {
353
0
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty");
354
0
        }
355
356
5
        size_t left = 0;
357
5
        size_t right = _num_elements;
358
359
5
        void* mid_value = nullptr;
360
361
        // find the first value >= target. after loop,
362
        // - left == index of first value >= target when found
363
        // - left == _num_elements when not found (all values < target)
364
54
        while (left < right) {
365
49
            size_t mid = left + (right - left) / 2;
366
49
            mid_value = get_data(mid);
367
49
            if (TypeTraits<Type>::cmp(mid_value, value) < 0) {
368
24
                left = mid + 1;
369
25
            } else {
370
25
                right = mid;
371
25
            }
372
49
        }
373
5
        if (left >= _num_elements) {
374
1
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("all value small than the value");
375
1
        }
376
4
        void* find_value = get_data(left);
377
4
        if (TypeTraits<Type>::cmp(find_value, value) == 0) {
378
3
            *exact_match = true;
379
3
        } else {
380
1
            *exact_match = false;
381
1
        }
382
383
4
        _cur_index = left;
384
4
        return Status::OK();
385
5
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE22seek_at_or_after_valueEPKvPb
Line
Count
Source
349
5
    Status seek_at_or_after_value(const void* value, bool* exact_match) override {
350
5
        DCHECK(_parsed) << "Must call init() firstly";
351
352
5
        if (_num_elements == 0) {
353
0
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty");
354
0
        }
355
356
5
        size_t left = 0;
357
5
        size_t right = _num_elements;
358
359
5
        void* mid_value = nullptr;
360
361
        // find the first value >= target. after loop,
362
        // - left == index of first value >= target when found
363
        // - left == _num_elements when not found (all values < target)
364
54
        while (left < right) {
365
49
            size_t mid = left + (right - left) / 2;
366
49
            mid_value = get_data(mid);
367
49
            if (TypeTraits<Type>::cmp(mid_value, value) < 0) {
368
23
                left = mid + 1;
369
26
            } else {
370
26
                right = mid;
371
26
            }
372
49
        }
373
5
        if (left >= _num_elements) {
374
1
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("all value small than the value");
375
1
        }
376
4
        void* find_value = get_data(left);
377
4
        if (TypeTraits<Type>::cmp(find_value, value) == 0) {
378
3
            *exact_match = true;
379
3
        } else {
380
1
            *exact_match = false;
381
1
        }
382
383
4
        _cur_index = left;
384
4
        return Status::OK();
385
5
    }
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_9FieldTypeE41EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE22seek_at_or_after_valueEPKvPb
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE22seek_at_or_after_valueEPKvPb
Line
Count
Source
349
5
    Status seek_at_or_after_value(const void* value, bool* exact_match) override {
350
5
        DCHECK(_parsed) << "Must call init() firstly";
351
352
5
        if (_num_elements == 0) {
353
0
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty");
354
0
        }
355
356
5
        size_t left = 0;
357
5
        size_t right = _num_elements;
358
359
5
        void* mid_value = nullptr;
360
361
        // find the first value >= target. after loop,
362
        // - left == index of first value >= target when found
363
        // - left == _num_elements when not found (all values < target)
364
54
        while (left < right) {
365
49
            size_t mid = left + (right - left) / 2;
366
49
            mid_value = get_data(mid);
367
49
            if (TypeTraits<Type>::cmp(mid_value, value) < 0) {
368
23
                left = mid + 1;
369
26
            } else {
370
26
                right = mid;
371
26
            }
372
49
        }
373
5
        if (left >= _num_elements) {
374
1
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("all value small than the value");
375
1
        }
376
4
        void* find_value = get_data(left);
377
4
        if (TypeTraits<Type>::cmp(find_value, value) == 0) {
378
3
            *exact_match = true;
379
3
        } else {
380
1
            *exact_match = false;
381
1
        }
382
383
4
        _cur_index = left;
384
4
        return Status::OK();
385
5
    }
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
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE22seek_at_or_after_valueEPKvPb
386
387
    template <bool forward_index = true>
388
1.83M
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
1.83M
        DCHECK(_parsed);
390
1.83M
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
1.83M
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
1.83M
        StorageLayout<Type>::storage_to_column(
398
1.83M
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
1.83M
        *n = max_fetch;
400
1.83M
        if constexpr (forward_index) {
401
1.78M
            _cur_index += max_fetch;
402
1.78M
        }
403
404
1.83M
        return Status::OK();
405
1.83M
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
155k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
155k
        DCHECK(_parsed);
390
156k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
155k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
155k
        StorageLayout<Type>::storage_to_column(
398
155k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
155k
        *n = max_fetch;
400
155k
        if constexpr (forward_index) {
401
155k
            _cur_index += max_fetch;
402
155k
        }
403
404
155k
        return Status::OK();
405
155k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
9.56k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
9.56k
        DCHECK(_parsed);
390
9.56k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
9.56k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
9.56k
        StorageLayout<Type>::storage_to_column(
398
9.56k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
9.56k
        *n = max_fetch;
400
9.56k
        if constexpr (forward_index) {
401
9.56k
            _cur_index += max_fetch;
402
9.56k
        }
403
404
9.56k
        return Status::OK();
405
9.56k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
753k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
753k
        DCHECK(_parsed);
390
753k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
753k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
753k
        StorageLayout<Type>::storage_to_column(
398
753k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
753k
        *n = max_fetch;
400
753k
        if constexpr (forward_index) {
401
753k
            _cur_index += max_fetch;
402
753k
        }
403
404
753k
        return Status::OK();
405
753k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
87.8k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
87.8k
        DCHECK(_parsed);
390
87.8k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
87.8k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
87.8k
        StorageLayout<Type>::storage_to_column(
398
87.8k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
87.8k
        *n = max_fetch;
400
87.8k
        if constexpr (forward_index) {
401
87.8k
            _cur_index += max_fetch;
402
87.8k
        }
403
404
87.8k
        return Status::OK();
405
87.8k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
13.1k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
13.1k
        DCHECK(_parsed);
390
13.1k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
13.1k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
13.1k
        StorageLayout<Type>::storage_to_column(
398
13.1k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
13.1k
        *n = max_fetch;
400
13.1k
        if constexpr (forward_index) {
401
13.1k
            _cur_index += max_fetch;
402
13.1k
        }
403
404
13.1k
        return Status::OK();
405
13.1k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
94.1k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
94.1k
        DCHECK(_parsed);
390
94.1k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
94.1k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
94.1k
        StorageLayout<Type>::storage_to_column(
398
94.1k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
94.1k
        *n = max_fetch;
400
94.1k
        if constexpr (forward_index) {
401
94.1k
            _cur_index += max_fetch;
402
94.1k
        }
403
404
94.1k
        return Status::OK();
405
94.1k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
54.3k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
54.3k
        DCHECK(_parsed);
390
54.4k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
54.3k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
54.3k
        StorageLayout<Type>::storage_to_column(
398
54.3k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
54.3k
        *n = max_fetch;
400
        if constexpr (forward_index) {
401
            _cur_index += max_fetch;
402
        }
403
404
54.3k
        return Status::OK();
405
54.3k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
5.69k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
5.69k
        DCHECK(_parsed);
390
5.69k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
5.69k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
5.69k
        StorageLayout<Type>::storage_to_column(
398
5.69k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
5.69k
        *n = max_fetch;
400
5.69k
        if constexpr (forward_index) {
401
5.69k
            _cur_index += max_fetch;
402
5.69k
        }
403
404
5.69k
        return Status::OK();
405
5.69k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
40.2k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
40.2k
        DCHECK(_parsed);
390
40.2k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
40.2k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
40.2k
        StorageLayout<Type>::storage_to_column(
398
40.2k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
40.2k
        *n = max_fetch;
400
40.2k
        if constexpr (forward_index) {
401
40.2k
            _cur_index += max_fetch;
402
40.2k
        }
403
404
40.2k
        return Status::OK();
405
40.2k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
93
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
93
        DCHECK(_parsed);
390
93
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
93
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
93
        StorageLayout<Type>::storage_to_column(
398
93
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
93
        *n = max_fetch;
400
93
        if constexpr (forward_index) {
401
93
            _cur_index += max_fetch;
402
93
        }
403
404
93
        return Status::OK();
405
93
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
3.93k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
3.93k
        DCHECK(_parsed);
390
3.93k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
3.93k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
3.93k
        StorageLayout<Type>::storage_to_column(
398
3.93k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
3.93k
        *n = max_fetch;
400
3.93k
        if constexpr (forward_index) {
401
3.93k
            _cur_index += max_fetch;
402
3.93k
        }
403
404
3.93k
        return Status::OK();
405
3.93k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
371k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
371k
        DCHECK(_parsed);
390
371k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
371k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
371k
        StorageLayout<Type>::storage_to_column(
398
371k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
371k
        *n = max_fetch;
400
371k
        if constexpr (forward_index) {
401
371k
            _cur_index += max_fetch;
402
371k
        }
403
404
371k
        return Status::OK();
405
371k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
63.9k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
63.9k
        DCHECK(_parsed);
390
63.9k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
63.9k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
63.9k
        StorageLayout<Type>::storage_to_column(
398
63.9k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
63.9k
        *n = max_fetch;
400
63.9k
        if constexpr (forward_index) {
401
63.9k
            _cur_index += max_fetch;
402
63.9k
        }
403
404
63.9k
        return Status::OK();
405
63.9k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
2.13k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
2.13k
        DCHECK(_parsed);
390
2.14k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
2.13k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
2.13k
        StorageLayout<Type>::storage_to_column(
398
2.13k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
2.13k
        *n = max_fetch;
400
2.13k
        if constexpr (forward_index) {
401
2.13k
            _cur_index += max_fetch;
402
2.13k
        }
403
404
2.13k
        return Status::OK();
405
2.13k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
1.20k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
1.20k
        DCHECK(_parsed);
390
1.20k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
1.20k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
1.20k
        StorageLayout<Type>::storage_to_column(
398
1.20k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
1.20k
        *n = max_fetch;
400
1.20k
        if constexpr (forward_index) {
401
1.20k
            _cur_index += max_fetch;
402
1.20k
        }
403
404
1.20k
        return Status::OK();
405
1.20k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
8.08k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
8.08k
        DCHECK(_parsed);
390
8.09k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
8.08k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
8.08k
        StorageLayout<Type>::storage_to_column(
398
8.08k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
8.08k
        *n = max_fetch;
400
8.08k
        if constexpr (forward_index) {
401
8.08k
            _cur_index += max_fetch;
402
8.08k
        }
403
404
8.08k
        return Status::OK();
405
8.08k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
1.25k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
1.25k
        DCHECK(_parsed);
390
1.26k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
1.25k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
1.25k
        StorageLayout<Type>::storage_to_column(
398
1.25k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
1.25k
        *n = max_fetch;
400
1.25k
        if constexpr (forward_index) {
401
1.25k
            _cur_index += max_fetch;
402
1.25k
        }
403
404
1.25k
        return Status::OK();
405
1.25k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
7.97k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
7.97k
        DCHECK(_parsed);
390
7.97k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
7.97k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
7.97k
        StorageLayout<Type>::storage_to_column(
398
7.97k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
7.97k
        *n = max_fetch;
400
7.97k
        if constexpr (forward_index) {
401
7.97k
            _cur_index += max_fetch;
402
7.97k
        }
403
404
7.97k
        return Status::OK();
405
7.97k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
46.0k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
46.0k
        DCHECK(_parsed);
390
46.0k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
46.0k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
46.0k
        StorageLayout<Type>::storage_to_column(
398
46.0k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
46.0k
        *n = max_fetch;
400
46.0k
        if constexpr (forward_index) {
401
46.0k
            _cur_index += max_fetch;
402
46.0k
        }
403
404
46.0k
        return Status::OK();
405
46.0k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
20.5k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
20.5k
        DCHECK(_parsed);
390
20.5k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
20.5k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
20.5k
        StorageLayout<Type>::storage_to_column(
398
20.5k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
20.5k
        *n = max_fetch;
400
20.5k
        if constexpr (forward_index) {
401
20.5k
            _cur_index += max_fetch;
402
20.5k
        }
403
404
20.5k
        return Status::OK();
405
20.5k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
3.24k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
3.24k
        DCHECK(_parsed);
390
3.24k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
3.24k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
3.24k
        StorageLayout<Type>::storage_to_column(
398
3.24k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
3.24k
        *n = max_fetch;
400
3.24k
        if constexpr (forward_index) {
401
3.24k
            _cur_index += max_fetch;
402
3.24k
        }
403
404
3.24k
        return Status::OK();
405
3.24k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
625
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
625
        DCHECK(_parsed);
390
625
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
625
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
625
        StorageLayout<Type>::storage_to_column(
398
625
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
625
        *n = max_fetch;
400
625
        if constexpr (forward_index) {
401
625
            _cur_index += max_fetch;
402
625
        }
403
404
625
        return Status::OK();
405
625
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
659
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
659
        DCHECK(_parsed);
390
659
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
659
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
659
        StorageLayout<Type>::storage_to_column(
398
659
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
659
        *n = max_fetch;
400
659
        if constexpr (forward_index) {
401
659
            _cur_index += max_fetch;
402
659
        }
403
404
659
        return Status::OK();
405
659
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE10next_batchILb1EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
388
93.6k
    Status next_batch(size_t* n, MutableColumnPtr& dst) {
389
93.6k
        DCHECK(_parsed);
390
93.8k
        if (*n == 0 || _cur_index >= _num_elements) [[unlikely]] {
391
0
            *n = 0;
392
0
            return Status::OK();
393
0
        }
394
395
93.6k
        size_t max_fetch = std::min(*n, _num_elements - _cur_index);
396
397
93.6k
        StorageLayout<Type>::storage_to_column(
398
93.6k
                reinterpret_cast<const uint8_t*>(get_data(_cur_index)), max_fetch, *dst);
399
93.6k
        *n = max_fetch;
400
93.6k
        if constexpr (forward_index) {
401
93.6k
            _cur_index += max_fetch;
402
93.6k
        }
403
404
93.6k
        return Status::OK();
405
93.6k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE10next_batchILb0EEENS_6StatusEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
406
407
1.78M
    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
407
156k
    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
407
9.57k
    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
407
754k
    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
407
87.8k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
13.1k
    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
407
94.1k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
5.70k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
40.2k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
93
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
3.94k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
371k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
63.9k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
2.14k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
1.20k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
8.09k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
1.26k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
7.98k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
46.0k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
20.5k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
3.24k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
625
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
659
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
407
93.9k
    Status next_batch(size_t* n, MutableColumnPtr& dst) override { return next_batch<>(n, dst); }
408
409
    Status read_by_rowids(const rowid_t* rowids, ordinal_t page_first_ordinal, size_t* n,
410
390k
                          MutableColumnPtr& dst) override {
411
390k
        DCHECK(_parsed);
412
390k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
390k
        auto total = *n;
418
390k
        auto read_count = 0;
419
390k
        _buffer.resize(total);
420
115M
        for (size_t i = 0; i < total; ++i) {
421
115M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
115M
            if (UNLIKELY(ord >= _num_elements)) {
423
12.4k
                break;
424
12.4k
            }
425
426
115M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
115M
        }
428
429
390k
        if (LIKELY(read_count > 0)) {
430
390k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
390k
                                                   read_count, *dst);
432
390k
        }
433
434
390k
        *n = read_count;
435
390k
        return Status::OK();
436
390k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
40.3k
                          MutableColumnPtr& dst) override {
411
40.3k
        DCHECK(_parsed);
412
40.3k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
40.3k
        auto total = *n;
418
40.3k
        auto read_count = 0;
419
40.3k
        _buffer.resize(total);
420
2.16M
        for (size_t i = 0; i < total; ++i) {
421
2.12M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
2.12M
            if (UNLIKELY(ord >= _num_elements)) {
423
76
                break;
424
76
            }
425
426
2.12M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
2.12M
        }
428
429
40.4k
        if (LIKELY(read_count > 0)) {
430
40.4k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
40.4k
                                                   read_count, *dst);
432
40.4k
        }
433
434
40.3k
        *n = read_count;
435
40.3k
        return Status::OK();
436
40.3k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
6.18k
                          MutableColumnPtr& dst) override {
411
6.18k
        DCHECK(_parsed);
412
6.18k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
6.18k
        auto total = *n;
418
6.18k
        auto read_count = 0;
419
6.18k
        _buffer.resize(total);
420
644k
        for (size_t i = 0; i < total; ++i) {
421
638k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
638k
            if (UNLIKELY(ord >= _num_elements)) {
423
12
                break;
424
12
            }
425
426
638k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
638k
        }
428
429
6.19k
        if (LIKELY(read_count > 0)) {
430
6.19k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
6.19k
                                                   read_count, *dst);
432
6.19k
        }
433
434
6.18k
        *n = read_count;
435
6.18k
        return Status::OK();
436
6.18k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
85.7k
                          MutableColumnPtr& dst) override {
411
85.7k
        DCHECK(_parsed);
412
85.7k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
85.7k
        auto total = *n;
418
85.7k
        auto read_count = 0;
419
85.7k
        _buffer.resize(total);
420
27.6M
        for (size_t i = 0; i < total; ++i) {
421
27.6M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
27.6M
            if (UNLIKELY(ord >= _num_elements)) {
423
1.36k
                break;
424
1.36k
            }
425
426
27.6M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
27.6M
        }
428
429
85.7k
        if (LIKELY(read_count > 0)) {
430
85.7k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
85.7k
                                                   read_count, *dst);
432
85.7k
        }
433
434
85.7k
        *n = read_count;
435
85.7k
        return Status::OK();
436
85.7k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
44.6k
                          MutableColumnPtr& dst) override {
411
44.6k
        DCHECK(_parsed);
412
44.6k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
44.6k
        auto total = *n;
418
44.6k
        auto read_count = 0;
419
44.6k
        _buffer.resize(total);
420
26.3M
        for (size_t i = 0; i < total; ++i) {
421
26.3M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
26.3M
            if (UNLIKELY(ord >= _num_elements)) {
423
2.72k
                break;
424
2.72k
            }
425
426
26.3M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
26.3M
        }
428
429
44.7k
        if (LIKELY(read_count > 0)) {
430
44.7k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
44.7k
                                                   read_count, *dst);
432
44.7k
        }
433
434
44.6k
        *n = read_count;
435
44.6k
        return Status::OK();
436
44.6k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
9.17k
                          MutableColumnPtr& dst) override {
411
9.17k
        DCHECK(_parsed);
412
9.17k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
9.17k
        auto total = *n;
418
9.17k
        auto read_count = 0;
419
9.17k
        _buffer.resize(total);
420
1.62M
        for (size_t i = 0; i < total; ++i) {
421
1.61M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
1.61M
            if (UNLIKELY(ord >= _num_elements)) {
423
548
                break;
424
548
            }
425
426
1.61M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
1.61M
        }
428
429
9.18k
        if (LIKELY(read_count > 0)) {
430
9.18k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
9.18k
                                                   read_count, *dst);
432
9.18k
        }
433
434
9.17k
        *n = read_count;
435
9.17k
        return Status::OK();
436
9.17k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
63.0k
                          MutableColumnPtr& dst) override {
411
63.0k
        DCHECK(_parsed);
412
63.0k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
63.0k
        auto total = *n;
418
63.0k
        auto read_count = 0;
419
63.0k
        _buffer.resize(total);
420
697k
        for (size_t i = 0; i < total; ++i) {
421
634k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
634k
            if (UNLIKELY(ord >= _num_elements)) {
423
12
                break;
424
12
            }
425
426
634k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
634k
        }
428
429
63.0k
        if (LIKELY(read_count > 0)) {
430
63.0k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
63.0k
                                                   read_count, *dst);
432
63.0k
        }
433
434
63.0k
        *n = read_count;
435
63.0k
        return Status::OK();
436
63.0k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
5.50k
                          MutableColumnPtr& dst) override {
411
5.50k
        DCHECK(_parsed);
412
5.50k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
5.50k
        auto total = *n;
418
5.50k
        auto read_count = 0;
419
5.50k
        _buffer.resize(total);
420
1.17M
        for (size_t i = 0; i < total; ++i) {
421
1.17M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
1.17M
            if (UNLIKELY(ord >= _num_elements)) {
423
30
                break;
424
30
            }
425
426
1.17M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
1.17M
        }
428
429
5.50k
        if (LIKELY(read_count > 0)) {
430
5.50k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
5.50k
                                                   read_count, *dst);
432
5.50k
        }
433
434
5.50k
        *n = read_count;
435
5.50k
        return Status::OK();
436
5.50k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
8.44k
                          MutableColumnPtr& dst) override {
411
8.44k
        DCHECK(_parsed);
412
8.44k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
8.44k
        auto total = *n;
418
8.44k
        auto read_count = 0;
419
8.44k
        _buffer.resize(total);
420
1.36M
        for (size_t i = 0; i < total; ++i) {
421
1.35M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
1.35M
            if (UNLIKELY(ord >= _num_elements)) {
423
264
                break;
424
264
            }
425
426
1.35M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
1.35M
        }
428
429
8.45k
        if (LIKELY(read_count > 0)) {
430
8.45k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
8.45k
                                                   read_count, *dst);
432
8.45k
        }
433
434
8.44k
        *n = read_count;
435
8.44k
        return Status::OK();
436
8.44k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
93
                          MutableColumnPtr& dst) override {
411
93
        DCHECK(_parsed);
412
93
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
93
        auto total = *n;
418
93
        auto read_count = 0;
419
93
        _buffer.resize(total);
420
803
        for (size_t i = 0; i < total; ++i) {
421
710
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
710
            if (UNLIKELY(ord >= _num_elements)) {
423
0
                break;
424
0
            }
425
426
710
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
710
        }
428
429
93
        if (LIKELY(read_count > 0)) {
430
93
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
93
                                                   read_count, *dst);
432
93
        }
433
434
93
        *n = read_count;
435
93
        return Status::OK();
436
93
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
1.57k
                          MutableColumnPtr& dst) override {
411
1.57k
        DCHECK(_parsed);
412
1.57k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
1.57k
        auto total = *n;
418
1.57k
        auto read_count = 0;
419
1.57k
        _buffer.resize(total);
420
465k
        for (size_t i = 0; i < total; ++i) {
421
463k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
463k
            if (UNLIKELY(ord >= _num_elements)) {
423
13
                break;
424
13
            }
425
426
463k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
463k
        }
428
429
1.57k
        if (LIKELY(read_count > 0)) {
430
1.57k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
1.57k
                                                   read_count, *dst);
432
1.57k
        }
433
434
1.57k
        *n = read_count;
435
1.57k
        return Status::OK();
436
1.57k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
29.7k
                          MutableColumnPtr& dst) override {
411
29.7k
        DCHECK(_parsed);
412
29.7k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
29.7k
        auto total = *n;
418
29.7k
        auto read_count = 0;
419
29.7k
        _buffer.resize(total);
420
6.56M
        for (size_t i = 0; i < total; ++i) {
421
6.54M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
6.54M
            if (UNLIKELY(ord >= _num_elements)) {
423
881
                break;
424
881
            }
425
426
6.53M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
6.53M
        }
428
429
29.7k
        if (LIKELY(read_count > 0)) {
430
29.7k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
29.7k
                                                   read_count, *dst);
432
29.7k
        }
433
434
29.7k
        *n = read_count;
435
29.7k
        return Status::OK();
436
29.7k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
32.6k
                          MutableColumnPtr& dst) override {
411
32.6k
        DCHECK(_parsed);
412
32.6k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
32.6k
        auto total = *n;
418
32.6k
        auto read_count = 0;
419
32.6k
        _buffer.resize(total);
420
10.1M
        for (size_t i = 0; i < total; ++i) {
421
10.1M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
10.1M
            if (UNLIKELY(ord >= _num_elements)) {
423
162
                break;
424
162
            }
425
426
10.1M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
10.1M
        }
428
429
32.6k
        if (LIKELY(read_count > 0)) {
430
32.6k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
32.6k
                                                   read_count, *dst);
432
32.6k
        }
433
434
32.6k
        *n = read_count;
435
32.6k
        return Status::OK();
436
32.6k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
1.23k
                          MutableColumnPtr& dst) override {
411
1.23k
        DCHECK(_parsed);
412
1.23k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
1.23k
        auto total = *n;
418
1.23k
        auto read_count = 0;
419
1.23k
        _buffer.resize(total);
420
4.26k
        for (size_t i = 0; i < total; ++i) {
421
3.03k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
3.03k
            if (UNLIKELY(ord >= _num_elements)) {
423
1
                break;
424
1
            }
425
426
3.03k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
3.03k
        }
428
429
1.23k
        if (LIKELY(read_count > 0)) {
430
1.23k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
1.23k
                                                   read_count, *dst);
432
1.23k
        }
433
434
1.23k
        *n = read_count;
435
1.23k
        return Status::OK();
436
1.23k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
1.82k
                          MutableColumnPtr& dst) override {
411
1.82k
        DCHECK(_parsed);
412
1.82k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
1.82k
        auto total = *n;
418
1.82k
        auto read_count = 0;
419
1.82k
        _buffer.resize(total);
420
471k
        for (size_t i = 0; i < total; ++i) {
421
470k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
470k
            if (UNLIKELY(ord >= _num_elements)) {
423
244
                break;
424
244
            }
425
426
470k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
470k
        }
428
429
1.82k
        if (LIKELY(read_count > 0)) {
430
1.82k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
1.82k
                                                   read_count, *dst);
432
1.82k
        }
433
434
1.82k
        *n = read_count;
435
1.82k
        return Status::OK();
436
1.82k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
12.4k
                          MutableColumnPtr& dst) override {
411
12.4k
        DCHECK(_parsed);
412
12.4k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
12.4k
        auto total = *n;
418
12.4k
        auto read_count = 0;
419
12.4k
        _buffer.resize(total);
420
26.4k
        for (size_t i = 0; i < total; ++i) {
421
14.0k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
14.0k
            if (UNLIKELY(ord >= _num_elements)) {
423
1
                break;
424
1
            }
425
426
14.0k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
14.0k
        }
428
429
12.4k
        if (LIKELY(read_count > 0)) {
430
12.4k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
12.4k
                                                   read_count, *dst);
432
12.4k
        }
433
434
12.4k
        *n = read_count;
435
12.4k
        return Status::OK();
436
12.4k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
161
                          MutableColumnPtr& dst) override {
411
161
        DCHECK(_parsed);
412
161
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
161
        auto total = *n;
418
161
        auto read_count = 0;
419
161
        _buffer.resize(total);
420
466
        for (size_t i = 0; i < total; ++i) {
421
307
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
307
            if (UNLIKELY(ord >= _num_elements)) {
423
2
                break;
424
2
            }
425
426
305
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
305
        }
428
429
161
        if (LIKELY(read_count > 0)) {
430
161
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
161
                                                   read_count, *dst);
432
161
        }
433
434
161
        *n = read_count;
435
161
        return Status::OK();
436
161
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
4.56k
                          MutableColumnPtr& dst) override {
411
4.56k
        DCHECK(_parsed);
412
4.56k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
4.56k
        auto total = *n;
418
4.56k
        auto read_count = 0;
419
4.56k
        _buffer.resize(total);
420
19.1k
        for (size_t i = 0; i < total; ++i) {
421
14.5k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
14.5k
            if (UNLIKELY(ord >= _num_elements)) {
423
0
                break;
424
0
            }
425
426
14.5k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
14.5k
        }
428
429
4.57k
        if (LIKELY(read_count > 0)) {
430
4.57k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
4.57k
                                                   read_count, *dst);
432
4.57k
        }
433
434
4.56k
        *n = read_count;
435
4.56k
        return Status::OK();
436
4.56k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
27.6k
                          MutableColumnPtr& dst) override {
411
27.6k
        DCHECK(_parsed);
412
27.6k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
27.6k
        auto total = *n;
418
27.6k
        auto read_count = 0;
419
27.6k
        _buffer.resize(total);
420
27.1M
        for (size_t i = 0; i < total; ++i) {
421
27.1M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
27.1M
            if (UNLIKELY(ord >= _num_elements)) {
423
5.36k
                break;
424
5.36k
            }
425
426
27.1M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
27.1M
        }
428
429
27.6k
        if (LIKELY(read_count > 0)) {
430
27.6k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
27.6k
                                                   read_count, *dst);
432
27.6k
        }
433
434
27.6k
        *n = read_count;
435
27.6k
        return Status::OK();
436
27.6k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
13.4k
                          MutableColumnPtr& dst) override {
411
13.4k
        DCHECK(_parsed);
412
13.4k
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
13.4k
        auto total = *n;
418
13.4k
        auto read_count = 0;
419
13.4k
        _buffer.resize(total);
420
9.13M
        for (size_t i = 0; i < total; ++i) {
421
9.12M
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
9.12M
            if (UNLIKELY(ord >= _num_elements)) {
423
702
                break;
424
702
            }
425
426
9.12M
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
9.12M
        }
428
429
13.4k
        if (LIKELY(read_count > 0)) {
430
13.4k
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
13.4k
                                                   read_count, *dst);
432
13.4k
        }
433
434
13.4k
        *n = read_count;
435
13.4k
        return Status::OK();
436
13.4k
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
974
                          MutableColumnPtr& dst) override {
411
974
        DCHECK(_parsed);
412
974
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
974
        auto total = *n;
418
974
        auto read_count = 0;
419
974
        _buffer.resize(total);
420
2.59k
        for (size_t i = 0; i < total; ++i) {
421
1.63k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
1.63k
            if (UNLIKELY(ord >= _num_elements)) {
423
6
                break;
424
6
            }
425
426
1.62k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
1.62k
        }
428
429
974
        if (LIKELY(read_count > 0)) {
430
974
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
974
                                                   read_count, *dst);
432
974
        }
433
434
974
        *n = read_count;
435
974
        return Status::OK();
436
974
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
302
                          MutableColumnPtr& dst) override {
411
302
        DCHECK(_parsed);
412
302
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
302
        auto total = *n;
418
302
        auto read_count = 0;
419
302
        _buffer.resize(total);
420
1.00k
        for (size_t i = 0; i < total; ++i) {
421
698
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
698
            if (UNLIKELY(ord >= _num_elements)) {
423
0
                break;
424
0
            }
425
426
698
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
698
        }
428
429
302
        if (LIKELY(read_count > 0)) {
430
302
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
302
                                                   read_count, *dst);
432
302
        }
433
434
302
        *n = read_count;
435
302
        return Status::OK();
436
302
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
340
                          MutableColumnPtr& dst) override {
411
340
        DCHECK(_parsed);
412
340
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
340
        auto total = *n;
418
340
        auto read_count = 0;
419
340
        _buffer.resize(total);
420
1.34k
        for (size_t i = 0; i < total; ++i) {
421
1.01k
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
1.01k
            if (UNLIKELY(ord >= _num_elements)) {
423
3
                break;
424
3
            }
425
426
1.00k
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
1.00k
        }
428
429
341
        if (LIKELY(read_count > 0)) {
430
341
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
341
                                                   read_count, *dst);
432
341
        }
433
434
340
        *n = read_count;
435
340
        return Status::OK();
436
340
    }
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
410
541
                          MutableColumnPtr& dst) override {
411
541
        DCHECK(_parsed);
412
541
        if (*n == 0) [[unlikely]] {
413
0
            *n = 0;
414
0
            return Status::OK();
415
0
        }
416
417
541
        auto total = *n;
418
541
        auto read_count = 0;
419
541
        _buffer.resize(total);
420
1.32k
        for (size_t i = 0; i < total; ++i) {
421
783
            ordinal_t ord = rowids[i] - page_first_ordinal;
422
783
            if (UNLIKELY(ord >= _num_elements)) {
423
3
                break;
424
3
            }
425
426
780
            _buffer[read_count++] = *reinterpret_cast<CppType*>(get_data(ord));
427
780
        }
428
429
541
        if (LIKELY(read_count > 0)) {
430
541
            StorageLayout<Type>::storage_to_column(reinterpret_cast<const uint8_t*>(_buffer.data()),
431
541
                                                   read_count, *dst);
432
541
        }
433
434
541
        *n = read_count;
435
541
        return Status::OK();
436
541
    }
437
438
54.4k
    Status peek_next_batch(size_t* n, MutableColumnPtr& dst) override {
439
54.4k
        return next_batch<false>(n, dst);
440
54.4k
    }
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_9FieldTypeE5EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
_ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
438
54.4k
    Status peek_next_batch(size_t* n, MutableColumnPtr& dst) override {
439
54.4k
        return next_batch<false>(n, dst);
440
54.4k
    }
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE15peek_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_9FieldTypeE41EE15peek_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
Unexecuted instantiation: _ZN5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE15peek_next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
441
442
4
    size_t count() const override { return _num_elements; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE5countEv
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE5countEv
Line
Count
Source
442
4
    size_t count() const override { return _num_elements; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE5countEv
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_9FieldTypeE41EE5countEv
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
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE5countEv
443
444
2.93M
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE13current_indexEv
Line
Count
Source
444
226k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE13current_indexEv
Line
Count
Source
444
225k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE13current_indexEv
Line
Count
Source
444
1.03M
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE13current_indexEv
Line
Count
Source
444
80.5k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE13current_indexEv
Line
Count
Source
444
113k
    size_t current_index() const override { return _cur_index; }
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE13current_indexEv
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE13current_indexEv
Line
Count
Source
444
231k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE13current_indexEv
Line
Count
Source
444
204k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE13current_indexEv
Line
Count
Source
444
184
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE13current_indexEv
Line
Count
Source
444
216k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE13current_indexEv
Line
Count
Source
444
233k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE13current_indexEv
Line
Count
Source
444
25.8k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE13current_indexEv
Line
Count
Source
444
316
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE13current_indexEv
Line
Count
Source
444
204k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE13current_indexEv
Line
Count
Source
444
1.12k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE13current_indexEv
Line
Count
Source
444
61
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE13current_indexEv
Line
Count
Source
444
3.63k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE13current_indexEv
Line
Count
Source
444
4.51k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE13current_indexEv
Line
Count
Source
444
118k
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE13current_indexEv
Line
Count
Source
444
367
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE13current_indexEv
Line
Count
Source
444
91
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE13current_indexEv
Line
Count
Source
444
100
    size_t current_index() const override { return _cur_index; }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE13current_indexEv
Line
Count
Source
444
11.7k
    size_t current_index() const override { return _cur_index; }
445
446
118M
    char* get_data(size_t index) const {
447
118M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
118M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE1EE8get_dataEm
Line
Count
Source
446
2.28M
    char* get_data(size_t index) const {
447
2.28M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
2.28M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE3EE8get_dataEm
Line
Count
Source
446
647k
    char* get_data(size_t index) const {
447
647k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
647k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE5EE8get_dataEm
Line
Count
Source
446
29.3M
    char* get_data(size_t index) const {
447
29.3M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
29.3M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE7EE8get_dataEm
Line
Count
Source
446
26.4M
    char* get_data(size_t index) const {
447
26.4M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
26.4M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE9EE8get_dataEm
Line
Count
Source
446
1.63M
    char* get_data(size_t index) const {
447
1.63M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
1.63M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE8EE8get_dataEm
Line
Count
Source
446
783k
    char* get_data(size_t index) const {
447
783k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
783k
    }
Unexecuted instantiation: _ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE6EE8get_dataEm
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE10EE8get_dataEm
Line
Count
Source
446
1.17M
    char* get_data(size_t index) const {
447
1.17M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
1.17M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE11EE8get_dataEm
Line
Count
Source
446
1.39M
    char* get_data(size_t index) const {
447
1.39M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
1.39M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE24EE8get_dataEm
Line
Count
Source
446
803
    char* get_data(size_t index) const {
447
803
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
803
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE14EE8get_dataEm
Line
Count
Source
446
467k
    char* get_data(size_t index) const {
447
467k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
467k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE28EE8get_dataEm
Line
Count
Source
446
6.91M
    char* get_data(size_t index) const {
447
6.91M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
6.91M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE29EE8get_dataEm
Line
Count
Source
446
10.1M
    char* get_data(size_t index) const {
447
10.1M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
10.1M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE41EE8get_dataEm
Line
Count
Source
446
5.17k
    char* get_data(size_t index) const {
447
5.17k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
5.17k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE15EE8get_dataEm
Line
Count
Source
446
471k
    char* get_data(size_t index) const {
447
471k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
471k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE40EE8get_dataEm
Line
Count
Source
446
22.1k
    char* get_data(size_t index) const {
447
22.1k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
22.1k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE16EE8get_dataEm
Line
Count
Source
446
1.61k
    char* get_data(size_t index) const {
447
1.61k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
1.61k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE31EE8get_dataEm
Line
Count
Source
446
22.5k
    char* get_data(size_t index) const {
447
22.5k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
22.5k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE32EE8get_dataEm
Line
Count
Source
446
27.2M
    char* get_data(size_t index) const {
447
27.2M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
27.2M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE33EE8get_dataEm
Line
Count
Source
446
9.14M
    char* get_data(size_t index) const {
447
9.14M
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
9.14M
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE37EE8get_dataEm
Line
Count
Source
446
4.86k
    char* get_data(size_t index) const {
447
4.86k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
4.86k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE38EE8get_dataEm
Line
Count
Source
446
1.32k
    char* get_data(size_t index) const {
447
1.32k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
1.32k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE39EE8get_dataEm
Line
Count
Source
446
1.66k
    char* get_data(size_t index) const {
447
1.66k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
1.66k
    }
_ZNK5doris10segment_v221BitShufflePageDecoderILNS_9FieldTypeE42EE8get_dataEm
Line
Count
Source
446
94.5k
    char* get_data(size_t index) const {
447
94.5k
        return &_data.data[BITSHUFFLE_PAGE_HEADER_SIZE + index * SIZE_OF_TYPE];
448
94.5k
    }
449
450
private:
451
    void _copy_next_values(size_t n, void* data) {
452
        memcpy(data, get_data(_cur_index), n * SIZE_OF_TYPE);
453
    }
454
455
    using CppType = typename TypeTraits<Type>::CppType;
456
457
    static constexpr size_t SIZE_OF_TYPE = TypeTraits<Type>::size;
458
459
    Slice _data;
460
    PageDecoderOptions _options;
461
    bool _parsed;
462
    size_t _num_elements;
463
    size_t _num_element_after_padding;
464
465
    int _size_of_element;
466
    size_t _cur_index;
467
468
    std::vector<std::conditional_t<std::is_same_v<CppType, bool>, uint8_t, CppType>> _buffer;
469
470
    friend class BinaryDictPageDecoder;
471
};
472
473
} // namespace segment_v2
474
} // namespace doris