Coverage Report

Created: 2026-07-27 13:51

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.29M
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
2.29M
    if (_parent->nereids_id() == -1) {
122
1.19M
        return fmt::format("(id={})", _parent->node_id());
123
1.19M
    } else {
124
1.10M
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
1.10M
    }
126
2.29M
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
66.9k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
66.9k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
66.9k
    } else {
124
66.9k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
66.9k
    }
126
66.9k
}
_ZNK5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
1
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
1
    if (_parent->nereids_id() == -1) {
122
1
        return fmt::format("(id={})", _parent->node_id());
123
1
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
1
}
_ZNK5doris19PipelineXLocalStateINS_15SortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
273k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
273k
    if (_parent->nereids_id() == -1) {
122
12
        return fmt::format("(id={})", _parent->node_id());
123
273k
    } else {
124
273k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
273k
    }
126
273k
}
_ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
28
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
28
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
28
    } else {
124
28
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
28
    }
126
28
}
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
9.91k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
9.91k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
9.91k
    } else {
124
9.91k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
9.91k
    }
126
9.91k
}
_ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
7.32k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
7.32k
    if (_parent->nereids_id() == -1) {
122
11
        return fmt::format("(id={})", _parent->node_id());
123
7.31k
    } else {
124
7.31k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
7.31k
    }
126
7.32k
}
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
161k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
161k
    if (_parent->nereids_id() == -1) {
122
29
        return fmt::format("(id={})", _parent->node_id());
123
161k
    } else {
124
161k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
161k
    }
126
161k
}
_ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
413
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
413
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
413
    } else {
124
413
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
413
    }
126
413
}
_ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
134
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
134
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
134
    } else {
124
134
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
134
    }
126
134
}
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
942k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
942k
    if (_parent->nereids_id() == -1) {
122
420k
        return fmt::format("(id={})", _parent->node_id());
123
522k
    } else {
124
522k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
522k
    }
126
942k
}
_ZNK5doris19PipelineXLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
56.2k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
56.2k
    if (_parent->nereids_id() == -1) {
122
2
        return fmt::format("(id={})", _parent->node_id());
123
56.2k
    } else {
124
56.2k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
56.2k
    }
126
56.2k
}
_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
10.7k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
10.7k
    if (_parent->nereids_id() == -1) {
122
10.7k
        return fmt::format("(id={})", _parent->node_id());
123
10.7k
    } else {
124
2
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
2
    }
126
10.7k
}
_ZNK5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
317
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
317
    if (_parent->nereids_id() == -1) {
122
102
        return fmt::format("(id={})", _parent->node_id());
123
215
    } else {
124
215
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
215
    }
126
317
}
_ZNK5doris19PipelineXLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
5.22k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
5.22k
    if (_parent->nereids_id() == -1) {
122
13
        return fmt::format("(id={})", _parent->node_id());
123
5.21k
    } else {
124
5.21k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
5.21k
    }
126
5.22k
}
_ZNK5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
763k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
763k
    if (_parent->nereids_id() == -1) {
122
762k
        return fmt::format("(id={})", _parent->node_id());
123
762k
    } else {
124
580
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
580
    }
126
763k
}
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.39M
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
1.39M
    if (_parent->nereids_id() == -1) {
131
821k
        return fmt::format("(id={})", _parent->node_id());
132
821k
    } else {
133
576k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
576k
    }
135
1.39M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
114k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
114k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
114k
    } else {
133
114k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
114k
    }
135
114k
}
_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
274k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
274k
    if (_parent->nereids_id() == -1) {
131
9
        return fmt::format("(id={})", _parent->node_id());
132
274k
    } else {
133
274k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
274k
    }
135
274k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
35
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
35
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
35
    } else {
133
35
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
35
    }
135
35
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
9.91k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
9.91k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
9.91k
    } else {
133
9.91k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
9.91k
    }
135
9.91k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
7.32k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
7.32k
    if (_parent->nereids_id() == -1) {
131
11
        return fmt::format("(id={})", _parent->node_id());
132
7.31k
    } else {
133
7.31k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
7.31k
    }
135
7.32k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
161k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
161k
    if (_parent->nereids_id() == -1) {
131
29
        return fmt::format("(id={})", _parent->node_id());
132
161k
    } else {
133
161k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
161k
    }
135
161k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
416
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
416
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
416
    } else {
133
416
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
416
    }
135
416
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
144
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
144
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
144
    } else {
133
144
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
144
    }
135
144
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
101
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
101
    if (_parent->nereids_id() == -1) {
131
101
        return fmt::format("(id={})", _parent->node_id());
132
101
    } else {
133
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
0
    }
135
101
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
6.36k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
6.36k
    if (_parent->nereids_id() == -1) {
131
3
        return fmt::format("(id={})", _parent->node_id());
132
6.36k
    } else {
133
6.36k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
6.36k
    }
135
6.36k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
319
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
319
    if (_parent->nereids_id() == -1) {
131
102
        return fmt::format("(id={})", _parent->node_id());
132
217
    } else {
133
217
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
217
    }
135
319
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE11name_suffixB5cxx11Ev
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
12.7k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
12.7k
    if (_parent->nereids_id() == -1) {
131
12.7k
        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
12.7k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
262k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
262k
    if (_parent->nereids_id() == -1) {
131
262k
        return fmt::format("(id={})", _parent->node_id());
132
262k
    } else {
133
59
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
59
    }
135
262k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
546k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
546k
    if (_parent->nereids_id() == -1) {
131
545k
        return fmt::format("(id={})", _parent->node_id());
132
545k
    } else {
133
646
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
646
    }
135
546k
}
_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
30.3k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
30.3k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
30.3k
    _terminated = true;
143
30.3k
    return Status::OK();
144
30.3k
}
_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.12k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
1.12k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
1.12k
    _terminated = true;
143
1.12k
    return Status::OK();
144
1.12k
}
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.82k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
2.82k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
2.82k
    _terminated = true;
143
2.82k
    return Status::OK();
144
2.82k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
4
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
4
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
4
    _terminated = true;
143
4
    return Status::OK();
144
4
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
1.20k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
1.20k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
1.20k
    _terminated = true;
143
1.20k
    return Status::OK();
144
1.20k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
55
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
55
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
55
    _terminated = true;
143
55
    return Status::OK();
144
55
}
_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
761
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
761
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
761
    _terminated = true;
143
761
    return Status::OK();
144
761
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
9
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
9
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
9
    _terminated = true;
143
9
    return Status::OK();
144
9
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
148
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
148
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
148
    _terminated = true;
143
148
    return Status::OK();
144
148
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
143
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
143
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
143
    _terminated = true;
143
143
    return Status::OK();
144
143
}
145
146
435k
DataDistribution OperatorBase::required_data_distribution(RuntimeState* /*state*/) const {
147
435k
    return _child && _child->is_serial_operator() && !is_source()
148
435k
                   ? DataDistribution(TLocalPartitionType::PASSTHROUGH)
149
435k
                   : DataDistribution(TLocalPartitionType::NOOP);
150
435k
}
151
152
41.2k
bool OperatorBase::child_breaks_local_key_distribution(RuntimeState* state) const {
153
41.2k
    if (!_child) {
154
36.1k
        return false;
155
36.1k
    }
156
5.04k
    if (_child->is_serial_operator()) {
157
138
        return true;
158
138
    }
159
4.91k
    const auto child_distribution = _child->required_data_distribution(state);
160
4.91k
    return child_distribution.need_local_exchange() &&
161
4.91k
           !is_shuffled_exchange(child_distribution.distribution_type);
162
5.04k
}
163
164
82.7k
const RowDescriptor& OperatorBase::row_desc() const {
165
82.7k
    return _child->row_desc();
166
82.7k
}
167
168
template <typename SharedStateArg>
169
19.9k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
19.9k
    fmt::memory_buffer debug_string_buffer;
171
19.9k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
19.9k
    return fmt::to_string(debug_string_buffer);
173
19.9k
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
114
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
114
    fmt::memory_buffer debug_string_buffer;
171
114
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
114
    return fmt::to_string(debug_string_buffer);
173
114
}
_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
42
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
42
    fmt::memory_buffer debug_string_buffer;
171
42
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
42
    return fmt::to_string(debug_string_buffer);
173
42
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
58
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
58
    fmt::memory_buffer debug_string_buffer;
171
58
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
58
    return fmt::to_string(debug_string_buffer);
173
58
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
74
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
74
    fmt::memory_buffer debug_string_buffer;
171
74
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
74
    return fmt::to_string(debug_string_buffer);
173
74
}
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
223
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
223
    fmt::memory_buffer debug_string_buffer;
171
223
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
223
    return fmt::to_string(debug_string_buffer);
173
223
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
174
175
template <typename SharedStateArg>
176
19.7k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
19.7k
    fmt::memory_buffer debug_string_buffer;
178
19.7k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
19.7k
    return fmt::to_string(debug_string_buffer);
180
19.7k
}
_ZNK5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
18
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
18
    fmt::memory_buffer debug_string_buffer;
178
18
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
18
    return fmt::to_string(debug_string_buffer);
180
18
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
42
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
42
    fmt::memory_buffer debug_string_buffer;
178
42
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
42
    return fmt::to_string(debug_string_buffer);
180
42
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
18
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
18
    fmt::memory_buffer debug_string_buffer;
178
18
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
18
    return fmt::to_string(debug_string_buffer);
180
18
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
74
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
74
    fmt::memory_buffer debug_string_buffer;
178
74
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
74
    return fmt::to_string(debug_string_buffer);
180
74
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
152
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
152
    fmt::memory_buffer debug_string_buffer;
178
152
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
152
    return fmt::to_string(debug_string_buffer);
180
152
}
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
132
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
132
    fmt::memory_buffer debug_string_buffer;
178
132
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
132
    return fmt::to_string(debug_string_buffer);
180
132
}
_ZNK5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
19.3k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
19.3k
    fmt::memory_buffer debug_string_buffer;
178
19.3k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
19.3k
    return fmt::to_string(debug_string_buffer);
180
19.3k
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
181
182
20.0k
std::string OperatorXBase::debug_string(int indentation_level) const {
183
20.0k
    fmt::memory_buffer debug_string_buffer;
184
20.0k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, parallel_tasks={}, _is_serial_operator={}",
185
20.0k
                   std::string(indentation_level * 2, ' '), _op_name, node_id(), _parallel_tasks,
186
20.0k
                   _is_serial_operator);
187
20.0k
    return fmt::to_string(debug_string_buffer);
188
20.0k
}
189
190
19.9k
std::string OperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
191
19.9k
    return state->get_local_state(operator_id())->debug_string(indentation_level);
192
19.9k
}
193
194
849k
Status OperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
195
849k
    std::string node_name = print_plan_node_type(tnode.node_type);
196
849k
    _nereids_id = tnode.nereids_id;
