Coverage Report

Created: 2026-06-25 02:56

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
be/src/exec/operator/operator.cpp
Line
Count
Source
1
// Licensed to the Apache Software Foundation (ASF) under one
2
// or more contributor license agreements.  See the NOTICE file
3
// distributed with this work for additional information
4
// regarding copyright ownership.  The ASF licenses this file
5
// to you under the Apache License, Version 2.0 (the
6
// "License"); you may not use this file except in compliance
7
// with the License.  You may obtain a copy of the License at
8
//
9
//   http://www.apache.org/licenses/LICENSE-2.0
10
//
11
// Unless required by applicable law or agreed to in writing,
12
// software distributed under the License is distributed on an
13
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14
// KIND, either express or implied.  See the License for the
15
// specific language governing permissions and limitations
16
// under the License.
17
18
#include "exec/operator/operator.h"
19
20
#include <algorithm>
21
22
#include "common/status.h"
23
#include "exec/common/util.hpp"
24
#include "exec/exchange/local_exchange_sink_operator.h"
25
#include "exec/exchange/local_exchange_source_operator.h"
26
#include "exec/operator/aggregation_sink_operator.h"
27
#include "exec/operator/aggregation_source_operator.h"
28
#include "exec/operator/analytic_sink_operator.h"
29
#include "exec/operator/analytic_source_operator.h"
30
#include "exec/operator/assert_num_rows_operator.h"
31
#include "exec/operator/blackhole_sink_operator.h"
32
#include "exec/operator/bucketed_aggregation_sink_operator.h"
33
#include "exec/operator/bucketed_aggregation_source_operator.h"
34
#include "exec/operator/cache_sink_operator.h"
35
#include "exec/operator/cache_source_operator.h"
36
#include "exec/operator/datagen_operator.h"
37
#include "exec/operator/dict_sink_operator.h"
38
#include "exec/operator/distinct_streaming_aggregation_operator.h"
39
#include "exec/operator/empty_set_operator.h"
40
#include "exec/operator/exchange_sink_operator.h"
41
#include "exec/operator/exchange_source_operator.h"
42
#include "exec/operator/file_scan_operator.h"
43
#include "exec/operator/group_commit_block_sink_operator.h"
44
#include "exec/operator/group_commit_scan_operator.h"
45
#include "exec/operator/hashjoin_build_sink.h"
46
#include "exec/operator/hashjoin_probe_operator.h"
47
#include "exec/operator/hive_table_sink_operator.h"
48
#include "exec/operator/iceberg_delete_sink_operator.h"
49
#include "exec/operator/iceberg_merge_sink_operator.h"
50
#include "exec/operator/iceberg_table_sink_operator.h"
51
#include "exec/operator/jdbc_scan_operator.h"
52
#include "exec/operator/jdbc_table_sink_operator.h"
53
#include "exec/operator/local_merge_sort_source_operator.h"
54
#include "exec/operator/materialization_opertor.h"
55
#include "exec/operator/maxcompute_table_sink_operator.h"
56
#include "exec/operator/memory_scratch_sink_operator.h"
57
#include "exec/operator/meta_scan_operator.h"
58
#include "exec/operator/mock_operator.h"
59
#include "exec/operator/mock_scan_operator.h"
60
#include "exec/operator/multi_cast_data_stream_sink.h"
61
#include "exec/operator/multi_cast_data_stream_source.h"
62
#include "exec/operator/nested_loop_join_build_operator.h"
63
#include "exec/operator/nested_loop_join_probe_operator.h"
64
#include "exec/operator/olap_scan_operator.h"
65
#include "exec/operator/olap_table_sink_operator.h"
66
#include "exec/operator/olap_table_sink_v2_operator.h"
67
#include "exec/operator/partition_sort_sink_operator.h"
68
#include "exec/operator/partition_sort_source_operator.h"
69
#include "exec/operator/partitioned_aggregation_sink_operator.h"
70
#include "exec/operator/partitioned_aggregation_source_operator.h"
71
#include "exec/operator/partitioned_hash_join_probe_operator.h"
72
#include "exec/operator/partitioned_hash_join_sink_operator.h"
73
#include "exec/operator/rec_cte_anchor_sink_operator.h"
74
#include "exec/operator/rec_cte_scan_operator.h"
75
#include "exec/operator/rec_cte_sink_operator.h"
76
#include "exec/operator/rec_cte_source_operator.h"
77
#include "exec/operator/repeat_operator.h"
78
#include "exec/operator/result_file_sink_operator.h"
79
#include "exec/operator/result_sink_operator.h"
80
#include "exec/operator/schema_scan_operator.h"
81
#include "exec/operator/select_operator.h"
82
#include "exec/operator/set_probe_sink_operator.h"
83
#include "exec/operator/set_sink_operator.h"
84
#include "exec/operator/set_source_operator.h"
85
#include "exec/operator/sort_sink_operator.h"
86
#include "exec/operator/sort_source_operator.h"
87
#include "exec/operator/spill_iceberg_table_sink_operator.h"
88
#include "exec/operator/spill_sort_sink_operator.h"
89
#include "exec/operator/spill_sort_source_operator.h"
90
#include "exec/operator/streaming_aggregation_operator.h"
91
#include "exec/operator/table_function_operator.h"
92
#include "exec/operator/tvf_table_sink_operator.h"
93
#include "exec/operator/union_sink_operator.h"
94
#include "exec/operator/union_source_operator.h"
95
#include "exec/pipeline/dependency.h"
96
#include "exec/pipeline/pipeline.h"
97
#include "exprs/vexpr.h"
98
#include "exprs/vexpr_context.h"
99
#include "runtime/runtime_profile.h"
100
#include "runtime/runtime_profile_counter_names.h"
101
#include "util/debug_util.h"
102
#include "util/string_util.h"
103
104
namespace doris {
105
class RowDescriptor;
106
class RuntimeState;
107
} // namespace doris
108
109
namespace doris {
110
111
0
Status OperatorBase::close(RuntimeState* state) {
112
0
    if (_is_closed) {
113
0
        return Status::OK();
114
0
    }
115
0
    _is_closed = true;
116
0
    return Status::OK();
117
0
}
118
119
template <typename SharedStateArg>
120
2.25M
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
2.25M
    if (_parent->nereids_id() == -1) {
122
1.17M
        return fmt::format("(id={})", _parent->node_id());
123
1.17M
    } else {
124
1.07M
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
1.07M
    }
126
2.25M
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
67.9k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
67.9k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
67.9k
    } else {
124
67.9k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
67.9k
    }
126
67.9k
}
_ZNK5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
1
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
1
    if (_parent->nereids_id() == -1) {
122
1
        return fmt::format("(id={})", _parent->node_id());
123
1
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
1
}
_ZNK5doris19PipelineXLocalStateINS_15SortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
256k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
256k
    if (_parent->nereids_id() == -1) {
122
12
        return fmt::format("(id={})", _parent->node_id());
123
256k
    } else {
124
256k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
256k
    }
126
256k
}
_ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
25
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
25
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
25
    } else {
124
25
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
25
    }
126
25
}
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
9.08k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
9.08k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
9.08k
    } else {
124
9.08k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
9.08k
    }
126
9.08k
}
_ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
8.97k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
8.97k
    if (_parent->nereids_id() == -1) {
122
11
        return fmt::format("(id={})", _parent->node_id());
123
8.96k
    } else {
124
8.96k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
8.96k
    }
126
8.97k
}
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
148k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
148k
    if (_parent->nereids_id() == -1) {
122
29
        return fmt::format("(id={})", _parent->node_id());
123
148k
    } else {
124
148k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
148k
    }
126
148k
}
_ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
293
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
293
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
293
    } else {
124
293
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
293
    }
126
293
}
_ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
122
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
122
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
122
    } else {
124
122
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
122
    }
126
122
}
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
934k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
934k
    if (_parent->nereids_id() == -1) {
122
410k
        return fmt::format("(id={})", _parent->node_id());
123
523k
    } else {
124
523k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
523k
    }
126
934k
}
_ZNK5doris19PipelineXLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
55.3k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
55.3k
    if (_parent->nereids_id() == -1) {
122
2
        return fmt::format("(id={})", _parent->node_id());
123
55.3k
    } else {
124
55.3k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
55.3k
    }
126
55.3k
}
_ZNK5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
17
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
17
    if (_parent->nereids_id() == -1) {
122
17
        return fmt::format("(id={})", _parent->node_id());
123
17
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
17
}
_ZNK5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
9.25k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
9.25k
    if (_parent->nereids_id() == -1) {
122
9.25k
        return fmt::format("(id={})", _parent->node_id());
123
18.4E
    } else {
124
18.4E
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
18.4E
    }
126
9.25k
}
_ZNK5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
457
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
457
    if (_parent->nereids_id() == -1) {
122
102
        return fmt::format("(id={})", _parent->node_id());
123
355
    } else {
124
355
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
355
    }
126
457
}
_ZNK5doris19PipelineXLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
4.83k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
4.83k
    if (_parent->nereids_id() == -1) {
122
13
        return fmt::format("(id={})", _parent->node_id());
123
4.82k
    } else {
124
4.82k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
4.82k
    }
126
4.83k
}
_ZNK5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
756k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
757k
    if (_parent->nereids_id() == -1) {
122
757k
        return fmt::format("(id={})", _parent->node_id());
123
18.4E
    } else {
124
18.4E
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
18.4E
    }
126
756k
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_16BasicSharedStateEE11name_suffixB5cxx11Ev
_ZNK5doris19PipelineXLocalStateINS_17RecCTESharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
163
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
163
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
163
    } else {
124
163
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
163
    }
126
163
}
127
128
template <typename SharedStateArg>
129
1.37M
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
1.37M
    if (_parent->nereids_id() == -1) {
131
826k
        return fmt::format("(id={})", _parent->node_id());
132
826k
    } else {
133
547k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
547k
    }
135
1.37M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
116k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
116k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
116k
    } else {
133
116k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
116k
    }
135
116k
}
_ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
2
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
2
    if (_parent->nereids_id() == -1) {
131
1
        return fmt::format("(id={})", _parent->node_id());
132
1
    } else {
133
1
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
1
    }
135
2
}
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
258k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
258k
    if (_parent->nereids_id() == -1) {
131
9
        return fmt::format("(id={})", _parent->node_id());
132
258k
    } else {
133
258k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
258k
    }
135
258k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
32
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
32
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
32
    } else {
133
32
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
32
    }
135
32
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
9.09k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
9.09k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
9.09k
    } else {
133
9.09k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
9.09k
    }
135
9.09k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
9.02k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
9.02k
    if (_parent->nereids_id() == -1) {
131
11
        return fmt::format("(id={})", _parent->node_id());
132
9.01k
    } else {
133
9.01k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
9.01k
    }
135
9.02k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
148k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
148k
    if (_parent->nereids_id() == -1) {
131
29
        return fmt::format("(id={})", _parent->node_id());
132
148k
    } else {
133
148k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
148k
    }
135
148k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
290
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
290
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
290
    } else {
133
290
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
290
    }
135
290
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
132
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
132
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
132
    } else {
133
132
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
132
    }
135
132
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
92
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
92
    if (_parent->nereids_id() == -1) {
131
92
        return fmt::format("(id={})", _parent->node_id());
132
92
    } else {
133
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
0
    }
135
92
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
5.42k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
5.42k
    if (_parent->nereids_id() == -1) {
131
3
        return fmt::format("(id={})", _parent->node_id());
132
5.42k
    } else {
133
5.42k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
5.42k
    }
135
5.42k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
460
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
460
    if (_parent->nereids_id() == -1) {
131
102
        return fmt::format("(id={})", _parent->node_id());
132
358
    } else {
133
358
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
358
    }
135
460
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE11name_suffixB5cxx11Ev
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
12.5k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
12.5k
    if (_parent->nereids_id() == -1) {
131
12.5k
        return fmt::format("(id={})", _parent->node_id());
132
12.5k
    } else {
133
6
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
6
    }
135
12.5k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
290k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
290k
    if (_parent->nereids_id() == -1) {
131
290k
        return fmt::format("(id={})", _parent->node_id());
132
18.4E
    } else {
133
18.4E
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
18.4E
    }
135
290k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
522k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
522k
    if (_parent->nereids_id() == -1) {
131
522k
        return fmt::format("(id={})", _parent->node_id());
132
522k
    } else {
133
362
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
362
    }
135
522k
}
_ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
17
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
17
    if (_parent->nereids_id() == -1) {
131
17
        return fmt::format("(id={})", _parent->node_id());
132
17
    } else {
133
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
0
    }
135
17
}
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
326
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
326
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
326
    } else {
133
326
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
326
    }
135
326
}
136
137
template <typename SharedStateArg>
138
29.9k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
29.9k
    if (_terminated) {
140
4
        return Status::OK();
141
4
    }
142
29.9k
    _terminated = true;
143
29.9k
    return Status::OK();
144
29.9k
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
24.0k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
24.0k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
24.0k
    _terminated = true;
143
24.0k
    return Status::OK();
144
24.0k
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
821
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
821
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
821
    _terminated = true;
143
821
    return Status::OK();
144
821
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
12
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
12
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
12
    _terminated = true;
143
12
    return Status::OK();
144
12
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
1
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
1
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
1
    _terminated = true;
143
1
    return Status::OK();
144
1
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
2.55k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
2.55k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
2.55k
    _terminated = true;
143
2.55k
    return Status::OK();
144
2.55k
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
1.76k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
1.76k
    if (_terminated) {
140
4
        return Status::OK();
141
4
    }
142
1.75k
    _terminated = true;
143
1.75k
    return Status::OK();
144
1.76k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
18
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
18
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
18
    _terminated = true;
143
18
    return Status::OK();
144
18
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
3
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
3
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
3
    _terminated = true;
143
3
    return Status::OK();
144
3
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
525
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
525
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
525
    _terminated = true;
143
525
    return Status::OK();
144
525
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
97
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
97
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
97
    _terminated = true;
143
97
    return Status::OK();
144
97
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
154
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
154
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
154
    _terminated = true;
143
154
    return Status::OK();
144
154
}
145
146
422k
DataDistribution OperatorBase::required_data_distribution(RuntimeState* /*state*/) const {
147
422k
    return _child && _child->is_serial_operator() && !is_source()
148
422k
                   ? DataDistribution(TLocalPartitionType::PASSTHROUGH)
149
422k
                   : DataDistribution(TLocalPartitionType::NOOP);
150
422k
}
151
152
40.8k
bool OperatorBase::child_breaks_local_key_distribution(RuntimeState* state) const {
153
40.8k
    if (!_child) {
154
35.9k
        return false;
155
35.9k
    }
156
4.86k
    if (_child->is_serial_operator()) {
157
158
        return true;
158
158
    }
159
4.70k
    const auto child_distribution = _child->required_data_distribution(state);
160
4.70k
    return child_distribution.need_local_exchange() &&
161
4.70k
           !is_shuffled_exchange(child_distribution.distribution_type);
162
4.86k
}
163
164
82.5k
const RowDescriptor& OperatorBase::row_desc() const {
165
82.5k
    return _child->row_desc();
166
82.5k
}
167
168
template <typename SharedStateArg>
169
17.2k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
17.2k
    fmt::memory_buffer debug_string_buffer;
171
17.2k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
17.2k
    return fmt::to_string(debug_string_buffer);
173
17.2k
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
84
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
84
    fmt::memory_buffer debug_string_buffer;
171
84
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
84
    return fmt::to_string(debug_string_buffer);
173
84
}
_ZNK5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
3
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
3
    fmt::memory_buffer debug_string_buffer;
171
3
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
3
    return fmt::to_string(debug_string_buffer);
173
3
}
_ZNK5doris19PipelineXLocalStateINS_15SortSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
88
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
88
    fmt::memory_buffer debug_string_buffer;
171
88
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
88
    return fmt::to_string(debug_string_buffer);
173
88
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
112
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
112
    fmt::memory_buffer debug_string_buffer;
171
112
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
112
    return fmt::to_string(debug_string_buffer);
173
112
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
16.6k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
16.6k
    fmt::memory_buffer debug_string_buffer;
171
16.6k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
16.6k
    return fmt::to_string(debug_string_buffer);
173
16.6k
}
_ZNK5doris19PipelineXLocalStateINS_16UnionSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
2
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
2
    fmt::memory_buffer debug_string_buffer;
171
2
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
2
    return fmt::to_string(debug_string_buffer);
173
2
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_14SetSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
335
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
335
    fmt::memory_buffer debug_string_buffer;
171
335
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
335
    return fmt::to_string(debug_string_buffer);
173
335
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
174
175
template <typename SharedStateArg>
176
17.1k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
17.1k
    fmt::memory_buffer debug_string_buffer;
178
17.1k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
17.1k
    return fmt::to_string(debug_string_buffer);
180
17.1k
}
_ZNK5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
18
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
18
    fmt::memory_buffer debug_string_buffer;
178
18
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
18
    return fmt::to_string(debug_string_buffer);
180
18
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
88
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
88
    fmt::memory_buffer debug_string_buffer;
178
88
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
88
    return fmt::to_string(debug_string_buffer);
180
88
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
112
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
112
    fmt::memory_buffer debug_string_buffer;
178
112
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
112
    return fmt::to_string(debug_string_buffer);
180
112
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
362
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
362
    fmt::memory_buffer debug_string_buffer;
178
362
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
362
    return fmt::to_string(debug_string_buffer);
180
362
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
105
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
105
    fmt::memory_buffer debug_string_buffer;
178
105
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
105
    return fmt::to_string(debug_string_buffer);
180
105
}
_ZNK5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
16.4k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
16.4k
    fmt::memory_buffer debug_string_buffer;
178
16.4k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
16.4k
    return fmt::to_string(debug_string_buffer);
180
16.4k
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
181
182
17.5k
std::string OperatorXBase::debug_string(int indentation_level) const {
183
17.5k
    fmt::memory_buffer debug_string_buffer;
184
17.5k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, parallel_tasks={}, _is_serial_operator={}",
185
17.5k
                   std::string(indentation_level * 2, ' '), _op_name, node_id(), _parallel_tasks,
186
17.5k
                   _is_serial_operator);
187
17.5k
    return fmt::to_string(debug_string_buffer);
188
17.5k
}
189
190
17.2k
std::string OperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
191
17.2k
    return state->get_local_state(operator_id())->debug_string(indentation_level);
192
17.2k
}
193
194
834k
Status OperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
195
834k
    std::string node_name = print_plan_node_type(tnode.node_type);
196
834k
    _nereids_id = tnode.nereids_id;
