Coverage Report

Created: 2026-06-16 16:04

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