197
849k
    if (!tnode.intermediate_output_tuple_id_list.empty()) {
198
4.16k
        if (!tnode.__isset.output_tuple_id) {
199
0
            return Status::InternalError("no final output tuple id");
200
0
        }
201
4.16k
        if (tnode.intermediate_output_tuple_id_list.size() !=
202
4.16k
            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.16k
    }
210
849k
    auto substr = node_name.substr(0, node_name.find("_NODE"));
211
849k
    _op_name = substr + "_OPERATOR";
212
213
849k
    if (tnode.__isset.vconjunct) {
214
0
        return Status::InternalError("vconjunct is not supported yet");
215
849k
    } else if (tnode.__isset.conjuncts) {
216
484k
        for (const auto& conjunct : tnode.conjuncts) {
217
484k
            VExprContextSPtr context;
218
484k
            RETURN_IF_ERROR(VExpr::create_expr_tree(conjunct, context));
219
484k
            _conjuncts.emplace_back(context);
220
484k
        }
221
156k
    }
222
223
    // create the projections expr
224
849k
    if (tnode.__isset.projections) {
225
333k
        DCHECK(tnode.__isset.output_tuple_id);
226
333k
        RETURN_IF_ERROR(VExpr::create_expr_trees(tnode.projections, _projections));
227
333k
    }
228
849k
    if (!tnode.intermediate_projections_list.empty()) {
229
4.16k
        DCHECK(tnode.__isset.projections) << "no final projections";
230
4.16k
        _intermediate_projections.reserve(tnode.intermediate_projections_list.size());
231
8.52k
        for (const auto& tnode_projections : tnode.intermediate_projections_list) {
232
8.52k
            VExprContextSPtrs projections;
233
8.52k
            RETURN_IF_ERROR(VExpr::create_expr_trees(tnode_projections, projections));
234
8.52k
            _intermediate_projections.push_back(projections);
235
8.52k
        }
236
4.16k
    }
237
849k
    return Status::OK();
238
849k
}
239
240
882k
Status OperatorXBase::prepare(RuntimeState* state) {
241
882k
    for (auto& conjunct : _conjuncts) {
242
483k
        RETURN_IF_ERROR(conjunct->prepare(state, intermediate_row_desc()));
243
483k
    }
244
882k
    if (state->enable_adjust_conjunct_order_by_cost()) {
245
828k
        std::ranges::stable_sort(_conjuncts, [](const auto& a, const auto& b) {
246
642k
            return a->execute_cost() < b->execute_cost();
247
642k
        });
248
828k
    };
249
250
890k
    for (int i = 0; i < _intermediate_projections.size(); i++) {
251
8.52k
        RETURN_IF_ERROR(
252
8.52k
                VExpr::prepare(_intermediate_projections[i], state, intermediate_row_desc(i)));
253
8.52k
    }
254
882k
    RETURN_IF_ERROR(VExpr::prepare(_projections, state, projections_row_desc()));
255
256
882k
    if (has_output_row_desc()) {
257
332k
        RETURN_IF_ERROR(VExpr::check_expr_output_type(_projections, *_output_row_descriptor));
258
332k
    }
259
260
882k
    for (auto& conjunct : _conjuncts) {
261
484k
        RETURN_IF_ERROR(conjunct->open(state));
262
484k
    }
263
882k
    RETURN_IF_ERROR(VExpr::open(_projections, state));
264
882k
    for (auto& projections : _intermediate_projections) {
265
8.52k
        RETURN_IF_ERROR(VExpr::open(projections, state));
266
8.52k
    }
267
882k
    if (_child && !is_source()) {
268
135k
        RETURN_IF_ERROR(_child->prepare(state));
269
135k
    }
270
271
882k
    if (VExpr::contains_blockable_function(_conjuncts) ||
272
882k
        VExpr::contains_blockable_function(_projections)) {
273
0
        _blockable = true;
274
0
    }
275
276
882k
    return Status::OK();
277
882k
}
278
279
7.80k
Status OperatorXBase::terminate(RuntimeState* state) {
280
7.80k
    if (_child && !is_source()) {
281
1.49k
        RETURN_IF_ERROR(_child->terminate(state));
282
1.49k
    }
283
7.80k
    auto result = state->get_local_state_result(operator_id());
284
7.80k
    if (!result) {
285
0
        return result.error();
286
0
    }
287
7.80k
    return result.value()->terminate(state);
288
7.80k
}
289
290
6.45M
Status OperatorXBase::close(RuntimeState* state) {
291
6.45M
    if (_child && !is_source()) {
292
1.18M
        RETURN_IF_ERROR(_child->close(state));
293
1.18M
    }
294
6.45M
    auto result = state->get_local_state_result(operator_id());
295
6.45M
    if (!result) {
296
0
        return result.error();
297
0
    }
298
6.45M
    return result.value()->close(state);
299
6.45M
}
300
301
291k
void PipelineXLocalStateBase::clear_origin_block() {
302
291k
    _origin_block.clear_column_data(_parent->intermediate_row_desc().num_materialized_slots());
303
291k
}
304
305
613k
Status PipelineXLocalStateBase::filter_block(const VExprContextSPtrs& expr_contexts, Block* block) {
306
613k
    RETURN_IF_ERROR(VExprContext::filter_block(expr_contexts, block, block->columns()));
307
308
613k
    _estimate_memory_usage += VExprContext::get_memory_usage(expr_contexts);
309
613k
    return Status::OK();
310
613k
}
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
291k
                                     Block* output_block) const {
319
291k
    auto* local_state = state->get_local_state(operator_id());
320
291k
    SCOPED_TIMER(local_state->exec_time_counter());
321
291k
    SCOPED_TIMER(local_state->_projection_timer);
322
291k
    const size_t rows = origin_block->rows();
323
291k
    if (rows == 0) {
324
146k
        return Status::OK();
325
146k
    }
326
144k
    Block input_block = *origin_block;
327
328
144k
    size_t bytes_usage = 0;
329
144k
    ColumnsWithTypeAndName new_columns;
330
144k
    for (const auto& projections : local_state->_intermediate_projections) {
331
1.94k
        if (projections.empty()) {
332
0
            return Status::InternalError("meet empty intermediate projection, node id: {}",
333
0
                                         node_id());
334
0
        }
335
1.94k
        new_columns.resize(projections.size());
336
14.8k
        for (int i = 0; i < projections.size(); i++) {
337
12.9k
            RETURN_IF_ERROR(projections[i]->execute(&input_block, new_columns[i]));
338
12.9k
            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
12.9k
        }
346
1.94k
        Block tmp_block {new_columns};
347
1.94k
        bytes_usage += tmp_block.allocated_bytes();
348
1.94k
        input_block.swap(tmp_block);
349
1.94k
    }
350
351
144k
    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
672k
    auto insert_column_datas = [&](auto& to, ColumnPtr& from, size_t rows) {
358
672k
        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
672k
        } else {
368
672k
            if (_keep_origin || !from->is_exclusive()) {
369
672k
                to->insert_range_from(*from, 0, rows);
370
672k
                bytes_usage += from->allocated_bytes();
371
18.4E
            } else {
372
18.4E
                to = from->assert_mutable();
373
18.4E
            }
374
672k
        }
375
672k
    };
376
377
144k
    auto scoped_mutable_block = VectorizedUtils::build_scoped_mutable_mem_reuse_block(
378
144k
            output_block, *_output_row_descriptor);
379
144k
    auto& mutable_block = scoped_mutable_block.mutable_block();
380
144k
    auto& mutable_columns = mutable_block.mutable_columns();
381
144k
    if (rows != 0) {
382
144k
        DCHECK_EQ(mutable_columns.size(), local_state->_projections.size()) << debug_string();
383
816k
        for (int i = 0; i < mutable_columns.size(); ++i) {
384
672k
            ColumnPtr column_ptr;
385
672k
            RETURN_IF_ERROR(local_state->_projections[i]->execute(&input_block, column_ptr));
386
672k
            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
672k
            column_ptr = column_ptr->convert_to_full_column_if_const();
393
672k
            bytes_usage += column_ptr->allocated_bytes();
394
672k
            insert_column_datas(mutable_columns[i], column_ptr, rows);
395
672k
        }
396
144k
        DCHECK(mutable_block.rows() == rows);
397
144k
    }
398
144k
    local_state->_estimate_memory_usage += bytes_usage;
399
400
144k
    return Status::OK();
401
144k
}
402
403
4.89M
Status OperatorXBase::get_block_after_projects(RuntimeState* state, Block* block, bool* eos) {
404
4.89M
    DBUG_EXECUTE_IF("Pipeline::return_empty_block", {
405
4.89M
        if (this->_op_name == "AGGREGATION_OPERATOR" || this->_op_name == "HASH_JOIN_OPERATOR" ||
406
4.89M
            this->_op_name == "PARTITIONED_AGGREGATION_OPERATOR" ||
407
4.89M
            this->_op_name == "PARTITIONED_HASH_JOIN_OPERATOR" ||
408
4.89M
            this->_op_name == "CROSS_JOIN_OPERATOR" || this->_op_name == "SORT_OPERATOR") {
409
4.89M
            if (_debug_point_count++ % 2 == 0) {
410
4.89M
                return Status::OK();
411
4.89M
            }
412
4.89M
        }
413
4.89M
    });
414
415
4.89M
    Status status;
416
4.89M
    auto* local_state = state->get_local_state(operator_id());
417
4.90M
    Defer defer([&]() {
418
4.90M
        if (status.ok()) {
419
4.90M
            local_state->update_output_block_counters(*block);
420
4.90M
        }
421
4.90M
    });
422
4.89M
    if (_output_row_descriptor) {
423
291k
        local_state->clear_origin_block();
424
291k
        status = get_block(state, &local_state->_origin_block, eos);
425
291k
        if (UNLIKELY(!status.ok())) {
426
20
            return status;
427
20
        }
428
291k
        status = do_projections(state, &local_state->_origin_block, block);
429
291k
        return status;
430
291k
    }
431
4.60M
    status = get_block(state, block, eos);
432
4.60M
    RETURN_IF_ERROR(block->check_type_and_column());
433
4.60M
    return status;
434
4.60M
}
435
436
3.26M
void PipelineXLocalStateBase::reached_limit(Block* block, bool* eos) {
437
3.26M
    if (_parent->_limit != -1 and _num_rows_returned + block->rows() >= _parent->_limit) {
438
7.10k
        block->set_num_rows(_parent->_limit - _num_rows_returned);
439
7.10k
        *eos = true;
440
7.10k
    }
441
442
3.26M
    DBUG_EXECUTE_IF("Pipeline::reached_limit_early", {
443
3.26M
        auto op_name = to_lower(_parent->_op_name);
444
3.26M
        auto arg_op_name = dp->param<std::string>("op_name");
445
3.26M
        arg_op_name = to_lower(arg_op_name);
446
447
3.26M
        if (op_name == arg_op_name) {
448
3.26M
            *eos = true;
449
3.26M
        }
450
3.26M
    });
451
452
3.26M
    if (auto rows = block->rows()) {
453
911k
        _num_rows_returned += rows;
454
911k
        _state->get_query_ctx()->resource_ctx()->io_context()->update_process_rows(rows);
455
911k
    }
456
3.26M
}
457
458
30.3k
Status DataSinkOperatorXBase::terminate(RuntimeState* state) {
459
30.3k
    auto result = state->get_sink_local_state_result();
460
30.3k
    if (!result) {
461
0
        return result.error();
462
0
    }
463
30.3k
    return result.value()->terminate(state);
464
30.3k
}
465
466
19.8k
std::string DataSinkOperatorXBase::debug_string(int indentation_level) const {
467
19.8k
    fmt::memory_buffer debug_string_buffer;
468
469
19.8k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, _is_serial_operator={}",
470
19.8k
                   std::string(indentation_level * 2, ' '), _name, node_id(), _is_serial_operator);
471
19.8k
    return fmt::to_string(debug_string_buffer);
472
19.8k
}
473
474
19.7k
std::string DataSinkOperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
475
19.7k
    return state->get_sink_local_state()->debug_string(indentation_level);
476
19.7k
}
477
478
477k
Status DataSinkOperatorXBase::init(const TDataSink& tsink) {
479
477k
    std::string op_name = "UNKNOWN_SINK";
480
477k
    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
477k
    _name = op_name + "_OPERATOR";
486
477k
    return Status::OK();
487
477k
}
488
489
315k
Status DataSinkOperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
490
315k
    std::string op_name = print_plan_node_type(tnode.node_type);
491
315k
    _nereids_id = tnode.nereids_id;
492
315k
    auto substr = op_name.substr(0, op_name.find("_NODE"));
493
315k
    _name = substr + "_SINK_OPERATOR";
494
315k
    return Status::OK();
495
315k
}
496
497
template <typename LocalStateType>
498
Status DataSinkOperatorX<LocalStateType>::setup_local_state(RuntimeState* state,
499
2.14M
                                                            LocalSinkStateInfo& info) {
500
2.14M
    auto local_state = LocalStateType::create_unique(this, state);
501
2.14M
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.14M
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.14M
    return Status::OK();
504
2.14M
}
_ZN5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
114k
                                                            LocalSinkStateInfo& info) {
500
114k
    auto local_state = LocalStateType::create_unique(this, state);
501
114k
    RETURN_IF_ERROR(local_state->init(state, info));
502
114k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
114k
    return Status::OK();
504
114k
}
_ZN5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
476k
                                                            LocalSinkStateInfo& info) {
500
476k
    auto local_state = LocalStateType::create_unique(this, state);
501
476k
    RETURN_IF_ERROR(local_state->init(state, info));
502
476k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
476k
    return Status::OK();
504
476k
}
_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
511
                                                            LocalSinkStateInfo& info) {
500
511
    auto local_state = LocalStateType::create_unique(this, state);
501
511
    RETURN_IF_ERROR(local_state->init(state, info));
502
511
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
511
    return Status::OK();
504
511
}
_ZN5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
48.4k
                                                            LocalSinkStateInfo& info) {
500
48.4k
    auto local_state = LocalStateType::create_unique(this, state);
501
48.4k
    RETURN_IF_ERROR(local_state->init(state, info));
502
48.4k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
48.4k
    return Status::OK();
504
48.4k
}
_ZN5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.56k
                                                            LocalSinkStateInfo& info) {
500
9.56k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.56k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.56k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.56k
    return Status::OK();
504
9.56k
}
_ZN5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
5.02k
                                                            LocalSinkStateInfo& info) {
500
5.02k
    auto local_state = LocalStateType::create_unique(this, state);
501
5.02k
    RETURN_IF_ERROR(local_state->init(state, info));
502
5.02k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
5.02k
    return Status::OK();
504
5.02k
}
_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.00k
                                                            LocalSinkStateInfo& info) {
500
4.00k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.00k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.00k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.00k
    return Status::OK();
504
4.00k
}
_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.68k
                                                            LocalSinkStateInfo& info) {
500
1.68k
    auto local_state = LocalStateType::create_unique(this, state);
501
1.68k
    RETURN_IF_ERROR(local_state->init(state, info));
502
1.68k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
1.68k
    return Status::OK();
504
1.68k
}
Unexecuted instantiation: _ZN5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
7.31k
                                                            LocalSinkStateInfo& info) {
500
7.31k
    auto local_state = LocalStateType::create_unique(this, state);
501
7.31k
    RETURN_IF_ERROR(local_state->init(state, info));
502
7.31k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
7.31k
    return Status::OK();
504
7.31k
}
_ZN5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
98
                                                            LocalSinkStateInfo& info) {
500
98
    auto local_state = LocalStateType::create_unique(this, state);
501
98
    RETURN_IF_ERROR(local_state->init(state, info));
502
98
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
98
    return Status::OK();
504
98
}
_ZN5doris17DataSinkOperatorXINS_18SortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
274k
                                                            LocalSinkStateInfo& info) {
500
274k
    auto local_state = LocalStateType::create_unique(this, state);
501
274k
    RETURN_IF_ERROR(local_state->init(state, info));
502
274k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
274k
    return Status::OK();
504
274k
}
_ZN5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
35
                                                            LocalSinkStateInfo& info) {
500
35
    auto local_state = LocalStateType::create_unique(this, state);
501
35
    RETURN_IF_ERROR(local_state->init(state, info));
502
35
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
35
    return Status::OK();
504
35
}
_ZN5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
263k
                                                            LocalSinkStateInfo& info) {
500
263k
    auto local_state = LocalStateType::create_unique(this, state);
501
263k
    RETURN_IF_ERROR(local_state->init(state, info));
502
263k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
263k
    return Status::OK();
504
263k
}
_ZN5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
161k
                                                            LocalSinkStateInfo& info) {
500
161k
    auto local_state = LocalStateType::create_unique(this, state);
501
161k
    RETURN_IF_ERROR(local_state->init(state, info));
502
161k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
161k
    return Status::OK();
504
161k
}
_ZN5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
415
                                                            LocalSinkStateInfo& info) {
500
415
    auto local_state = LocalStateType::create_unique(this, state);
501
415
    RETURN_IF_ERROR(local_state->init(state, info));
502
415
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
415
    return Status::OK();
504
415
}
_ZN5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
144
                                                            LocalSinkStateInfo& info) {
500
144
    auto local_state = LocalStateType::create_unique(this, state);
501
144
    RETURN_IF_ERROR(local_state->init(state, info));
502
144
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
144
    return Status::OK();
504
144
}
_ZN5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
740k
                                                            LocalSinkStateInfo& info) {
500
740k
    auto local_state = LocalStateType::create_unique(this, state);
501
740k
    RETURN_IF_ERROR(local_state->init(state, info));
502
740k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
740k
    return Status::OK();
504
740k
}
_ZN5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.91k
                                                            LocalSinkStateInfo& info) {
500
9.91k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.91k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.91k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.91k
    return Status::OK();
504
9.91k
}
_ZN5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
6.36k
                                                            LocalSinkStateInfo& info) {
500
6.36k
    auto local_state = LocalStateType::create_unique(this, state);
501
6.36k
    RETURN_IF_ERROR(local_state->init(state, info));
502
6.36k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
6.36k
    return Status::OK();
504
6.36k
}
_ZN5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3.96k
                                                            LocalSinkStateInfo& info) {
500
3.96k
    auto local_state = LocalStateType::create_unique(this, state);
501
3.96k
    RETURN_IF_ERROR(local_state->init(state, info));
502
3.96k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3.96k
    return Status::OK();
504
3.96k
}
_ZN5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
217
                                                            LocalSinkStateInfo& info) {
500
217
    auto local_state = LocalStateType::create_unique(this, state);
501
217
    RETURN_IF_ERROR(local_state->init(state, info));
502
217
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
217
    return Status::OK();
504
217
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
4.90k
                                                            LocalSinkStateInfo& info) {
500
4.90k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.90k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.90k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.90k
    return Status::OK();
504
4.90k
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.58k
                                                            LocalSinkStateInfo& info) {
500
2.58k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.58k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.58k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.58k
    return Status::OK();
504
2.58k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.69k
                                                            LocalSinkStateInfo& info) {
500
2.69k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.69k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.69k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.69k
    return Status::OK();
504
2.69k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.50k
                                                            LocalSinkStateInfo& info) {
500
2.50k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.50k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.50k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.50k
    return Status::OK();
504
2.50k
}
_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
567
                                                            LocalSinkStateInfo& info) {
500
567
    auto local_state = LocalStateType::create_unique(this, state);
501
567
    RETURN_IF_ERROR(local_state->init(state, info));
502
567
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
567
    return Status::OK();
504
567
}
_ZN5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
14
                                                            LocalSinkStateInfo& info) {
500
14
    auto local_state = LocalStateType::create_unique(this, state);
501
14
    RETURN_IF_ERROR(local_state->init(state, info));
502
14
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
14
    return Status::OK();
504
14
}
_ZN5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
104
                                                            LocalSinkStateInfo& info) {
500
104
    auto local_state = LocalStateType::create_unique(this, state);
501
104
    RETURN_IF_ERROR(local_state->init(state, info));
502
104
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
104
    return Status::OK();
504
104
}
_ZN5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
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.84M
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.84M
    } else {
515
1.84M
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.84M
        ss->id = operator_id();
517
1.84M
        for (auto& dest : dests_id()) {
518
1.84M
            ss->related_op_ids.insert(dest);
519
1.84M
        }
520
1.84M
        return ss;
521
1.84M
    }