197
834k
    if (!tnode.intermediate_output_tuple_id_list.empty()) {
198
3.96k
        if (!tnode.__isset.output_tuple_id) {
199
0
            return Status::InternalError("no final output tuple id");
200
0
        }
201
3.96k
        if (tnode.intermediate_output_tuple_id_list.size() !=
202
3.96k
            tnode.intermediate_projections_list.size()) {
203
0
            return Status::InternalError(
204
0
                    "intermediate_output_tuple_id_list size:{} not match "
205
0
                    "intermediate_projections_list size:{}",
206
0
                    tnode.intermediate_output_tuple_id_list.size(),
207
0
                    tnode.intermediate_projections_list.size());
208
0
        }
209
3.96k
    }
210
834k
    auto substr = node_name.substr(0, node_name.find("_NODE"));
211
834k
    _op_name = substr + "_OPERATOR";
212
213
834k
    if (tnode.__isset.vconjunct) {
214
0
        return Status::InternalError("vconjunct is not supported yet");
215
834k
    } else if (tnode.__isset.conjuncts) {
216
449k
        for (const auto& conjunct : tnode.conjuncts) {
217
449k
            VExprContextSPtr context;
218
449k
            RETURN_IF_ERROR(VExpr::create_expr_tree(conjunct, context));
219
449k
            _conjuncts.emplace_back(context);
220
449k
        }
221
147k
    }
222
223
    // create the projections expr
224
834k
    if (tnode.__isset.projections) {
225
321k
        DCHECK(tnode.__isset.output_tuple_id);
226
321k
        RETURN_IF_ERROR(VExpr::create_expr_trees(tnode.projections, _projections));
227
321k
    }
228
834k
    if (!tnode.intermediate_projections_list.empty()) {
229
3.96k
        DCHECK(tnode.__isset.projections) << "no final projections";
230
3.96k
        _intermediate_projections.reserve(tnode.intermediate_projections_list.size());
231
7.86k
        for (const auto& tnode_projections : tnode.intermediate_projections_list) {
232
7.86k
            VExprContextSPtrs projections;
233
7.86k
            RETURN_IF_ERROR(VExpr::create_expr_trees(tnode_projections, projections));
234
7.86k
            _intermediate_projections.push_back(projections);
235
7.86k
        }
236
3.96k
    }
237
834k
    return Status::OK();
238
834k
}
239
240
866k
Status OperatorXBase::prepare(RuntimeState* state) {
241
866k
    for (auto& conjunct : _conjuncts) {
242
449k
        RETURN_IF_ERROR(conjunct->prepare(state, intermediate_row_desc()));
243
449k
    }
244
866k
    if (state->enable_adjust_conjunct_order_by_cost()) {
245
813k
        std::ranges::stable_sort(_conjuncts, [](const auto& a, const auto& b) {
246
594k
            return a->execute_cost() < b->execute_cost();
247
594k
        });
248
813k
    };
249
250
874k
    for (int i = 0; i < _intermediate_projections.size(); i++) {
251
7.86k
        RETURN_IF_ERROR(
252
7.86k
                VExpr::prepare(_intermediate_projections[i], state, intermediate_row_desc(i)));
253
7.86k
    }
254
866k
    RETURN_IF_ERROR(VExpr::prepare(_projections, state, projections_row_desc()));
255
256
866k
    if (has_output_row_desc()) {
257
321k
        RETURN_IF_ERROR(VExpr::check_expr_output_type(_projections, *_output_row_descriptor));
258
321k
    }
259
260
866k
    for (auto& conjunct : _conjuncts) {
261
449k
        RETURN_IF_ERROR(conjunct->open(state));
262
449k
    }
263
866k
    RETURN_IF_ERROR(VExpr::open(_projections, state));
264
866k
    for (auto& projections : _intermediate_projections) {
265
7.86k
        RETURN_IF_ERROR(VExpr::open(projections, state));
266
7.86k
    }
267
866k
    if (_child && !is_source()) {
268
136k
        RETURN_IF_ERROR(_child->prepare(state));
269
136k
    }
270
271
866k
    if (VExpr::contains_blockable_function(_conjuncts) ||
272
866k
        VExpr::contains_blockable_function(_projections)) {
273
0
        _blockable = true;
274
0
    }
275
276
866k
    return Status::OK();
277
866k
}
278
279
7.42k
Status OperatorXBase::terminate(RuntimeState* state) {
280
7.42k
    if (_child && !is_source()) {
281
1.43k
        RETURN_IF_ERROR(_child->terminate(state));
282
1.43k
    }
283
7.42k
    auto result = state->get_local_state_result(operator_id());
284
7.42k
    if (!result) {
285
0
        return result.error();
286
0
    }
287
7.42k
    return result.value()->terminate(state);
288
7.42k
}
289
290
6.33M
Status OperatorXBase::close(RuntimeState* state) {
291
6.33M
    if (_child && !is_source()) {
292
1.18M
        RETURN_IF_ERROR(_child->close(state));
293
1.18M
    }
294
6.33M
    auto result = state->get_local_state_result(operator_id());
295
6.33M
    if (!result) {
296
0
        return result.error();
297
0
    }
298
6.33M
    return result.value()->close(state);
299
6.33M
}
300
301
303k
void PipelineXLocalStateBase::clear_origin_block() {
302
303k
    _origin_block.clear_column_data(_parent->intermediate_row_desc().num_materialized_slots());
303
303k
}
304
305
620k
Status PipelineXLocalStateBase::filter_block(const VExprContextSPtrs& expr_contexts, Block* block) {
306
620k
    RETURN_IF_ERROR(VExprContext::filter_block(expr_contexts, block, block->columns()));
307
308
620k
    _estimate_memory_usage += VExprContext::get_memory_usage(expr_contexts);
309
620k
    return Status::OK();
310
620k
}
311
312
0
bool PipelineXLocalStateBase::is_blockable() const {
313
0
    return std::any_of(_projections.begin(), _projections.end(),
314
0
                       [&](VExprContextSPtr expr) -> bool { return expr->is_blockable(); });
315
0
}
316
317
Status OperatorXBase::do_projections(RuntimeState* state, Block* origin_block,
318
303k
                                     Block* output_block) const {
319
303k
    auto* local_state = state->get_local_state(operator_id());
320
303k
    SCOPED_TIMER(local_state->exec_time_counter());
321
303k
    SCOPED_TIMER(local_state->_projection_timer);
322
303k
    const size_t rows = origin_block->rows();
323
303k
    if (rows == 0) {
324
157k
        return Status::OK();
325
157k
    }
326
146k
    Block input_block = *origin_block;
327
328
146k
    size_t bytes_usage = 0;
329
146k
    ColumnsWithTypeAndName new_columns;
330
146k
    for (const auto& projections : local_state->_intermediate_projections) {
331
1.51k
        if (projections.empty()) {
332
0
            return Status::InternalError("meet empty intermediate projection, node id: {}",
333
0
                                         node_id());
334
0
        }
335
1.51k
        new_columns.resize(projections.size());
336
10.5k
        for (int i = 0; i < projections.size(); i++) {
337
9.02k
            RETURN_IF_ERROR(projections[i]->execute(&input_block, new_columns[i]));
338
9.02k
            if (new_columns[i].column->size() != rows) {
339
0
                return Status::InternalError(
340
0
                        "intermediate projection result column size {} not equal input rows {}, "
341
0
                        "expr: {}",
342
0
                        new_columns[i].column->size(), rows,
343
0
                        projections[i]->root()->debug_string());
344
0
            }
345
9.02k
        }
346
1.51k
        Block tmp_block {new_columns};
347
1.51k
        bytes_usage += tmp_block.allocated_bytes();
348
1.51k
        input_block.swap(tmp_block);
349
1.51k
    }
350
351
146k
    if (input_block.rows() != rows) {
352
0
        return Status::InternalError(
353
0
                "after intermediate projections input block rows {} not equal origin rows {}, "
354
0
                "input_block: {}",
355
0
                input_block.rows(), rows, input_block.dump_structure());
356
0
    }
357
670k
    auto insert_column_datas = [&](auto& to, ColumnPtr& from, size_t rows) {
358
670k
        if (is_column_nullable(*to) && !is_column_nullable(*from)) {
359
0
            if (_keep_origin || !from->is_exclusive()) {
360
0
                auto& null_column = reinterpret_cast<ColumnNullable&>(*to);
361
0
                null_column.get_nested_column().insert_range_from(*from, 0, rows);
362
0
                null_column.get_null_map_column().get_data().resize_fill(rows, 0);
363
0
                bytes_usage += null_column.allocated_bytes();
364
0
            } else {
365
0
                to = make_nullable(from, false)->assert_mutable();
366
0
            }
367
670k
        } else {
368
670k
            if (_keep_origin || !from->is_exclusive()) {
369
670k
                to->insert_range_from(*from, 0, rows);
370
670k
                bytes_usage += from->allocated_bytes();
371
18.4E
            } else {
372
18.4E
                to = from->assert_mutable();
373
18.4E
            }
374
670k
        }
375
670k
    };
376
377
146k
    auto scoped_mutable_block = VectorizedUtils::build_scoped_mutable_mem_reuse_block(
378
146k
            output_block, *_output_row_descriptor);
379
146k
    auto& mutable_block = scoped_mutable_block.mutable_block();
380
146k
    auto& mutable_columns = mutable_block.mutable_columns();
381
146k
    if (rows != 0) {
382
146k
        DCHECK_EQ(mutable_columns.size(), local_state->_projections.size()) << debug_string();
383
816k
        for (int i = 0; i < mutable_columns.size(); ++i) {
384
670k
            ColumnPtr column_ptr;
385
670k
            RETURN_IF_ERROR(local_state->_projections[i]->execute(&input_block, column_ptr));
386
670k
            if (column_ptr->size() != rows) {
387
0
                return Status::InternalError(
388
0
                        "projection result column size {} not equal input rows {}, expr: {}",
389
0
                        column_ptr->size(), rows,
390
0
                        local_state->_projections[i]->root()->debug_string());
391
0
            }
392
670k
            column_ptr = column_ptr->convert_to_full_column_if_const();
393
670k
            bytes_usage += column_ptr->allocated_bytes();
394
670k
            insert_column_datas(mutable_columns[i], column_ptr, rows);
395
670k
        }
396
146k
        DCHECK(mutable_block.rows() == rows);
397
146k
    }
398
146k
    local_state->_estimate_memory_usage += bytes_usage;
399
400
146k
    return Status::OK();
401
146k
}
402
403
4.56M
Status OperatorXBase::get_block_after_projects(RuntimeState* state, Block* block, bool* eos) {
404
4.56M
    DBUG_EXECUTE_IF("Pipeline::return_empty_block", {
405
4.56M
        if (this->_op_name == "AGGREGATION_OPERATOR" || this->_op_name == "HASH_JOIN_OPERATOR" ||
406
4.56M
            this->_op_name == "PARTITIONED_AGGREGATION_OPERATOR" ||
407
4.56M
            this->_op_name == "PARTITIONED_HASH_JOIN_OPERATOR" ||
408
4.56M
            this->_op_name == "CROSS_JOIN_OPERATOR" || this->_op_name == "SORT_OPERATOR") {
409
4.56M
            if (_debug_point_count++ % 2 == 0) {
410
4.56M
                return Status::OK();
411
4.56M
            }
412
4.56M
        }
413
4.56M
    });
414
415
4.56M
    Status status;
416
4.56M
    auto* local_state = state->get_local_state(operator_id());
417
4.56M
    Defer defer([&]() {
418
4.56M
        if (status.ok()) {
419
4.56M
            local_state->update_output_block_counters(*block);
420
4.56M
        }
421
4.56M
    });
422
4.56M
    if (_output_row_descriptor) {
423
303k
        local_state->clear_origin_block();
424
303k
        status = get_block(state, &local_state->_origin_block, eos);
425
303k
        if (UNLIKELY(!status.ok())) {
426
20
            return status;
427
20
        }
428
303k
        status = do_projections(state, &local_state->_origin_block, block);
429
303k
        return status;
430
303k
    }
431
4.26M
    status = get_block(state, block, eos);
432
4.26M
    RETURN_IF_ERROR(block->check_type_and_column());
433
4.26M
    return status;
434
4.26M
}
435
436
3.10M
void PipelineXLocalStateBase::reached_limit(Block* block, bool* eos) {
437
3.10M
    if (_parent->_limit != -1 and _num_rows_returned + block->rows() >= _parent->_limit) {
438
7.93k
        block->set_num_rows(_parent->_limit - _num_rows_returned);
439
7.93k
        *eos = true;
440
7.93k
    }
441
442
3.10M
    DBUG_EXECUTE_IF("Pipeline::reached_limit_early", {
443
3.10M
        auto op_name = to_lower(_parent->_op_name);
444
3.10M
        auto arg_op_name = dp->param<std::string>("op_name");
445
3.10M
        arg_op_name = to_lower(arg_op_name);
446
447
3.10M
        if (op_name == arg_op_name) {
448
3.10M
            *eos = true;
449
3.10M
        }
450
3.10M
    });
451
452
3.10M
    if (auto rows = block->rows()) {
453
872k
        _num_rows_returned += rows;
454
872k
        _state->get_query_ctx()->resource_ctx()->io_context()->update_process_rows(rows);
455
872k
    }
456
3.10M
}
457
458
29.9k
Status DataSinkOperatorXBase::terminate(RuntimeState* state) {
459
29.9k
    auto result = state->get_sink_local_state_result();
460
29.9k
    if (!result) {
461
0
        return result.error();
462
0
    }
463
29.9k
    return result.value()->terminate(state);
464
29.9k
}
465
466
17.4k
std::string DataSinkOperatorXBase::debug_string(int indentation_level) const {
467
17.4k
    fmt::memory_buffer debug_string_buffer;
468
469
17.4k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, _is_serial_operator={}",
470
17.4k
                   std::string(indentation_level * 2, ' '), _name, node_id(), _is_serial_operator);
471
17.4k
    return fmt::to_string(debug_string_buffer);
472
17.4k
}
473
474
17.1k
std::string DataSinkOperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
475
17.1k
    return state->get_sink_local_state()->debug_string(indentation_level);
476
17.1k
}
477
478
460k
Status DataSinkOperatorXBase::init(const TDataSink& tsink) {
479
460k
    std::string op_name = "UNKNOWN_SINK";
480
460k
    auto it = _TDataSinkType_VALUES_TO_NAMES.find(tsink.type);
481
482
460k
    if (it != _TDataSinkType_VALUES_TO_NAMES.end()) {
483
460k
        op_name = it->second;
484
460k
    }
485
460k
    _name = op_name + "_OPERATOR";
486
460k
    return Status::OK();
487
460k
}
488
489
315k
Status DataSinkOperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
490
315k
    std::string op_name = print_plan_node_type(tnode.node_type);
491
315k
    _nereids_id = tnode.nereids_id;
492
315k
    auto substr = op_name.substr(0, op_name.find("_NODE"));
493
315k
    _name = substr + "_SINK_OPERATOR";
494
315k
    return Status::OK();
