Coverage Report

Created: 2026-10-06 13:32

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
be/src/storage/segment/plain_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 "common/cast_set.h"
21
#include "storage/olap_common.h"
22
#include "storage/segment/options.h"
23
#include "storage/segment/page_builder.h"
24
#include "storage/segment/page_decoder.h"
25
#include "storage/types.h"
26
#include "util/coding.h"
27
#include "util/faststring.h"
28
#include "util/unaligned.h"
29
30
namespace doris {
31
namespace segment_v2 {
32
33
static const size_t PLAIN_PAGE_HEADER_SIZE = sizeof(uint32_t);
34
35
template <FieldType Type>
36
class PlainPageBuilder : public PageBuilderHelper<PlainPageBuilder<Type>> {
37
public:
38
    using Self = PlainPageBuilder<Type>;
39
    friend class PageBuilderHelper<Self>;
40
41
2.13k
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2.13k
        return reset();
45
2.13k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE4initEv
Line
Count
Source
41
128
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
128
        return reset();
45
128
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE4initEv
Line
Count
Source
41
38
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
38
        return reset();
45
38
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE4initEv
Line
Count
Source
41
1.49k
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
1.49k
        return reset();
45
1.49k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE4initEv
Line
Count
Source
41
377
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
377
        return reset();
45
377
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE4initEv
Line
Count
Source
41
38
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
38
        return reset();
45
38
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE4initEv
Line
Count
Source
41
10
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
10
        return reset();
45
10
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE4initEv
Line
Count
Source
41
23
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
23
        return reset();
45
23
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE4initEv
Line
Count
Source
41
2
    Status init() override {
42
        // Reserve enough space for the page, plus a bit of slop since
43
        // we often overrun the page by a few values.
44
2
        return reset();
45
2
    }
46
47
215k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE12is_page_fullEv
Line
Count
Source
47
648
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE12is_page_fullEv
Line
Count
Source
47
280
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE12is_page_fullEv
Line
Count
Source
47
201k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE12is_page_fullEv
Line
Count
Source
47
10.3k
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE12is_page_fullEv
Line
Count
Source
47
216
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE12is_page_fullEv
Line
Count
Source
47
140
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE12is_page_fullEv
Line
Count
Source
47
170
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE12is_page_fullEv
Line
Count
Source
47
388
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE12is_page_fullEv
Line
Count
Source
47
152
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE12is_page_fullEv
Line
Count
Source
47
116
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE12is_page_fullEv
Line
Count
Source
47
120
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE12is_page_fullEv
Line
Count
Source
47
120
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE12is_page_fullEv
Line
Count
Source
47
120
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE12is_page_fullEv
Line
Count
Source
47
120
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE12is_page_fullEv
Line
Count
Source
47
128
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE12is_page_fullEv
Line
Count
Source
47
116
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE12is_page_fullEv
Line
Count
Source
47
120
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE12is_page_fullEv
Line
Count
Source
47
136
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE12is_page_fullEv
Line
Count
Source
47
168
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE12is_page_fullEv
Line
Count
Source
47
116
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE12is_page_fullEv
Line
Count
Source
47
136
    bool is_page_full() override { return _remain_element_capacity == 0; }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE12is_page_fullEv
Line
Count
Source
47
136
    bool is_page_full() override { return _remain_element_capacity == 0; }
48
49
107k
    Status add(const uint8_t* vals, size_t* count) override {
50
107k
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
107k
        size_t old_size = _buffer.size();
55
107k
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
107k
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
107k
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
107k
        _count += to_add;
61
107k
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
107k
        *count = to_add;
64
107k
        _remain_element_capacity -= to_add;
65
107k
        return Status::OK();
66
107k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE3addEPKhPm
Line
Count
Source
49
324
    Status add(const uint8_t* vals, size_t* count) override {
50
324
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
324
        size_t old_size = _buffer.size();
55
324
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
324
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
324
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
324
        _count += to_add;
61
324
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
324
        *count = to_add;
64
324
        _remain_element_capacity -= to_add;
65
324
        return Status::OK();
66
324
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE3addEPKhPm
Line
Count
Source
49
140
    Status add(const uint8_t* vals, size_t* count) override {
50
140
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
140
        size_t old_size = _buffer.size();
55
140
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
140
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
140
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
140
        _count += to_add;
61
140
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
140
        *count = to_add;
64
140
        _remain_element_capacity -= to_add;
65
140
        return Status::OK();
66
140
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE3addEPKhPm
Line
Count
Source
49
100k
    Status add(const uint8_t* vals, size_t* count) override {
50
100k
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
100k
        size_t old_size = _buffer.size();
55
100k
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
100k
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
100k
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
100k
        _count += to_add;
61
100k
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
100k
        *count = to_add;
64
100k
        _remain_element_capacity -= to_add;
65
100k
        return Status::OK();
66
100k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE3addEPKhPm
Line
Count
Source
49
5.19k
    Status add(const uint8_t* vals, size_t* count) override {
50
5.19k
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
5.19k
        size_t old_size = _buffer.size();
55
5.19k
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
5.19k
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
5.19k
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
5.19k
        _count += to_add;
61
5.19k
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
5.19k
        *count = to_add;
64
5.19k
        _remain_element_capacity -= to_add;
65
5.19k
        return Status::OK();
66
5.19k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE3addEPKhPm
Line
Count
Source
49
108
    Status add(const uint8_t* vals, size_t* count) override {
50
108
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
108
        size_t old_size = _buffer.size();
55
108
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
108
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
108
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
108
        _count += to_add;
61
108
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
108
        *count = to_add;
64
108
        _remain_element_capacity -= to_add;
65
108
        return Status::OK();
66
108
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE3addEPKhPm
Line
Count
Source
49
70
    Status add(const uint8_t* vals, size_t* count) override {
50
70
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
70
        size_t old_size = _buffer.size();
55
70
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
70
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
70
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
70
        _count += to_add;
61
70
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
70
        *count = to_add;
64
70
        _remain_element_capacity -= to_add;
65
70
        return Status::OK();
66
70
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE3addEPKhPm
Line
Count
Source
49
85
    Status add(const uint8_t* vals, size_t* count) override {
50
85
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
85
        size_t old_size = _buffer.size();
55
85
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
85
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
85
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
85
        _count += to_add;
61
85
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
85
        *count = to_add;
64
85
        _remain_element_capacity -= to_add;
65
85
        return Status::OK();
66
85
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE3addEPKhPm
Line
Count
Source
49
194
    Status add(const uint8_t* vals, size_t* count) override {
50
194
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
194
        size_t old_size = _buffer.size();
55
194
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
194
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
194
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
194
        _count += to_add;
61
194
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
194
        *count = to_add;
64
194
        _remain_element_capacity -= to_add;
65
194
        return Status::OK();
66
194
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE3addEPKhPm
Line
Count
Source
49
76
    Status add(const uint8_t* vals, size_t* count) override {
50
76
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
76
        size_t old_size = _buffer.size();
55
76
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
76
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
76
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
76
        _count += to_add;
61
76
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
76
        *count = to_add;
64
76
        _remain_element_capacity -= to_add;
65
76
        return Status::OK();
66
76
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE3addEPKhPm
Line
Count
Source
49
58
    Status add(const uint8_t* vals, size_t* count) override {
50
58
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
58
        size_t old_size = _buffer.size();
55
58
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
58
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
58
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
58
        _count += to_add;
61
58
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
58
        *count = to_add;
64
58
        _remain_element_capacity -= to_add;
65
58
        return Status::OK();
66
58
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE3addEPKhPm
Line
Count
Source
49
60
    Status add(const uint8_t* vals, size_t* count) override {
50
60
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
60
        size_t old_size = _buffer.size();
55
60
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
60
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
60
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
60
        _count += to_add;
61
60
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
60
        *count = to_add;
64
60
        _remain_element_capacity -= to_add;
65
60
        return Status::OK();
66
60
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE3addEPKhPm
Line
Count
Source
49
60
    Status add(const uint8_t* vals, size_t* count) override {
50
60
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
60
        size_t old_size = _buffer.size();
55
60
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
60
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
60
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
60
        _count += to_add;
61
60
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
60
        *count = to_add;
64
60
        _remain_element_capacity -= to_add;
65
60
        return Status::OK();
66
60
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE3addEPKhPm
Line
Count
Source
49
60
    Status add(const uint8_t* vals, size_t* count) override {
50
60
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
60
        size_t old_size = _buffer.size();
55
60
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
60
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
60
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
60
        _count += to_add;
61
60
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
60
        *count = to_add;
64
60
        _remain_element_capacity -= to_add;
65
60
        return Status::OK();
66
60
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE3addEPKhPm
Line
Count
Source
49
60
    Status add(const uint8_t* vals, size_t* count) override {
50
60
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
60
        size_t old_size = _buffer.size();
55
60
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
60
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
60
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
60
        _count += to_add;
61
60
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
60
        *count = to_add;
64
60
        _remain_element_capacity -= to_add;
65
60
        return Status::OK();
66
60
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE3addEPKhPm
Line
Count
Source
49
64
    Status add(const uint8_t* vals, size_t* count) override {
50
64
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
64
        size_t old_size = _buffer.size();
55
64
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
64
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
64
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
64
        _count += to_add;
61
64
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
64
        *count = to_add;
64
64
        _remain_element_capacity -= to_add;
65
64
        return Status::OK();
66
64
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE3addEPKhPm
Line
Count
Source
49
58
    Status add(const uint8_t* vals, size_t* count) override {
50
58
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
58
        size_t old_size = _buffer.size();
55
58
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
58
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
58
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
58
        _count += to_add;
61
58
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
58
        *count = to_add;
64
58
        _remain_element_capacity -= to_add;
65
58
        return Status::OK();
66
58
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE3addEPKhPm
Line
Count
Source
49
60
    Status add(const uint8_t* vals, size_t* count) override {
50
60
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
60
        size_t old_size = _buffer.size();
55
60
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
60
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
60
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
60
        _count += to_add;
61
60
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
60
        *count = to_add;
64
60
        _remain_element_capacity -= to_add;
65
60
        return Status::OK();
66
60
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE3addEPKhPm
Line
Count
Source
49
68
    Status add(const uint8_t* vals, size_t* count) override {
50
68
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
68
        size_t old_size = _buffer.size();
55
68
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
68
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
68
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
68
        _count += to_add;
61
68
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
68
        *count = to_add;
64
68
        _remain_element_capacity -= to_add;
65
68
        return Status::OK();
66
68
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE3addEPKhPm
Line
Count
Source
49
84
    Status add(const uint8_t* vals, size_t* count) override {
50
84
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
84
        size_t old_size = _buffer.size();
55
84
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
84
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
84
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
84
        _count += to_add;
61
84
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
84
        *count = to_add;
64
84
        _remain_element_capacity -= to_add;
65
84
        return Status::OK();
66
84
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE3addEPKhPm
Line
Count
Source
49
58
    Status add(const uint8_t* vals, size_t* count) override {
50
58
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
58
        size_t old_size = _buffer.size();
55
58
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
58
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
58
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
58
        _count += to_add;
61
58
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
58
        *count = to_add;
64
58
        _remain_element_capacity -= to_add;
65
58
        return Status::OK();
66
58
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE3addEPKhPm
Line
Count
Source
49
68
    Status add(const uint8_t* vals, size_t* count) override {
50
68
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
68
        size_t old_size = _buffer.size();
55
68
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
68
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
68
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
68
        _count += to_add;
61
68
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
68
        *count = to_add;
64
68
        _remain_element_capacity -= to_add;
65
68
        return Status::OK();
66
68
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE3addEPKhPm
Line
Count
Source
49
68
    Status add(const uint8_t* vals, size_t* count) override {
50
68
        if (is_page_full() || *count == 0) {
51
0
            *count = 0;
52
0
            return Status::OK();
53
0
        }
54
68
        size_t old_size = _buffer.size();
55
68
        size_t to_add = std::min(_remain_element_capacity, *count);
56
        // This may need a large memory, should return error if could not allocated
57
        // successfully, to avoid BE OOM.
58
68
        RETURN_IF_CATCH_EXCEPTION(_buffer.resize(old_size + to_add * SIZE_OF_TYPE));
59
68
        memcpy(&_buffer[old_size], vals, to_add * SIZE_OF_TYPE);
60
68
        _count += to_add;
61
68
        _raw_data_size += to_add * SIZE_OF_TYPE;
62
63
68
        *count = to_add;
64
68
        _remain_element_capacity -= to_add;
65
68
        return Status::OK();
66
68
    }
67
68
2.36k
    Status finish(OwnedSlice* slice) override {
69
2.36k
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
2.36k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
2.36k
        return Status::OK();
72
2.36k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
132
    Status finish(OwnedSlice* slice) override {
69
132
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
132
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
132
        return Status::OK();
72
132
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
42
    Status finish(OwnedSlice* slice) override {
69
42
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
42
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
42
        return Status::OK();
72
42
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
1.53k
    Status finish(OwnedSlice* slice) override {
69
1.53k
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
1.53k
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
1.53k
        return Status::OK();
72
1.53k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
397
    Status finish(OwnedSlice* slice) override {
69
397
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
397
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
397
        return Status::OK();
72
397
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
52
    Status finish(OwnedSlice* slice) override {
69
52
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
52
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
52
        return Status::OK();
72
52
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
14
    Status finish(OwnedSlice* slice) override {
69
14
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
14
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
14
        return Status::OK();
72
14
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
29
    Status finish(OwnedSlice* slice) override {
69
29
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
29
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
29
        return Status::OK();
72
29
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
6
    Status finish(OwnedSlice* slice) override {
69
6
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
6
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
6
        return Status::OK();
72
6
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
6
    Status finish(OwnedSlice* slice) override {
69
6
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
6
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
6
        return Status::OK();
72
6
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
6
    Status finish(OwnedSlice* slice) override {
69
6
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
6
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
6
        return Status::OK();
72
6
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
8
    Status finish(OwnedSlice* slice) override {
69
8
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
8
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
8
        return Status::OK();
72
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
8
    Status finish(OwnedSlice* slice) override {
69
8
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
8
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
8
        return Status::OK();
72
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
8
    Status finish(OwnedSlice* slice) override {
69
8
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
8
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
8
        return Status::OK();
72
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
8
    Status finish(OwnedSlice* slice) override {
69
8
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
8
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
8
        return Status::OK();
72
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
12
    Status finish(OwnedSlice* slice) override {
69
12
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
12
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
12
        return Status::OK();
72
12
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
6
    Status finish(OwnedSlice* slice) override {
69
6
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
6
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
6
        return Status::OK();
72
6
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
8
    Status finish(OwnedSlice* slice) override {
69
8
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
8
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
8
        return Status::OK();
72
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
16
    Status finish(OwnedSlice* slice) override {
69
16
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
16
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
16
        return Status::OK();
72
16
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
32
    Status finish(OwnedSlice* slice) override {
69
32
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
32
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
32
        return Status::OK();
72
32
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
6
    Status finish(OwnedSlice* slice) override {
69
6
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
6
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
6
        return Status::OK();
72
6
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
16
    Status finish(OwnedSlice* slice) override {
69
16
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
16
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
16
        return Status::OK();
72
16
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE6finishEPNS_10OwnedSliceE
Line
Count
Source
68
16
    Status finish(OwnedSlice* slice) override {
69
16
        encode_fixed32_le((uint8_t*)&_buffer[0], cast_set<uint32_t>(_count));
70
16
        RETURN_IF_CATCH_EXCEPTION({ *slice = _buffer.build(); });
71
16
        return Status::OK();
72
16
    }
73
74
4.49k
    Status reset() override {
75
4.49k
        RETURN_IF_CATCH_EXCEPTION({
76
4.49k
            _buffer.reserve(_options.data_page_size);
77
4.49k
            _count = 0;
78
4.49k
            _raw_data_size = 0;
79
4.49k
            _buffer.clear();
80
4.49k
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
4.49k
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
4.49k
        });
83
4.49k
        return Status::OK();
84
4.49k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE5resetEv
Line
Count
Source
74
260
    Status reset() override {
75
260
        RETURN_IF_CATCH_EXCEPTION({
76
260
            _buffer.reserve(_options.data_page_size);
77
260
            _count = 0;
78
260
            _raw_data_size = 0;
79
260
            _buffer.clear();
80
260
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
260
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
260
        });
83
260
        return Status::OK();
84
260
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE5resetEv
Line
Count
Source
74
80
    Status reset() override {
75
80
        RETURN_IF_CATCH_EXCEPTION({
76
80
            _buffer.reserve(_options.data_page_size);
77
80
            _count = 0;
78
80
            _raw_data_size = 0;
79
80
            _buffer.clear();
80
80
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
80
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
80
        });
83
80
        return Status::OK();
84
80
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE5resetEv
Line
Count
Source
74
3.02k
    Status reset() override {
75
3.02k
        RETURN_IF_CATCH_EXCEPTION({
76
3.02k
            _buffer.reserve(_options.data_page_size);
77
3.02k
            _count = 0;
78
3.02k
            _raw_data_size = 0;
79
3.02k
            _buffer.clear();
80
3.02k
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
3.02k
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
3.02k
        });
83
3.02k
        return Status::OK();
84
3.02k
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE5resetEv
Line
Count
Source
74
774
    Status reset() override {
75
774
        RETURN_IF_CATCH_EXCEPTION({
76
774
            _buffer.reserve(_options.data_page_size);
77
774
            _count = 0;
78
774
            _raw_data_size = 0;
79
774
            _buffer.clear();
80
774
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
774
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
774
        });
83
774
        return Status::OK();
84
774
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE5resetEv
Line
Count
Source
74
90
    Status reset() override {
75
90
        RETURN_IF_CATCH_EXCEPTION({
76
90
            _buffer.reserve(_options.data_page_size);
77
90
            _count = 0;
78
90
            _raw_data_size = 0;
79
90
            _buffer.clear();
80
90
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
90
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
90
        });
83
90
        return Status::OK();
84
90
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE5resetEv
Line
Count
Source
74
24
    Status reset() override {
75
24
        RETURN_IF_CATCH_EXCEPTION({
76
24
            _buffer.reserve(_options.data_page_size);
77
24
            _count = 0;
78
24
            _raw_data_size = 0;
79
24
            _buffer.clear();
80
24
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
24
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
24
        });
83
24
        return Status::OK();
84
24
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE5resetEv
Line
Count
Source
74
52
    Status reset() override {
75
52
        RETURN_IF_CATCH_EXCEPTION({
76
52
            _buffer.reserve(_options.data_page_size);
77
52
            _count = 0;
78
52
            _raw_data_size = 0;
79
52
            _buffer.clear();
80
52
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
52
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
52
        });
83
52
        return Status::OK();
84
52
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE5resetEv
Line
Count
Source
74
8
    Status reset() override {
75
8
        RETURN_IF_CATCH_EXCEPTION({
76
8
            _buffer.reserve(_options.data_page_size);
77
8
            _count = 0;
78
8
            _raw_data_size = 0;
79
8
            _buffer.clear();
80
8
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
8
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
8
        });
83
8
        return Status::OK();
84
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE5resetEv
Line
Count
Source
74
8
    Status reset() override {
75
8
        RETURN_IF_CATCH_EXCEPTION({
76
8
            _buffer.reserve(_options.data_page_size);
77
8
            _count = 0;
78
8
            _raw_data_size = 0;
79
8
            _buffer.clear();
80
8
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
8
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
8
        });
83
8
        return Status::OK();
84
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE5resetEv
Line
Count
Source
74
8
    Status reset() override {
75
8
        RETURN_IF_CATCH_EXCEPTION({
76
8
            _buffer.reserve(_options.data_page_size);
77
8
            _count = 0;
78
8
            _raw_data_size = 0;
79
8
            _buffer.clear();
80
8
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
8
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
8
        });
83
8
        return Status::OK();
84
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE5resetEv
Line
Count
Source
74
10
    Status reset() override {
75
10
        RETURN_IF_CATCH_EXCEPTION({
76
10
            _buffer.reserve(_options.data_page_size);
77
10
            _count = 0;
78
10
            _raw_data_size = 0;
79
10
            _buffer.clear();
80
10
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
10
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
10
        });
83
10
        return Status::OK();
84
10
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE5resetEv
Line
Count
Source
74
10
    Status reset() override {
75
10
        RETURN_IF_CATCH_EXCEPTION({
76
10
            _buffer.reserve(_options.data_page_size);
77
10
            _count = 0;
78
10
            _raw_data_size = 0;
79
10
            _buffer.clear();
80
10
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
10
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
10
        });
83
10
        return Status::OK();
84
10
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE5resetEv
Line
Count
Source
74
10
    Status reset() override {
75
10
        RETURN_IF_CATCH_EXCEPTION({
76
10
            _buffer.reserve(_options.data_page_size);
77
10
            _count = 0;
78
10
            _raw_data_size = 0;
79
10
            _buffer.clear();
80
10
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
10
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
10
        });
83
10
        return Status::OK();
84
10
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE5resetEv
Line
Count
Source
74
10
    Status reset() override {
75
10
        RETURN_IF_CATCH_EXCEPTION({
76
10
            _buffer.reserve(_options.data_page_size);
77
10
            _count = 0;
78
10
            _raw_data_size = 0;
79
10
            _buffer.clear();
80
10
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
10
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
10
        });
83
10
        return Status::OK();
84
10
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE5resetEv
Line
Count
Source
74
14
    Status reset() override {
75
14
        RETURN_IF_CATCH_EXCEPTION({
76
14
            _buffer.reserve(_options.data_page_size);
77
14
            _count = 0;
78
14
            _raw_data_size = 0;
79
14
            _buffer.clear();
80
14
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
14
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
14
        });
83
14
        return Status::OK();
84
14
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE5resetEv
Line
Count
Source
74
8
    Status reset() override {
75
8
        RETURN_IF_CATCH_EXCEPTION({
76
8
            _buffer.reserve(_options.data_page_size);
77
8
            _count = 0;
78
8
            _raw_data_size = 0;
79
8
            _buffer.clear();
80
8
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
8
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
8
        });
83
8
        return Status::OK();
84
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE5resetEv
Line
Count
Source
74
10
    Status reset() override {
75
10
        RETURN_IF_CATCH_EXCEPTION({
76
10
            _buffer.reserve(_options.data_page_size);
77
10
            _count = 0;
78
10
            _raw_data_size = 0;
79
10
            _buffer.clear();
80
10
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
10
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
10
        });
83
10
        return Status::OK();
84
10
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE5resetEv
Line
Count
Source
74
18
    Status reset() override {
75
18
        RETURN_IF_CATCH_EXCEPTION({
76
18
            _buffer.reserve(_options.data_page_size);
77
18
            _count = 0;
78
18
            _raw_data_size = 0;
79
18
            _buffer.clear();
80
18
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
18
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
18
        });
83
18
        return Status::OK();
84
18
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE5resetEv
Line
Count
Source
74
34
    Status reset() override {
75
34
        RETURN_IF_CATCH_EXCEPTION({
76
34
            _buffer.reserve(_options.data_page_size);
77
34
            _count = 0;
78
34
            _raw_data_size = 0;
79
34
            _buffer.clear();
80
34
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
34
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
34
        });
83
34
        return Status::OK();
84
34
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE5resetEv
Line
Count
Source
74
8
    Status reset() override {
75
8
        RETURN_IF_CATCH_EXCEPTION({
76
8
            _buffer.reserve(_options.data_page_size);
77
8
            _count = 0;
78
8
            _raw_data_size = 0;
79
8
            _buffer.clear();
80
8
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
8
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
8
        });
83
8
        return Status::OK();
84
8
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE5resetEv
Line
Count
Source
74
18
    Status reset() override {
75
18
        RETURN_IF_CATCH_EXCEPTION({
76
18
            _buffer.reserve(_options.data_page_size);
77
18
            _count = 0;
78
18
            _raw_data_size = 0;
79
18
            _buffer.clear();
80
18
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
18
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
18
        });
83
18
        return Status::OK();
84
18
    }
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE5resetEv
Line
Count
Source
74
18
    Status reset() override {
75
18
        RETURN_IF_CATCH_EXCEPTION({
76
18
            _buffer.reserve(_options.data_page_size);
77
18
            _count = 0;
78
18
            _raw_data_size = 0;
79
18
            _buffer.clear();
80
18
            _buffer.resize(PLAIN_PAGE_HEADER_SIZE);
81
18
            _remain_element_capacity = _options.data_page_size / SIZE_OF_TYPE;
82
18
        });
83
18
        return Status::OK();
84
18
    }
85
86
0
    size_t count() const override { return _count; }
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE5countEv
87
88
827
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE4sizeEv
Line
Count
Source
88
60
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE4sizeEv
Line
Count
Source
88
16
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE4sizeEv
Line
Count
Source
88
694
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE4sizeEv
Line
Count
Source
88
33
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE4sizeEv
Line
Count
Source
88
16
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE4sizeEv
Line
Count
Source
88
4
    uint64_t size() const override { return _buffer.size(); }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE4sizeEv
Line
Count
Source
88
4
    uint64_t size() const override { return _buffer.size(); }
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE4sizeEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE4sizeEv
89
90
2.36k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EE17get_raw_data_sizeEv
Line
Count
Source
90
132
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EE17get_raw_data_sizeEv
Line
Count
Source
90
42
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EE17get_raw_data_sizeEv
Line
Count
Source
90
1.53k
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EE17get_raw_data_sizeEv
Line
Count
Source
90
397
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EE17get_raw_data_sizeEv
Line
Count
Source
90
52
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EE17get_raw_data_sizeEv
Line
Count
Source
90
14
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EE17get_raw_data_sizeEv
Line
Count
Source
90
29
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EE17get_raw_data_sizeEv
Line
Count
Source
90
6
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EE17get_raw_data_sizeEv
Line
Count
Source
90
6
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EE17get_raw_data_sizeEv
Line
Count
Source
90
6
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EE17get_raw_data_sizeEv
Line
Count
Source
90
8
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EE17get_raw_data_sizeEv
Line
Count
Source
90
8
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EE17get_raw_data_sizeEv
Line
Count
Source
90
8
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EE17get_raw_data_sizeEv
Line
Count
Source
90
8
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EE17get_raw_data_sizeEv
Line
Count
Source
90
12
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EE17get_raw_data_sizeEv
Line
Count
Source
90
6
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EE17get_raw_data_sizeEv
Line
Count
Source
90
8
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EE17get_raw_data_sizeEv
Line
Count
Source
90
16
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EE17get_raw_data_sizeEv
Line
Count
Source
90
32
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EE17get_raw_data_sizeEv
Line
Count
Source
90
6
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EE17get_raw_data_sizeEv
Line
Count
Source
90
16
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
_ZNK5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EE17get_raw_data_sizeEv
Line
Count
Source
90
16
    uint64_t get_raw_data_size() const override { return _raw_data_size; }
91
92
private:
93
2.13k
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE1EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
128
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE3EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
38
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE5EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
1.49k
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE7EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
377
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE9EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
38
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE10EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
10
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE11EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
23
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE24EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE14EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE28EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE29EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE41EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE15EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE40EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE16EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE31EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE32EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE33EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE37EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE38EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE39EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
_ZN5doris10segment_v216PlainPageBuilderILNS_9FieldTypeE42EEC2ERKNS0_18PageBuilderOptionsE
Line
Count
Source
93
2
    PlainPageBuilder(const PageBuilderOptions& options) : _options(options) {}
94
95
    faststring _buffer;
96
    PageBuilderOptions _options;
97
    size_t _count;
98
    size_t _remain_element_capacity {0};
99
    uint64_t _raw_data_size = 0;
100
    typedef typename TypeTraits<Type>::CppType CppType;
101
    enum { SIZE_OF_TYPE = TypeTraits<Type>::size };
102
};
103
104
template <FieldType Type>
105
class PlainPageDecoder : public PageDecoder {
106
public:
107
    PlainPageDecoder(Slice data, const PageDecoderOptions& options)
108
382
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
23
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
222
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
37
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
8
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
5
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
4
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
4
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
4
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
4
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
6
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
4
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
8
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
16
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
3
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
8
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EEC2ENS_5SliceERKNS0_18PageDecoderOptionsE
Line
Count
Source
108
8
            : _data(data), _options(options), _parsed(false), _num_elems(0), _cur_idx(0) {}
109
110
382
    Status init() override {
111
382
        CHECK(!_parsed);
112
113
382
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
382
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
382
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
382
        _parsed = true;
127
128
382
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
382
        return Status::OK();
130
382
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE4initEv
Line
Count
Source
110
23
    Status init() override {
111
23
        CHECK(!_parsed);
112
113
23
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
23
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
23
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
23
        _parsed = true;
127
128
23
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
23
        return Status::OK();
130
23
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE4initEv
Line
Count
Source
110
222
    Status init() override {
111
222
        CHECK(!_parsed);
112
113
222
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
222
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
222
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
222
        _parsed = true;
127
128
222
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
222
        return Status::OK();
130
222
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE4initEv
Line
Count
Source
110
37
    Status init() override {
111
37
        CHECK(!_parsed);
112
113
37
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
37
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
37
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
37
        _parsed = true;
127
128
37
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
37
        return Status::OK();
130
37
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE4initEv
Line
Count
Source
110
8
    Status init() override {
111
8
        CHECK(!_parsed);
112
113
8
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
8
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
8
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
8
        _parsed = true;
127
128
8
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
8
        return Status::OK();
130
8
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE4initEv
Line
Count
Source
110
5
    Status init() override {
111
5
        CHECK(!_parsed);
112
113
5
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
5
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
5
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
5
        _parsed = true;
127
128
5
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
5
        return Status::OK();
130
5
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE4initEv
Line
Count
Source
110
4
    Status init() override {
111
4
        CHECK(!_parsed);
112
113
4
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
4
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
4
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
4
        _parsed = true;
127
128
4
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
4
        return Status::OK();
130
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE4initEv
Line
Count
Source
110
4
    Status init() override {
111
4
        CHECK(!_parsed);
112
113
4
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
4
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
4
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
4
        _parsed = true;
127
128
4
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
4
        return Status::OK();
130
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE4initEv
Line
Count
Source
110
4
    Status init() override {
111
4
        CHECK(!_parsed);
112
113
4
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
4
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
4
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
4
        _parsed = true;
127
128
4
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
4
        return Status::OK();
130
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE4initEv
Line
Count
Source
110
4
    Status init() override {
111
4
        CHECK(!_parsed);
112
113
4
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
4
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
4
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
4
        _parsed = true;
127
128
4
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
4
        return Status::OK();
130
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE4initEv
Line
Count
Source
110
6
    Status init() override {
111
6
        CHECK(!_parsed);
112
113
6
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
6
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
6
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
6
        _parsed = true;
127
128
6
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
6
        return Status::OK();
130
6
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE4initEv
Line
Count
Source
110
4
    Status init() override {
111
4
        CHECK(!_parsed);
112
113
4
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
4
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
4
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
4
        _parsed = true;
127
128
4
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
4
        return Status::OK();
130
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE4initEv
Line
Count
Source
110
8
    Status init() override {
111
8
        CHECK(!_parsed);
112
113
8
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
8
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
8
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
8
        _parsed = true;
127
128
8
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
8
        return Status::OK();
130
8
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE4initEv
Line
Count
Source
110
16
    Status init() override {
111
16
        CHECK(!_parsed);
112
113
16
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
16
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
16
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
16
        _parsed = true;
127
128
16
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
16
        return Status::OK();
130
16
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE4initEv
Line
Count
Source
110
3
    Status init() override {
111
3
        CHECK(!_parsed);
112
113
3
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
3
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
3
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
3
        _parsed = true;
127
128
3
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
3
        return Status::OK();
130
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE4initEv
Line
Count
Source
110
8
    Status init() override {
111
8
        CHECK(!_parsed);
112
113
8
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
8
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
8
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
8
        _parsed = true;
127
128
8
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
8
        return Status::OK();
130
8
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE4initEv
Line
Count
Source
110
8
    Status init() override {
111
8
        CHECK(!_parsed);
112
113
8
        if (_data.size < PLAIN_PAGE_HEADER_SIZE) {
114
0
            return Status::InternalError(
115
0
                    "file corruption: not enough bytes for header in PlainPageDecoder ."
116
0
                    "invalid data size:{}, header size:{}",
117
0
                    _data.size, PLAIN_PAGE_HEADER_SIZE);
118
0
        }
119
120
8
        _num_elems = decode_fixed32_le((const uint8_t*)&_data[0]);
121
122
8
        if (_data.size != PLAIN_PAGE_HEADER_SIZE + _num_elems * SIZE_OF_TYPE) {
123
0
            return Status::InternalError("file corruption: unexpected data size.");
124
0
        }
125
126
8
        _parsed = true;
127
128
8
        RETURN_IF_ERROR(seek_to_position_in_page(0));
129
8
        return Status::OK();
130
8
    }
131
132
405
    Status seek_to_position_in_page(size_t pos) override {
133
405
        CHECK(_parsed) << "Must call init()";
134
405
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
405
        DCHECK_LE(pos, _num_elems);
142
143
405
        _cur_idx = cast_set<uint32_t>(pos);
144
405
        return Status::OK();
145
405
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE24seek_to_position_in_pageEm
Line
Count
Source
132
24
    Status seek_to_position_in_page(size_t pos) override {
133
24
        CHECK(_parsed) << "Must call init()";
134
24
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
24
        DCHECK_LE(pos, _num_elems);
142
143
24
        _cur_idx = cast_set<uint32_t>(pos);
144
24
        return Status::OK();
145
24
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE24seek_to_position_in_pageEm
Line
Count
Source
132
242
    Status seek_to_position_in_page(size_t pos) override {
133
242
        CHECK(_parsed) << "Must call init()";
134
242
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
242
        DCHECK_LE(pos, _num_elems);
142
143
242
        _cur_idx = cast_set<uint32_t>(pos);
144
242
        return Status::OK();
145
242
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE24seek_to_position_in_pageEm
Line
Count
Source
132
39
    Status seek_to_position_in_page(size_t pos) override {
133
39
        CHECK(_parsed) << "Must call init()";
134
39
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
39
        DCHECK_LE(pos, _num_elems);
142
143
39
        _cur_idx = cast_set<uint32_t>(pos);
144
39
        return Status::OK();
145
39
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE24seek_to_position_in_pageEm
Line
Count
Source
132
8
    Status seek_to_position_in_page(size_t pos) override {
133
8
        CHECK(_parsed) << "Must call init()";
134
8
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
8
        DCHECK_LE(pos, _num_elems);
142
143
8
        _cur_idx = cast_set<uint32_t>(pos);
144
8
        return Status::OK();
145
8
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE24seek_to_position_in_pageEm
Line
Count
Source
132
5
    Status seek_to_position_in_page(size_t pos) override {
133
5
        CHECK(_parsed) << "Must call init()";
134
5
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
5
        DCHECK_LE(pos, _num_elems);
142
143
5
        _cur_idx = cast_set<uint32_t>(pos);
144
5
        return Status::OK();
145
5
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE24seek_to_position_in_pageEm
Line
Count
Source
132
4
    Status seek_to_position_in_page(size_t pos) override {
133
4
        CHECK(_parsed) << "Must call init()";
134
4
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
4
        DCHECK_LE(pos, _num_elems);
142
143
4
        _cur_idx = cast_set<uint32_t>(pos);
144
4
        return Status::OK();
145
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE24seek_to_position_in_pageEm
Line
Count
Source
132
4
    Status seek_to_position_in_page(size_t pos) override {
133
4
        CHECK(_parsed) << "Must call init()";
134
4
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
4
        DCHECK_LE(pos, _num_elems);
142
143
4
        _cur_idx = cast_set<uint32_t>(pos);
144
4
        return Status::OK();
145
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE24seek_to_position_in_pageEm
Line
Count
Source
132
4
    Status seek_to_position_in_page(size_t pos) override {
133
4
        CHECK(_parsed) << "Must call init()";
134
4
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
4
        DCHECK_LE(pos, _num_elems);
142
143
4
        _cur_idx = cast_set<uint32_t>(pos);
144
4
        return Status::OK();
145
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE24seek_to_position_in_pageEm
Line
Count
Source
132
4
    Status seek_to_position_in_page(size_t pos) override {
133
4
        CHECK(_parsed) << "Must call init()";
134
4
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
4
        DCHECK_LE(pos, _num_elems);
142
143
4
        _cur_idx = cast_set<uint32_t>(pos);
144
4
        return Status::OK();
145
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE24seek_to_position_in_pageEm
Line
Count
Source
132
6
    Status seek_to_position_in_page(size_t pos) override {
133
6
        CHECK(_parsed) << "Must call init()";
134
6
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
6
        DCHECK_LE(pos, _num_elems);
142
143
6
        _cur_idx = cast_set<uint32_t>(pos);
144
6
        return Status::OK();
145
6
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE24seek_to_position_in_pageEm
Line
Count
Source
132
4
    Status seek_to_position_in_page(size_t pos) override {
133
4
        CHECK(_parsed) << "Must call init()";
134
4
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
4
        DCHECK_LE(pos, _num_elems);
142
143
4
        _cur_idx = cast_set<uint32_t>(pos);
144
4
        return Status::OK();
145
4
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE24seek_to_position_in_pageEm
Line
Count
Source
132
8
    Status seek_to_position_in_page(size_t pos) override {
133
8
        CHECK(_parsed) << "Must call init()";
134
8
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
8
        DCHECK_LE(pos, _num_elems);
142
143
8
        _cur_idx = cast_set<uint32_t>(pos);
144
8
        return Status::OK();
145
8
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE24seek_to_position_in_pageEm
Line
Count
Source
132
16
    Status seek_to_position_in_page(size_t pos) override {
133
16
        CHECK(_parsed) << "Must call init()";
134
16
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
16
        DCHECK_LE(pos, _num_elems);
142
143
16
        _cur_idx = cast_set<uint32_t>(pos);
144
16
        return Status::OK();
145
16
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE24seek_to_position_in_pageEm
Line
Count
Source
132
3
    Status seek_to_position_in_page(size_t pos) override {
133
3
        CHECK(_parsed) << "Must call init()";
134
3
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
3
        DCHECK_LE(pos, _num_elems);
142
143
3
        _cur_idx = cast_set<uint32_t>(pos);
144
3
        return Status::OK();
145
3
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE24seek_to_position_in_pageEm
Line
Count
Source
132
8
    Status seek_to_position_in_page(size_t pos) override {
133
8
        CHECK(_parsed) << "Must call init()";
134
8
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
8
        DCHECK_LE(pos, _num_elems);
142
143
8
        _cur_idx = cast_set<uint32_t>(pos);
144
8
        return Status::OK();
145
8
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE24seek_to_position_in_pageEm
Line
Count
Source
132
8
    Status seek_to_position_in_page(size_t pos) override {
133
8
        CHECK(_parsed) << "Must call init()";
134
8
        if (_num_elems == 0) [[unlikely]] {
135
0
            if (pos != 0) {
136
0
                return Status::Error<ErrorCode::INTERNAL_ERROR, false>(
137
0
                        "seek pos {} is larger than total elements  {}", pos, _num_elems);
138
0
            }
139
0
        }
140
141
8
        DCHECK_LE(pos, _num_elems);
142
143
8
        _cur_idx = cast_set<uint32_t>(pos);
144
8
        return Status::OK();
145
8
    }
146
147
0
    Status seek_at_or_after_value(const void* value, bool* exact_match) override {
148
0
        DCHECK(_parsed) << "Must call init() firstly";
149
150
0
        if (_num_elems == 0) {
151
0
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("page is empty");
152
0
        }
153
154
0
        uint32_t left = 0;
155
0
        uint32_t right = _num_elems;
156
157
0
        const void* mid_value = nullptr;
158
159
        // find the first value >= target. after loop,
160
        // - left == index of first value >= target when found
161
        // - left == _num_elems when not found (all values < target)
162
0
        while (left < right) {
163
0
            uint32_t mid = left + (right - left) / 2;
164
0
            mid_value = &_data[PLAIN_PAGE_HEADER_SIZE + mid * SIZE_OF_TYPE];
165
0
            if (TypeTraits<Type>::cmp(mid_value, value) < 0) {
166
0
                left = mid + 1;
167
0
            } else {
168
0
                right = mid;
169
0
            }
170
0
        }
171
0
        if (left >= _num_elems) {
172
0
            return Status::Error<ErrorCode::ENTRY_NOT_FOUND>("all value small than the value");
173
0
        }
174
0
        const void* find_value = &_data[PLAIN_PAGE_HEADER_SIZE + left * SIZE_OF_TYPE];
175
0
        if (TypeTraits<Type>::cmp(find_value, value) == 0) {
176
0
            *exact_match = true;
177
0
        } else {
178
0
            *exact_match = false;
179
0
        }
180
181
0
        _cur_idx = left;
182
0
        return Status::OK();
183
0
    }
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE22seek_at_or_after_valueEPKvPb
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE22seek_at_or_after_valueEPKvPb
184
185
933
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
933
        DCHECK(_parsed);
187
933
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
933
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
933
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
933
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
933
        *n = max_fetch;
197
933
        _cur_idx += max_fetch;
198
199
933
        return Status::OK();
200
933
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
103
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
103
        DCHECK(_parsed);
187
103
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
103
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
103
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
103
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
103
        *n = max_fetch;
197
103
        _cur_idx += max_fetch;
198
199
103
        return Status::OK();
200
103
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
46
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
46
        DCHECK(_parsed);
187
46
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
46
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
46
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
46
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
46
        *n = max_fetch;
197
46
        _cur_idx += max_fetch;
198
199
46
        return Status::OK();
200
46
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
147
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
147
        DCHECK(_parsed);
187
147
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
147
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
147
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
147
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
147
        *n = max_fetch;
197
147
        _cur_idx += max_fetch;
198
199
147
        return Status::OK();
200
147
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
64
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
64
        DCHECK(_parsed);
187
64
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
64
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
64
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
64
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
64
        *n = max_fetch;
197
64
        _cur_idx += max_fetch;
198
199
64
        return Status::OK();
200
64
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
30
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
30
        DCHECK(_parsed);
187
30
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
30
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
30
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
30
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
30
        *n = max_fetch;
197
30
        _cur_idx += max_fetch;
198
199
30
        return Status::OK();
200
30
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
93
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
93
        DCHECK(_parsed);
187
93
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
93
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
93
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
93
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
93
        *n = max_fetch;
197
93
        _cur_idx += max_fetch;
198
199
93
        return Status::OK();
200
93
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
34
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
34
        DCHECK(_parsed);
187
34
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
34
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
34
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
34
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
34
        *n = max_fetch;
197
34
        _cur_idx += max_fetch;
198
199
34
        return Status::OK();
200
34
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
28
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
28
        DCHECK(_parsed);
187
28
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
28
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
28
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
28
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
28
        *n = max_fetch;
197
28
        _cur_idx += max_fetch;
198
199
28
        return Status::OK();
200
28
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
30
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
30
        DCHECK(_parsed);
187
30
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
30
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
30
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
30
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
30
        *n = max_fetch;
197
30
        _cur_idx += max_fetch;
198
199
30
        return Status::OK();
200
30
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
38
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
38
        DCHECK(_parsed);
187
38
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
38
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
38
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
38
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
38
        *n = max_fetch;
197
38
        _cur_idx += max_fetch;
198
199
38
        return Status::OK();
200
38
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
26
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
26
        DCHECK(_parsed);
187
26
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
26
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
26
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
26
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
26
        *n = max_fetch;
197
26
        _cur_idx += max_fetch;
198
199
26
        return Status::OK();
200
26
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
30
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
30
        DCHECK(_parsed);
187
30
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
30
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
30
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
30
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
30
        *n = max_fetch;
197
30
        _cur_idx += max_fetch;
198
199
30
        return Status::OK();
200
30
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE10next_batchEPmRNS_3COWINS_7IColumnEE11mutable_ptrIS6_EE
Line
Count
Source
185
30
    Status next_batch(size_t* n, MutableColumnPtr& dst) override {
186
30
        DCHECK(_parsed);
187
30
        if (*n == 0 || _cur_idx >= _num_elems) [[unlikely]] {
188
0
            return Status::OK();
189
0
        }
190
191
30
        size_t max_fetch = std::min(*n, static_cast<size_t>(_num_elems - _cur_idx));
192
30
        const void* src_data = &_data[PLAIN_PAGE_HEADER_SIZE + _cur_idx * SIZE_OF_TYPE];
193
194
30
        dst->insert_many_fix_len_data((const char*)src_data, max_fetch);
195
196
30
        *n = max_fetch;
197
30
        _cur_idx += max_fetch;
198
199
30
        return Status::OK();
200
30
    }
201
202
    Status read_by_rowids(const rowid_t* rowids, ordinal_t page_first_ordinal, size_t* n,
203
125
                          MutableColumnPtr& dst) override {
204
125
        DCHECK(_parsed);
205
125
        if (*n == 0) [[unlikely]] {
206
0
            return Status::OK();
207
0
        }
208
209
125
        auto total = *n;
210
125
        auto read_count = 0;
211
125
        _buffer.resize(total);
212
8.47k
        for (size_t i = 0; i < total; ++i) {
213
8.35k
            ordinal_t ord = rowids[i] - page_first_ordinal;
214
8.35k
            if (UNLIKELY(ord >= _num_elems)) {
215
0
                break;
216
0
            }
217
218
8.35k
            _buffer[read_count++] =
219
8.35k
                    unaligned_load<CppType>(&_data[PLAIN_PAGE_HEADER_SIZE + ord * SIZE_OF_TYPE]);
220
8.35k
        }
221
222
125
        if (LIKELY(read_count > 0)) {
223
125
            dst->insert_many_fix_len_data((char*)_buffer.data(), read_count);
224
125
        }
225
226
125
        *n = read_count;
227
125
        return Status::OK();
228
125
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
203
10
                          MutableColumnPtr& dst) override {
204
10
        DCHECK(_parsed);
205
10
        if (*n == 0) [[unlikely]] {
206
0
            return Status::OK();
207
0
        }
208
209
10
        auto total = *n;
210
10
        auto read_count = 0;
211
10
        _buffer.resize(total);
212
21
        for (size_t i = 0; i < total; ++i) {
213
11
            ordinal_t ord = rowids[i] - page_first_ordinal;
214
11
            if (UNLIKELY(ord >= _num_elems)) {
215
0
                break;
216
0
            }
217
218
11
            _buffer[read_count++] =
219
11
                    unaligned_load<CppType>(&_data[PLAIN_PAGE_HEADER_SIZE + ord * SIZE_OF_TYPE]);
220
11
        }
221
222
10
        if (LIKELY(read_count > 0)) {
223
10
            dst->insert_many_fix_len_data((char*)_buffer.data(), read_count);
224
10
        }
225
226
10
        *n = read_count;
227
10
        return Status::OK();
228
10
    }
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
203
106
                          MutableColumnPtr& dst) override {
204
106
        DCHECK(_parsed);
205
106
        if (*n == 0) [[unlikely]] {
206
0
            return Status::OK();
207
0
        }
208
209
106
        auto total = *n;
210
106
        auto read_count = 0;
211
106
        _buffer.resize(total);
212
8.43k
        for (size_t i = 0; i < total; ++i) {
213
8.32k
            ordinal_t ord = rowids[i] - page_first_ordinal;
214
8.32k
            if (UNLIKELY(ord >= _num_elems)) {
215
0
                break;
216
0
            }
217
218
8.32k
            _buffer[read_count++] =
219
8.32k
                    unaligned_load<CppType>(&_data[PLAIN_PAGE_HEADER_SIZE + ord * SIZE_OF_TYPE]);
220
8.32k
        }
221
222
106
        if (LIKELY(read_count > 0)) {
223
106
            dst->insert_many_fix_len_data((char*)_buffer.data(), read_count);
224
106
        }
225
226
106
        *n = read_count;
227
106
        return Status::OK();
228
106
    }
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
203
8
                          MutableColumnPtr& dst) override {
204
8
        DCHECK(_parsed);
205
8
        if (*n == 0) [[unlikely]] {
206
0
            return Status::OK();
207
0
        }
208
209
8
        auto total = *n;
210
8
        auto read_count = 0;
211
8
        _buffer.resize(total);
212
22
        for (size_t i = 0; i < total; ++i) {
213
14
            ordinal_t ord = rowids[i] - page_first_ordinal;
214
14
            if (UNLIKELY(ord >= _num_elems)) {
215
0
                break;
216
0
            }
217
218
14
            _buffer[read_count++] =
219
14
                    unaligned_load<CppType>(&_data[PLAIN_PAGE_HEADER_SIZE + ord * SIZE_OF_TYPE]);
220
14
        }
221
222
8
        if (LIKELY(read_count > 0)) {
223
8
            dst->insert_many_fix_len_data((char*)_buffer.data(), read_count);
224
8
        }
225
226
8
        *n = read_count;
227
8
        return Status::OK();
228
8
    }
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
_ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Line
Count
Source
203
1
                          MutableColumnPtr& dst) override {
204
1
        DCHECK(_parsed);
205
1
        if (*n == 0) [[unlikely]] {
206
0
            return Status::OK();
207
0
        }
208
209
1
        auto total = *n;
210
1
        auto read_count = 0;
211
1
        _buffer.resize(total);
212
2
        for (size_t i = 0; i < total; ++i) {
213
1
            ordinal_t ord = rowids[i] - page_first_ordinal;
214
1
            if (UNLIKELY(ord >= _num_elems)) {
215
0
                break;
216
0
            }
217
218
1
            _buffer[read_count++] =
219
1
                    unaligned_load<CppType>(&_data[PLAIN_PAGE_HEADER_SIZE + ord * SIZE_OF_TYPE]);
220
1
        }
221
222
1
        if (LIKELY(read_count > 0)) {
223
1
            dst->insert_many_fix_len_data((char*)_buffer.data(), read_count);
224
1
        }
225
226
1
        *n = read_count;
227
1
        return Status::OK();
228
1
    }
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
Unexecuted instantiation: _ZN5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE14read_by_rowidsEPKjmPmRNS_3COWINS_7IColumnEE11mutable_ptrIS8_EE
229
230
0
    size_t count() const override {
231
0
        DCHECK(_parsed);
232
0
        return _num_elems;
233
0
    }
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE5countEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE5countEv
234
235
11
    size_t current_index() const override {
236
        DCHECK(_parsed);
237
11
        return _cur_idx;
238
11
    }
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE1EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE3EE13current_indexEv
_ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE5EE13current_indexEv
Line
Count
Source
235
11
    size_t current_index() const override {
236
        DCHECK(_parsed);
237
11
        return _cur_idx;
238
11
    }
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE7EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE9EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE10EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE11EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE24EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE14EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE28EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE29EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE41EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE15EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE40EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE16EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE31EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE32EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE33EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE37EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE38EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE39EE13current_indexEv
Unexecuted instantiation: _ZNK5doris10segment_v216PlainPageDecoderILNS_9FieldTypeE42EE13current_indexEv
239
240
private:
241
    Slice _data;
242
    PageDecoderOptions _options;
243
    bool _parsed;
244
    uint32_t _num_elems;
245
    uint32_t _cur_idx;
246
    typedef typename TypeTraits<Type>::CppType CppType;
247
    enum { SIZE_OF_TYPE = TypeTraits<Type>::size };
248
249
    std::vector<std::conditional_t<std::is_same_v<CppType, bool>, uint8_t, CppType>> _buffer;
250
};
251
252
} // namespace segment_v2
253
} // namespace doris