522
1.84M
}
_ZNK5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
99.5k
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
99.5k
    } else {
515
99.5k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
99.5k
        ss->id = operator_id();
517
99.5k
        for (auto& dest : dests_id()) {
518
99.4k
            ss->related_op_ids.insert(dest);
519
99.4k
        }
520
99.5k
        return ss;
521
99.5k
    }
522
99.5k
}
_ZNK5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
476k
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
476k
    } else {
515
476k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
476k
        ss->id = operator_id();
517
476k
        for (auto& dest : dests_id()) {
518
475k
            ss->related_op_ids.insert(dest);
519
475k
        }
520
476k
        return ss;
521
476k
    }
522
476k
}
_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
511
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
511
    } else {
515
511
        auto ss = LocalStateType::SharedStateType::create_shared();
516
511
        ss->id = operator_id();
517
511
        for (auto& dest : dests_id()) {
518
511
            ss->related_op_ids.insert(dest);
519
511
        }
520
511
        return ss;
521
511
    }
522
511
}
_ZNK5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
48.4k
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.4k
    } else {
515
48.4k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
48.4k
        ss->id = operator_id();
517
48.4k
        for (auto& dest : dests_id()) {
518
48.3k
            ss->related_op_ids.insert(dest);
519
48.3k
        }
520
48.4k
        return ss;
521
48.4k
    }
522
48.4k
}
_ZNK5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.56k
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.56k
    } else {
515
9.56k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.56k
        ss->id = operator_id();
517
9.56k
        for (auto& dest : dests_id()) {
518
9.56k
            ss->related_op_ids.insert(dest);
519
9.56k
        }
520
9.56k
        return ss;
521
9.56k
    }
522
9.56k
}
_ZNK5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
5.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
5.02k
    } else {
515
5.02k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
5.02k
        ss->id = operator_id();
517
5.02k
        for (auto& dest : dests_id()) {
518
5.02k
            ss->related_op_ids.insert(dest);
519
5.02k
        }
520
5.02k
        return ss;
521
5.02k
    }
522
5.02k
}
_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.00k
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.00k
    } else {
515
4.00k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
4.00k
        ss->id = operator_id();
517
4.00k
        for (auto& dest : dests_id()) {
518
4.00k
            ss->related_op_ids.insert(dest);
519
4.00k
        }
520
4.00k
        return ss;
521
4.00k
    }
522
4.00k
}
_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.68k
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.68k
    } else {
515
1.68k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.68k
        ss->id = operator_id();
517
1.68k
        for (auto& dest : dests_id()) {
518
1.68k
            ss->related_op_ids.insert(dest);
519
1.68k
        }
520
1.68k
        return ss;
521
1.68k
    }
522
1.68k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
7.33k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
7.33k
    } else {
515
7.33k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
7.33k
        ss->id = operator_id();
517
7.33k
        for (auto& dest : dests_id()) {
518
7.33k
            ss->related_op_ids.insert(dest);
519
7.33k
        }
520
7.33k
        return ss;
521
7.33k
    }
522
7.33k
}
_ZNK5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
98
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
98
    } else {
515
98
        auto ss = LocalStateType::SharedStateType::create_shared();
516
98
        ss->id = operator_id();
517
98
        for (auto& dest : dests_id()) {
518
98
            ss->related_op_ids.insert(dest);
519
98
        }
520
98
        return ss;
521
98
    }
522
98
}
_ZNK5doris17DataSinkOperatorXINS_18SortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
274k
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
274k
    } else {
515
274k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
274k
        ss->id = operator_id();
517
274k
        for (auto& dest : dests_id()) {
518
274k
            ss->related_op_ids.insert(dest);
519
274k
        }
520
274k
        return ss;
521
274k
    }
522
274k
}
_ZNK5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
37
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
37
    } else {
515
37
        auto ss = LocalStateType::SharedStateType::create_shared();
516
37
        ss->id = operator_id();
517
37
        for (auto& dest : dests_id()) {
518
37
            ss->related_op_ids.insert(dest);
519
37
        }
520
37
        return ss;
521
37
    }
522
37
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
161k
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
161k
    } else {
515
161k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
161k
        ss->id = operator_id();
517
161k
        for (auto& dest : dests_id()) {
518
161k
            ss->related_op_ids.insert(dest);
519
161k
        }
520
161k
        return ss;
521
161k
    }
522
161k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
143
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
143
    } else {
515
143
        auto ss = LocalStateType::SharedStateType::create_shared();
516
143
        ss->id = operator_id();
517
143
        for (auto& dest : dests_id()) {
518
143
            ss->related_op_ids.insert(dest);
519
143
        }
520
143
        return ss;
521
143
    }
522
143
}
_ZNK5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
739k
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
739k
    } else {
515
739k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
739k
        ss->id = operator_id();
517
739k
        for (auto& dest : dests_id()) {
518
737k
            ss->related_op_ids.insert(dest);
519
737k
        }
520
739k
        return ss;
521
739k
    }
522
739k
}
_ZNK5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.92k
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.92k
    } else {
515
9.92k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.92k
        ss->id = operator_id();
517
9.92k
        for (auto& dest : dests_id()) {
518
9.92k
            ss->related_op_ids.insert(dest);
519
9.92k
        }
520
9.92k
        return ss;
521
9.92k
    }
522
9.92k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
319
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
319
    } else {
515
319
        auto ss = LocalStateType::SharedStateType::create_shared();
516
319
        ss->id = operator_id();
517
319
        for (auto& dest : dests_id()) {
518
319
            ss->related_op_ids.insert(dest);
519
319
        }
520
319
        return ss;
521
319
    }
522
319
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE19create_shared_stateEv
Line
Count
Source
507
2.68k
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.68k
    } else {
515
2.68k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.68k
        ss->id = operator_id();
517
2.68k
        for (auto& dest : dests_id()) {
518
2.67k
            ss->related_op_ids.insert(dest);
519
2.67k
        }
520
2.68k
        return ss;
521
2.68k
    }
522
2.68k
}
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE19create_shared_stateEv
Line
Count
Source
507
2.49k
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.49k
    } else {
515
2.49k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.49k
        ss->id = operator_id();
517
2.49k
        for (auto& dest : dests_id()) {
518
2.48k
            ss->related_op_ids.insert(dest);
519
2.48k
        }
520
2.49k
        return ss;
521
2.49k
    }
522
2.49k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33PartitionedHashJoinSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_30GroupCommitBlockSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
568
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
568
    } else {
515
568
        auto ss = LocalStateType::SharedStateType::create_shared();
516
568
        ss->id = operator_id();
517
568
        for (auto& dest : dests_id()) {
518
565
            ss->related_op_ids.insert(dest);
519
565
        }
520
568
        return ss;
521
568
    }
522
568
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
104
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
104
    } else {
515
104
        auto ss = LocalStateType::SharedStateType::create_shared();
516
104
        ss->id = operator_id();
517
104
        for (auto& dest : dests_id()) {
518
104
            ss->related_op_ids.insert(dest);
519
104
        }
520
104
        return ss;
521
104
    }
522
104
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE19create_shared_stateEv
523
524
template <typename LocalStateType>
525
2.65M
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.65M
    auto local_state = LocalStateType::create_unique(state, this);
527
2.65M
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.65M
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.65M
    return Status::OK();
530
2.65M
}
_ZN5doris9OperatorXINS_23HashJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
66.9k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
66.9k
    auto local_state = LocalStateType::create_unique(state, this);
527
66.9k
    RETURN_IF_ERROR(local_state->init(state, info));
528
66.9k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
66.9k
    return Status::OK();
530
66.9k
}
_ZN5doris9OperatorXINS_18OlapScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
316k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
316k
    auto local_state = LocalStateType::create_unique(state, this);
527
316k
    RETURN_IF_ERROR(local_state->init(state, info));
528
316k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
316k
    return Status::OK();
530
316k
}
_ZN5doris9OperatorXINS_21GroupCommitLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
143
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
143
    auto local_state = LocalStateType::create_unique(state, this);
527
143
    RETURN_IF_ERROR(local_state->init(state, info));
528
143
    state->emplace_local_state(operator_id(), std::move(local_state));
529
143
    return Status::OK();
530
143
}
Unexecuted instantiation: _ZN5doris9OperatorXINS_18JDBCScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris9OperatorXINS_18FileScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
37.7k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
37.7k
    auto local_state = LocalStateType::create_unique(state, this);
527
37.7k
    RETURN_IF_ERROR(local_state->init(state, info));
528
37.7k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
37.7k
    return Status::OK();
530
37.7k
}
_ZN5doris9OperatorXINS_18AnalyticLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.30k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.30k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.30k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.30k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.30k
    return Status::OK();
530
7.30k
}
_ZN5doris9OperatorXINS_14SortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.60k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.60k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.60k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.60k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.60k
    return Status::OK();
530
7.60k
}
_ZN5doris9OperatorXINS_19SpillSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
28
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
28
    auto local_state = LocalStateType::create_unique(state, this);
527
28
    RETURN_IF_ERROR(local_state->init(state, info));
528
28
    state->emplace_local_state(operator_id(), std::move(local_state));
529
28
    return Status::OK();
530
28
}
_ZN5doris9OperatorXINS_24LocalMergeSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
266k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
266k
    auto local_state = LocalStateType::create_unique(state, this);
527
266k
    RETURN_IF_ERROR(local_state->init(state, info));
528
266k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
266k
    return Status::OK();
530
266k
}
_ZN5doris9OperatorXINS_13AggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
161k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
161k
    auto local_state = LocalStateType::create_unique(state, this);
527
161k
    RETURN_IF_ERROR(local_state->init(state, info));
528
161k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
161k
    return Status::OK();
530
161k
}
_ZN5doris9OperatorXINS_21BucketedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
414
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
414
    auto local_state = LocalStateType::create_unique(state, this);
527
414
    RETURN_IF_ERROR(local_state->init(state, info));
528
414
    state->emplace_local_state(operator_id(), std::move(local_state));