495
315k
}
496
497
template <typename LocalStateType>
498
Status DataSinkOperatorX<LocalStateType>::setup_local_state(RuntimeState* state,
499
2.08M
                                                            LocalSinkStateInfo& info) {
500
2.08M
    auto local_state = LocalStateType::create_unique(this, state);
501
2.08M
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.08M
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.08M
    return Status::OK();
504
2.08M
}
_ZN5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
116k
                                                            LocalSinkStateInfo& info) {
500
116k
    auto local_state = LocalStateType::create_unique(this, state);
501
116k
    RETURN_IF_ERROR(local_state->init(state, info));
502
116k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
116k
    return Status::OK();
504
116k
}
_ZN5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
457k
                                                            LocalSinkStateInfo& info) {
500
457k
    auto local_state = LocalStateType::create_unique(this, state);
501
457k
    RETURN_IF_ERROR(local_state->init(state, info));
502
457k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
457k
    return Status::OK();
504
457k
}
_ZN5doris17DataSinkOperatorXINS_23JdbcTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
88
                                                            LocalSinkStateInfo& info) {
500
88
    auto local_state = LocalStateType::create_unique(this, state);
501
88
    RETURN_IF_ERROR(local_state->init(state, info));
502
88
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
88
    return Status::OK();
504
88
}
_ZN5doris17DataSinkOperatorXINS_27MemoryScratchSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3
                                                            LocalSinkStateInfo& info) {
500
3
    auto local_state = LocalStateType::create_unique(this, state);
501
3
    RETURN_IF_ERROR(local_state->init(state, info));
502
3
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3
    return Status::OK();
504
3
}
_ZN5doris17DataSinkOperatorXINS_24ResultFileSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
513
                                                            LocalSinkStateInfo& info) {
500
513
    auto local_state = LocalStateType::create_unique(this, state);
501
513
    RETURN_IF_ERROR(local_state->init(state, info));
502
513
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
513
    return Status::OK();
504
513
}
_ZN5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
45.8k
                                                            LocalSinkStateInfo& info) {
500
45.8k
    auto local_state = LocalStateType::create_unique(this, state);
501
45.8k
    RETURN_IF_ERROR(local_state->init(state, info));
502
45.8k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
45.8k
    return Status::OK();
504
45.8k
}
_ZN5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.33k
                                                            LocalSinkStateInfo& info) {
500
9.33k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.33k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.33k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.33k
    return Status::OK();
504
9.33k
}
_ZN5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
5.16k
                                                            LocalSinkStateInfo& info) {
500
5.16k
    auto local_state = LocalStateType::create_unique(this, state);
501
5.16k
    RETURN_IF_ERROR(local_state->init(state, info));
502
5.16k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
5.16k
    return Status::OK();
504
5.16k
}
_ZN5doris17DataSinkOperatorXINS_22TVFTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
156
                                                            LocalSinkStateInfo& info) {
500
156
    auto local_state = LocalStateType::create_unique(this, state);
501
156
    RETURN_IF_ERROR(local_state->init(state, info));
502
156
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
156
    return Status::OK();
504
156
}
_ZN5doris17DataSinkOperatorXINS_26IcebergTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3.39k
                                                            LocalSinkStateInfo& info) {
500
3.39k
    auto local_state = LocalStateType::create_unique(this, state);
501
3.39k
    RETURN_IF_ERROR(local_state->init(state, info));
502
3.39k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3.39k
    return Status::OK();
504
3.39k
}
_ZN5doris17DataSinkOperatorXINS_31SpillIcebergTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
32
                                                            LocalSinkStateInfo& info) {
500
32
    auto local_state = LocalStateType::create_unique(this, state);
501
32
    RETURN_IF_ERROR(local_state->init(state, info));
502
32
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
32
    return Status::OK();
504
32
}
_ZN5doris17DataSinkOperatorXINS_27IcebergDeleteSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
160
                                                            LocalSinkStateInfo& info) {
500
160
    auto local_state = LocalStateType::create_unique(this, state);
501
160
    RETURN_IF_ERROR(local_state->init(state, info));
502
160
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
160
    return Status::OK();
504
160
}
_ZN5doris17DataSinkOperatorXINS_26IcebergMergeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
640
                                                            LocalSinkStateInfo& info) {
500
640
    auto local_state = LocalStateType::create_unique(this, state);
501
640
    RETURN_IF_ERROR(local_state->init(state, info));
502
640
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
640
    return Status::OK();
504
640
}
Unexecuted instantiation: _ZN5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.02k
                                                            LocalSinkStateInfo& info) {
500
9.02k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.02k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.02k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.02k
    return Status::OK();
504
9.02k
}
_ZN5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
89
                                                            LocalSinkStateInfo& info) {
500
89
    auto local_state = LocalStateType::create_unique(this, state);
501
89
    RETURN_IF_ERROR(local_state->init(state, info));
502
89
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
89
    return Status::OK();
504
89
}
_ZN5doris17DataSinkOperatorXINS_18SortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
258k
                                                            LocalSinkStateInfo& info) {
500
258k
    auto local_state = LocalStateType::create_unique(this, state);
501
258k
    RETURN_IF_ERROR(local_state->init(state, info));
502
258k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
258k
    return Status::OK();
504
258k
}
_ZN5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
32
                                                            LocalSinkStateInfo& info) {
500
32
    auto local_state = LocalStateType::create_unique(this, state);
501
32
    RETURN_IF_ERROR(local_state->init(state, info));
502
32
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
32
    return Status::OK();
504
32
}
_ZN5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
290k
                                                            LocalSinkStateInfo& info) {
500
290k
    auto local_state = LocalStateType::create_unique(this, state);
501
290k
    RETURN_IF_ERROR(local_state->init(state, info));
502
290k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
290k
    return Status::OK();
504
290k
}
_ZN5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
148k
                                                            LocalSinkStateInfo& info) {
500
148k
    auto local_state = LocalStateType::create_unique(this, state);
501
148k
    RETURN_IF_ERROR(local_state->init(state, info));
502
148k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
148k
    return Status::OK();
504
148k
}
_ZN5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
293
                                                            LocalSinkStateInfo& info) {
500
293
    auto local_state = LocalStateType::create_unique(this, state);
501
293
    RETURN_IF_ERROR(local_state->init(state, info));
502
293
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
293
    return Status::OK();
504
293
}
_ZN5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
132
                                                            LocalSinkStateInfo& info) {
500
132
    auto local_state = LocalStateType::create_unique(this, state);
501
132
    RETURN_IF_ERROR(local_state->init(state, info));
502
132
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
132
    return Status::OK();
504
132
}
_ZN5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
704k
                                                            LocalSinkStateInfo& info) {
500
704k
    auto local_state = LocalStateType::create_unique(this, state);
501
704k
    RETURN_IF_ERROR(local_state->init(state, info));
502
704k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
704k
    return Status::OK();
504
704k
}
_ZN5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.09k
                                                            LocalSinkStateInfo& info) {
500
9.09k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.09k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.09k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.09k
    return Status::OK();
504
9.09k
}
_ZN5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
5.42k
                                                            LocalSinkStateInfo& info) {
500
5.42k
    auto local_state = LocalStateType::create_unique(this, state);
501
5.42k
    RETURN_IF_ERROR(local_state->init(state, info));
502
5.42k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
5.42k
    return Status::OK();
504
5.42k
}
_ZN5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3.25k
                                                            LocalSinkStateInfo& info) {
500
3.25k
    auto local_state = LocalStateType::create_unique(this, state);
501
3.25k
    RETURN_IF_ERROR(local_state->init(state, info));
502
3.25k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3.25k
    return Status::OK();
504
3.25k
}
_ZN5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
357
                                                            LocalSinkStateInfo& info) {
500
357
    auto local_state = LocalStateType::create_unique(this, state);
501
357
    RETURN_IF_ERROR(local_state->init(state, info));
502
357
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
357
    return Status::OK();
504
357
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
4.80k
                                                            LocalSinkStateInfo& info) {
500
4.80k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.80k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.80k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.80k
    return Status::OK();
504
4.80k
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.61k
                                                            LocalSinkStateInfo& info) {
500
2.61k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.61k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.61k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.61k
    return Status::OK();
504
2.61k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.58k
                                                            LocalSinkStateInfo& info) {
500
2.58k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.58k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.58k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.58k
    return Status::OK();
504
2.58k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.51k
                                                            LocalSinkStateInfo& info) {
500
2.51k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.51k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.51k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.51k
    return Status::OK();
504
2.51k
}
_ZN5doris17DataSinkOperatorXINS_33PartitionedHashJoinSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
1
                                                            LocalSinkStateInfo& info) {
500
1
    auto local_state = LocalStateType::create_unique(this, state);
501
1
    RETURN_IF_ERROR(local_state->init(state, info));
502
1
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
1
    return Status::OK();
504
1
}
_ZN5doris17DataSinkOperatorXINS_30GroupCommitBlockSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
168
                                                            LocalSinkStateInfo& info) {
500
168
    auto local_state = LocalStateType::create_unique(this, state);
501
168
    RETURN_IF_ERROR(local_state->init(state, info));
502
168
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
168
    return Status::OK();
504
168
}
_ZN5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
14
                                                            LocalSinkStateInfo& info) {
500
14
    auto local_state = LocalStateType::create_unique(this, state);
501
14
    RETURN_IF_ERROR(local_state->init(state, info));
502
14
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
14
    return Status::OK();
504
14
}
_ZN5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
104
                                                            LocalSinkStateInfo& info) {
500
104
    auto local_state = LocalStateType::create_unique(this, state);
501
104
    RETURN_IF_ERROR(local_state->init(state, info));
502
104
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
104
    return Status::OK();
504
104
}
_ZN5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
163
                                                            LocalSinkStateInfo& info) {
500
163
    auto local_state = LocalStateType::create_unique(this, state);
501
163
    RETURN_IF_ERROR(local_state->init(state, info));
502
163
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
163
    return Status::OK();
504
163
}
_ZN5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
163
                                                            LocalSinkStateInfo& info) {
500
163
    auto local_state = LocalStateType::create_unique(this, state);
501
163
    RETURN_IF_ERROR(local_state->init(state, info));
502
163
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
163
    return Status::OK();
504
163
}
505
506
template <typename LocalStateType>
507
1.75M
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
0
                                 LocalExchangeSharedState>) {
510
0
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
0
                                        MultiCastSharedState>) {
513
0
        throw Exception(Status::FatalError("should not reach here!"));
514
1.75M
    } else {
515
1.75M
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.75M
        ss->id = operator_id();
517
1.75M
        for (auto& dest : dests_id()) {
518
1.75M
            ss->related_op_ids.insert(dest);
519
1.75M
        }
520
1.75M
        return ss;
521
1.75M
    }
522
1.75M
}
_ZNK5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
96.3k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
96.3k
    } else {
515
96.3k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
96.3k
        ss->id = operator_id();
517
96.3k
        for (auto& dest : dests_id()) {
518
96.2k
            ss->related_op_ids.insert(dest);
519
96.2k
        }
520
96.3k
        return ss;
521
96.3k
    }
522
96.3k
}
_ZNK5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
458k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
458k
    } else {
515
458k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
458k
        ss->id = operator_id();
517
458k
        for (auto& dest : dests_id()) {
518
457k
            ss->related_op_ids.insert(dest);
519
457k
        }
520
458k
        return ss;
521
458k
    }
522
458k
}
_ZNK5doris17DataSinkOperatorXINS_23JdbcTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
88
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
88
    } else {
515
88
        auto ss = LocalStateType::SharedStateType::create_shared();
516
88
        ss->id = operator_id();
517
88
        for (auto& dest : dests_id()) {
518
88
            ss->related_op_ids.insert(dest);
519
88
        }
520
88
        return ss;
521
88
    }
522
88
}
_ZNK5doris17DataSinkOperatorXINS_27MemoryScratchSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
3
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
3
    } else {
515
3
        auto ss = LocalStateType::SharedStateType::create_shared();
516
3
        ss->id = operator_id();
517
3
        for (auto& dest : dests_id()) {
518
3
            ss->related_op_ids.insert(dest);
519
3
        }
520
3
        return ss;
521
3
    }
522
3
}
_ZNK5doris17DataSinkOperatorXINS_24ResultFileSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
513
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
513
    } else {
515
513
        auto ss = LocalStateType::SharedStateType::create_shared();
516
513
        ss->id = operator_id();
517
513
        for (auto& dest : dests_id()) {
518
513
            ss->related_op_ids.insert(dest);
519
513
        }
520
513
        return ss;
521
513
    }
522
513
}
_ZNK5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
45.9k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
45.9k
    } else {
515
45.9k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
45.9k
        ss->id = operator_id();
517
45.9k
        for (auto& dest : dests_id()) {
518
45.7k
            ss->related_op_ids.insert(dest);
519
45.7k
        }
520
45.9k
        return ss;
521
45.9k
    }
522
45.9k
}
_ZNK5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.33k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
9.33k
    } else {
515
9.33k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.33k
        ss->id = operator_id();
517
9.33k
        for (auto& dest : dests_id()) {
518
9.33k
            ss->related_op_ids.insert(dest);
519
9.33k
        }
520
9.33k
        return ss;
521
9.33k
    }
522
9.33k
}
_ZNK5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
5.16k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
5.16k
    } else {
515
5.16k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
5.16k
        ss->id = operator_id();
517
5.16k
        for (auto& dest : dests_id()) {
518
5.16k
            ss->related_op_ids.insert(dest);
519
5.16k
        }
520
5.16k
        return ss;
521
5.16k
    }
522
5.16k
}
_ZNK5doris17DataSinkOperatorXINS_22TVFTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
156
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
156
    } else {
515
156
        auto ss = LocalStateType::SharedStateType::create_shared();
516
156
        ss->id = operator_id();
517
156
        for (auto& dest : dests_id()) {
518
156
            ss->related_op_ids.insert(dest);
519
156
        }
520
156
        return ss;
521
156
    }
522
156
}
_ZNK5doris17DataSinkOperatorXINS_26IcebergTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
3.39k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
3.39k
    } else {
515
3.39k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
3.39k
        ss->id = operator_id();
517
3.39k
        for (auto& dest : dests_id()) {
518
3.39k
            ss->related_op_ids.insert(dest);
519
3.39k
        }
520
3.39k
        return ss;
521
3.39k
    }
522
3.39k
}
_ZNK5doris17DataSinkOperatorXINS_31SpillIcebergTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
32
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
32
    } else {
515
32
        auto ss = LocalStateType::SharedStateType::create_shared();
516
32
        ss->id = operator_id();
517
32
        for (auto& dest : dests_id()) {
518
32
            ss->related_op_ids.insert(dest);
519
32
        }
520
32
        return ss;
521
32
    }
522
32
}
_ZNK5doris17DataSinkOperatorXINS_27IcebergDeleteSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
160
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
160
    } else {
515
160
        auto ss = LocalStateType::SharedStateType::create_shared();
516
160
        ss->id = operator_id();
517
160
        for (auto& dest : dests_id()) {
518
160
            ss->related_op_ids.insert(dest);
519
160
        }
520
160
        return ss;
521
160
    }
522
160
}
_ZNK5doris17DataSinkOperatorXINS_26IcebergMergeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
640
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
640
    } else {
515
640
        auto ss = LocalStateType::SharedStateType::create_shared();
516
640
        ss->id = operator_id();
517
640
        for (auto& dest : dests_id()) {
518
640
            ss->related_op_ids.insert(dest);
519
640
        }
520
640
        return ss;
521
640
    }
522
640
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.04k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
9.04k
    } else {
515
9.04k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.04k
        ss->id = operator_id();
517
9.04k
        for (auto& dest : dests_id()) {
518
9.04k
            ss->related_op_ids.insert(dest);
519
9.04k
        }
520
9.04k
        return ss;
521
9.04k
    }
522
9.04k
}
_ZNK5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
89
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
89
    } else {
515
89
        auto ss = LocalStateType::SharedStateType::create_shared();
516
89
        ss->id = operator_id();
517
89
        for (auto& dest : dests_id()) {
518
89
            ss->related_op_ids.insert(dest);
519
89
        }
520
89
        return ss;
521
89
    }
522
89
}
_ZNK5doris17DataSinkOperatorXINS_18SortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
259k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
259k
    } else {
515
259k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
259k
        ss->id = operator_id();
517
259k
        for (auto& dest : dests_id()) {
518
258k
            ss->related_op_ids.insert(dest);
519
258k
        }
520
259k
        return ss;
521
259k
    }
522
259k
}
_ZNK5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
34
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
34
    } else {
515
34
        auto ss = LocalStateType::SharedStateType::create_shared();
516
34
        ss->id = operator_id();
517
34
        for (auto& dest : dests_id()) {
518
34
            ss->related_op_ids.insert(dest);
519
34
        }
520
34
        return ss;
521
34
    }
522
34
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
148k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
148k
    } else {
515
148k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
148k
        ss->id = operator_id();
517
148k
        for (auto& dest : dests_id()) {
518
148k
            ss->related_op_ids.insert(dest);
519
148k
        }
520
148k
        return ss;
521
148k
    }
522
148k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
131
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
131
    } else {
515
131
        auto ss = LocalStateType::SharedStateType::create_shared();
516
131
        ss->id = operator_id();
517
131
        for (auto& dest : dests_id()) {
518
131
            ss->related_op_ids.insert(dest);
519
131
        }
520
131
        return ss;
521
131
    }
522
131
}
_ZNK5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
704k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
704k
    } else {
515
704k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
704k
        ss->id = operator_id();
517
704k
        for (auto& dest : dests_id()) {
518
701k
            ss->related_op_ids.insert(dest);
519
701k
        }
520
704k
        return ss;
521
704k
    }
522
704k
}
_ZNK5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.09k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
9.09k
    } else {
515
9.09k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.09k
        ss->id = operator_id();
517
9.09k
        for (auto& dest : dests_id()) {
518
9.09k
            ss->related_op_ids.insert(dest);
519
9.09k
        }
520
9.09k
        return ss;
521
9.09k
    }
522
9.09k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
461
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
461
    } else {
515
461
        auto ss = LocalStateType::SharedStateType::create_shared();
516
461
        ss->id = operator_id();
517
461
        for (auto& dest : dests_id()) {
518
461
            ss->related_op_ids.insert(dest);
519
461
        }
520
461
        return ss;
521
461
    }
522
461
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE19create_shared_stateEv
Line
Count
Source
507
2.60k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
2.60k
    } else {
515
2.60k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.60k
        ss->id = operator_id();
517
2.60k
        for (auto& dest : dests_id()) {
518
2.59k
            ss->related_op_ids.insert(dest);
519
2.59k
        }
520
2.60k
        return ss;
521
2.60k
    }
522
2.60k
}
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE19create_shared_stateEv
Line
Count
Source
507
2.54k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
2.54k
    } else {
515
2.54k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.54k
        ss->id = operator_id();
517
2.54k
        for (auto& dest : dests_id()) {
518
2.53k
            ss->related_op_ids.insert(dest);
519
2.53k
        }
520
2.54k
        return ss;
521
2.54k
    }
522
2.54k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33PartitionedHashJoinSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_30GroupCommitBlockSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
168
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
168
    } else {
515
168
        auto ss = LocalStateType::SharedStateType::create_shared();
516
168
        ss->id = operator_id();
517
168
        for (auto& dest : dests_id()) {
518
168
            ss->related_op_ids.insert(dest);
519
168
        }
520
168
        return ss;
521
168
    }
522
168
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
104
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
104
    } else {
515
104
        auto ss = LocalStateType::SharedStateType::create_shared();
516
104
        ss->id = operator_id();
517
104
        for (auto& dest : dests_id()) {
518
104
            ss->related_op_ids.insert(dest);
519
104
        }
520
104
        return ss;
521
104
    }
522
104
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE19create_shared_stateEv
523
524
template <typename LocalStateType>
525
2.60M
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.60M
    auto local_state = LocalStateType::create_unique(state, this);
527
2.60M
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.60M
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.60M
    return Status::OK();
530
2.60M
}
_ZN5doris9OperatorXINS_23HashJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
68.0k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
68.0k
    auto local_state = LocalStateType::create_unique(state, this);
527
68.0k
    RETURN_IF_ERROR(local_state->init(state, info));
528
68.0k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
68.0k
    return Status::OK();
530
68.0k
}
_ZN5doris9OperatorXINS_18OlapScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
304k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
304k
    auto local_state = LocalStateType::create_unique(state, this);
527
304k
    RETURN_IF_ERROR(local_state->init(state, info));
528
304k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
304k
    return Status::OK();
530
304k
}
_ZN5doris9OperatorXINS_21GroupCommitLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
78
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
78
    auto local_state = LocalStateType::create_unique(state, this);
527
78
    RETURN_IF_ERROR(local_state->init(state, info));
528
78
    state->emplace_local_state(operator_id(), std::move(local_state));
529
78
    return Status::OK();
530
78
}
Unexecuted instantiation: _ZN5doris9OperatorXINS_18JDBCScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris9OperatorXINS_18FileScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
34.1k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
34.1k
    auto local_state = LocalStateType::create_unique(state, this);
527
34.1k
    RETURN_IF_ERROR(local_state->init(state, info));
528
34.1k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
34.1k
    return Status::OK();
530
34.1k
}
_ZN5doris9OperatorXINS_18AnalyticLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
8.94k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
8.94k
    auto local_state = LocalStateType::create_unique(state, this);
527
8.94k
    RETURN_IF_ERROR(local_state->init(state, info));
528
8.94k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
8.94k
    return Status::OK();
530
8.94k
}
_ZN5doris9OperatorXINS_14SortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
9.12k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
9.12k
    auto local_state = LocalStateType::create_unique(state, this);
527
9.12k
    RETURN_IF_ERROR(local_state->init(state, info));
528
9.12k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
9.12k
    return Status::OK();
530
9.12k
}
_ZN5doris9OperatorXINS_19SpillSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
25
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
25
    auto local_state = LocalStateType::create_unique(state, this);
527
25
    RETURN_IF_ERROR(local_state->init(state, info));
528
25
    state->emplace_local_state(operator_id(), std::move(local_state));
529
25
    return Status::OK();
