Coverage Report

Created: 2026-07-30 18:21

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