529
414
    return Status::OK();
530
414
}
_ZN5doris9OperatorXINS_24PartitionedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
134
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
134
    auto local_state = LocalStateType::create_unique(state, this);
527
134
    RETURN_IF_ERROR(local_state->init(state, info));
528
134
    state->emplace_local_state(operator_id(), std::move(local_state));
529
134
    return Status::OK();
530
134
}
_ZN5doris9OperatorXINS_23TableFunctionLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
3.79k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
3.79k
    auto local_state = LocalStateType::create_unique(state, this);
527
3.79k
    RETURN_IF_ERROR(local_state->init(state, info));
528
3.79k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
3.79k
    return Status::OK();
530
3.79k
}
_ZN5doris9OperatorXINS_18ExchangeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
420k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
420k
    auto local_state = LocalStateType::create_unique(state, this);
527
420k
    RETURN_IF_ERROR(local_state->init(state, info));
528
420k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
420k
    return Status::OK();
530
420k
}
_ZN5doris9OperatorXINS_16RepeatLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.05k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.05k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.05k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.05k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.05k
    return Status::OK();
530
1.05k
}
_ZN5doris9OperatorXINS_29NestedLoopJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
9.88k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
9.88k
    auto local_state = LocalStateType::create_unique(state, this);
527
9.88k
    RETURN_IF_ERROR(local_state->init(state, info));
528
9.88k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
9.88k
    return Status::OK();
530
9.88k
}
_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.98k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.98k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.98k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.98k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.98k
    return Status::OK();
530
1.98k
}
_ZN5doris9OperatorXINS_21UnionSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
56.3k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
56.3k
    auto local_state = LocalStateType::create_unique(state, this);
527
56.3k
    RETURN_IF_ERROR(local_state->init(state, info));
528
56.3k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
56.3k
    return Status::OK();
530
56.3k
}
_ZN5doris9OperatorXINS_35MultiCastDataStreamSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
10.7k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
10.7k
    auto local_state = LocalStateType::create_unique(state, this);
527
10.7k
    RETURN_IF_ERROR(local_state->init(state, info));
528
10.7k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
10.7k
    return Status::OK();
530
10.7k
}
_ZN5doris9OperatorXINS_29PartitionSortSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
215
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
215
    auto local_state = LocalStateType::create_unique(state, this);
527
215
    RETURN_IF_ERROR(local_state->init(state, info));
528
215
    state->emplace_local_state(operator_id(), std::move(local_state));
529
215
    return Status::OK();
530
215
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.70k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.70k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.70k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.70k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.70k
    return Status::OK();
530
2.70k
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.51k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.51k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.51k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.51k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.51k
    return Status::OK();
530
2.51k
}
_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.21k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.21k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.21k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.21k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.21k
    return Status::OK();
530
2.21k
}
_ZN5doris9OperatorXINS_18MetaScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.04k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.04k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.04k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.04k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.04k
    return Status::OK();
530
7.04k
}
_ZN5doris9OperatorXINS_29LocalExchangeSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
765k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
765k
    auto local_state = LocalStateType::create_unique(state, this);
527
765k
    RETURN_IF_ERROR(local_state->init(state, info));
528
765k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
765k
    return Status::OK();
530
765k
}
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.73k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.73k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.73k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.73k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.73k
    return Status::OK();
530
1.73k
}
_ZN5doris9OperatorXINS_16SelectLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.93k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.93k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.93k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.93k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.93k
    return Status::OK();
530
2.93k
}
_ZN5doris9OperatorXINS_22StreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
13.1k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
13.1k
    auto local_state = LocalStateType::create_unique(state, this);
527
13.1k
    RETURN_IF_ERROR(local_state->init(state, info));
528
13.1k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
13.1k
    return Status::OK();
530
13.1k
}
_ZN5doris9OperatorXINS_30DistinctStreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
489k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
489k
    auto local_state = LocalStateType::create_unique(state, this);
527
489k
    RETURN_IF_ERROR(local_state->init(state, info));
528
489k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
489k
    return Status::OK();
530
489k
}
531
532
PipelineXSinkLocalStateBase::PipelineXSinkLocalStateBase(DataSinkOperatorXBase* parent,
533
                                                         RuntimeState* state)
534
2.14M
        : _parent(parent), _state(state) {}
535
536
PipelineXLocalStateBase::PipelineXLocalStateBase(RuntimeState* state, OperatorXBase* parent)
537
2.65M
        : _num_rows_returned(0),
538
2.65M
          _rows_returned_counter(nullptr),
539
2.65M
          _parent(parent),
540
2.65M
          _state(state),
541
2.65M
          _budget(state->batch_size(), state->preferred_block_size_bytes()) {}
542
543
template <typename SharedStateArg>
544
2.66M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
2.66M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
2.66M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
2.66M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
2.66M
    _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.66M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
2.66M
    _operator_profile->add_child(_common_profile.get(), true);
553
2.66M
    _operator_profile->add_child(_custom_profile.get(), true);
554
2.66M
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
2.66M
    if constexpr (!is_fake_shared) {
556
1.36M
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
779k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
779k
                                    .first.get()
559
779k
                                    ->template cast<SharedStateArg>();
560
561
779k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
779k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
779k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
779k
        } else if (info.shared_state) {
565
520k
            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
520k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
520k
            _dependency = _shared_state->create_source_dependency(
572
520k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
520k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
520k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
520k
        } else {
576
62.4k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
4.87k
                DCHECK(false);
578
4.87k
            }
579
62.4k
        }
580
1.36M
    }
581
582
2.66M
    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.66M
    _rows_returned_counter =
587
2.66M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
2.66M
    _blocks_returned_counter =
589
2.66M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
2.66M
    _output_block_bytes_counter =
591
2.66M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
2.66M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
2.66M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
2.66M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
2.66M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
2.66M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
2.66M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
2.66M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
2.66M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
2.66M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
2.66M
    _memory_used_counter =
602
2.66M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
2.66M
    _common_profile->add_info_string("IsColocate",
604
2.66M
                                     std::to_string(_parent->is_colocated_operator()));
605
2.66M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
2.66M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
2.66M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
2.66M
    return Status::OK();
609
2.66M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
67.0k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
67.0k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
67.0k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
67.0k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
67.0k
    _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
67.0k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
67.0k
    _operator_profile->add_child(_common_profile.get(), true);
553
67.0k
    _operator_profile->add_child(_custom_profile.get(), true);
554
67.0k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
67.0k
    if constexpr (!is_fake_shared) {
556
67.0k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
15.5k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
15.5k
                                    .first.get()
559
15.5k
                                    ->template cast<SharedStateArg>();
560
561
15.5k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
15.5k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
15.5k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
51.5k
        } 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
51.1k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
51.1k
            _dependency = _shared_state->create_source_dependency(
572
51.1k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
51.1k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
51.1k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
51.1k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
380
        }
580
67.0k
    }
581
582
67.0k
    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
67.0k
    _rows_returned_counter =
587
67.0k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
67.0k
    _blocks_returned_counter =
589
67.0k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
67.0k
    _output_block_bytes_counter =
591
67.0k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
67.0k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
67.0k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
67.0k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
67.0k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
67.0k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
67.0k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
67.0k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
67.0k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
67.0k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
67.0k
    _memory_used_counter =
602
67.0k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
67.0k
    _common_profile->add_info_string("IsColocate",
604
67.0k
                                     std::to_string(_parent->is_colocated_operator()));
605
67.0k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
67.0k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
67.0k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
67.0k
    return Status::OK();
609
67.0k
}
_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
274k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
274k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
274k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
274k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
274k
    _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
274k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
274k
    _operator_profile->add_child(_common_profile.get(), true);
553
274k
    _operator_profile->add_child(_custom_profile.get(), true);
554
274k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
274k
    if constexpr (!is_fake_shared) {
556
274k
        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
274k
        } 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
271k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
271k
            _dependency = _shared_state->create_source_dependency(
572
271k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
271k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
271k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
271k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
2.86k
        }
580
274k
    }
581
582
274k
    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
274k
    _rows_returned_counter =
587
274k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
274k
    _blocks_returned_counter =
589
274k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
274k
    _output_block_bytes_counter =
591
274k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
274k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
274k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
274k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
274k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
274k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
274k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
274k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
274k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
274k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
274k
    _memory_used_counter =
602
274k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
274k
    _common_profile->add_info_string("IsColocate",
604
274k
                                     std::to_string(_parent->is_colocated_operator()));
605
274k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
274k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
274k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
274k
    return Status::OK();
609
274k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
28
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
28
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
28
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
28
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
28
    _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
28
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
28
    _operator_profile->add_child(_common_profile.get(), true);
553
28
    _operator_profile->add_child(_custom_profile.get(), true);
554
28
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
28
    if constexpr (!is_fake_shared) {
556
28
        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
28
        } 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
28
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
28
            _dependency = _shared_state->create_source_dependency(
572
28
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
28
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
28
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
28
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
28
    }
581
582
28
    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
28
    _rows_returned_counter =
587
28
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
28
    _blocks_returned_counter =
589
28
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
28
    _output_block_bytes_counter =
591
28
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
28
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
28
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
28
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
28
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
28
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
28
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
28
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
28
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
28
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
28
    _memory_used_counter =
602
28
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
28
    _common_profile->add_info_string("IsColocate",
604
28
                                     std::to_string(_parent->is_colocated_operator()));
605
28
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
28
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
28
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
28
    return Status::OK();
609
28
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
9.92k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
9.92k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
9.92k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
9.92k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
9.92k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
9.92k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
9.92k
    _operator_profile->add_child(_common_profile.get(), true);
553
9.92k
    _operator_profile->add_child(_custom_profile.get(), true);
554
9.92k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
9.92k
    if constexpr (!is_fake_shared) {
556
9.92k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
9.92k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
9.86k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
9.86k
            _dependency = _shared_state->create_source_dependency(
572
9.86k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
9.86k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
9.86k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
9.86k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
64
        }
580
9.92k
    }
581
582
9.92k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
9.92k
    _rows_returned_counter =
587
9.92k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
9.92k
    _blocks_returned_counter =
589
9.92k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
9.92k
    _output_block_bytes_counter =
591
9.92k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
9.92k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
9.92k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
9.92k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
9.92k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
9.92k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
9.92k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
9.92k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
9.92k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
9.92k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
9.92k
    _memory_used_counter =
602
9.92k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
9.92k
    _common_profile->add_info_string("IsColocate",
604
9.92k
                                     std::to_string(_parent->is_colocated_operator()));
605
9.92k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
9.92k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
9.92k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
9.92k
    return Status::OK();
609
9.92k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
7.34k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
7.34k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
7.34k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
7.34k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
7.34k
    _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
7.34k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
7.34k
    _operator_profile->add_child(_common_profile.get(), true);
553
7.34k
    _operator_profile->add_child(_custom_profile.get(), true);
554
7.34k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
7.34k
    if constexpr (!is_fake_shared) {
556
7.34k
        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
7.34k
        } 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
7.30k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
7.30k
            _dependency = _shared_state->create_source_dependency(
572
7.30k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
7.30k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
7.30k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
7.30k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
34
        }
580
7.34k
    }
581
582
7.34k
    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
7.34k
    _rows_returned_counter =
587
7.34k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
7.34k
    _blocks_returned_counter =
589
7.34k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
7.34k
    _output_block_bytes_counter =
591
7.34k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
7.34k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
7.34k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
7.34k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
7.34k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
7.34k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
7.34k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
7.34k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
7.34k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
7.34k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
7.34k
    _memory_used_counter =
602
7.34k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
7.34k
    _common_profile->add_info_string("IsColocate",
604
7.34k
                                     std::to_string(_parent->is_colocated_operator()));
605
7.34k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
7.34k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
7.34k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
7.34k
    return Status::OK();
609
7.34k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
161k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
161k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
161k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
161k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
161k
    _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
161k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
161k
    _operator_profile->add_child(_common_profile.get(), true);
553
161k
    _operator_profile->add_child(_custom_profile.get(), true);
554
161k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
161k
    if constexpr (!is_fake_shared) {
556
161k
        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
161k
        } 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
160k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
160k
            _dependency = _shared_state->create_source_dependency(
572
160k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
160k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
160k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
160k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
804
        }
580
161k
    }
581
582
161k
    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
161k
    _rows_returned_counter =
587
161k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
161k
    _blocks_returned_counter =
589
161k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
161k
    _output_block_bytes_counter =
591
161k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
161k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
161k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
161k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
161k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
161k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
161k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
161k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
161k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
161k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
161k
    _memory_used_counter =
602
161k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
161k
    _common_profile->add_info_string("IsColocate",
604
161k
                                     std::to_string(_parent->is_colocated_operator()));
605
161k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
161k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
161k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
161k
    return Status::OK();
609
161k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
416
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
416
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
416
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
416
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
416
    _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
416
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
416
    _operator_profile->add_child(_common_profile.get(), true);
553
416
    _operator_profile->add_child(_custom_profile.get(), true);
554
416
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
416
    if constexpr (!is_fake_shared) {
556
416
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
414
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
414
                                    .first.get()
559
414
                                    ->template cast<SharedStateArg>();
560
561
414
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
414
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
414
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
414
        } 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
2
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
2
        }
580
416
    }
581
582
416
    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
416
    _rows_returned_counter =
587
416
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
416
    _blocks_returned_counter =
589
416
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
416
    _output_block_bytes_counter =
591
416
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
416
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
416
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
416
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
416
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
416
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
416
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
416
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
416
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
416
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
416
    _memory_used_counter =
602
416
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
416
    _common_profile->add_info_string("IsColocate",
604
416
                                     std::to_string(_parent->is_colocated_operator()));
605
416
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
416
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
416
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
416
    return Status::OK();