530
25
}
_ZN5doris9OperatorXINS_24LocalMergeSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
248k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
248k
    auto local_state = LocalStateType::create_unique(state, this);
527
248k
    RETURN_IF_ERROR(local_state->init(state, info));
528
248k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
248k
    return Status::OK();
530
248k
}
_ZN5doris9OperatorXINS_13AggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
148k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
148k
    auto local_state = LocalStateType::create_unique(state, this);
527
148k
    RETURN_IF_ERROR(local_state->init(state, info));
528
148k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
148k
    return Status::OK();
530
148k
}
_ZN5doris9OperatorXINS_21BucketedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
290
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
290
    auto local_state = LocalStateType::create_unique(state, this);
527
290
    RETURN_IF_ERROR(local_state->init(state, info));
528
290
    state->emplace_local_state(operator_id(), std::move(local_state));
529
290
    return Status::OK();
530
290
}
_ZN5doris9OperatorXINS_24PartitionedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
122
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
122
    auto local_state = LocalStateType::create_unique(state, this);
527
122
    RETURN_IF_ERROR(local_state->init(state, info));
528
122
    state->emplace_local_state(operator_id(), std::move(local_state));
529
122
    return Status::OK();
530
122
}
_ZN5doris9OperatorXINS_23TableFunctionLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
5.12k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
5.12k
    auto local_state = LocalStateType::create_unique(state, this);
527
5.12k
    RETURN_IF_ERROR(local_state->init(state, info));
528
5.12k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
5.12k
    return Status::OK();
530
5.12k
}
_ZN5doris9OperatorXINS_18ExchangeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
411k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
411k
    auto local_state = LocalStateType::create_unique(state, this);
527
411k
    RETURN_IF_ERROR(local_state->init(state, info));
528
411k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
411k
    return Status::OK();
530
411k
}
_ZN5doris9OperatorXINS_16RepeatLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.28k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.28k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.28k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.28k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.28k
    return Status::OK();
530
1.28k
}
_ZN5doris9OperatorXINS_29NestedLoopJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
9.09k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
9.09k
    auto local_state = LocalStateType::create_unique(state, this);
527
9.09k
    RETURN_IF_ERROR(local_state->init(state, info));
528
9.09k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
9.09k
    return Status::OK();
530
9.09k
}
_ZN5doris9OperatorXINS_23AssertNumRowsLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
221
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
221
    auto local_state = LocalStateType::create_unique(state, this);
527
221
    RETURN_IF_ERROR(local_state->init(state, info));
528
221
    state->emplace_local_state(operator_id(), std::move(local_state));
529
221
    return Status::OK();
530
221
}
_ZN5doris9OperatorXINS_18EmptySetLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.70k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.70k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.70k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.70k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.70k
    return Status::OK();
530
1.70k
}
_ZN5doris9OperatorXINS_21UnionSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
55.3k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
55.3k
    auto local_state = LocalStateType::create_unique(state, this);
527
55.3k
    RETURN_IF_ERROR(local_state->init(state, info));
528
55.3k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
55.3k
    return Status::OK();
530
55.3k
}
_ZN5doris9OperatorXINS_35MultiCastDataStreamSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
9.25k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
9.25k
    auto local_state = LocalStateType::create_unique(state, this);
527
9.25k
    RETURN_IF_ERROR(local_state->init(state, info));
528
9.25k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
9.25k
    return Status::OK();
530
9.25k
}
_ZN5doris9OperatorXINS_29PartitionSortSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
352
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
352
    auto local_state = LocalStateType::create_unique(state, this);
527
352
    RETURN_IF_ERROR(local_state->init(state, info));
528
352
    state->emplace_local_state(operator_id(), std::move(local_state));
529
352
    return Status::OK();
530
352
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.53k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.53k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.53k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.53k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.53k
    return Status::OK();
530
2.53k
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.48k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.48k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.48k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.48k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.48k
    return Status::OK();
530
2.48k
}
_ZN5doris9OperatorXINS_17DataGenLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
489
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
489
    auto local_state = LocalStateType::create_unique(state, this);
527
489
    RETURN_IF_ERROR(local_state->init(state, info));
528
489
    state->emplace_local_state(operator_id(), std::move(local_state));
529
489
    return Status::OK();
530
489
}
_ZN5doris9OperatorXINS_20SchemaScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.08k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.08k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.08k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.08k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.08k
    return Status::OK();
530
2.08k
}
_ZN5doris9OperatorXINS_18MetaScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.62k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.62k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.62k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.62k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.62k
    return Status::OK();
530
7.62k
}
_ZN5doris9OperatorXINS_29LocalExchangeSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
760k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
760k
    auto local_state = LocalStateType::create_unique(state, this);
527
760k
    RETURN_IF_ERROR(local_state->init(state, info));
528
760k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
760k
    return Status::OK();
530
760k
}
Unexecuted instantiation: _ZN5doris9OperatorXINS_34PartitionedHashJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris9OperatorXINS_21CacheSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
14
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
14
    auto local_state = LocalStateType::create_unique(state, this);
527
14
    RETURN_IF_ERROR(local_state->init(state, info));
528
14
    state->emplace_local_state(operator_id(), std::move(local_state));
529
14
    return Status::OK();
530
14
}
_ZN5doris9OperatorXINS_22RecCTESourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
163
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
163
    auto local_state = LocalStateType::create_unique(state, this);
527
163
    RETURN_IF_ERROR(local_state->init(state, info));
528
163
    state->emplace_local_state(operator_id(), std::move(local_state));
529
163
    return Status::OK();
530
163
}
_ZN5doris9OperatorXINS_20RecCTEScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.18k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.18k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.18k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.18k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.18k
    return Status::OK();
530
2.18k
}
_ZN5doris9OperatorXINS_25MaterializationLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.65k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.65k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.65k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.65k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.65k
    return Status::OK();
530
1.65k
}
_ZN5doris9OperatorXINS_16SelectLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.64k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.64k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.64k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.64k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.64k
    return Status::OK();
530
2.64k
}
_ZN5doris9OperatorXINS_22StreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
10.4k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
10.4k
    auto local_state = LocalStateType::create_unique(state, this);
527
10.4k
    RETURN_IF_ERROR(local_state->init(state, info));
528
10.4k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
10.4k
    return Status::OK();
530
10.4k
}
_ZN5doris9OperatorXINS_30DistinctStreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
491k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
491k
    auto local_state = LocalStateType::create_unique(state, this);
527
491k
    RETURN_IF_ERROR(local_state->init(state, info));
528
491k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
491k
    return Status::OK();
530
491k
}
531
532
PipelineXSinkLocalStateBase::PipelineXSinkLocalStateBase(DataSinkOperatorXBase* parent,
533
                                                         RuntimeState* state)
534
2.08M
        : _parent(parent), _state(state) {}
535
536
PipelineXLocalStateBase::PipelineXLocalStateBase(RuntimeState* state, OperatorXBase* parent)
537
2.59M
        : _num_rows_returned(0),
538
2.59M
          _rows_returned_counter(nullptr),
539
2.59M
          _parent(parent),
540
2.59M
          _state(state),
541
2.59M
          _budget(state->batch_size(), state->preferred_block_size_bytes()) {}
542
543
template <typename SharedStateArg>
544
2.60M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
2.60M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
2.60M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
2.60M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
2.60M
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
2.60M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
2.60M
    _operator_profile->add_child(_common_profile.get(), true);
553
2.60M
    _operator_profile->add_child(_custom_profile.get(), true);
554
2.60M
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
2.60M
    if constexpr (!is_fake_shared) {
556
1.32M
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
777k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
777k
                                    .first.get()
559
777k
                                    ->template cast<SharedStateArg>();
560
561
777k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
777k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
777k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
777k
        } else if (info.shared_state) {
565
484k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
0
                DCHECK(false);
567
0
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
484k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
484k
            _dependency = _shared_state->create_source_dependency(
572
484k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
484k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
484k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
484k
        } else {
576
65.7k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
5.75k
                DCHECK(false);
578
5.75k
            }
579
65.7k
        }
580
1.32M
    }
581
582
2.60M
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
2.60M
    _rows_returned_counter =
587
2.60M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
2.60M
    _blocks_returned_counter =
589
2.60M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
2.60M
    _output_block_bytes_counter =
591
2.60M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
2.60M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
2.60M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
2.60M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
2.60M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
2.60M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
2.60M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
2.60M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
2.60M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
2.60M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
2.60M
    _memory_used_counter =
602
2.60M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
2.60M
    _common_profile->add_info_string("IsColocate",
604
2.60M
                                     std::to_string(_parent->is_colocated_operator()));
605
2.60M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
2.60M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
2.60M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
2.60M
    return Status::OK();
609
2.60M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
68.1k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
68.1k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
68.1k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
68.1k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
68.1k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
68.1k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
68.1k
    _operator_profile->add_child(_common_profile.get(), true);
553
68.1k
    _operator_profile->add_child(_custom_profile.get(), true);
554
68.1k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
68.1k
    if constexpr (!is_fake_shared) {
556
68.1k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
19.7k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
19.7k
                                    .first.get()
559
19.7k
                                    ->template cast<SharedStateArg>();
560
561
19.7k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
19.7k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
19.7k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
48.4k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
48.1k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
48.1k
            _dependency = _shared_state->create_source_dependency(
572
48.1k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
48.1k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
48.1k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
48.1k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
312
        }
580
68.1k
    }
581
582
68.1k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
68.1k
    _rows_returned_counter =
587
68.1k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
68.1k
    _blocks_returned_counter =
589
68.1k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
68.1k
    _output_block_bytes_counter =
591
68.1k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
68.1k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
68.1k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
68.1k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
68.1k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
68.1k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
68.1k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
68.1k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
68.1k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
68.1k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
68.1k
    _memory_used_counter =
602
68.1k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
68.1k
    _common_profile->add_info_string("IsColocate",
604
68.1k
                                     std::to_string(_parent->is_colocated_operator()));
605
68.1k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
68.1k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
68.1k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
68.1k
    return Status::OK();
609
68.1k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
1
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1
    _operator_profile->add_child(_common_profile.get(), true);
553
1
    _operator_profile->add_child(_custom_profile.get(), true);
554
1
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
1
    if constexpr (!is_fake_shared) {
556
1
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
1
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
1
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
1
            _dependency = _shared_state->create_source_dependency(
572
1
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
1
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
1
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
1
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
1
    }
581
582
1
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
1
    _rows_returned_counter =
587
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1
    _blocks_returned_counter =
589
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1
    _output_block_bytes_counter =
591
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1
    _memory_used_counter =
602
1
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1
    _common_profile->add_info_string("IsColocate",
604
1
                                     std::to_string(_parent->is_colocated_operator()));
605
1
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1
    return Status::OK();
609
1
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
258k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
258k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
258k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
258k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
258k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
258k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
258k
    _operator_profile->add_child(_common_profile.get(), true);
553
258k
    _operator_profile->add_child(_custom_profile.get(), true);
554
258k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
258k
    if constexpr (!is_fake_shared) {
556
258k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
258k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
253k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
253k
            _dependency = _shared_state->create_source_dependency(
572
253k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
253k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
253k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
253k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
4.94k
        }
580
258k
    }
581
582
258k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
258k
    _rows_returned_counter =
587
258k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
258k
    _blocks_returned_counter =
589
258k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
258k
    _output_block_bytes_counter =
591
258k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
258k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
258k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
258k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
258k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
258k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
258k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
258k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
258k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
258k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
258k
    _memory_used_counter =
602
258k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
258k
    _common_profile->add_info_string("IsColocate",
604
258k
                                     std::to_string(_parent->is_colocated_operator()));
605
258k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
258k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
258k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
258k
    return Status::OK();
609
258k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
25
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
25
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
25
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
25
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
25
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
25
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
25
    _operator_profile->add_child(_common_profile.get(), true);
553
25
    _operator_profile->add_child(_custom_profile.get(), true);
554
25
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
25
    if constexpr (!is_fake_shared) {
556
25
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
25
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
25
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
25
            _dependency = _shared_state->create_source_dependency(
572
25
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
25
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
25
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
25
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
25
    }
581
582
25
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
25
    _rows_returned_counter =
587
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
25
    _blocks_returned_counter =
589
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
25
    _output_block_bytes_counter =
591
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
25
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
25
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
25
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
25
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
25
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
25
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
25
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
25
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
25
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
25
    _memory_used_counter =
602
25
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
25
    _common_profile->add_info_string("IsColocate",
604
25
                                     std::to_string(_parent->is_colocated_operator()));
605
25
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
25
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
25
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
25
    return Status::OK();
609
25
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
9.09k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
9.09k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
9.09k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
9.09k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
9.09k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
9.09k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
9.09k
    _operator_profile->add_child(_common_profile.get(), true);
553
9.09k
    _operator_profile->add_child(_custom_profile.get(), true);
554
9.09k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
9.09k
    if constexpr (!is_fake_shared) {
556
9.09k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
9.09k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
9.08k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
9.08k
            _dependency = _shared_state->create_source_dependency(
572
9.08k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
9.08k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
9.08k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
9.08k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
9
        }
580
9.09k
    }
581
582
9.09k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
9.09k
    _rows_returned_counter =
587
9.09k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
9.09k
    _blocks_returned_counter =
589
9.09k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
9.09k
    _output_block_bytes_counter =
591
9.09k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
9.09k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
9.09k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
9.09k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
9.09k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
9.09k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
9.09k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
9.09k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
9.09k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
9.09k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
9.09k
    _memory_used_counter =
602
9.09k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
9.09k
    _common_profile->add_info_string("IsColocate",
604
9.09k
                                     std::to_string(_parent->is_colocated_operator()));
605
9.09k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
9.09k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
9.09k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
9.09k
    return Status::OK();
609
9.09k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
9.04k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
9.04k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
9.04k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
9.04k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
9.04k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
9.04k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
9.04k
    _operator_profile->add_child(_common_profile.get(), true);
553
9.04k
    _operator_profile->add_child(_custom_profile.get(), true);
554
9.04k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
9.04k
    if constexpr (!is_fake_shared) {
556
9.04k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
9.04k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
8.87k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
8.87k
            _dependency = _shared_state->create_source_dependency(
572
8.87k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
8.87k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
8.87k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
8.87k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
166
        }
580
9.04k
    }
581
582
9.04k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
9.04k
    _rows_returned_counter =
587
9.04k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
9.04k
    _blocks_returned_counter =
589
9.04k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
9.04k
    _output_block_bytes_counter =
591
9.04k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
9.04k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
9.04k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
9.04k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
9.04k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
9.04k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
9.04k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
9.04k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
9.04k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
9.04k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
9.04k
    _memory_used_counter =
602
9.04k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
9.04k
    _common_profile->add_info_string("IsColocate",
604
9.04k
                                     std::to_string(_parent->is_colocated_operator()));
605
9.04k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
9.04k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
9.04k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
9.04k
    return Status::OK();
609
9.04k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
148k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
148k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
148k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
148k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
148k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
148k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
148k
    _operator_profile->add_child(_common_profile.get(), true);
553
148k
    _operator_profile->add_child(_custom_profile.get(), true);
554
148k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
148k
    if constexpr (!is_fake_shared) {
556
148k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
148k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
147k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
147k
            _dependency = _shared_state->create_source_dependency(
572
147k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
147k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
147k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
147k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
1.07k
        }
580
148k
    }
581
582
148k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
148k
    _rows_returned_counter =
587
148k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
148k
    _blocks_returned_counter =
589
148k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
148k
    _output_block_bytes_counter =
591
148k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
148k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
148k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
148k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
148k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
148k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
148k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
148k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
148k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
148k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
148k
    _memory_used_counter =
602
148k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
148k
    _common_profile->add_info_string("IsColocate",
604
148k
                                     std::to_string(_parent->is_colocated_operator()));
605
148k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
148k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
148k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
148k
    return Status::OK();
609
148k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
297
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
297
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
297
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
297
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
297
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
297
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
297
    _operator_profile->add_child(_common_profile.get(), true);
553
297
    _operator_profile->add_child(_custom_profile.get(), true);
554
297
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
297
    if constexpr (!is_fake_shared) {
556
297
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
289
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
289
                                    .first.get()
559
289
                                    ->template cast<SharedStateArg>();
560
561
289
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
289
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
289
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
289
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
0
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
0
            _dependency = _shared_state->create_source_dependency(
572
0
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
8
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
8
        }
580
297
    }
581
582
297
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
297
    _rows_returned_counter =
587
297
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
297
    _blocks_returned_counter =
589
297
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
297
    _output_block_bytes_counter =
591
297
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
297
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
297
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
297
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
297
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
297
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
297
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
297
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
297
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
297
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
297
    _memory_used_counter =
602
297
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
297
    _common_profile->add_info_string("IsColocate",
604
297
                                     std::to_string(_parent->is_colocated_operator()));
605
297
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
297
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
297
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
297
    return Status::OK();
609
297
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
122
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
122
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
122
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
122
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
122
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
122
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
122
    _operator_profile->add_child(_common_profile.get(), true);
553
122
    _operator_profile->add_child(_custom_profile.get(), true);
554
122
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
122
    if constexpr (!is_fake_shared) {
556
122
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
122
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
122
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
122
            _dependency = _shared_state->create_source_dependency(
572
122
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
122
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
122
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
122
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
122
    }
581
582
122
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
122
    _rows_returned_counter =
587
122
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
122
    _blocks_returned_counter =
589
122
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
122
    _output_block_bytes_counter =
591
122
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
122
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
122
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
122
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
122
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
122
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
122
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
122
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
122
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
122
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
122
    _memory_used_counter =
602
122
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
122
    _common_profile->add_info_string("IsColocate",
604
122
                                     std::to_string(_parent->is_colocated_operator()));
605
122
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
122
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
122
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
122
    return Status::OK();
609
122
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1.27M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1.27M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1.27M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1.27M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1.27M
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
1.27M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1.27M
    _operator_profile->add_child(_common_profile.get(), true);
553
1.27M
    _operator_profile->add_child(_custom_profile.get(), true);
554
1.27M
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
    if constexpr (!is_fake_shared) {
556
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
                                    .first.get()
559
                                    ->template cast<SharedStateArg>();
560
561
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
            _dependency = _shared_state->create_source_dependency(
572
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
        }
580
    }
581
582
1.27M
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
1.27M
    _rows_returned_counter =
587
1.27M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1.27M
    _blocks_returned_counter =
589
1.27M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1.27M
    _output_block_bytes_counter =
591
1.27M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1.27M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1.27M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1.27M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1.27M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1.27M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1.27M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1.27M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1.27M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1.27M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1.27M
    _memory_used_counter =
602
1.27M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1.27M
    _common_profile->add_info_string("IsColocate",
604
1.27M
                                     std::to_string(_parent->is_colocated_operator()));
605
1.27M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1.27M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1.27M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1.27M
    return Status::OK();
609
1.27M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
55.3k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
55.3k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
55.3k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
55.3k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
55.3k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
55.3k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
55.3k
    _operator_profile->add_child(_common_profile.get(), true);
553
55.3k
    _operator_profile->add_child(_custom_profile.get(), true);
554
55.3k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
55.3k
    if constexpr (!is_fake_shared) {
556
55.3k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
55.3k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
2.51k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
2.51k
            _dependency = _shared_state->create_source_dependency(
572
2.51k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
2.51k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
2.51k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
52.8k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
52.8k
        }
580
55.3k
    }
581
582
55.3k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
55.3k
    _rows_returned_counter =
587
55.3k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
55.3k
    _blocks_returned_counter =
589
55.3k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
55.3k
    _output_block_bytes_counter =
591
55.3k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
55.3k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
55.3k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
55.3k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
55.3k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
55.3k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
55.3k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
55.3k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
55.3k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
55.3k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
55.3k
    _memory_used_counter =
602
55.3k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
55.3k
    _common_profile->add_info_string("IsColocate",
604
55.3k
                                     std::to_string(_parent->is_colocated_operator()));
605
55.3k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
55.3k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
55.3k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
55.3k
    return Status::OK();
609
55.3k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
17
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
17
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
17
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
17
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
17
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
17
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
17
    _operator_profile->add_child(_common_profile.get(), true);
553
17
    _operator_profile->add_child(_custom_profile.get(), true);
554
17
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
17
    if constexpr (!is_fake_shared) {
556
17
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
17
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
17
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
17
            _dependency = _shared_state->create_source_dependency(
572
17
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
17
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
17
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
17
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
17
    }
581
582
17
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
17
    _rows_returned_counter =
587
17
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
17
    _blocks_returned_counter =
589
17
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
17
    _output_block_bytes_counter =
591
17
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
17
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
17
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
17
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
17
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
17
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
17
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
17
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
17
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
17
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
17
    _memory_used_counter =
602
17
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
17
    _common_profile->add_info_string("IsColocate",
604
17
                                     std::to_string(_parent->is_colocated_operator()));
605
17
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
17
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
17
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
17
    return Status::OK();
609
17
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
9.26k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
9.26k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
9.26k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
9.26k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
9.26k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
9.26k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
9.26k
    _operator_profile->add_child(_common_profile.get(), true);
553
9.26k
    _operator_profile->add_child(_custom_profile.get(), true);
554
9.26k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
9.26k
    if constexpr (!is_fake_shared) {
556
9.26k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
9.26k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
9.25k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
9.25k
            _dependency = _shared_state->create_source_dependency(
572
9.25k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
9.25k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
9.25k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
9.25k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
9
        }
580
9.26k
    }
581
582
9.26k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
9.26k
    _rows_returned_counter =
587
9.26k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
9.26k
    _blocks_returned_counter =
589
9.26k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
9.26k
    _output_block_bytes_counter =
591
9.26k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
9.26k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
9.26k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
9.26k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
9.26k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
9.26k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
9.26k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
9.26k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
9.26k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
9.26k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
9.26k
    _memory_used_counter =
602
9.26k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
9.26k
    _common_profile->add_info_string("IsColocate",
604
9.26k
                                     std::to_string(_parent->is_colocated_operator()));
605
9.26k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
9.26k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
9.26k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
9.26k
    return Status::OK();
609
9.26k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
461
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
461
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
461
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
461
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
461
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
461
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
461
    _operator_profile->add_child(_common_profile.get(), true);
553
461
    _operator_profile->add_child(_custom_profile.get(), true);
554
461
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
461
    if constexpr (!is_fake_shared) {
556
461
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
461
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
457
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
457
            _dependency = _shared_state->create_source_dependency(
572
457
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
457
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
457
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
457
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
4
        }
580
461
    }
581
582
461
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
461
    _rows_returned_counter =
587
461
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
461
    _blocks_returned_counter =
589
461
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
461
    _output_block_bytes_counter =
591
461
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
461
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
461
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
461
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
461
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
461
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
461
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
461
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
461
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
461
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
461
    _memory_used_counter =
602
461
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
461
    _common_profile->add_info_string("IsColocate",
604
461
                                     std::to_string(_parent->is_colocated_operator()));
605
461
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
461
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
461
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
461
    return Status::OK();
609
461
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
5.12k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
5.12k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
5.12k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
5.12k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
5.12k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
5.12k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
5.12k
    _operator_profile->add_child(_common_profile.get(), true);
553
5.12k
    _operator_profile->add_child(_custom_profile.get(), true);
554
5.12k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
5.12k
    if constexpr (!is_fake_shared) {
556
5.12k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
5.12k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
4.52k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
4.52k
            _dependency = _shared_state->create_source_dependency(
572
4.52k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
4.52k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
4.52k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
4.52k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
598
        }
580
5.12k
    }
581
582
5.12k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
5.12k
    _rows_returned_counter =
587
5.12k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
5.12k
    _blocks_returned_counter =
589
5.12k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
5.12k
    _output_block_bytes_counter =
591
5.12k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
5.12k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
5.12k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
5.12k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
5.12k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
5.12k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
5.12k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
5.12k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
5.12k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
5.12k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
5.12k
    _memory_used_counter =
602
5.12k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
5.12k
    _common_profile->add_info_string("IsColocate",
604
5.12k
                                     std::to_string(_parent->is_colocated_operator()));
605
5.12k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
5.12k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
5.12k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
5.12k
    return Status::OK();
609
5.12k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
763k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
763k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
763k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
763k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
763k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
763k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
763k
    _operator_profile->add_child(_common_profile.get(), true);
553
763k
    _operator_profile->add_child(_custom_profile.get(), true);
554
763k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
763k
    if constexpr (!is_fake_shared) {
556
763k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
757k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
757k
                                    .first.get()
559
757k
                                    ->template cast<SharedStateArg>();
560
561
757k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
757k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
757k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
757k
        } else if (info.shared_state) {
565
0
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
0
                DCHECK(false);
567
0
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
0
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
0
            _dependency = _shared_state->create_source_dependency(
572
0
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
5.75k
        } else {
576
5.75k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
5.75k
                DCHECK(false);
578
5.75k
            }
579
5.75k
        }
580
763k
    }
581
582
763k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
763k
    _rows_returned_counter =
587
763k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
763k
    _blocks_returned_counter =
589
763k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
763k
    _output_block_bytes_counter =
591
763k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
763k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
763k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
763k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
763k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
763k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
763k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
763k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
763k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
763k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
763k
    _memory_used_counter =
602
763k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
763k
    _common_profile->add_info_string("IsColocate",
604
763k
                                     std::to_string(_parent->is_colocated_operator()));
605
763k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
763k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
763k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
763k
    return Status::OK();
609
763k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
163
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
163
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
163
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
163
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
163
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
163
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
163
    _operator_profile->add_child(_common_profile.get(), true);
553
163
    _operator_profile->add_child(_custom_profile.get(), true);
554
163
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
163
    if constexpr (!is_fake_shared) {
556
163
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
163
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
163
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
163
            _dependency = _shared_state->create_source_dependency(
572
163
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
163
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
163
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
163
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
163
    }
581
582
163
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
163
    _rows_returned_counter =
587
163
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
163
    _blocks_returned_counter =
589
163
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
163
    _output_block_bytes_counter =
591
163
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
163
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
163
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
163
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
163
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
163
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
163
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
163
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
163
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
163
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
163
    _memory_used_counter =
602
163
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
163
    _common_profile->add_info_string("IsColocate",
604
163
                                     std::to_string(_parent->is_colocated_operator()));
605
163
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
163
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
163
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
163
    return Status::OK();
609
163
}
610
611
template <typename SharedStateArg>
612
2.61M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
2.61M
    _conjuncts.resize(_parent->_conjuncts.size());
614
2.61M
    _projections.resize(_parent->_projections.size());
615
3.11M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
501k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
501k
    }
618
5.30M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.69M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.69M
    }
621
2.61M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
2.62M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
12.1k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
79.6k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
67.4k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
67.4k
                    state, _intermediate_projections[i][j]));
627
67.4k
        }
628
12.1k
    }
629
2.61M
    return Status::OK();
630
2.61M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
68.1k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
68.1k
    _conjuncts.resize(_parent->_conjuncts.size());
614
68.1k
    _projections.resize(_parent->_projections.size());
615
68.8k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
664
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
664
    }
618
336k
    for (size_t i = 0; i < _projections.size(); i++) {
619
268k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
268k
    }
621
68.1k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
69.6k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
1.50k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
15.3k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
13.8k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
13.8k
                    state, _intermediate_projections[i][j]));
627
13.8k
        }
628
1.50k
    }
629
68.1k
    return Status::OK();
630
68.1k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
3
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
3
    _conjuncts.resize(_parent->_conjuncts.size());
614
3
    _projections.resize(_parent->_projections.size());
615
3
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
3
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
3
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
3
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
3
    return Status::OK();
630
3
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
259k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
259k
    _conjuncts.resize(_parent->_conjuncts.size());
614
259k
    _projections.resize(_parent->_projections.size());
615
259k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
259k
    for (size_t i = 0; i < _projections.size(); i++) {
619
359
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
359
    }
621
259k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
259k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
259k
    return Status::OK();
630
259k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
25
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
25
    _conjuncts.resize(_parent->_conjuncts.size());
614
25
    _projections.resize(_parent->_projections.size());
615
25
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
25
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
25
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
25
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
25
    return Status::OK();
630
25
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
9.08k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
9.08k
    _conjuncts.resize(_parent->_conjuncts.size());
614
9.08k
    _projections.resize(_parent->_projections.size());
615
9.14k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
53
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
53
    }
618
60.2k
    for (size_t i = 0; i < _projections.size(); i++) {
619
51.1k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
51.1k
    }
621
9.08k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
9.23k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
143
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
893
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
750
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
750
                    state, _intermediate_projections[i][j]));
627
750
        }
628
143
    }
629
9.08k
    return Status::OK();
630
9.08k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
9.05k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
9.05k
    _conjuncts.resize(_parent->_conjuncts.size());
614
9.05k
    _projections.resize(_parent->_projections.size());
615
9.79k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
739
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
739
    }
618
25.4k
    for (size_t i = 0; i < _projections.size(); i++) {
619
16.3k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
16.3k
    }
621
9.05k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
9.13k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
83
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
622
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
539
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
539
                    state, _intermediate_projections[i][j]));
627
539
        }
628
83
    }
629
9.05k
    return Status::OK();
630
9.05k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
148k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
148k
    _conjuncts.resize(_parent->_conjuncts.size());
614
148k
    _projections.resize(_parent->_projections.size());
615
152k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
4.10k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
4.10k
    }
618
406k
    for (size_t i = 0; i < _projections.size(); i++) {
619
258k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
258k
    }
621
148k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
148k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
254
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
1.74k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
1.49k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
1.49k
                    state, _intermediate_projections[i][j]));
627
1.49k
        }
628
254
    }
629
148k
    return Status::OK();
630
148k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
298
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
298
    _conjuncts.resize(_parent->_conjuncts.size());
614
298
    _projections.resize(_parent->_projections.size());
615
311
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
13
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
13
    }
618
1.35k
    for (size_t i = 0; i < _projections.size(); i++) {
619
1.05k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
1.05k
    }
621
298
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
298
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
298
    return Status::OK();
630
298
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
126
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
126
    _conjuncts.resize(_parent->_conjuncts.size());
614
126
    _projections.resize(_parent->_projections.size());
615
126
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
342
    for (size_t i = 0; i < _projections.size(); i++) {
619
216
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
216
    }
621
126
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
126
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
126
    return Status::OK();
630
126
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
1.28M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
1.28M
    _conjuncts.resize(_parent->_conjuncts.size());
614
1.28M
    _projections.resize(_parent->_projections.size());
615
1.77M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
492k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
492k
    }
618
3.28M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.00M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.00M
    }
621
1.28M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
1.29M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
10.1k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
60.9k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
50.8k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
50.8k
                    state, _intermediate_projections[i][j]));
627
50.8k
        }
628
10.1k
    }
629
1.28M
    return Status::OK();
630
1.28M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
55.4k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
55.4k
    _conjuncts.resize(_parent->_conjuncts.size());
614
55.4k
    _projections.resize(_parent->_projections.size());
615
55.4k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
150k
    for (size_t i = 0; i < _projections.size(); i++) {
619
95.3k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
95.3k
    }
621
55.4k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
55.4k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
55.4k
    return Status::OK();
630
55.4k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
17
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
17
    _conjuncts.resize(_parent->_conjuncts.size());
614
17
    _projections.resize(_parent->_projections.size());
615
17
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
17
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
17
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
17
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
17
    return Status::OK();
630
17
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
9.25k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
9.25k
    _conjuncts.resize(_parent->_conjuncts.size());
614
9.25k
    _projections.resize(_parent->_projections.size());
615
12.8k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
3.56k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
3.56k
    }
618
9.25k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
9.25k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
9.25k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
9.25k
    return Status::OK();
630
9.25k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
462
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
462
    _conjuncts.resize(_parent->_conjuncts.size());
614
462
    _projections.resize(_parent->_projections.size());
615
462
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
462
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
462
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
462
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
462
    return Status::OK();
630
462
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
5.21k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
5.21k
    _conjuncts.resize(_parent->_conjuncts.size());
614
5.21k
    _projections.resize(_parent->_projections.size());
615
5.21k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
5.45k
    for (size_t i = 0; i < _projections.size(); i++) {
619
240
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
240
    }
621
5.21k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
5.21k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
5.21k
    return Status::OK();
630
5.21k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
764k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
764k
    _conjuncts.resize(_parent->_conjuncts.size());
614
764k
    _projections.resize(_parent->_projections.size());
615
764k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
764k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
764k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
764k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
764k
    return Status::OK();
630
764k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE4openEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
163
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
163
    _conjuncts.resize(_parent->_conjuncts.size());
614
163
    _projections.resize(_parent->_projections.size());
615
170
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
7
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
7
    }
618
479
    for (size_t i = 0; i < _projections.size(); i++) {
619
316
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
316
    }
621
163
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
166
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
3
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
11
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
8
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
8
                    state, _intermediate_projections[i][j]));
627
8
        }
628
3
    }
629
163
    return Status::OK();
630
163
}
631
632
template <typename SharedStateArg>
633
7.42k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
7.42k
    if (_terminated) {
635
6
        return Status::OK();
636
6
    }
637
7.42k
    _terminated = true;
638
7.42k
    return Status::OK();
639
7.42k
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
357
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
357
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
357
    _terminated = true;
638
357
    return Status::OK();
639
357
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
214
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
214
    if (_terminated) {
635
2
        return Status::OK();
636
2
    }
637
212
    _terminated = true;
638
212
    return Status::OK();
639
214
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
113
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
113
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
113
    _terminated = true;
638
113
    return Status::OK();
639
113
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
359
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
359
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
359
    _terminated = true;
638
359
    return Status::OK();
639
359
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
4.83k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
4.83k
    if (_terminated) {
635
2
        return Status::OK();
636
2
    }
637
4.83k
    _terminated = true;
638
4.83k
    return Status::OK();
639
4.83k
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
14
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
14
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
14
    _terminated = true;
638
14
    return Status::OK();
639
14
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
16
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
16
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
16
    _terminated = true;
638
16
    return Status::OK();
639
16
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
368
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
368
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
368
    _terminated = true;
638
368
    return Status::OK();
639
368
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
1.14k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
1.14k
    if (_terminated) {
635
2
        return Status::OK();
636
2
    }
637
1.14k
    _terminated = true;
638
1.14k
    return Status::OK();
639
1.14k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
4
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
4
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
4
    _terminated = true;
638
4
    return Status::OK();
639
4
}
640
641
template <typename SharedStateArg>
642
2.90M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
2.90M
    if (_closed) {
644
292k
        return Status::OK();
645
292k
    }
646
2.61M
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
1.32M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
1.32M
    }
649
2.61M
    _closed = true;
650
2.61M
    return Status::OK();
651
2.90M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
68.0k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
68.0k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
68.0k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
68.0k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
68.0k
    }
649
68.0k
    _closed = true;
650
68.0k
    return Status::OK();
651
68.0k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
4
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
4
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
4
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
4
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
4
    }
649
4
    _closed = true;
650
4
    return Status::OK();
651
4
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
516k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
516k
    if (_closed) {
644
258k
        return Status::OK();
645
258k
    }
646
258k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
258k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
258k
    }
649
258k
    _closed = true;
650
258k
    return Status::OK();
651
516k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
25
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
25
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
25
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
25
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
25
    }
649
25
    _closed = true;
650
25
    return Status::OK();
651
25
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
9.09k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
9.09k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
9.09k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
9.09k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
9.09k
    }
649
9.09k
    _closed = true;
650
9.09k
    return Status::OK();
651
9.09k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
18.1k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
18.1k
    if (_closed) {
644
9.15k
        return Status::OK();
645
9.15k
    }
646
9.04k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
9.04k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
9.04k
    }
649
9.04k
    _closed = true;
650
9.04k
    return Status::OK();
651
18.1k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
148k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
148k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
148k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
148k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
148k
    }
649
148k
    _closed = true;
650
148k
    return Status::OK();
651
148k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
297
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
297
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
297
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
297
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
297
    }
649
297
    _closed = true;
650
297
    return Status::OK();
651
297
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
121
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
121
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
121
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
121
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
121
    }
649
121
    _closed = true;
650
121
    return Status::OK();
651
121
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
1.30M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
1.30M
    if (_closed) {
644
19.1k
        return Status::OK();
645
19.1k
    }
646
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
    }
649
1.28M
    _closed = true;
650
1.28M
    return Status::OK();
651
1.30M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
55.4k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
55.4k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
55.4k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
55.4k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
55.4k
    }
649
55.4k
    _closed = true;
650
55.4k
    return Status::OK();
651
55.4k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
28
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
28
    if (_closed) {
644
14
        return Status::OK();
645
14
    }
646
14
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
14
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
14
    }
649
14
    _closed = true;
650
14
    return Status::OK();
651
28
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
9.24k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
9.24k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
9.24k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
9.24k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
9.24k
    }
649
9.24k
    _closed = true;
650
9.24k
    return Status::OK();
651
9.24k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
720
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
720
    if (_closed) {
644
360
        return Status::OK();
645
360
    }
646
360
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
360
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
360
    }