609
416
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
134
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
134
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
134
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
134
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
134
    _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
134
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
134
    _operator_profile->add_child(_common_profile.get(), true);
553
134
    _operator_profile->add_child(_custom_profile.get(), true);
554
134
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
134
    if constexpr (!is_fake_shared) {
556
134
        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
134
        } 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
134
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
134
            _dependency = _shared_state->create_source_dependency(
572
134
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
134
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
134
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
134
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
134
    }
581
582
134
    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
134
    _rows_returned_counter =
587
134
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
134
    _blocks_returned_counter =
589
134
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
134
    _output_block_bytes_counter =
591
134
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
134
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
134
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
134
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
134
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
134
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
134
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
134
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
134
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
134
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
134
    _memory_used_counter =
602
134
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
134
    _common_profile->add_info_string("IsColocate",
604
134
                                     std::to_string(_parent->is_colocated_operator()));
605
134
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
134
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
134
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
134
    return Status::OK();
609
134
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1.30M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1.30M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1.30M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1.30M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1.30M
    _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.30M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1.30M
    _operator_profile->add_child(_common_profile.get(), true);
553
1.30M
    _operator_profile->add_child(_custom_profile.get(), true);
554
1.30M
    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.30M
    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.30M
    _rows_returned_counter =
587
1.30M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1.30M
    _blocks_returned_counter =
589
1.30M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1.30M
    _output_block_bytes_counter =
591
1.30M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1.30M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1.30M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1.30M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1.30M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1.30M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1.30M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1.30M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1.30M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1.30M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1.30M
    _memory_used_counter =
602
1.30M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1.30M
    _common_profile->add_info_string("IsColocate",
604
1.30M
                                     std::to_string(_parent->is_colocated_operator()));
605
1.30M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1.30M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1.30M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1.30M
    return Status::OK();
609
1.30M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
56.3k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
56.3k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
56.3k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
56.3k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
56.3k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
56.3k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
56.3k
    _operator_profile->add_child(_common_profile.get(), true);
553
56.3k
    _operator_profile->add_child(_custom_profile.get(), true);
554
56.3k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
56.3k
    if constexpr (!is_fake_shared) {
556
56.3k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
56.3k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
2.90k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
2.90k
            _dependency = _shared_state->create_source_dependency(
572
2.90k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
2.90k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
2.90k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
53.3k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
53.3k
        }
580
56.3k
    }
581
582
56.3k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
56.3k
    _rows_returned_counter =
587
56.3k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
56.3k
    _blocks_returned_counter =
589
56.3k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
56.3k
    _output_block_bytes_counter =
591
56.3k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
56.3k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
56.3k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
56.3k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
56.3k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
56.3k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
56.3k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
56.3k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
56.3k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
56.3k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
56.3k
    _memory_used_counter =
602
56.3k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
56.3k
    _common_profile->add_info_string("IsColocate",
604
56.3k
                                     std::to_string(_parent->is_colocated_operator()));
605
56.3k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
56.3k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
56.3k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
56.3k
    return Status::OK();
609
56.3k
}
_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
10.7k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
10.7k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
10.7k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
10.7k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
10.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
10.7k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
10.7k
    _operator_profile->add_child(_common_profile.get(), true);
553
10.7k
    _operator_profile->add_child(_custom_profile.get(), true);
554
10.7k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
10.7k
    if constexpr (!is_fake_shared) {
556
10.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
10.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
10.7k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
10.7k
            _dependency = _shared_state->create_source_dependency(
572
10.7k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
10.7k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
10.7k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
10.7k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
26
        }
580
10.7k
    }
581
582
10.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
10.7k
    _rows_returned_counter =
587
10.7k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
10.7k
    _blocks_returned_counter =
589
10.7k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
10.7k
    _output_block_bytes_counter =
591
10.7k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
10.7k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
10.7k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
10.7k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
10.7k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
10.7k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
10.7k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
10.7k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
10.7k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
10.7k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
10.7k
    _memory_used_counter =
602
10.7k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
10.7k
    _common_profile->add_info_string("IsColocate",
604
10.7k
                                     std::to_string(_parent->is_colocated_operator()));
605
10.7k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
10.7k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
10.7k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
10.7k
    return Status::OK();
609
10.7k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
317
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
317
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
317
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
317
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
317
    _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
317
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
317
    _operator_profile->add_child(_common_profile.get(), true);
553
317
    _operator_profile->add_child(_custom_profile.get(), true);
554
317
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
317
    if constexpr (!is_fake_shared) {
556
317
        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
317
        } 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
317
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
317
            _dependency = _shared_state->create_source_dependency(
572
317
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
317
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
317
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
317
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
317
    }
581
582
317
    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
317
    _rows_returned_counter =
587
317
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
317
    _blocks_returned_counter =
589
317
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
317
    _output_block_bytes_counter =
591
317
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
317
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
317
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
317
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
317
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
317
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
317
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
317
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
317
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
317
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
317
    _memory_used_counter =
602
317
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
317
    _common_profile->add_info_string("IsColocate",
604
317
                                     std::to_string(_parent->is_colocated_operator()));
605
317
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
317
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
317
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
317
    return Status::OK();
609
317
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
5.23k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
5.23k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
5.23k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
5.23k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
5.23k
    _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.23k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
5.23k
    _operator_profile->add_child(_common_profile.get(), true);
553
5.23k
    _operator_profile->add_child(_custom_profile.get(), true);
554
5.23k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
5.23k
    if constexpr (!is_fake_shared) {
556
5.23k
        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.23k
        } 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
5.20k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
25
        }
580
5.23k
    }
581
582
5.23k
    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.23k
    _rows_returned_counter =
587
5.23k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
5.23k
    _blocks_returned_counter =
589
5.23k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
5.23k
    _output_block_bytes_counter =
591
5.23k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
5.23k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
5.23k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
5.23k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
5.23k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
5.23k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
5.23k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
5.23k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
5.23k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
5.23k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
5.23k
    _memory_used_counter =
602
5.23k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
5.23k
    _common_profile->add_info_string("IsColocate",
604
5.23k
                                     std::to_string(_parent->is_colocated_operator()));
605
5.23k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
5.23k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
5.23k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
5.23k
    return Status::OK();
609
5.23k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
768k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
768k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
768k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
768k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
768k
    _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
768k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
768k
    _operator_profile->add_child(_common_profile.get(), true);
553
768k
    _operator_profile->add_child(_custom_profile.get(), true);
554
768k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
768k
    if constexpr (!is_fake_shared) {
556
768k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
763k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
763k
                                    .first.get()
559
763k
                                    ->template cast<SharedStateArg>();
560
561
763k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
763k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
763k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
763k
        } 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
4.87k
        } else {
576
4.87k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
4.87k
                DCHECK(false);
578
4.87k
            }
579
4.87k
        }
580
768k
    }
581
582
768k
    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
768k
    _rows_returned_counter =
587
768k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
768k
    _blocks_returned_counter =
589
768k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
768k
    _output_block_bytes_counter =
591
768k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
768k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
768k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
768k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
768k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
768k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
768k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
768k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
768k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
768k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
768k
    _memory_used_counter =
602
768k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
768k
    _common_profile->add_info_string("IsColocate",
604
768k
                                     std::to_string(_parent->is_colocated_operator()));
605
768k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
768k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
768k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
768k
    return Status::OK();
609
768k
}
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.66M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
2.66M
    _conjuncts.resize(_parent->_conjuncts.size());
614
2.66M
    _projections.resize(_parent->_projections.size());
615
3.20M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
537k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
537k
    }
618
5.46M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.79M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.79M
    }
621
2.66M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
2.68M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
14.8k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
110k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
95.7k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
95.7k
                    state, _intermediate_projections[i][j]));
627
95.7k
        }
628
14.8k
    }
629
2.66M
    return Status::OK();
630
2.66M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
67.0k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
67.0k
    _conjuncts.resize(_parent->_conjuncts.size());
614
67.0k
    _projections.resize(_parent->_projections.size());
615
67.6k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
541
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
541
    }
618
322k
    for (size_t i = 0; i < _projections.size(); i++) {
619
254k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
254k
    }
621
67.0k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
70.1k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
3.04k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
39.7k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
36.7k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
36.7k
                    state, _intermediate_projections[i][j]));
627
36.7k
        }
628
3.04k
    }
629
67.0k
    return Status::OK();
630
67.0k
}
_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
274k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
274k
    _conjuncts.resize(_parent->_conjuncts.size());
614
274k
    _projections.resize(_parent->_projections.size());
615
274k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
275k
    for (size_t i = 0; i < _projections.size(); i++) {
619
365
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
365
    }
621
274k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
274k
    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
274k
    return Status::OK();
630
274k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
28
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
28
    _conjuncts.resize(_parent->_conjuncts.size());
614
28
    _projections.resize(_parent->_projections.size());
615
28
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
28
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
28
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
28
    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
28
    return Status::OK();
630
28
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
9.93k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
9.93k
    _conjuncts.resize(_parent->_conjuncts.size());
614
9.93k
    _projections.resize(_parent->_projections.size());
615
9.99k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
61
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
61
    }
618
61.9k
    for (size_t i = 0; i < _projections.size(); i++) {
619
52.0k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
52.0k
    }
621
9.93k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
10.0k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
146
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
900
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
754
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
754
                    state, _intermediate_projections[i][j]));
627
754
        }
628
146
    }
629
9.93k
    return Status::OK();
630
9.93k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
7.34k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
7.34k
    _conjuncts.resize(_parent->_conjuncts.size());
614
7.34k
    _projections.resize(_parent->_projections.size());
615
8.05k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
706
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
706
    }
618
20.0k
    for (size_t i = 0; i < _projections.size(); i++) {
619
12.7k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
12.7k
    }
621
7.34k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
7.42k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
83
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
624
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
541
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
541
                    state, _intermediate_projections[i][j]));
627
541
        }
628
83
    }
629
7.34k
    return Status::OK();
630
7.34k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
161k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
161k
    _conjuncts.resize(_parent->_conjuncts.size());
614
161k
    _projections.resize(_parent->_projections.size());
615
165k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
4.12k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
4.12k
    }
618
425k
    for (size_t i = 0; i < _projections.size(); i++) {
619
264k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
264k
    }
621
161k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
161k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
266
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
1.92k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
1.65k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
1.65k
                    state, _intermediate_projections[i][j]));
627
1.65k
        }
628
266
    }
629
161k
    return Status::OK();
630
161k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
416
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
416
    _conjuncts.resize(_parent->_conjuncts.size());
614
416
    _projections.resize(_parent->_projections.size());
615
422
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
6
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
6
    }
618
1.63k
    for (size_t i = 0; i < _projections.size(); i++) {
619
1.22k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
1.22k
    }
621
416
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
416
    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
416
    return Status::OK();
630
416
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
138
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
138
    _conjuncts.resize(_parent->_conjuncts.size());
614
138
    _projections.resize(_parent->_projections.size());
615
138
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
358
    for (size_t i = 0; i < _projections.size(); i++) {
619
220
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
220
    }
621
138
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
138
    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
138
    return Status::OK();
630
138
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
1.30M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
1.30M
    _conjuncts.resize(_parent->_conjuncts.size());
614
1.30M
    _projections.resize(_parent->_projections.size());
615
1.83M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
527k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
527k
    }
618
3.42M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.11M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.11M
    }
621
1.30M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
1.31M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
11.3k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
67.3k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
55.9k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
55.9k
                    state, _intermediate_projections[i][j]));
627
55.9k
        }
628
11.3k
    }
629
1.30M
    return Status::OK();
630
1.30M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
56.3k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
56.3k
    _conjuncts.resize(_parent->_conjuncts.size());
614
56.3k
    _projections.resize(_parent->_projections.size());
615
56.3k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
152k
    for (size_t i = 0; i < _projections.size(); i++) {
619
96.4k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
96.4k
    }
621
56.3k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
56.3k
    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
56.3k
    return Status::OK();
630
56.3k
}
_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
10.7k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
10.7k
    _conjuncts.resize(_parent->_conjuncts.size());
614
10.7k
    _projections.resize(_parent->_projections.size());
615
14.9k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
4.18k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
4.18k
    }
618
10.7k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
10.7k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
10.7k
    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
10.7k
    return Status::OK();
630
10.7k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
319
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
319
    _conjuncts.resize(_parent->_conjuncts.size());
614
319
    _projections.resize(_parent->_projections.size());
615
319
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
319
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
319
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
319
    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
319
    return Status::OK();
630
319
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
5.24k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
5.24k
    _conjuncts.resize(_parent->_conjuncts.size());
614
5.24k
    _projections.resize(_parent->_projections.size());
615
5.24k
    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.40k
    for (size_t i = 0; i < _projections.size(); i++) {
619
166
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
166
    }
621
5.24k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
5.24k
    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.24k
    return Status::OK();
630
5.24k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
769k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
769k
    _conjuncts.resize(_parent->_conjuncts.size());
614
769k
    _projections.resize(_parent->_projections.size());
615
769k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
769k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
769k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
769k
    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
769k
    return Status::OK();
630
769k
}
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
7.80k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
7.80k
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
7.80k
    _terminated = true;
638
7.80k
    return Status::OK();
639
7.80k
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
355
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
355
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
355
    _terminated = true;
638
355
    return Status::OK();
639
355
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
69
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
69
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
69
    _terminated = true;
638
69
    return Status::OK();
639
69
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
115
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
115
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
115
    _terminated = true;
638
115
    return Status::OK();
639
115
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
353
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
353
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
353
    _terminated = true;
638
353
    return Status::OK();
639
353
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
2
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
2
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
2
    _terminated = true;
638
2
    return Status::OK();
639
2
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
5.92k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
5.92k
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
5.92k
    _terminated = true;