649
360
    _closed = true;
650
360
    return Status::OK();
651
720
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
10.5k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
10.5k
    if (_closed) {
644
5.31k
        return Status::OK();
645
5.31k
    }
646
5.20k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
5.20k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
5.20k
    }
649
5.20k
    _closed = true;
650
5.20k
    return Status::OK();
651
10.5k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
766k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
766k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
766k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
766k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
766k
    }
649
766k
    _closed = true;
650
766k
    return Status::OK();
651
766k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
336
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
336
    if (_closed) {
644
182
        return Status::OK();
645
182
    }
646
154
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
154
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
154
    }
649
154
    _closed = true;
650
154
    return Status::OK();
651
336
}
652
653
template <typename SharedState>
654
2.08M
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
2.08M
    _operator_profile =
657
2.08M
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
2.08M
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
2.08M
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
2.08M
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
2.08M
    _operator_profile->add_child(_common_profile, true);
666
2.08M
    _operator_profile->add_child(_custom_profile, true);
667
668
2.08M
    _operator_profile->set_metadata(_parent->node_id());
669
2.08M
    _wait_for_finish_dependency_timer =
670
2.08M
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
2.08M
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
2.08M
    if constexpr (!is_fake_shared) {
673
1.38M
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
1.38M
            info.shared_state_map.end()) {
675
311k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
291k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
291k
            }
678
311k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
311k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
311k
                                                  ? 0
681
311k
                                                  : info.task_idx]
682
311k
                                  .get();
683
311k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
1.06M
        } else {
685
1.06M
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
230
                DCHECK(false);
687
230
            }
688
1.06M
            _shared_state = info.shared_state->template cast<SharedState>();
689
1.06M
            _dependency = _shared_state->create_sink_dependency(
690
1.06M
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
1.06M
        }
692
1.38M
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
1.38M
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
1.38M
    }
695
696
2.08M
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
2.08M
    _rows_input_counter =
701
2.08M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
2.08M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
2.08M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
2.08M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
2.08M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
2.08M
    _memory_used_counter =
707
2.08M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
2.08M
    _common_profile->add_info_string("IsColocate",
709
2.08M
                                     std::to_string(_parent->is_colocated_operator()));
710
2.08M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
2.08M
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
2.08M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
2.08M
    return Status::OK();
714
2.08M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
116k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
116k
    _operator_profile =
657
116k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
116k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
116k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
116k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
116k
    _operator_profile->add_child(_common_profile, true);
666
116k
    _operator_profile->add_child(_custom_profile, true);
667
668
116k
    _operator_profile->set_metadata(_parent->node_id());
669
116k
    _wait_for_finish_dependency_timer =
670
116k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
116k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
116k
    if constexpr (!is_fake_shared) {
673
116k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
116k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
19.7k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
19.7k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
19.7k
                                                  ? 0
681
19.7k
                                                  : info.task_idx]
682
19.7k
                                  .get();
683
19.7k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
96.3k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
96.3k
            _shared_state = info.shared_state->template cast<SharedState>();
689
96.3k
            _dependency = _shared_state->create_sink_dependency(
690
96.3k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
96.3k
        }
692
116k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
116k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
116k
    }
695
696
116k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
116k
    _rows_input_counter =
701
116k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
116k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
116k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
116k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
116k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
116k
    _memory_used_counter =
707
116k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
116k
    _common_profile->add_info_string("IsColocate",
709
116k
                                     std::to_string(_parent->is_colocated_operator()));
710
116k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
116k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
116k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
116k
    return Status::OK();
714
116k
}
_ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
2
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
2
    _operator_profile =
657
2
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
2
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
2
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
2
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
2
    _operator_profile->add_child(_common_profile, true);
666
2
    _operator_profile->add_child(_custom_profile, true);
667
668
2
    _operator_profile->set_metadata(_parent->node_id());
669
2
    _wait_for_finish_dependency_timer =
670
2
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
2
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
2
    if constexpr (!is_fake_shared) {
673
2
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
2
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
2
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
2
            _shared_state = info.shared_state->template cast<SharedState>();
689
2
            _dependency = _shared_state->create_sink_dependency(
690
2
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
2
        }
692
2
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
2
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
2
    }
695
696
2
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
2
    _rows_input_counter =
701
2
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
2
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
2
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
2
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
2
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
2
    _memory_used_counter =
707
2
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
2
    _common_profile->add_info_string("IsColocate",
709
2
                                     std::to_string(_parent->is_colocated_operator()));
710
2
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
2
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
2
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
2
    return Status::OK();
714
2
}
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
258k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
258k
    _operator_profile =
657
258k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
258k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
258k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
258k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
258k
    _operator_profile->add_child(_common_profile, true);
666
258k
    _operator_profile->add_child(_custom_profile, true);
667
668
258k
    _operator_profile->set_metadata(_parent->node_id());
669
258k
    _wait_for_finish_dependency_timer =
670
258k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
258k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
258k
    if constexpr (!is_fake_shared) {
673
258k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
258k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
258k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
258k
            _shared_state = info.shared_state->template cast<SharedState>();
689
258k
            _dependency = _shared_state->create_sink_dependency(
690
258k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
258k
        }
692
258k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
258k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
258k
    }
695
696
258k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
258k
    _rows_input_counter =
701
258k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
258k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
258k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
258k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
258k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
258k
    _memory_used_counter =
707
258k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
258k
    _common_profile->add_info_string("IsColocate",
709
258k
                                     std::to_string(_parent->is_colocated_operator()));
710
258k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
258k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
258k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
258k
    return Status::OK();
714
258k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
32
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
32
    _operator_profile =
657
32
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
32
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
32
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
32
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
32
    _operator_profile->add_child(_common_profile, true);
666
32
    _operator_profile->add_child(_custom_profile, true);
667
668
32
    _operator_profile->set_metadata(_parent->node_id());
669
32
    _wait_for_finish_dependency_timer =
670
32
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
32
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
32
    if constexpr (!is_fake_shared) {
673
32
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
32
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
32
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
32
            _shared_state = info.shared_state->template cast<SharedState>();
689
32
            _dependency = _shared_state->create_sink_dependency(
690
32
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
32
        }
692
32
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
32
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
32
    }
695
696
32
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
32
    _rows_input_counter =
701
32
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
32
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
32
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
32
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
32
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
32
    _memory_used_counter =
707
32
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
32
    _common_profile->add_info_string("IsColocate",
709
32
                                     std::to_string(_parent->is_colocated_operator()));
710
32
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
32
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
32
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
32
    return Status::OK();
714
32
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
9.09k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
9.09k
    _operator_profile =
657
9.09k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
9.09k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
9.09k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
9.09k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
9.09k
    _operator_profile->add_child(_common_profile, true);
666
9.09k
    _operator_profile->add_child(_custom_profile, true);
667
668
9.09k
    _operator_profile->set_metadata(_parent->node_id());
669
9.09k
    _wait_for_finish_dependency_timer =
670
9.09k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
9.09k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
9.09k
    if constexpr (!is_fake_shared) {
673
9.09k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
9.09k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
9.09k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
9.09k
            _shared_state = info.shared_state->template cast<SharedState>();
689
9.09k
            _dependency = _shared_state->create_sink_dependency(
690
9.09k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
9.09k
        }
692
9.09k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
9.09k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
9.09k
    }
695
696
9.09k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
9.09k
    _rows_input_counter =
701
9.09k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
9.09k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
9.09k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
9.09k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
9.09k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
9.09k
    _memory_used_counter =
707
9.09k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
9.09k
    _common_profile->add_info_string("IsColocate",
709
9.09k
                                     std::to_string(_parent->is_colocated_operator()));
710
9.09k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
9.09k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
9.09k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
9.09k
    return Status::OK();
714
9.09k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
9.03k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
9.03k
    _operator_profile =
657
9.03k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
9.03k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
9.03k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
9.03k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
9.03k
    _operator_profile->add_child(_common_profile, true);
666
9.03k
    _operator_profile->add_child(_custom_profile, true);
667
668
9.03k
    _operator_profile->set_metadata(_parent->node_id());
669
9.03k
    _wait_for_finish_dependency_timer =
670
9.03k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
9.03k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
9.03k
    if constexpr (!is_fake_shared) {
673
9.03k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
9.03k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
9.03k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
9.03k
            _shared_state = info.shared_state->template cast<SharedState>();
689
9.03k
            _dependency = _shared_state->create_sink_dependency(
690
9.03k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
9.03k
        }
692
9.03k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
9.03k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
9.03k
    }
695
696
9.03k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
9.03k
    _rows_input_counter =
701
9.03k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
9.03k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
9.03k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
9.03k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
9.03k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
9.03k
    _memory_used_counter =
707
9.03k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
9.03k
    _common_profile->add_info_string("IsColocate",
709
9.03k
                                     std::to_string(_parent->is_colocated_operator()));
710
9.03k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
9.03k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
9.03k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
9.03k
    return Status::OK();
714
9.03k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
148k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
148k
    _operator_profile =
657
148k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
148k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
148k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
148k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
148k
    _operator_profile->add_child(_common_profile, true);
666
148k
    _operator_profile->add_child(_custom_profile, true);
667
668
148k
    _operator_profile->set_metadata(_parent->node_id());
669
148k
    _wait_for_finish_dependency_timer =
670
148k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
148k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
148k
    if constexpr (!is_fake_shared) {
673
148k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
148k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
148k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
148k
            _shared_state = info.shared_state->template cast<SharedState>();
689
148k
            _dependency = _shared_state->create_sink_dependency(
690
148k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
148k
        }
692
148k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
148k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
148k
    }
695
696
148k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
148k
    _rows_input_counter =
701
148k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
148k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
148k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
148k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
148k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
148k
    _memory_used_counter =
707
148k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
148k
    _common_profile->add_info_string("IsColocate",
709
148k
                                     std::to_string(_parent->is_colocated_operator()));
710
148k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
148k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
148k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
148k
    return Status::OK();
714
148k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
294
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
294
    _operator_profile =
657
294
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
294
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
294
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
294
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
294
    _operator_profile->add_child(_common_profile, true);
666
294
    _operator_profile->add_child(_custom_profile, true);
667
668
294
    _operator_profile->set_metadata(_parent->node_id());
669
294
    _wait_for_finish_dependency_timer =
670
294
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
294
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
294
    if constexpr (!is_fake_shared) {
673
294
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
294
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
291
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
291
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
291
                                                  ? 0
681
291
                                                  : info.task_idx]
682
291
                                  .get();
683
291
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
291
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
3
            _shared_state = info.shared_state->template cast<SharedState>();
689
3
            _dependency = _shared_state->create_sink_dependency(
690
3
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
3
        }
692
294
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
294
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
294
    }
695
696
294
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
294
    _rows_input_counter =
701
294
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
294
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
294
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
294
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
294
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
294
    _memory_used_counter =
707
294
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
294
    _common_profile->add_info_string("IsColocate",
709
294
                                     std::to_string(_parent->is_colocated_operator()));
710
294
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
294
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
294
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
294
    return Status::OK();
714
294
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
132
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
132
    _operator_profile =
657
132
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
132
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
132
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
132
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
132
    _operator_profile->add_child(_common_profile, true);
666
132
    _operator_profile->add_child(_custom_profile, true);
667
668
132
    _operator_profile->set_metadata(_parent->node_id());
669
132
    _wait_for_finish_dependency_timer =
670
132
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
132
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
132
    if constexpr (!is_fake_shared) {
673
132
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
132
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
132
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
132
            _shared_state = info.shared_state->template cast<SharedState>();
689
132
            _dependency = _shared_state->create_sink_dependency(
690
132
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
132
        }
692
132
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
132
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
132
    }
695
696
132
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
132
    _rows_input_counter =
701
132
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
132
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
132
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
132
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
132
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
132
    _memory_used_counter =
707
132
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
132
    _common_profile->add_info_string("IsColocate",
709
132
                                     std::to_string(_parent->is_colocated_operator()));
710
132
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
132
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
132
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
132
    return Status::OK();
714
132
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
706k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
706k
    _operator_profile =
657
706k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
706k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
706k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
706k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
706k
    _operator_profile->add_child(_common_profile, true);
666
706k
    _operator_profile->add_child(_custom_profile, true);
667
668
706k
    _operator_profile->set_metadata(_parent->node_id());
669
706k
    _wait_for_finish_dependency_timer =
670
706k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
706k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
    if constexpr (!is_fake_shared) {
673
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
                                                  ? 0
681
                                                  : info.task_idx]
682
                                  .get();
683
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
            _shared_state = info.shared_state->template cast<SharedState>();
689
            _dependency = _shared_state->create_sink_dependency(
690
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
        }
692
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
    }
695
696
706k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
706k
    _rows_input_counter =
701
706k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
706k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
706k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
706k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
706k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
706k
    _memory_used_counter =
707
706k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
706k
    _common_profile->add_info_string("IsColocate",
709
706k
                                     std::to_string(_parent->is_colocated_operator()));
710
706k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
706k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
706k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
706k
    return Status::OK();
714
706k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
5.44k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
5.44k
    _operator_profile =
657
5.44k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
5.44k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
5.44k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
5.44k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
5.44k
    _operator_profile->add_child(_common_profile, true);
666
5.44k
    _operator_profile->add_child(_custom_profile, true);
667
668
5.44k
    _operator_profile->set_metadata(_parent->node_id());
669
5.44k
    _wait_for_finish_dependency_timer =
670
5.44k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
5.44k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
5.44k
    if constexpr (!is_fake_shared) {
673
5.44k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
5.44k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
5.44k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
5.44k
            _shared_state = info.shared_state->template cast<SharedState>();
689
5.44k
            _dependency = _shared_state->create_sink_dependency(
690
5.44k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
5.44k
        }
692
5.44k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
5.44k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
5.44k
    }
695
696
5.44k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
5.44k
    _rows_input_counter =
701
5.44k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
5.44k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
5.44k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
5.44k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
5.44k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
5.44k
    _memory_used_counter =
707
5.44k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
5.44k
    _common_profile->add_info_string("IsColocate",
709
5.44k
                                     std::to_string(_parent->is_colocated_operator()));
710
5.44k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
5.44k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
5.44k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
5.44k
    return Status::OK();
714
5.44k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
460
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
460
    _operator_profile =
657
460
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
460
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
460
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
460
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
460
    _operator_profile->add_child(_common_profile, true);
666
460
    _operator_profile->add_child(_custom_profile, true);
667
668
460
    _operator_profile->set_metadata(_parent->node_id());
669
460
    _wait_for_finish_dependency_timer =
670
460
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
460
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
460
    if constexpr (!is_fake_shared) {
673
460
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
460
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
460
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
460
            _shared_state = info.shared_state->template cast<SharedState>();
689
460
            _dependency = _shared_state->create_sink_dependency(
690
460
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
460
        }
692
460
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
460
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
460
    }
695
696
460
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
460
    _rows_input_counter =
701
460
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
460
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
460
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
460
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
460
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
460
    _memory_used_counter =
707
460
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
460
    _common_profile->add_info_string("IsColocate",
709
460
                                     std::to_string(_parent->is_colocated_operator()));
710
460
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
460
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
460
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
460
    return Status::OK();
714
460
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
3.24k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
3.24k
    _operator_profile =
657
3.24k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
3.24k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
3.24k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
3.24k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
3.24k
    _operator_profile->add_child(_common_profile, true);
666
3.24k
    _operator_profile->add_child(_custom_profile, true);
667
668
3.24k
    _operator_profile->set_metadata(_parent->node_id());
669
3.24k
    _wait_for_finish_dependency_timer =
670
3.24k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
3.24k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
3.24k
    if constexpr (!is_fake_shared) {
673
3.24k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
3.24k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
3.24k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
3.24k
            _shared_state = info.shared_state->template cast<SharedState>();
689
3.24k
            _dependency = _shared_state->create_sink_dependency(
690
3.24k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
3.24k
        }
692
3.24k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
3.24k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
3.24k
    }
695
696
3.24k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
3.24k
    _rows_input_counter =
701
3.24k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
3.24k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
3.24k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
3.24k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
3.24k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
3.24k
    _memory_used_counter =
707
3.24k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
3.24k
    _common_profile->add_info_string("IsColocate",
709
3.24k
                                     std::to_string(_parent->is_colocated_operator()));
710
3.24k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
3.24k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
3.24k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
3.24k
    return Status::OK();
714
3.24k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
12.6k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
12.6k
    _operator_profile =
657
12.6k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
12.6k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
12.6k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
12.6k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
12.6k
    _operator_profile->add_child(_common_profile, true);
666
12.6k
    _operator_profile->add_child(_custom_profile, true);
667
668
12.6k
    _operator_profile->set_metadata(_parent->node_id());
669
12.6k
    _wait_for_finish_dependency_timer =
670
12.6k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
12.6k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
12.6k
    if constexpr (!is_fake_shared) {
673
12.6k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
12.6k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
12.6k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
12.6k
            _shared_state = info.shared_state->template cast<SharedState>();
689
12.6k
            _dependency = _shared_state->create_sink_dependency(
690
12.6k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
12.6k
        }
692
12.6k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
12.6k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
12.6k
    }
695
696
12.6k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
12.6k
    _rows_input_counter =
701
12.6k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
12.6k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
12.6k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
12.6k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
12.6k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
12.6k
    _memory_used_counter =
707
12.6k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
12.6k
    _common_profile->add_info_string("IsColocate",
709
12.6k
                                     std::to_string(_parent->is_colocated_operator()));
710
12.6k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
12.6k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
12.6k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
12.6k
    return Status::OK();
714
12.6k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
291k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
291k
    _operator_profile =
657
291k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
291k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
291k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
291k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
291k
    _operator_profile->add_child(_common_profile, true);
666
291k
    _operator_profile->add_child(_custom_profile, true);
667
668
291k
    _operator_profile->set_metadata(_parent->node_id());
669
291k
    _wait_for_finish_dependency_timer =
670
291k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
291k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
291k
    if constexpr (!is_fake_shared) {
673
291k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
291k
            info.shared_state_map.end()) {
675
291k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
291k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
291k
            }
678
291k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
291k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
291k
                                                  ? 0
681
291k
                                                  : info.task_idx]
682
291k
                                  .get();
683
291k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
291k
        } else {
685
230
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
230
                DCHECK(false);
687
230
            }
688
230
            _shared_state = info.shared_state->template cast<SharedState>();
689
230
            _dependency = _shared_state->create_sink_dependency(
690
230
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
230
        }
692
291k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
291k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
291k
    }
695
696
291k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
291k
    _rows_input_counter =
701
291k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
291k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
291k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
291k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
291k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
291k
    _memory_used_counter =
707
291k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
291k
    _common_profile->add_info_string("IsColocate",
709
291k
                                     std::to_string(_parent->is_colocated_operator()));
710
291k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
291k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
291k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
291k
    return Status::OK();
714
291k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
524k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
524k
    _operator_profile =
657
524k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
524k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
524k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
524k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
524k
    _operator_profile->add_child(_common_profile, true);
666
524k
    _operator_profile->add_child(_custom_profile, true);
667
668
524k
    _operator_profile->set_metadata(_parent->node_id());
669
524k
    _wait_for_finish_dependency_timer =
670
524k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
524k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
524k
    if constexpr (!is_fake_shared) {
673
524k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
524k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
524k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
524k
            _shared_state = info.shared_state->template cast<SharedState>();
689
524k
            _dependency = _shared_state->create_sink_dependency(
690
524k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
524k
        }
692
524k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
524k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
524k
    }
695
696
524k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
524k
    _rows_input_counter =
701
524k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
524k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
524k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
524k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
524k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
524k
    _memory_used_counter =
707
524k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
524k
    _common_profile->add_info_string("IsColocate",
709
524k
                                     std::to_string(_parent->is_colocated_operator()));
710
524k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
524k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
524k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
524k
    return Status::OK();
714
524k
}
_ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
17
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
17
    _operator_profile =
657
17
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
17
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
17
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
17
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
17
    _operator_profile->add_child(_common_profile, true);
666
17
    _operator_profile->add_child(_custom_profile, true);
667
668
17
    _operator_profile->set_metadata(_parent->node_id());
669
17
    _wait_for_finish_dependency_timer =
670
17
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
17
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
17
    if constexpr (!is_fake_shared) {
673
17
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
17
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
17
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
17
            _shared_state = info.shared_state->template cast<SharedState>();
689
17
            _dependency = _shared_state->create_sink_dependency(
690
17
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
17
        }
692
17
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
17
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
17
    }
695
696
17
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
17
    _rows_input_counter =
701
17
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
17
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
17
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
17
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
17
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
17
    _memory_used_counter =
707
17
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
17
    _common_profile->add_info_string("IsColocate",
709
17
                                     std::to_string(_parent->is_colocated_operator()));
710
17
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
17
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
17
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
17
    return Status::OK();
714
17
}
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
326
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
326
    _operator_profile =
657
326
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
326
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
326
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
326
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
326
    _operator_profile->add_child(_common_profile, true);
666
326
    _operator_profile->add_child(_custom_profile, true);
667
668
326
    _operator_profile->set_metadata(_parent->node_id());
669
326
    _wait_for_finish_dependency_timer =
670
326
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
326
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
326
    if constexpr (!is_fake_shared) {
673
326
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
326
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
326
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
326
            _shared_state = info.shared_state->template cast<SharedState>();
689
326
            _dependency = _shared_state->create_sink_dependency(
690
326
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
326
        }
692
326
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
326
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
326
    }
695
696
326
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
326
    _rows_input_counter =
701
326
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
326
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
326
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
326
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
326
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
326
    _memory_used_counter =
707
326
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
326
    _common_profile->add_info_string("IsColocate",
709
326
                                     std::to_string(_parent->is_colocated_operator()));
710
326
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
326
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
326
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
326
    return Status::OK();
714
326
}
715
716
template <typename SharedState>
717
2.08M
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
2.08M
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
2.08M
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
1.38M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
1.38M
    }
724
2.08M
    _closed = true;
725
2.08M
    return Status::OK();
726
2.08M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
116k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
116k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
116k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
116k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
116k
    }
724
116k
    _closed = true;
725
116k
    return Status::OK();
726
116k
}
_ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
1
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
1
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
1
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
1
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
1
    }
724
1
    _closed = true;
725
1
    return Status::OK();
726
1
}
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
258k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
258k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
258k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
258k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
258k
    }
724
258k
    _closed = true;
725
258k
    return Status::OK();
726
258k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
23
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
23
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
21
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
21
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
21
    }
724
21
    _closed = true;
725
21
    return Status::OK();
726
23
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
9.08k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
9.08k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
9.08k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
9.08k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
9.08k
    }
724
9.08k
    _closed = true;
725
9.08k
    return Status::OK();
726
9.08k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
9.03k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
9.03k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
9.03k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
9.03k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
9.03k
    }
724
9.03k
    _closed = true;
725
9.03k
    return Status::OK();
726
9.03k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
148k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
148k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
148k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
148k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
148k
    }
724
148k
    _closed = true;
725
148k
    return Status::OK();
726
148k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
293
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
293
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
293
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
293
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
293
    }
724
293
    _closed = true;
725
293
    return Status::OK();
726
293
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
121
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
121
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
121
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
121
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
121
    }
724
121
    _closed = true;
725
121
    return Status::OK();
726
121
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
707k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
707k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
    }
724
707k
    _closed = true;
725
707k
    return Status::OK();
726
707k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
5.43k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
5.43k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
5.43k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
5.43k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
5.43k
    }
724
5.43k
    _closed = true;
725
5.43k
    return Status::OK();
726
5.43k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
357
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
357
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
357
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
357
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
357
    }
724
357
    _closed = true;
725
357
    return Status::OK();
726
357
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
3.25k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
3.25k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
3.25k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
3.25k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
3.25k
    }
724
3.25k
    _closed = true;
725
3.25k
    return Status::OK();
726
3.25k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
12.7k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
12.7k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
12.7k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
12.7k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
12.7k
    }
724
12.7k
    _closed = true;
725
12.7k
    return Status::OK();
726
12.7k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
291k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
291k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
291k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
291k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
291k
    }
724
291k
    _closed = true;
725
291k
    return Status::OK();
726
291k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
525k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
525k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
525k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
525k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
525k
    }
724
525k
    _closed = true;
725
525k
    return Status::OK();
726
525k
}
_ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
14
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
14
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
14
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
14
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
14
    }
724
14
    _closed = true;
725
14
    return Status::OK();
726
14
}
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
326
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
326
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
326
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
326
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
326
    }
724
326
    _closed = true;
725
326
    return Status::OK();
726
326
}
727
728
template <typename LocalStateType>
729
Status StreamingOperatorX<LocalStateType>::get_block_impl(RuntimeState* state, Block* block,
730
11.5k
                                                          bool* eos) {
731
11.5k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
11.5k
    return pull(state, block, eos);
733
11.5k
}
_ZN5doris18StreamingOperatorXINS_23AssertNumRowsLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
730
431
                                                          bool* eos) {
731
431
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
431
    return pull(state, block, eos);
733
431
}
_ZN5doris18StreamingOperatorXINS_16SelectLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
730
11.1k
                                                          bool* eos) {
731
11.1k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
11.1k
    return pull(state, block, eos);
733
11.1k
}
734
735
template <typename LocalStateType>
736
Status StatefulOperatorX<LocalStateType>::get_block_impl(RuntimeState* state, Block* block,
737
770k
                                                         bool* eos) {
738
770k
    auto& local_state = get_local_state(state);
739
770k
    if (need_more_input_data(state)) {
740
741k
        local_state._child_block->clear_column_data(
741
741k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
741k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
741k
                state, local_state._child_block.get(), &local_state._child_eos));
744
741k
        *eos = local_state._child_eos;
745
741k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
77.8k
            return Status::OK();
747
77.8k
        }
748
663k
        {
749
663k
            SCOPED_TIMER(local_state.exec_time_counter());
750
663k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
663k
        }
752
663k
    }
753
754
692k
    if (!need_more_input_data(state)) {
755
644k
        SCOPED_TIMER(local_state.exec_time_counter());
756
644k
        bool new_eos = false;
757
644k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
644k
        if (new_eos) {
759
563k
            *eos = true;
760
563k
        } else if (!need_more_input_data(state)) {
761
24.1k
            *eos = false;
762
24.1k
        }
763
644k
    }
764
692k
    return Status::OK();
765
692k
}
_ZN5doris17StatefulOperatorXINS_23HashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
146k
                                                         bool* eos) {
738
146k
    auto& local_state = get_local_state(state);
739
146k
    if (need_more_input_data(state)) {
740
130k
        local_state._child_block->clear_column_data(
741
130k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
130k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
130k
                state, local_state._child_block.get(), &local_state._child_eos));
744
130k
        *eos = local_state._child_eos;
745
130k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
46.3k
            return Status::OK();
747
46.3k
        }
748
84.0k
        {
749
84.0k
            SCOPED_TIMER(local_state.exec_time_counter());
750
84.0k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
84.0k
        }
752
84.0k
    }
753
754
100k
    if (!need_more_input_data(state)) {
755
100k
        SCOPED_TIMER(local_state.exec_time_counter());
756
100k
        bool new_eos = false;
757
100k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
100k
        if (new_eos) {
759
43.9k
            *eos = true;
760
56.2k
        } else if (!need_more_input_data(state)) {
761
9.53k
            *eos = false;
762
9.53k
        }
763
100k
    }
764
100k
    return Status::OK();
765
100k
}
Unexecuted instantiation: _ZN5doris17StatefulOperatorXINS_34PartitionedHashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
_ZN5doris17StatefulOperatorXINS_16RepeatLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.06k
                                                         bool* eos) {
738
4.06k
    auto& local_state = get_local_state(state);
739
4.06k
    if (need_more_input_data(state)) {
740
2.26k
        local_state._child_block->clear_column_data(
741
2.26k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
2.26k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
2.26k
                state, local_state._child_block.get(), &local_state._child_eos));
744
2.26k
        *eos = local_state._child_eos;
745
2.26k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
418
            return Status::OK();
747
418
        }
748
1.84k
        {
749
1.84k
            SCOPED_TIMER(local_state.exec_time_counter());
750
1.84k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
1.84k
        }
752
1.84k
    }
753
754
3.65k
    if (!need_more_input_data(state)) {
755
3.65k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.65k
        bool new_eos = false;
757
3.65k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.65k
        if (new_eos) {
759
1.27k
            *eos = true;
760
2.37k
        } else if (!need_more_input_data(state)) {
761
1.80k
            *eos = false;
762
1.80k
        }
763
3.65k
    }
764
3.64k
    return Status::OK();
765
3.64k
}
_ZN5doris17StatefulOperatorXINS_25MaterializationLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.83k
                                                         bool* eos) {
738
4.83k
    auto& local_state = get_local_state(state);
739
4.83k
    if (need_more_input_data(state)) {
740
4.83k
        local_state._child_block->clear_column_data(
741
4.83k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
4.83k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
4.83k
                state, local_state._child_block.get(), &local_state._child_eos));
744
4.83k
        *eos = local_state._child_eos;
745
4.83k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
1.62k
            return Status::OK();
747
1.62k
        }
748
3.20k
        {
749
3.20k
            SCOPED_TIMER(local_state.exec_time_counter());
750
3.20k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
3.20k
        }
752
3.20k
    }
753
754
3.20k
    if (!need_more_input_data(state)) {
755
3.20k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.20k
        bool new_eos = false;
757
3.20k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.20k
        if (new_eos) {
759
1.65k
            *eos = true;
760
1.65k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
3.20k
    }
764
3.20k
    return Status::OK();
765
3.20k
}
_ZN5doris17StatefulOperatorXINS_22StreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
30.8k
                                                         bool* eos) {
738
30.8k
    auto& local_state = get_local_state(state);
739
30.8k
    if (need_more_input_data(state)) {
740
30.8k
        local_state._child_block->clear_column_data(
741
30.8k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
30.8k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
30.8k
                state, local_state._child_block.get(), &local_state._child_eos));
744
30.8k
        *eos = local_state._child_eos;
745
30.8k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
4.42k
            return Status::OK();
747
4.42k
        }
748
26.4k
        {
749
26.4k
            SCOPED_TIMER(local_state.exec_time_counter());
750
26.4k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
26.4k
        }
752
26.4k
    }
753
754
26.4k
    if (!need_more_input_data(state)) {
755
10.3k
        SCOPED_TIMER(local_state.exec_time_counter());
756
10.3k
        bool new_eos = false;
757
10.3k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
10.3k
        if (new_eos) {
759
10.3k
            *eos = true;
760
10.3k
        } else if (!need_more_input_data(state)) {
761
2
            *eos = false;
762
2
        }
763
10.3k
    }
764
26.4k
    return Status::OK();
765
26.4k
}
_ZN5doris17StatefulOperatorXINS_30DistinctStreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
547k
                                                         bool* eos) {
738
547k
    auto& local_state = get_local_state(state);
739
548k
    if (need_more_input_data(state)) {
740
548k
        local_state._child_block->clear_column_data(
741
548k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
548k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
548k
                state, local_state._child_block.get(), &local_state._child_eos));
744
548k
        *eos = local_state._child_eos;
745
548k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
22.1k
            return Status::OK();
747
22.1k
        }
748
526k
        {
749
526k
            SCOPED_TIMER(local_state.exec_time_counter());
750
526k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
526k
        }
752
526k
    }
753
754
525k
    if (!need_more_input_data(state)) {
755
493k
        SCOPED_TIMER(local_state.exec_time_counter());
756
493k
        bool new_eos = false;
757
493k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
493k
        if (new_eos) {
759
491k
            *eos = true;
760
491k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
493k
    }
764
525k
    return Status::OK();
765
525k
}
_ZN5doris17StatefulOperatorXINS_29NestedLoopJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
29.2k
                                                         bool* eos) {
738
29.2k
    auto& local_state = get_local_state(state);
739
29.2k
    if (need_more_input_data(state)) {
740
16.7k
        local_state._child_block->clear_column_data(
741
16.7k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
16.7k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
16.7k
                state, local_state._child_block.get(), &local_state._child_eos));
744
16.7k
        *eos = local_state._child_eos;
745
16.7k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
2.47k
            return Status::OK();
747
2.47k
        }
748
14.3k
        {
749
14.3k
            SCOPED_TIMER(local_state.exec_time_counter());
750
14.3k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
14.3k
        }
752
14.3k
    }
753
754
26.7k
    if (!need_more_input_data(state)) {
755
26.2k
        SCOPED_TIMER(local_state.exec_time_counter());
756
26.2k
        bool new_eos = false;
757
26.2k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
26.2k
        if (new_eos) {
759
9.06k
            *eos = true;
760
17.1k
        } else if (!need_more_input_data(state)) {
761
12.4k
            *eos = false;
762
12.4k
        }
763
26.2k
    }
764
26.7k
    return Status::OK();
765
26.7k
}
_ZN5doris17StatefulOperatorXINS_23TableFunctionLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
7.57k
                                                         bool* eos) {
738
7.57k
    auto& local_state = get_local_state(state);
739
7.57k
    if (need_more_input_data(state)) {
740
7.21k
        local_state._child_block->clear_column_data(
741
7.21k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
7.21k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
7.21k
                state, local_state._child_block.get(), &local_state._child_eos));
744
7.21k
        *eos = local_state._child_eos;
745
7.21k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
376
            return Status::OK();
747
376
        }
748
6.84k
        {
749
6.84k
            SCOPED_TIMER(local_state.exec_time_counter());
750
6.84k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
6.84k
        }
752
6.84k
    }
753
754
7.19k
    if (!need_more_input_data(state)) {
755
7.19k
        SCOPED_TIMER(local_state.exec_time_counter());
756
7.19k
        bool new_eos = false;
757
7.19k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
7.19k
        if (new_eos) {
759
5.12k
            *eos = true;
760
5.12k
        } else if (!need_more_input_data(state)) {
761
366
            *eos = false;
762
366
        }
763
7.19k
    }
764
7.19k
    return Status::OK();
765
7.19k
}
766
767
template <typename Writer, typename Parent>
768
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
769
65.2k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
65.2k
    RETURN_IF_ERROR(Base::init(state, info));
771
65.2k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
65.2k
                                                         "AsyncWriterDependency", true);
773
65.2k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
65.2k
                             _finish_dependency));
775
776
65.2k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
65.2k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
65.2k
    return Status::OK();
779
65.2k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
513
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
513
    RETURN_IF_ERROR(Base::init(state, info));
771
513
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
513
                                                         "AsyncWriterDependency", true);
773
513
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
513
                             _finish_dependency));
775
776
513
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
513
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
513
    return Status::OK();
779
513
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
88
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
88
    RETURN_IF_ERROR(Base::init(state, info));
771
88
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
88
                                                         "AsyncWriterDependency", true);
773
88
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
88
                             _finish_dependency));
775
776
88
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
88
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
88
    return Status::OK();
779
88
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
45.7k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
45.7k
    RETURN_IF_ERROR(Base::init(state, info));
771
45.7k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
45.7k
                                                         "AsyncWriterDependency", true);
773
45.7k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
45.7k
                             _finish_dependency));
775
776
45.7k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
45.7k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
45.7k
    return Status::OK();
779
45.7k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
9.33k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
9.33k
    RETURN_IF_ERROR(Base::init(state, info));
771
9.33k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
9.33k
                                                         "AsyncWriterDependency", true);
773
9.33k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
9.33k
                             _finish_dependency));
775
776
9.33k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
9.33k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
9.33k
    return Status::OK();
779
9.33k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
5.16k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
5.16k
    RETURN_IF_ERROR(Base::init(state, info));
771
5.16k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
5.16k
                                                         "AsyncWriterDependency", true);
773
5.16k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
5.16k
                             _finish_dependency));
775
776
5.16k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
5.16k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
5.16k
    return Status::OK();
779
5.16k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
3.39k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
3.39k
    RETURN_IF_ERROR(Base::init(state, info));
771
3.39k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
3.39k
                                                         "AsyncWriterDependency", true);
773
3.39k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
3.39k
                             _finish_dependency));
775
776
3.39k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
3.39k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
3.39k
    return Status::OK();
779
3.39k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
32
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
32
    RETURN_IF_ERROR(Base::init(state, info));
771
32
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
32
                                                         "AsyncWriterDependency", true);
773
32
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
32
                             _finish_dependency));
775
776
32
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
32
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
32
    return Status::OK();
779
32
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
160
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
160
    RETURN_IF_ERROR(Base::init(state, info));
771
160
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
160
                                                         "AsyncWriterDependency", true);
773
160
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
160
                             _finish_dependency));
775
776
160
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
160
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
160
    return Status::OK();
779
160
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
640
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
640
    RETURN_IF_ERROR(Base::init(state, info));
771
640
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
640
                                                         "AsyncWriterDependency", true);
773
640
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
640
                             _finish_dependency));
775
776
640
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
640
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
640
    return Status::OK();
779
640
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
156
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
156
    RETURN_IF_ERROR(Base::init(state, info));
771
156
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
156
                                                         "AsyncWriterDependency", true);