638
5.92k
    return Status::OK();
639
5.92k
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
2
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
2
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
2
    _terminated = true;
638
2
    return Status::OK();
639
2
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
15
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
15
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
15
    _terminated = true;
638
15
    return Status::OK();
639
15
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
23
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
23
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
23
    _terminated = true;
638
23
    return Status::OK();
639
23
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
931
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
931
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
931
    _terminated = true;
638
931
    return Status::OK();
639
931
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
11
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
11
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
11
    _terminated = true;
638
11
    return Status::OK();
639
11
}
640
641
template <typename SharedStateArg>
642
2.97M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
2.97M
    if (_closed) {
644
305k
        return Status::OK();
645
305k
    }
646
2.66M
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
1.36M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
1.36M
    }
649
2.66M
    _closed = true;
650
2.66M
    return Status::OK();
651
2.97M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
67.0k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
67.0k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
67.0k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
67.0k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
67.0k
    }
649
67.0k
    _closed = true;
650
67.0k
    return Status::OK();
651
67.0k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
4
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
4
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
4
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
4
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
4
    }
649
4
    _closed = true;
650
4
    return Status::OK();
651
4
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
546k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
546k
    if (_closed) {
644
273k
        return Status::OK();
645
273k
    }
646
273k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
273k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
273k
    }
649
273k
    _closed = true;
650
273k
    return Status::OK();
651
546k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
28
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
28
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
28
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
28
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
28
    }
649
28
    _closed = true;
650
28
    return Status::OK();
651
28
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
9.93k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
9.93k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
9.93k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
9.93k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
9.93k
    }
649
9.93k
    _closed = true;
650
9.93k
    return Status::OK();
651
9.93k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
14.7k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
14.7k
    if (_closed) {
644
7.45k
        return Status::OK();
645
7.45k
    }
646
7.33k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
7.33k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
7.33k
    }
649
7.33k
    _closed = true;
650
7.33k
    return Status::OK();
651
14.7k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
161k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
161k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
161k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
161k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
161k
    }
649
161k
    _closed = true;
650
161k
    return Status::OK();
651
161k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
417
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
417
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
417
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
417
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
417
    }
649
417
    _closed = true;
650
417
    return Status::OK();
651
417
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
133
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
133
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
133
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
133
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
133
    }
649
133
    _closed = true;
650
133
    return Status::OK();
651
133
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
1.32M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
1.32M
    if (_closed) {
644
18.0k
        return Status::OK();
645
18.0k
    }
646
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
    }
649
1.30M
    _closed = true;
650
1.30M
    return Status::OK();
651
1.32M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
56.3k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
56.3k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
56.3k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
56.3k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
56.3k
    }
649
56.3k
    _closed = true;
650
56.3k
    return Status::OK();
651
56.3k
}
_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
10.7k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
10.7k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
10.7k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
10.7k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
10.7k
    }
649
10.7k
    _closed = true;
650
10.7k
    return Status::OK();
651
10.7k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
434
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
434
    if (_closed) {
644
217
        return Status::OK();
645
217
    }
646
217
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
217
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
217
    }
649
217
    _closed = true;
650
217
    return Status::OK();
651
434
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
10.8k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
10.8k
    if (_closed) {
644
5.63k
        return Status::OK();
645
5.63k
    }
646
5.22k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
5.22k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
5.22k
    }
649
5.22k
    _closed = true;
650
5.22k
    return Status::OK();
651
10.8k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
770k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
770k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
770k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
770k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
770k
    }
649
770k
    _closed = true;
650
770k
    return Status::OK();
651
770k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
333
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
333
    if (_closed) {
644
178
        return Status::OK();
645
178
    }
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
333
}
652
653
template <typename SharedState>
654
2.14M
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
2.14M
    _operator_profile =
657
2.14M
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
2.14M
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
2.14M
    _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.14M
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
2.14M
    _operator_profile->add_child(_common_profile, true);
666
2.14M
    _operator_profile->add_child(_custom_profile, true);
667
668
2.14M
    _operator_profile->set_metadata(_parent->node_id());
669
2.14M
    _wait_for_finish_dependency_timer =
670
2.14M
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
2.14M
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
2.14M
    if constexpr (!is_fake_shared) {
673
1.40M
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
1.40M
            info.shared_state_map.end()) {
675
279k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
263k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
263k
            }
678
279k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
279k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
279k
                                                  ? 0
681
279k
                                                  : info.task_idx]
682
279k
                                  .get();
683
279k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
1.12M
        } else {
685
1.12M
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
6
                DCHECK(false);
687
6
            }
688
1.12M
            _shared_state = info.shared_state->template cast<SharedState>();
689
1.12M
            _dependency = _shared_state->create_sink_dependency(
690
1.12M
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
1.12M
        }
692
1.40M
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
1.40M
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
1.40M
    }
695
696
2.14M
    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.14M
    _rows_input_counter =
701
2.14M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
2.14M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
2.14M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
2.14M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
2.14M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
2.14M
    _memory_used_counter =
707
2.14M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
2.14M
    _common_profile->add_info_string("IsColocate",
709
2.14M
                                     std::to_string(_parent->is_colocated_operator()));
710
2.14M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
2.14M
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
2.14M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
2.14M
    return Status::OK();
714
2.14M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
115k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
115k
    _operator_profile =
657
115k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
115k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
115k
    _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
115k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
115k
    _operator_profile->add_child(_common_profile, true);
666
115k
    _operator_profile->add_child(_custom_profile, true);
667
668
115k
    _operator_profile->set_metadata(_parent->node_id());
669
115k
    _wait_for_finish_dependency_timer =
670
115k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
115k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
115k
    if constexpr (!is_fake_shared) {
673
115k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
115k
            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
15.5k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
15.5k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
15.5k
                                                  ? 0
681
15.5k
                                                  : info.task_idx]
682
15.5k
                                  .get();
683
15.5k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
99.4k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
99.4k
            _shared_state = info.shared_state->template cast<SharedState>();
689
99.4k
            _dependency = _shared_state->create_sink_dependency(
690
99.4k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
99.4k
        }
692
115k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
115k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
115k
    }
695
696
115k
    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
115k
    _rows_input_counter =
701
115k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
115k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
115k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
115k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
115k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
115k
    _memory_used_counter =
707
115k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
115k
    _common_profile->add_info_string("IsColocate",
709
115k
                                     std::to_string(_parent->is_colocated_operator()));
710
115k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
115k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
115k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
115k
    return Status::OK();
714
115k
}
_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
274k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
274k
    _operator_profile =
657
274k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
274k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
274k
    _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
274k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
274k
    _operator_profile->add_child(_common_profile, true);
666
274k
    _operator_profile->add_child(_custom_profile, true);
667
668
274k
    _operator_profile->set_metadata(_parent->node_id());
669
274k
    _wait_for_finish_dependency_timer =
670
274k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
274k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
274k
    if constexpr (!is_fake_shared) {
673
274k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
274k
            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
274k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
274k
            _shared_state = info.shared_state->template cast<SharedState>();
689
274k
            _dependency = _shared_state->create_sink_dependency(
690
274k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
274k
        }
692
274k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
274k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
274k
    }
695
696
274k
    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
274k
    _rows_input_counter =
701
274k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
274k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
274k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
274k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
274k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
274k
    _memory_used_counter =
707
274k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
274k
    _common_profile->add_info_string("IsColocate",
709
274k
                                     std::to_string(_parent->is_colocated_operator()));
710
274k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
274k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
274k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
274k
    return Status::OK();
714
274k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
35
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
35
    _operator_profile =
657
35
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
35
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
35
    _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
35
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
35
    _operator_profile->add_child(_common_profile, true);
666
35
    _operator_profile->add_child(_custom_profile, true);
667
668
35
    _operator_profile->set_metadata(_parent->node_id());
669
35
    _wait_for_finish_dependency_timer =
670
35
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
35
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
35
    if constexpr (!is_fake_shared) {
673
35
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
35
            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
35
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
35
            _shared_state = info.shared_state->template cast<SharedState>();
689
35
            _dependency = _shared_state->create_sink_dependency(
690
35
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
35
        }
692
35
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
35
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
35
    }
695
696
35
    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
35
    _rows_input_counter =
701
35
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
35
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
35
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
35
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
35
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
35
    _memory_used_counter =
707
35
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
35
    _common_profile->add_info_string("IsColocate",
709
35
                                     std::to_string(_parent->is_colocated_operator()));
710
35
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
35
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
35
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
35
    return Status::OK();
714
35
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
9.91k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
9.91k
    _operator_profile =
657
9.91k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
9.91k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
9.91k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
9.91k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
9.91k
    _operator_profile->add_child(_common_profile, true);
666
9.91k
    _operator_profile->add_child(_custom_profile, true);
667
668
9.91k
    _operator_profile->set_metadata(_parent->node_id());
669
9.91k
    _wait_for_finish_dependency_timer =
670
9.91k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
9.91k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
9.91k
    if constexpr (!is_fake_shared) {
673
9.91k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
9.91k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
9.91k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
9.91k
            _shared_state = info.shared_state->template cast<SharedState>();
689
9.91k
            _dependency = _shared_state->create_sink_dependency(
690
9.91k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
9.91k
        }
692
9.91k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
9.91k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
9.91k
    }
695
696
9.91k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
9.91k
    _rows_input_counter =
701
9.91k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
9.91k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
9.91k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
9.91k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
9.91k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
9.91k
    _memory_used_counter =
707
9.91k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
9.91k
    _common_profile->add_info_string("IsColocate",
709
9.91k
                                     std::to_string(_parent->is_colocated_operator()));
710
9.91k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
9.91k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
9.91k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
9.91k
    return Status::OK();
714
9.91k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
7.34k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
7.34k
    _operator_profile =
657
7.34k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
7.34k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
7.34k
    _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.34k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
7.34k
    _operator_profile->add_child(_common_profile, true);
666
7.34k
    _operator_profile->add_child(_custom_profile, true);
667
668
7.34k
    _operator_profile->set_metadata(_parent->node_id());
669
7.34k
    _wait_for_finish_dependency_timer =
670
7.34k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
7.34k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
7.34k
    if constexpr (!is_fake_shared) {
673
7.34k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
7.34k
            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.34k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
7.34k
            _shared_state = info.shared_state->template cast<SharedState>();
689
7.34k
            _dependency = _shared_state->create_sink_dependency(
690
7.34k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
7.34k
        }
692
7.34k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
7.34k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
7.34k
    }
695
696
7.34k
    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.34k
    _rows_input_counter =
701
7.34k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
7.34k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
7.34k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
7.34k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
7.34k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
7.34k
    _memory_used_counter =
707
7.34k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
7.34k
    _common_profile->add_info_string("IsColocate",
709
7.34k
                                     std::to_string(_parent->is_colocated_operator()));
710
7.34k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
7.34k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
7.34k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
7.34k
    return Status::OK();
714
7.34k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
161k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
161k
    _operator_profile =
657
161k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
161k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
161k
    _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
161k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
161k
    _operator_profile->add_child(_common_profile, true);
666
161k
    _operator_profile->add_child(_custom_profile, true);
667
668
161k
    _operator_profile->set_metadata(_parent->node_id());
669
161k
    _wait_for_finish_dependency_timer =
670
161k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
161k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
161k
    if constexpr (!is_fake_shared) {
673
161k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
161k
            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
161k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
161k
            _shared_state = info.shared_state->template cast<SharedState>();
689
161k
            _dependency = _shared_state->create_sink_dependency(
690
161k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
161k
        }
692
161k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
161k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
161k
    }
695
696
161k
    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
161k
    _rows_input_counter =
701
161k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
161k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
161k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
161k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
161k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
161k
    _memory_used_counter =
707
161k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
161k
    _common_profile->add_info_string("IsColocate",
709
161k
                                     std::to_string(_parent->is_colocated_operator()));
710
161k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
161k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
161k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
161k
    return Status::OK();
714
161k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
417
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
417
    _operator_profile =
657
417
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
417
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
417
    _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
417
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
417
    _operator_profile->add_child(_common_profile, true);
666
417
    _operator_profile->add_child(_custom_profile, true);
667
668
417
    _operator_profile->set_metadata(_parent->node_id());
669
417
    _wait_for_finish_dependency_timer =
670
417
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
417
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
417
    if constexpr (!is_fake_shared) {
673
417
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
417
            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
417
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
417
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
417
                                                  ? 0
681
417
                                                  : info.task_idx]
682
417
                                  .get();
683
417
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
417
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
0
            _shared_state = info.shared_state->template cast<SharedState>();
689
0
            _dependency = _shared_state->create_sink_dependency(
690
0
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
0
        }
692
417
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
417
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
417
    }
695
696
417
    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
417
    _rows_input_counter =
701
417
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
417
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
417
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
417
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
417
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
417
    _memory_used_counter =
707
417
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
417
    _common_profile->add_info_string("IsColocate",
709
417
                                     std::to_string(_parent->is_colocated_operator()));
710
417
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
417
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
417
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
417
    return Status::OK();
714
417
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
144
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
144
    _operator_profile =
657
144
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
144
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
144
    _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
144
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
144
    _operator_profile->add_child(_common_profile, true);
666
144
    _operator_profile->add_child(_custom_profile, true);
667
668
144
    _operator_profile->set_metadata(_parent->node_id());
669
144
    _wait_for_finish_dependency_timer =
670
144
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
144
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
144
    if constexpr (!is_fake_shared) {
673
144
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
144
            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
144
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
144
            _shared_state = info.shared_state->template cast<SharedState>();
689
144
            _dependency = _shared_state->create_sink_dependency(
690
144
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
144
        }
692
144
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
144
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
144
    }
695
696
144
    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
144
    _rows_input_counter =
701
144
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
144
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
144
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
144
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
144
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
144
    _memory_used_counter =