773
156
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
156
                             _finish_dependency));
775
776
156
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
156
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
156
    return Status::OK();
779
156
}
780
781
template <typename Writer, typename Parent>
782
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
783
65.4k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
65.4k
    RETURN_IF_ERROR(Base::open(state));
785
65.4k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
582k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
516k
        RETURN_IF_ERROR(
788
516k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
516k
    }
790
65.4k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
65.4k
    return Status::OK();
792
65.4k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
513
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
513
    RETURN_IF_ERROR(Base::open(state));
785
513
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
2.76k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
2.25k
        RETURN_IF_ERROR(
788
2.25k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
2.25k
    }
790
513
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
513
    return Status::OK();
792
513
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
88
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
88
    RETURN_IF_ERROR(Base::open(state));
785
88
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
412
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
324
        RETURN_IF_ERROR(
788
324
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
324
    }
790
88
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
88
    return Status::OK();
792
88
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
46.0k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
46.0k
    RETURN_IF_ERROR(Base::open(state));
785
46.0k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
335k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
289k
        RETURN_IF_ERROR(
788
289k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
289k
    }
790
46.0k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
46.0k
    return Status::OK();
792
46.0k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
9.27k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
9.27k
    RETURN_IF_ERROR(Base::open(state));
785
9.27k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
57.4k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
48.1k
        RETURN_IF_ERROR(
788
48.1k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
48.1k
    }
790
9.27k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
9.27k
    return Status::OK();
792
9.27k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
5.16k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
5.16k
    RETURN_IF_ERROR(Base::open(state));
785
5.16k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
137k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
132k
        RETURN_IF_ERROR(
788
132k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
132k
    }
790
5.16k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
5.16k
    return Status::OK();
792
5.16k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
3.38k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
3.38k
    RETURN_IF_ERROR(Base::open(state));
785
3.38k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
42.4k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
39.0k
        RETURN_IF_ERROR(
788
39.0k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
39.0k
    }
790
3.38k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
3.38k
    return Status::OK();
792
3.38k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
32
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
32
    RETURN_IF_ERROR(Base::open(state));
785
32
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
126
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
94
        RETURN_IF_ERROR(
788
94
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
94
    }
790
32
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
32
    return Status::OK();
792
32
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
160
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
160
    RETURN_IF_ERROR(Base::open(state));
785
160
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
480
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
320
        RETURN_IF_ERROR(
788
320
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
320
    }
790
160
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
160
    return Status::OK();
792
160
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
640
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
640
    RETURN_IF_ERROR(Base::open(state));
785
640
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
4.40k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
3.76k
        RETURN_IF_ERROR(
788
3.76k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
3.76k
    }
790
640
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
640
    return Status::OK();
792
640
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4openEPNS_12RuntimeStateE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
156
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
156
    RETURN_IF_ERROR(Base::open(state));
785
156
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
786
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
630
        RETURN_IF_ERROR(
788
630
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
630
    }
790
156
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
156
    return Status::OK();
792
156
}
793
794
template <typename Writer, typename Parent>
795
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
796
89.5k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
89.5k
    return _writer->sink(block, eos);
798
89.5k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
2.37k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
2.37k
    return _writer->sink(block, eos);
798
2.37k
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
112
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
112
    return _writer->sink(block, eos);
798
112
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
62.1k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
62.1k
    return _writer->sink(block, eos);
798
62.1k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
10.7k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
10.7k
    return _writer->sink(block, eos);
798
10.7k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
7.53k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
7.53k
    return _writer->sink(block, eos);
798
7.53k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
5.35k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
5.35k
    return _writer->sink(block, eos);
798
5.35k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
40
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
40
    return _writer->sink(block, eos);
798
40
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
180
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
180
    return _writer->sink(block, eos);
798
180
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
794
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
794
    return _writer->sink(block, eos);
798
794
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
310
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
310
    return _writer->sink(block, eos);
798
310
}
799
800
template <typename Writer, typename Parent>
801
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
802
65.5k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
65.5k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
65.5k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
65.5k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
65.5k
    if (_writer) {
810
65.5k
        Status st = _writer->get_writer_status();
811
65.5k
        if (exec_status.ok()) {
812
65.3k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
65.3k
                                                       : Status::Cancelled("force close"));
814
65.3k
        } else {
815
203
            _writer->force_close(exec_status);
816
203
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
65.5k
        RETURN_IF_ERROR(st);
821
65.5k
    }
822
65.4k
    return Base::close(state, exec_status);
823
65.5k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
501
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
501
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
501
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
501
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
501
    if (_writer) {
810
501
        Status st = _writer->get_writer_status();
811
501
        if (exec_status.ok()) {
812
501
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
501
                                                       : Status::Cancelled("force close"));
814
501
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
501
        RETURN_IF_ERROR(st);
821
501
    }
822
501
    return Base::close(state, exec_status);
823
501
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
88
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
88
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
88
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
88
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
88
    if (_writer) {
810
88
        Status st = _writer->get_writer_status();
811
88
        if (exec_status.ok()) {
812
88
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
88
                                                       : Status::Cancelled("force close"));
814
88
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
88
        RETURN_IF_ERROR(st);
821
88
    }
822
80
    return Base::close(state, exec_status);
823
88
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
46.0k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
46.0k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
46.0k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
46.0k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
46.1k
    if (_writer) {
810
46.1k
        Status st = _writer->get_writer_status();
811
46.1k
        if (exec_status.ok()) {
812
45.9k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
45.9k
                                                       : Status::Cancelled("force close"));
814
45.9k
        } else {
815
107
            _writer->force_close(exec_status);
816
107
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
46.1k
        RETURN_IF_ERROR(st);
821
46.1k
    }
822
46.0k
    return Base::close(state, exec_status);
823
46.0k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
9.32k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
9.32k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
9.32k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
9.32k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
9.32k
    if (_writer) {
810
9.32k
        Status st = _writer->get_writer_status();
811
9.32k
        if (exec_status.ok()) {
812
9.23k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
9.23k
                                                       : Status::Cancelled("force close"));
814
9.23k
        } else {
815
98
            _writer->force_close(exec_status);
816
98
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
9.32k
        RETURN_IF_ERROR(st);
821
9.32k
    }
822
9.32k
    return Base::close(state, exec_status);
823
9.32k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
5.16k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
5.16k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
5.16k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
5.16k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
5.16k
    if (_writer) {
810
5.16k
        Status st = _writer->get_writer_status();
811
5.16k
        if (exec_status.ok()) {
812
5.16k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
5.16k
                                                       : Status::Cancelled("force close"));
814
5.16k
        } else {
815
2
            _writer->force_close(exec_status);
816
2
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
5.16k
        RETURN_IF_ERROR(st);
821
5.16k
    }
822
5.16k
    return Base::close(state, exec_status);
823
5.16k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
3.39k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
3.39k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
3.39k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
3.39k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
3.39k
    if (_writer) {
810
3.38k
        Status st = _writer->get_writer_status();
811
3.39k
        if (exec_status.ok()) {
812
3.39k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
3.39k
                                                       : Status::Cancelled("force close"));
814
18.4E
        } else {
815
18.4E
            _writer->force_close(exec_status);
816
18.4E
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
3.38k
        RETURN_IF_ERROR(st);
821
3.38k
    }
822
3.39k
    return Base::close(state, exec_status);
823
3.39k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
32
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
32
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
32
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
32
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
32
    if (_writer) {
810
32
        Status st = _writer->get_writer_status();
811
32
        if (exec_status.ok()) {
812
32
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
32
                                                       : Status::Cancelled("force close"));
814
32
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
32
        RETURN_IF_ERROR(st);
821
32
    }
822
32
    return Base::close(state, exec_status);
823
32
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
160
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
160
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
160
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
160
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
160
    if (_writer) {
810
160
        Status st = _writer->get_writer_status();
811
160
        if (exec_status.ok()) {
812
160
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
160
                                                       : Status::Cancelled("force close"));
814
160
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
160
        RETURN_IF_ERROR(st);
821
160
    }
822
160
    return Base::close(state, exec_status);
823
160
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
640
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
640
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
640
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
640
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
640
    if (_writer) {
810
640
        Status st = _writer->get_writer_status();
811
640
        if (exec_status.ok()) {
812
640
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
640
                                                       : Status::Cancelled("force close"));
814
640
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
640
        RETURN_IF_ERROR(st);
821
640
    }
822
640
    return Base::close(state, exec_status);
823
640
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
156
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
156
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
156
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
156
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
156
    if (_writer) {
810
156
        Status st = _writer->get_writer_status();
811
156
        if (exec_status.ok()) {
812
156
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
156
                                                       : Status::Cancelled("force close"));
814
156
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
156
        RETURN_IF_ERROR(st);
821
156
    }
822
156
    return Base::close(state, exec_status);
823
156
}
824
825
#define DECLARE_OPERATOR(LOCAL_STATE) template class DataSinkOperatorX<LOCAL_STATE>;
826
DECLARE_OPERATOR(HashJoinBuildSinkLocalState)
827
DECLARE_OPERATOR(ResultSinkLocalState)
828
DECLARE_OPERATOR(JdbcTableSinkLocalState)
829
DECLARE_OPERATOR(MemoryScratchSinkLocalState)
830
DECLARE_OPERATOR(ResultFileSinkLocalState)
831
DECLARE_OPERATOR(OlapTableSinkLocalState)
832
DECLARE_OPERATOR(OlapTableSinkV2LocalState)
833
DECLARE_OPERATOR(HiveTableSinkLocalState)
834
DECLARE_OPERATOR(TVFTableSinkLocalState)
835
DECLARE_OPERATOR(IcebergTableSinkLocalState)
836
DECLARE_OPERATOR(SpillIcebergTableSinkLocalState)
837
DECLARE_OPERATOR(IcebergDeleteSinkLocalState)
838
DECLARE_OPERATOR(IcebergMergeSinkLocalState)
839
DECLARE_OPERATOR(MCTableSinkLocalState)
840
DECLARE_OPERATOR(AnalyticSinkLocalState)
841
DECLARE_OPERATOR(BlackholeSinkLocalState)
842
DECLARE_OPERATOR(SortSinkLocalState)
843
DECLARE_OPERATOR(SpillSortSinkLocalState)
844
DECLARE_OPERATOR(LocalExchangeSinkLocalState)
845
DECLARE_OPERATOR(AggSinkLocalState)
846
DECLARE_OPERATOR(BucketedAggSinkLocalState)
847
DECLARE_OPERATOR(PartitionedAggSinkLocalState)
848
DECLARE_OPERATOR(ExchangeSinkLocalState)
849
DECLARE_OPERATOR(NestedLoopJoinBuildSinkLocalState)
850
DECLARE_OPERATOR(UnionSinkLocalState)
851
DECLARE_OPERATOR(MultiCastDataStreamSinkLocalState)
852
DECLARE_OPERATOR(PartitionSortSinkLocalState)
853
DECLARE_OPERATOR(SetProbeSinkLocalState<true>)
854
DECLARE_OPERATOR(SetProbeSinkLocalState<false>)
855
DECLARE_OPERATOR(SetSinkLocalState<true>)
856
DECLARE_OPERATOR(SetSinkLocalState<false>)
857
DECLARE_OPERATOR(PartitionedHashJoinSinkLocalState)
858
DECLARE_OPERATOR(GroupCommitBlockSinkLocalState)
859
DECLARE_OPERATOR(CacheSinkLocalState)
860
DECLARE_OPERATOR(DictSinkLocalState)
861
DECLARE_OPERATOR(RecCTESinkLocalState)
862
DECLARE_OPERATOR(RecCTEAnchorSinkLocalState)
863
864
#undef DECLARE_OPERATOR
865
866
#define DECLARE_OPERATOR(LOCAL_STATE) template class OperatorX<LOCAL_STATE>;
867
DECLARE_OPERATOR(HashJoinProbeLocalState)
868
DECLARE_OPERATOR(OlapScanLocalState)
869
DECLARE_OPERATOR(GroupCommitLocalState)
870
DECLARE_OPERATOR(JDBCScanLocalState)
871
DECLARE_OPERATOR(FileScanLocalState)
872
DECLARE_OPERATOR(AnalyticLocalState)
873
DECLARE_OPERATOR(SortLocalState)
874
DECLARE_OPERATOR(SpillSortLocalState)
875
DECLARE_OPERATOR(LocalMergeSortLocalState)
876
DECLARE_OPERATOR(AggLocalState)
877
DECLARE_OPERATOR(BucketedAggLocalState)
878
DECLARE_OPERATOR(PartitionedAggLocalState)
879
DECLARE_OPERATOR(TableFunctionLocalState)
880
DECLARE_OPERATOR(ExchangeLocalState)
881
DECLARE_OPERATOR(RepeatLocalState)
882
DECLARE_OPERATOR(NestedLoopJoinProbeLocalState)
883
DECLARE_OPERATOR(AssertNumRowsLocalState)
884
DECLARE_OPERATOR(EmptySetLocalState)
885
DECLARE_OPERATOR(UnionSourceLocalState)
886
DECLARE_OPERATOR(MultiCastDataStreamSourceLocalState)
887
DECLARE_OPERATOR(PartitionSortSourceLocalState)
888
DECLARE_OPERATOR(SetSourceLocalState<true>)
889
DECLARE_OPERATOR(SetSourceLocalState<false>)
890
DECLARE_OPERATOR(DataGenLocalState)
891
DECLARE_OPERATOR(SchemaScanLocalState)
892
DECLARE_OPERATOR(MetaScanLocalState)
893
DECLARE_OPERATOR(LocalExchangeSourceLocalState)
894
DECLARE_OPERATOR(PartitionedHashJoinProbeLocalState)
895
DECLARE_OPERATOR(CacheSourceLocalState)
896
DECLARE_OPERATOR(RecCTESourceLocalState)
897
DECLARE_OPERATOR(RecCTEScanLocalState)
898
899
#ifdef BE_TEST
900
DECLARE_OPERATOR(MockLocalState)
901
DECLARE_OPERATOR(MockScanLocalState)
902
#endif
903
#undef DECLARE_OPERATOR
904
905
template class StreamingOperatorX<AssertNumRowsLocalState>;
906
template class StreamingOperatorX<SelectLocalState>;
907
908
template class StatefulOperatorX<HashJoinProbeLocalState>;
909
template class StatefulOperatorX<PartitionedHashJoinProbeLocalState>;
910
template class StatefulOperatorX<RepeatLocalState>;
911
template class StatefulOperatorX<MaterializationLocalState>;
912
template class StatefulOperatorX<StreamingAggLocalState>;
913
template class StatefulOperatorX<DistinctStreamingAggLocalState>;
914
template class StatefulOperatorX<NestedLoopJoinProbeLocalState>;
915
template class StatefulOperatorX<TableFunctionLocalState>;
916
917
template class PipelineXSinkLocalState<HashJoinSharedState>;
918
template class PipelineXSinkLocalState<PartitionedHashJoinSharedState>;
919
template class PipelineXSinkLocalState<SortSharedState>;
920
template class PipelineXSinkLocalState<SpillSortSharedState>;
921
template class PipelineXSinkLocalState<NestedLoopJoinSharedState>;
922
template class PipelineXSinkLocalState<AnalyticSharedState>;
923
template class PipelineXSinkLocalState<AggSharedState>;
924
template class PipelineXSinkLocalState<BucketedAggSharedState>;
925
template class PipelineXSinkLocalState<PartitionedAggSharedState>;
926
template class PipelineXSinkLocalState<FakeSharedState>;
927
template class PipelineXSinkLocalState<UnionSharedState>;
928
template class PipelineXSinkLocalState<PartitionSortNodeSharedState>;
929
template class PipelineXSinkLocalState<MultiCastSharedState>;
930
template class PipelineXSinkLocalState<SetSharedState>;
931
template class PipelineXSinkLocalState<LocalExchangeSharedState>;
932
template class PipelineXSinkLocalState<BasicSharedState>;
933
template class PipelineXSinkLocalState<DataQueueSharedState>;
934
template class PipelineXSinkLocalState<RecCTESharedState>;
935
936
template class PipelineXLocalState<HashJoinSharedState>;
937
template class PipelineXLocalState<PartitionedHashJoinSharedState>;
938
template class PipelineXLocalState<SortSharedState>;
939
template class PipelineXLocalState<SpillSortSharedState>;
940
template class PipelineXLocalState<NestedLoopJoinSharedState>;
941
template class PipelineXLocalState<AnalyticSharedState>;
942
template class PipelineXLocalState<AggSharedState>;
943
template class PipelineXLocalState<BucketedAggSharedState>;
944
template class PipelineXLocalState<PartitionedAggSharedState>;
945
template class PipelineXLocalState<FakeSharedState>;
946
template class PipelineXLocalState<UnionSharedState>;
947
template class PipelineXLocalState<DataQueueSharedState>;
948
template class PipelineXLocalState<MultiCastSharedState>;
949
template class PipelineXLocalState<PartitionSortNodeSharedState>;
950
template class PipelineXLocalState<SetSharedState>;
951
template class PipelineXLocalState<LocalExchangeSharedState>;
952
template class PipelineXLocalState<BasicSharedState>;
953
template class PipelineXLocalState<RecCTESharedState>;
954
955
template class AsyncWriterSink<doris::VFileResultWriter, ResultFileSinkOperatorX>;
956
template class AsyncWriterSink<doris::VJdbcTableWriter, JdbcTableSinkOperatorX>;
957
template class AsyncWriterSink<doris::VTabletWriter, OlapTableSinkOperatorX>;
958
template class AsyncWriterSink<doris::VTabletWriterV2, OlapTableSinkV2OperatorX>;
959
template class AsyncWriterSink<doris::VHiveTableWriter, HiveTableSinkOperatorX>;
960
template class AsyncWriterSink<doris::VIcebergTableWriter, IcebergTableSinkOperatorX>;
961
template class AsyncWriterSink<doris::VIcebergTableWriter, SpillIcebergTableSinkOperatorX>;
962
template class AsyncWriterSink<doris::VIcebergDeleteSink, IcebergDeleteSinkOperatorX>;
963
template class AsyncWriterSink<doris::VIcebergMergeSink, IcebergMergeSinkOperatorX>;
964
template class AsyncWriterSink<doris::VMCTableWriter, MCTableSinkOperatorX>;
965
template class AsyncWriterSink<doris::VTVFTableWriter, TVFTableSinkOperatorX>;
966
967
#ifdef BE_TEST
968
template class OperatorX<DummyOperatorLocalState>;
969
template class DataSinkOperatorX<DummySinkLocalState>;
970
#endif
971
972
} // namespace doris