707
144
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
144
    _common_profile->add_info_string("IsColocate",
709
144
                                     std::to_string(_parent->is_colocated_operator()));
710
144
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
144
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
144
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
144
    return Status::OK();
714
144
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
742k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
742k
    _operator_profile =
657
742k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
742k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
742k
    _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
742k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
742k
    _operator_profile->add_child(_common_profile, true);
666
742k
    _operator_profile->add_child(_custom_profile, true);
667
668
742k
    _operator_profile->set_metadata(_parent->node_id());
669
742k
    _wait_for_finish_dependency_timer =
670
742k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
742k
    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
742k
    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
742k
    _rows_input_counter =
701
742k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
742k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
742k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
742k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
742k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
742k
    _memory_used_counter =
707
742k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
742k
    _common_profile->add_info_string("IsColocate",
709
742k
                                     std::to_string(_parent->is_colocated_operator()));
710
742k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
742k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
742k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
742k
    return Status::OK();
714
742k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
6.38k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
6.38k
    _operator_profile =
657
6.38k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
6.38k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
6.38k
    _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
6.38k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
6.38k
    _operator_profile->add_child(_common_profile, true);
666
6.38k
    _operator_profile->add_child(_custom_profile, true);
667
668
6.38k
    _operator_profile->set_metadata(_parent->node_id());
669
6.38k
    _wait_for_finish_dependency_timer =
670
6.38k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
6.38k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
6.38k
    if constexpr (!is_fake_shared) {
673
6.38k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
6.38k
            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
6.38k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
6.38k
            _shared_state = info.shared_state->template cast<SharedState>();
689
6.38k
            _dependency = _shared_state->create_sink_dependency(
690
6.38k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
6.38k
        }
692
6.38k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
6.38k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
6.38k
    }
695
696
6.38k
    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
6.38k
    _rows_input_counter =
701
6.38k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
6.38k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
6.38k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
6.38k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
6.38k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
6.38k
    _memory_used_counter =
707
6.38k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
6.38k
    _common_profile->add_info_string("IsColocate",
709
6.38k
                                     std::to_string(_parent->is_colocated_operator()));
710
6.38k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
6.38k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
6.38k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
6.38k
    return Status::OK();
714
6.38k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
317
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
317
    _operator_profile =
657
317
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
317
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
317
    _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
317
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
317
    _operator_profile->add_child(_common_profile, true);
666
317
    _operator_profile->add_child(_custom_profile, true);
667
668
317
    _operator_profile->set_metadata(_parent->node_id());
669
317
    _wait_for_finish_dependency_timer =
670
317
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
317
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
317
    if constexpr (!is_fake_shared) {
673
317
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
317
            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
317
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
317
            _shared_state = info.shared_state->template cast<SharedState>();
689
317
            _dependency = _shared_state->create_sink_dependency(
690
317
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
317
        }
692
317
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
317
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
317
    }
695
696
318
    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
317
    _rows_input_counter =
701
317
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
317
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
317
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
317
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
317
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
317
    _memory_used_counter =
707
317
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
317
    _common_profile->add_info_string("IsColocate",
709
317
                                     std::to_string(_parent->is_colocated_operator()));
710
317
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
317
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
317
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
317
    return Status::OK();
714
317
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
3.96k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
3.96k
    _operator_profile =
657
3.96k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
3.96k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
3.96k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
3.96k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
3.96k
    _operator_profile->add_child(_common_profile, true);
666
3.96k
    _operator_profile->add_child(_custom_profile, true);
667
668
3.96k
    _operator_profile->set_metadata(_parent->node_id());
669
3.96k
    _wait_for_finish_dependency_timer =
670
3.96k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
3.96k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
3.96k
    if constexpr (!is_fake_shared) {
673
3.96k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
3.96k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
3.96k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
3.96k
            _shared_state = info.shared_state->template cast<SharedState>();
689
3.96k
            _dependency = _shared_state->create_sink_dependency(
690
3.96k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
3.96k
        }
692
3.96k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
3.96k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
3.96k
    }
695
696
3.96k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
3.96k
    _rows_input_counter =
701
3.96k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
3.96k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
3.96k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
3.96k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
3.96k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
3.96k
    _memory_used_counter =
707
3.96k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
3.96k
    _common_profile->add_info_string("IsColocate",
709
3.96k
                                     std::to_string(_parent->is_colocated_operator()));
710
3.96k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
3.96k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
3.96k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
3.96k
    return Status::OK();
714
3.96k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
12.7k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
12.7k
    _operator_profile =
657
12.7k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
12.7k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
12.7k
    _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.7k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
12.7k
    _operator_profile->add_child(_common_profile, true);
666
12.7k
    _operator_profile->add_child(_custom_profile, true);
667
668
12.7k
    _operator_profile->set_metadata(_parent->node_id());
669
12.7k
    _wait_for_finish_dependency_timer =
670
12.7k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
12.7k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
12.7k
    if constexpr (!is_fake_shared) {
673
12.7k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
12.7k
            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.7k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
12.7k
            _shared_state = info.shared_state->template cast<SharedState>();
689
12.7k
            _dependency = _shared_state->create_sink_dependency(
690
12.7k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
12.7k
        }
692
12.7k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
12.7k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
12.7k
    }
695
696
12.7k
    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.7k
    _rows_input_counter =
701
12.7k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
12.7k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
12.7k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
12.7k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
12.7k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
12.7k
    _memory_used_counter =
707
12.7k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
12.7k
    _common_profile->add_info_string("IsColocate",
709
12.7k
                                     std::to_string(_parent->is_colocated_operator()));
710
12.7k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
12.7k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
12.7k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
12.7k
    return Status::OK();
714
12.7k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
263k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
263k
    _operator_profile =
657
263k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
263k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
263k
    _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
263k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
263k
    _operator_profile->add_child(_common_profile, true);
666
263k
    _operator_profile->add_child(_custom_profile, true);
667
668
263k
    _operator_profile->set_metadata(_parent->node_id());
669
263k
    _wait_for_finish_dependency_timer =
670
263k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
263k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
263k
    if constexpr (!is_fake_shared) {
673
263k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
263k
            info.shared_state_map.end()) {
675
263k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
263k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
263k
            }
678
263k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
263k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
263k
                                                  ? 0
681
263k
                                                  : info.task_idx]
682
263k
                                  .get();
683
263k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
263k
        } else {
685
6
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
6
                DCHECK(false);
687
6
            }
688
6
            _shared_state = info.shared_state->template cast<SharedState>();
689
6
            _dependency = _shared_state->create_sink_dependency(
690
6
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
6
        }
692
263k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
263k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
263k
    }
695
696
263k
    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
263k
    _rows_input_counter =
701
263k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
263k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
263k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
263k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
263k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
263k
    _memory_used_counter =
707
263k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
263k
    _common_profile->add_info_string("IsColocate",
709
263k
                                     std::to_string(_parent->is_colocated_operator()));
710
263k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
263k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
263k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
263k
    return Status::OK();
714
263k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
547k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
547k
    _operator_profile =
657
547k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
547k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
547k
    _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
547k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
547k
    _operator_profile->add_child(_common_profile, true);
666
547k
    _operator_profile->add_child(_custom_profile, true);
667
668
547k
    _operator_profile->set_metadata(_parent->node_id());
669
547k
    _wait_for_finish_dependency_timer =
670
547k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
547k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
547k
    if constexpr (!is_fake_shared) {
673
547k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
547k
            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
547k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
547k
            _shared_state = info.shared_state->template cast<SharedState>();
689
547k
            _dependency = _shared_state->create_sink_dependency(
690
547k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
547k
        }
692
547k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
547k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
547k
    }
695
696
547k
    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
547k
    _rows_input_counter =
701
547k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
547k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
547k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
547k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
547k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
547k
    _memory_used_counter =
707
547k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
547k
    _common_profile->add_info_string("IsColocate",
709
547k
                                     std::to_string(_parent->is_colocated_operator()));
710
547k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
547k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
547k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
547k
    return Status::OK();
714
547k
}
_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.14M
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
2.14M
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
2.14M
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
1.40M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
1.40M
    }
724
2.14M
    _closed = true;
725
2.14M
    return Status::OK();
726
2.14M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
115k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
115k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
115k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
115k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
115k
    }
724
115k
    _closed = true;
725
115k
    return Status::OK();
726
115k
}
_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
274k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
274k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
274k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
274k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
274k
    }
724
274k
    _closed = true;
725
274k
    return Status::OK();
726
274k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
26
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
26
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
24
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
24
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
24
    }
724
24
    _closed = true;
725
24
    return Status::OK();
726
26
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
9.92k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
9.92k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
9.92k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
9.92k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
9.92k
    }
724
9.92k
    _closed = true;
725
9.92k
    return Status::OK();
726
9.92k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
7.32k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
7.32k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
7.32k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
7.32k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
7.32k
    }
724
7.32k
    _closed = true;
725
7.32k
    return Status::OK();
726
7.32k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
160k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
160k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
160k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
160k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
160k
    }
724
160k
    _closed = true;
725
160k
    return Status::OK();
726
160k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
414
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
414
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
414
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
414
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
414
    }
724
414
    _closed = true;
725
414
    return Status::OK();
726
414
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
133
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
133
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
133
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
133
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
133
    }
724
133
    _closed = true;
725
133
    return Status::OK();
726
133
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
742k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
742k
    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
742k
    _closed = true;
725
742k
    return Status::OK();
726
742k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
6.37k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
6.37k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
6.37k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
6.37k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
6.37k
    }
724
6.37k
    _closed = true;
725
6.37k
    return Status::OK();
726
6.37k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
217
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
217
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
217
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
217
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
217
    }
724
217
    _closed = true;
725
217
    return Status::OK();
726
217
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
3.97k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
3.97k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
3.97k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
3.97k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
3.97k
    }
724
3.97k
    _closed = true;
725
3.97k
    return Status::OK();
726
3.97k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
12.7k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
12.7k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
12.7k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
12.7k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
12.7k
    }
724
12.7k
    _closed = true;
725
12.7k
    return Status::OK();
726
12.7k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
263k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
263k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
263k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
263k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
263k
    }
724
263k
    _closed = true;
725
263k
    return Status::OK();
726
263k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
549k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
549k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
549k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
549k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
549k
    }
724
549k
    _closed = true;
725
549k
    return Status::OK();
726
549k
}
_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.6k
                                                          bool* eos) {
731
15.6k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
15.6k
    return pull(state, block, eos);
733
15.6k
}
_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
15.2k
                                                          bool* eos) {
731
15.2k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
15.2k
    return pull(state, block, eos);
733
15.2k
}
734
735
template <typename LocalStateType>
736
Status StatefulOperatorX<LocalStateType>::get_block_impl(RuntimeState* state, Block* block,
737
779k
                                                         bool* eos) {
738
779k
    auto& local_state = get_local_state(state);
739
779k
    if (need_more_input_data(state)) {
740
751k
        local_state._child_block->clear_column_data(
741
751k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
751k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
751k
                state, local_state._child_block.get(), &local_state._child_eos));
744
751k
        *eos = local_state._child_eos;
745
751k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
81.7k
            return Status::OK();
747
81.7k
        }
748
670k
        {
749
670k
            SCOPED_TIMER(local_state.exec_time_counter());
750
670k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
670k
        }
752
670k
    }
753
754
698k
    if (!need_more_input_data(state)) {
755
641k
        SCOPED_TIMER(local_state.exec_time_counter());
756
641k
        bool new_eos = false;
757
641k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
641k
        if (new_eos) {
759
562k
            *eos = true;
760
562k
        } else if (!need_more_input_data(state)) {
761
23.4k
            *eos = false;
762
23.4k
        }
763
641k
    }
764
698k
    return Status::OK();
765
698k
}
_ZN5doris17StatefulOperatorXINS_23HashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
137k
                                                         bool* eos) {
738
137k
    auto& local_state = get_local_state(state);
739
137k
    if (need_more_input_data(state)) {
740
121k
        local_state._child_block->clear_column_data(
741
121k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
121k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
121k
                state, local_state._child_block.get(), &local_state._child_eos));
744
121k
        *eos = local_state._child_eos;
745
121k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
38.0k
            return Status::OK();
747
38.0k
        }
748
83.4k
        {
749
83.4k
            SCOPED_TIMER(local_state.exec_time_counter());
750
83.4k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
83.4k
        }
752
83.4k
    }
753
754
99.1k
    if (!need_more_input_data(state)) {
755
99.1k
        SCOPED_TIMER(local_state.exec_time_counter());
756
99.1k
        bool new_eos = false;
757
99.1k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
99.1k
        if (new_eos) {
759
42.8k
            *eos = true;
760
56.2k
        } else if (!need_more_input_data(state)) {
761
10.1k
            *eos = false;
762
10.1k
        }
763
99.1k
    }
764
99.1k
    return Status::OK();
765
99.1k
}
Unexecuted instantiation: _ZN5doris17StatefulOperatorXINS_34PartitionedHashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
_ZN5doris17StatefulOperatorXINS_16RepeatLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.00k
                                                         bool* eos) {
738
4.00k
    auto& local_state = get_local_state(state);
739
4.00k
    if (need_more_input_data(state)) {
740
2.25k
        local_state._child_block->clear_column_data(
741
2.25k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
2.25k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
2.25k
                state, local_state._child_block.get(), &local_state._child_eos));
744
2.25k
        *eos = local_state._child_eos;
745
2.25k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
577
            return Status::OK();
747
577
        }
748
1.68k
        {
749
1.68k
            SCOPED_TIMER(local_state.exec_time_counter());
750
1.68k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
1.68k
        }
752
1.68k
    }
753
754
3.43k
    if (!need_more_input_data(state)) {
755
3.43k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.43k
        bool new_eos = false;
757
3.43k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.43k
        if (new_eos) {
759
1.05k
            *eos = true;
760
2.37k
        } else if (!need_more_input_data(state)) {
761
1.74k
            *eos = false;
762
1.74k
        }
763
3.43k
    }
764
3.43k
    return Status::OK();
765
3.43k
}
_ZN5doris17StatefulOperatorXINS_25MaterializationLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.97k
                                                         bool* eos) {
738
4.97k
    auto& local_state = get_local_state(state);
739
4.97k
    if (need_more_input_data(state)) {
740
4.97k
        local_state._child_block->clear_column_data(
741
4.97k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
4.97k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
4.97k
                state, local_state._child_block.get(), &local_state._child_eos));
744
4.97k
        *eos = local_state._child_eos;
745
4.97k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
1.71k
            return Status::OK();
747
1.71k
        }
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.73k
            *eos = true;
760
1.73k
        } 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
39.0k
                                                         bool* eos) {
738
39.0k
    auto& local_state = get_local_state(state);
739
39.0k
    if (need_more_input_data(state)) {
740
38.9k
        local_state._child_block->clear_column_data(
741
38.9k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
38.9k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
38.9k
                state, local_state._child_block.get(), &local_state._child_eos));
744
38.9k
        *eos = local_state._child_eos;
745
38.9k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
4.69k
            return Status::OK();
747
4.69k
        }
748
34.2k
        {
749
34.2k
            SCOPED_TIMER(local_state.exec_time_counter());
750
34.2k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
34.2k
        }
752
34.2k
    }
753
754
34.3k
    if (!need_more_input_data(state)) {
755
13.0k
        SCOPED_TIMER(local_state.exec_time_counter());
756
13.0k
        bool new_eos = false;
757
13.0k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
13.0k
        if (new_eos) {
759
12.9k
            *eos = true;
760
12.9k
        } else if (!need_more_input_data(state)) {
761
8
            *eos = false;
762
8
        }
763
13.0k
    }
764
34.3k
    return Status::OK();
765
34.3k
}
_ZN5doris17StatefulOperatorXINS_30DistinctStreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
559k
                                                         bool* eos) {
738
559k
    auto& local_state = get_local_state(state);
739
560k
    if (need_more_input_data(state)) {
740
560k
        local_state._child_block->clear_column_data(
741
560k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
560k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
560k
                state, local_state._child_block.get(), &local_state._child_eos));
744
560k
        *eos = local_state._child_eos;
745
560k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
33.4k
            return Status::OK();
747
33.4k
        }
748
526k
        {
749
526k
            SCOPED_TIMER(local_state.exec_time_counter());
750
526k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
526k
        }
752
526k
    }
753
754
526k
    if (!need_more_input_data(state)) {
755
491k
        SCOPED_TIMER(local_state.exec_time_counter());
756
491k
        bool new_eos = false;
757
491k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
491k
        if (new_eos) {
759
490k
            *eos = true;
760
490k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
491k
    }
764
526k
    return Status::OK();
765
526k
}
_ZN5doris17StatefulOperatorXINS_29NestedLoopJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
29.1k
                                                         bool* eos) {
738
29.1k
    auto& local_state = get_local_state(state);
739
29.1k
    if (need_more_input_data(state)) {
740
18.0k
        local_state._child_block->clear_column_data(
741
18.0k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
18.0k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
18.0k
                state, local_state._child_block.get(), &local_state._child_eos));
744
18.0k
        *eos = local_state._child_eos;
745
18.0k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
2.94k
            return Status::OK();
747
2.94k
        }
748
15.0k
        {
749
15.0k
            SCOPED_TIMER(local_state.exec_time_counter());
750
15.0k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
15.0k
        }
752
15.0k
    }
753
754
26.2k
    if (!need_more_input_data(state)) {
755
25.5k
        SCOPED_TIMER(local_state.exec_time_counter());
756
25.5k
        bool new_eos = false;
757
25.5k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
25.5k
        if (new_eos) {
759
9.89k
            *eos = true;
760
15.6k
        } else if (!need_more_input_data(state)) {
761
11.1k
            *eos = false;
762
11.1k
        }
763
25.5k
    }
764
26.2k
    return Status::OK();
765
26.2k
}
_ZN5doris17StatefulOperatorXINS_23TableFunctionLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
6.12k
                                                         bool* eos) {
738
6.12k
    auto& local_state = get_local_state(state);
739
6.12k
    if (need_more_input_data(state)) {
740
5.75k
        local_state._child_block->clear_column_data(
741
5.75k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
5.75k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
5.75k
                state, local_state._child_block.get(), &local_state._child_eos));
744
5.75k
        *eos = local_state._child_eos;
745
5.75k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
345
            return Status::OK();
747
345
        }
748
5.41k
        {
749
5.41k
            SCOPED_TIMER(local_state.exec_time_counter());
750
5.41k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
5.41k
        }
752
5.41k
    }
753
754
5.77k
    if (!need_more_input_data(state)) {
755
5.77k
        SCOPED_TIMER(local_state.exec_time_counter());
756
5.77k
        bool new_eos = false;
757
5.77k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
5.77k
        if (new_eos) {
759
3.74k
            *eos = true;
760
3.74k
        } else if (!need_more_input_data(state)) {
761
366
            *eos = false;
762
366
        }
763
5.77k
    }
764
5.77k
    return Status::OK();
765
5.77k
}
766
767
template <typename Writer, typename Parent>
768
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
769
70.1k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
70.1k
    RETURN_IF_ERROR(Base::init(state, info));
771
70.1k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
70.1k
                                                         "AsyncWriterDependency", true);
773
70.1k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
70.1k
                             _finish_dependency));
775
776
70.1k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
70.1k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
70.1k
    return Status::OK();
779
70.1k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
511
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
511
    RETURN_IF_ERROR(Base::init(state, info));
771
511
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
511
                                                         "AsyncWriterDependency", true);
773
511
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
511
                             _finish_dependency));
775
776
511
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
511
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
511
    return Status::OK();
779
511
}
_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.3k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
48.3k
    RETURN_IF_ERROR(Base::init(state, info));
771
48.3k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
48.3k
                                                         "AsyncWriterDependency", true);
773
48.3k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
48.3k
                             _finish_dependency));
775
776
48.3k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
48.3k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
48.3k
    return Status::OK();
779
48.3k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
9.56k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
9.56k
    RETURN_IF_ERROR(Base::init(state, info));
771
9.56k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
9.56k
                                                         "AsyncWriterDependency", true);
773
9.56k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
9.56k
                             _finish_dependency));
775
776
9.56k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
9.56k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
9.56k
    return Status::OK();
779
9.56k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
5.02k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
5.02k
    RETURN_IF_ERROR(Base::init(state, info));
771
5.02k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
5.02k
                                                         "AsyncWriterDependency", true);
773
5.02k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
5.02k
                             _finish_dependency));
775
776
5.02k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
5.02k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
5.02k
    return Status::OK();
779
5.02k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
4.00k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
4.00k
    RETURN_IF_ERROR(Base::init(state, info));
771
4.00k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
4.00k
                                                         "AsyncWriterDependency", true);
773
4.00k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
4.00k
                             _finish_dependency));
775
776
4.00k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
4.00k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
4.00k
    return Status::OK();
779
4.00k
}
_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.68k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
1.68k
    RETURN_IF_ERROR(Base::init(state, info));
771
1.68k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
1.68k
                                                         "AsyncWriterDependency", true);
773
1.68k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
1.68k
                             _finish_dependency));
775
776
1.68k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
1.68k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
1.68k
    return Status::OK();
779
1.68k
}
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
70.3k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
70.3k
    RETURN_IF_ERROR(Base::open(state));
785
70.3k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
606k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
536k
        RETURN_IF_ERROR(
788
536k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
536k
    }
790
70.3k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
70.3k
    return Status::OK();
792
70.3k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
511
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
511
    RETURN_IF_ERROR(Base::open(state));
785
511
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
2.76k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
2.25k
        RETURN_IF_ERROR(
788
2.25k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
2.25k
    }
790
511
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
511
    return Status::OK();
792
511
}
_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.6k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
48.6k
    RETURN_IF_ERROR(Base::open(state));
785
48.6k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
351k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
302k
        RETURN_IF_ERROR(
788
302k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
302k
    }
790
48.6k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
48.6k
    return Status::OK();
792
48.6k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
9.51k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
9.51k
    RETURN_IF_ERROR(Base::open(state));
785
9.51k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
57.9k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
48.3k
        RETURN_IF_ERROR(
788
48.3k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
48.3k
    }
790
9.51k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
9.51k
    return Status::OK();
792
9.51k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
5.02k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
5.02k
    RETURN_IF_ERROR(Base::open(state));
785
5.02k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
133k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
128k
        RETURN_IF_ERROR(
788
128k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
128k
    }
790
5.02k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
5.02k
    return Status::OK();
792
5.02k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
4.00k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
4.00k
    RETURN_IF_ERROR(Base::open(state));
785
4.00k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
44.4k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
40.4k
        RETURN_IF_ERROR(
788
40.4k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
40.4k
    }
790
4.00k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
4.00k
    return Status::OK();
792
4.00k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
46
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
46
    RETURN_IF_ERROR(Base::open(state));
785
46
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
198
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
152
        RETURN_IF_ERROR(
788
152
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
152
    }
790
46
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
46
    return Status::OK();
792
46
}
_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.11k
    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.67k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
1.67k
    RETURN_IF_ERROR(Base::open(state));
785
1.67k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
13.2k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
11.5k
        RETURN_IF_ERROR(
788
11.5k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
11.5k
    }
790
1.67k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
1.67k
    return Status::OK();
792
1.67k
}
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
95.9k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
95.9k
    return _writer->sink(block, eos);
798
95.9k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
2.33k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
2.33k
    return _writer->sink(block, eos);
798
2.33k
}
_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.5k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
65.5k
    return _writer->sink(block, eos);
798
65.5k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
11.1k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
11.1k
    return _writer->sink(block, eos);
798
11.1k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
7.25k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
7.25k
    return _writer->sink(block, eos);
798
7.25k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
6.35k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
6.35k
    return _writer->sink(block, eos);
798
6.35k
}
_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.12k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
2.12k
    return _writer->sink(block, eos);
798
2.12k
}
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
70.3k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
70.3k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
70.3k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
70.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
70.4k
    if (_writer) {
810
70.4k
        Status st = _writer->get_writer_status();
811
70.4k
        if (exec_status.ok()) {
812
70.3k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
70.3k
                                                       : Status::Cancelled("force close"));
814
70.3k
        } else {
815
59
            _writer->force_close(exec_status);
816
59
        }
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
70.4k
        RETURN_IF_ERROR(st);
821
70.4k
    }
822
70.3k
    return Base::close(state, exec_status);
823
70.3k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
499
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
499
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
499
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
499
    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
499
    if (_writer) {
810
499
        Status st = _writer->get_writer_status();
811
499
        if (exec_status.ok()) {
812
499
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
499
                                                       : Status::Cancelled("force close"));
814
499
        } 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
499
        RETURN_IF_ERROR(st);
821
499
    }
822
499
    return Base::close(state, exec_status);
823
499
}
_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.6k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
48.6k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
48.6k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
48.6k
    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.6k
    if (_writer) {
810
48.6k
        Status st = _writer->get_writer_status();
811
48.6k
        if (exec_status.ok()) {
812
48.6k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
48.6k
                                                       : Status::Cancelled("force close"));
814
48.6k
        } else {
815
29
            _writer->force_close(exec_status);
816
29
        }
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.6k
        RETURN_IF_ERROR(st);
821
48.6k
    }
822
48.6k
    return Base::close(state, exec_status);
823
48.6k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
9.53k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
9.53k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
9.53k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
9.53k
    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.53k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
9.53k
                                                       : Status::Cancelled("force close"));
814
9.53k
        } else {
815
32
            _writer->force_close(exec_status);
816
32
        }
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.53k
    return Base::close(state, exec_status);
823
9.53k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
5.01k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
5.01k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
5.01k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
5.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
5.02k
    if (_writer) {
810
5.02k
        Status st = _writer->get_writer_status();
811
5.02k
        if (exec_status.ok()) {
812
5.02k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
5.02k
                                                       : Status::Cancelled("force close"));
814
18.4E
        } else {
815
18.4E
            _writer->force_close(exec_status);
816
18.4E
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
5.02k
        RETURN_IF_ERROR(st);
821
5.02k
    }
822
5.01k
    return Base::close(state, exec_status);
823
5.01k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
4.00k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
4.00k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
4.00k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
4.00k
    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.00k
    if (_writer) {
810
4.00k
        Status st = _writer->get_writer_status();
811
4.00k
        if (exec_status.ok()) {
812
4.00k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
4.00k
                                                       : Status::Cancelled("force close"));
814
4.00k
        } 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.00k
        RETURN_IF_ERROR(st);
821
4.00k
    }
822
4.00k
    return Base::close(state, exec_status);
823
4.00k
}
_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
702
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
702
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
702
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
702
    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
704
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
704
                                                       : Status::Cancelled("force close"));
814
704
        } 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
704
        RETURN_IF_ERROR(st);
821
704
    }
822
702
    return Base::close(state, exec_status);
823
702
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
1.68k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
1.68k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
1.68k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
1.68k
    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.68k
    if (_writer) {
810
1.68k
        Status st = _writer->get_writer_status();
811
1.68k
        if (exec_status.ok()) {
812
1.68k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
1.68k
                                                       : Status::Cancelled("force close"));
814
1.68k
        } 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.68k
        RETURN_IF_ERROR(st);
821
1.68k
    }
822
1.68k
    return Base::close(state, exec_status);
823
1.68k
}
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