Coverage Report

Created: 2026-07-30 10:17

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
1.99M
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
1.99M
    if (_parent->nereids_id() == -1) {
122
1.04M
        return fmt::format("(id={})", _parent->node_id());
123
1.04M
    } else {
124
952k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
952k
    }
126
1.99M
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
74.4k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
74.4k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
74.4k
    } else {
124
74.4k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
74.4k
    }
126
74.4k
}
_ZNK5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
1
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
1
    if (_parent->nereids_id() == -1) {
122
1
        return fmt::format("(id={})", _parent->node_id());
123
1
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
1
}
_ZNK5doris19PipelineXLocalStateINS_15SortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
275k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
275k
    if (_parent->nereids_id() == -1) {
122
12
        return fmt::format("(id={})", _parent->node_id());
123
275k
    } else {
124
275k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
275k
    }
126
275k
}
_ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
25
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
25
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
25
    } else {
124
25
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
25
    }
126
25
}
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
9.56k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
9.56k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
9.56k
    } else {
124
9.56k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
9.56k
    }
126
9.56k
}
_ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
7.43k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
7.43k
    if (_parent->nereids_id() == -1) {
122
11
        return fmt::format("(id={})", _parent->node_id());
123
7.42k
    } else {
124
7.42k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
7.42k
    }
126
7.43k
}
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
164k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
164k
    if (_parent->nereids_id() == -1) {
122
29
        return fmt::format("(id={})", _parent->node_id());
123
164k
    } else {
124
164k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
164k
    }
126
164k
}
_ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
532
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
532
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
532
    } else {
124
532
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
532
    }
126
532
}
_ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
180
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
180
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
180
    } else {
124
180
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
180
    }
126
180
}
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
706k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
706k
    if (_parent->nereids_id() == -1) {
122
349k
        return fmt::format("(id={})", _parent->node_id());
123
357k
    } else {
124
357k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
357k
    }
126
706k
}
_ZNK5doris19PipelineXLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
56.6k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
56.6k
    if (_parent->nereids_id() == -1) {
122
2
        return fmt::format("(id={})", _parent->node_id());
123
56.6k
    } else {
124
56.6k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
56.6k
    }
126
56.6k
}
_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
11.0k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
11.0k
    if (_parent->nereids_id() == -1) {
122
10.9k
        return fmt::format("(id={})", _parent->node_id());
123
10.9k
    } else {
124
2
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
2
    }
126
11.0k
}
_ZNK5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
299
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
299
    if (_parent->nereids_id() == -1) {
122
102
        return fmt::format("(id={})", _parent->node_id());
123
197
    } else {
124
197
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
197
    }
126
299
}
_ZNK5doris19PipelineXLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
5.04k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
5.04k
    if (_parent->nereids_id() == -1) {
122
13
        return fmt::format("(id={})", _parent->node_id());
123
5.03k
    } else {
124
5.03k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
5.03k
    }
126
5.04k
}
_ZNK5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
684k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
684k
    if (_parent->nereids_id() == -1) {
122
683k
        return fmt::format("(id={})", _parent->node_id());
123
683k
    } else {
124
1.23k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
1.23k
    }
126
684k
}
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.32M
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
1.32M
    if (_parent->nereids_id() == -1) {
131
730k
        return fmt::format("(id={})", _parent->node_id());
132
730k
    } else {
133
592k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
592k
    }
135
1.32M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
122k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
122k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
122k
    } else {
133
122k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
122k
    }
135
122k
}
_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
278k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
278k
    if (_parent->nereids_id() == -1) {
131
9
        return fmt::format("(id={})", _parent->node_id());
132
278k
    } else {
133
278k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
278k
    }
135
278k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
32
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
32
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
32
    } else {
133
32
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
32
    }
135
32
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
9.59k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
9.59k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
9.59k
    } else {
133
9.59k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
9.59k
    }
135
9.59k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
7.48k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
7.48k
    if (_parent->nereids_id() == -1) {
131
11
        return fmt::format("(id={})", _parent->node_id());
132
7.47k
    } else {
133
7.47k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
7.47k
    }
135
7.48k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
164k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
164k
    if (_parent->nereids_id() == -1) {
131
29
        return fmt::format("(id={})", _parent->node_id());
132
164k
    } else {
133
164k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
164k
    }
135
164k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
533
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
533
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
533
    } else {
133
533
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
533
    }
135
533
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
190
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
190
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
190
    } else {
133
190
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
190
    }
135
190
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
89
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
89
    if (_parent->nereids_id() == -1) {
131
89
        return fmt::format("(id={})", _parent->node_id());
132
89
    } else {
133
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
0
    }
135
89
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
7.73k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
7.73k
    if (_parent->nereids_id() == -1) {
131
3
        return fmt::format("(id={})", _parent->node_id());
132
7.73k
    } else {
133
7.73k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
7.73k
    }
135
7.73k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
298
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
298
    if (_parent->nereids_id() == -1) {
131
102
        return fmt::format("(id={})", _parent->node_id());
132
196
    } else {
133
196
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
196
    }
135
298
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE11name_suffixB5cxx11Ev
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
12.1k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
12.1k
    if (_parent->nereids_id() == -1) {
131
12.1k
        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.1k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
252k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
252k
    if (_parent->nereids_id() == -1) {
131
252k
        return fmt::format("(id={})", _parent->node_id());
132
252k
    } else {
133
27
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
27
    }
135
252k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
465k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
465k
    if (_parent->nereids_id() == -1) {
131
465k
        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
465k
}
_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
29.5k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
29.5k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
29.5k
    _terminated = true;
143
29.5k
    return Status::OK();
144
29.5k
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
24.0k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
24.0k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
24.0k
    _terminated = true;
143
24.0k
    return Status::OK();
144
24.0k
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
1.32k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
1.32k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
1.32k
    _terminated = true;
143
1.32k
    return Status::OK();
144
1.32k
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
7
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
7
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
7
    _terminated = true;
143
7
    return Status::OK();
144
7
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_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_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
2.36k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
2.36k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
2.36k
    _terminated = true;
143
2.36k
    return Status::OK();
144
2.36k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
6
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
6
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
6
    _terminated = true;
143
6
    return Status::OK();
144
6
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
851
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
851
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
851
    _terminated = true;
143
851
    return Status::OK();
144
851
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
43
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
43
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
43
    _terminated = true;
143
43
    return Status::OK();
144
43
}
_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
583
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
583
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
583
    _terminated = true;
143
583
    return Status::OK();
144
583
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
7
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
7
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
7
    _terminated = true;
143
7
    return Status::OK();
144
7
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
138
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
138
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
138
    _terminated = true;
143
138
    return Status::OK();
144
138
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
140
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
140
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
140
    _terminated = true;
143
140
    return Status::OK();
144
140
}
145
146
433k
DataDistribution OperatorBase::required_data_distribution(RuntimeState* /*state*/) const {
147
433k
    return _child && _child->is_serial_operator() && !is_source()
148
433k
                   ? DataDistribution(TLocalPartitionType::PASSTHROUGH)
149
433k
                   : DataDistribution(TLocalPartitionType::NOOP);
150
433k
}
151
152
41.6k
bool OperatorBase::child_breaks_local_key_distribution(RuntimeState* state) const {
153
41.6k
    if (!_child) {
154
36.5k
        return false;
155
36.5k
    }
156
5.08k
    if (_child->is_serial_operator()) {
157
220
        return true;
158
220
    }
159
4.86k
    const auto child_distribution = _child->required_data_distribution(state);
160
4.86k
    return child_distribution.need_local_exchange() &&
161
4.86k
           !is_shuffled_exchange(child_distribution.distribution_type);
162
5.08k
}
163
164
82.6k
const RowDescriptor& OperatorBase::row_desc() const {
165
82.6k
    return _child->row_desc();
166
82.6k
}
167
168
template <typename SharedStateArg>
169
19.8k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
19.8k
    fmt::memory_buffer debug_string_buffer;
171
19.8k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
19.8k
    return fmt::to_string(debug_string_buffer);
173
19.8k
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
23
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
23
    fmt::memory_buffer debug_string_buffer;
171
23
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
23
    return fmt::to_string(debug_string_buffer);
173
23
}
_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
13
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
13
    fmt::memory_buffer debug_string_buffer;
171
13
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
13
    return fmt::to_string(debug_string_buffer);
173
13
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
9
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
9
    fmt::memory_buffer debug_string_buffer;
171
9
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
9
    return fmt::to_string(debug_string_buffer);
173
9
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
13
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
13
    fmt::memory_buffer debug_string_buffer;
171
13
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
13
    return fmt::to_string(debug_string_buffer);
173
13
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
19.7k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
19.7k
    fmt::memory_buffer debug_string_buffer;
171
19.7k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
19.7k
    return fmt::to_string(debug_string_buffer);
173
19.7k
}
_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
22
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
22
    fmt::memory_buffer debug_string_buffer;
171
22
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
22
    return fmt::to_string(debug_string_buffer);
173
22
}
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
6
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
6
    fmt::memory_buffer debug_string_buffer;
178
6
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
6
    return fmt::to_string(debug_string_buffer);
180
6
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
13
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
13
    fmt::memory_buffer debug_string_buffer;
178
13
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
13
    return fmt::to_string(debug_string_buffer);
180
13
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
6
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
6
    fmt::memory_buffer debug_string_buffer;
178
6
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
6
    return fmt::to_string(debug_string_buffer);
180
6
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
13
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
13
    fmt::memory_buffer debug_string_buffer;
178
13
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
13
    return fmt::to_string(debug_string_buffer);
180
13
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
26
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
26
    fmt::memory_buffer debug_string_buffer;
178
26
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
26
    return fmt::to_string(debug_string_buffer);
180
26
}
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
12
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
12
    fmt::memory_buffer debug_string_buffer;
178
12
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
12
    return fmt::to_string(debug_string_buffer);
180
12
}
_ZNK5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
19.6k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
19.6k
    fmt::memory_buffer debug_string_buffer;
178
19.6k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
19.6k
    return fmt::to_string(debug_string_buffer);
180
19.6k
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
181
182
19.8k
std::string OperatorXBase::debug_string(int indentation_level) const {
183
19.8k
    fmt::memory_buffer debug_string_buffer;
184
19.8k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, parallel_tasks={}, _is_serial_operator={}",
185
19.8k
                   std::string(indentation_level * 2, ' '), _op_name, node_id(), _parallel_tasks,
186
19.8k
                   _is_serial_operator);
187
19.8k
    return fmt::to_string(debug_string_buffer);
188
19.8k
}
189
190
19.7k
std::string OperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
191
19.7k
    return state->get_local_state(operator_id())->debug_string(indentation_level);
192
19.7k
}
193
194
846k
Status OperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
195
846k
    std::string node_name = print_plan_node_type(tnode.node_type);
196
846k
    _nereids_id = tnode.nereids_id;
197
846k
    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
846k
    auto substr = node_name.substr(0, node_name.find("_NODE"));
211
846k
    _op_name = substr + "_OPERATOR";
212
213
846k
    if (tnode.__isset.vconjunct) {
214
0
        return Status::InternalError("vconjunct is not supported yet");
215
846k
    } else if (tnode.__isset.conjuncts) {
216
488k
        for (const auto& conjunct : tnode.conjuncts) {
217
488k
            VExprContextSPtr context;
218
488k
            RETURN_IF_ERROR(VExpr::create_expr_tree(conjunct, context));
219
488k
            _conjuncts.emplace_back(context);
220
488k
        }
221
157k
    }
222
223
    // create the projections expr
224
846k
    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
846k
    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.56k
        for (const auto& tnode_projections : tnode.intermediate_projections_list) {
232
8.56k
            VExprContextSPtrs projections;
233
8.56k
            RETURN_IF_ERROR(VExpr::create_expr_trees(tnode_projections, projections));
234
8.56k
            _intermediate_projections.push_back(projections);
235
8.56k
        }
236
4.16k
    }
237
846k
    return Status::OK();
238
846k
}
239
240
878k
Status OperatorXBase::prepare(RuntimeState* state) {
241
878k
    for (auto& conjunct : _conjuncts) {
242
487k
        RETURN_IF_ERROR(conjunct->prepare(state, intermediate_row_desc()));
243
487k
    }
244
878k
    if (state->enable_adjust_conjunct_order_by_cost()) {
245
825k
        std::ranges::stable_sort(_conjuncts, [](const auto& a, const auto& b) {
246
648k
            return a->execute_cost() < b->execute_cost();
247
648k
        });
248
825k
    };
249
250
887k
    for (int i = 0; i < _intermediate_projections.size(); i++) {
251
8.56k
        RETURN_IF_ERROR(
252
8.56k
                VExpr::prepare(_intermediate_projections[i], state, intermediate_row_desc(i)));
253
8.56k
    }
254
878k
    RETURN_IF_ERROR(VExpr::prepare(_projections, state, projections_row_desc()));
255
256
878k
    if (has_output_row_desc()) {
257
333k
        RETURN_IF_ERROR(VExpr::check_expr_output_type(_projections, *_output_row_descriptor));
258
333k
    }
259
260
878k
    for (auto& conjunct : _conjuncts) {
261
488k
        RETURN_IF_ERROR(conjunct->open(state));
262
488k
    }
263
878k
    RETURN_IF_ERROR(VExpr::open(_projections, state));
264
878k
    for (auto& projections : _intermediate_projections) {
265
8.56k
        RETURN_IF_ERROR(VExpr::open(projections, state));
266
8.56k
    }
267
878k
    if (_child && !is_source()) {
268
131k
        RETURN_IF_ERROR(_child->prepare(state));
269
131k
    }
270
271
878k
    if (VExpr::contains_blockable_function(_conjuncts) ||
272
878k
        VExpr::contains_blockable_function(_projections)) {
273
0
        _blockable = true;
274
0
    }
275
276
878k
    return Status::OK();
277
878k
}
278
279
6.63k
Status OperatorXBase::terminate(RuntimeState* state) {
280
6.63k
    if (_child && !is_source()) {
281
1.10k
        RETURN_IF_ERROR(_child->terminate(state));
282
1.10k
    }
283
6.63k
    auto result = state->get_local_state_result(operator_id());
284
6.63k
    if (!result) {
285
0
        return result.error();
286
0
    }
287
6.63k
    return result.value()->terminate(state);
288
6.63k
}
289
290
5.54M
Status OperatorXBase::close(RuntimeState* state) {
291
5.54M
    if (_child && !is_source()) {
292
867k
        RETURN_IF_ERROR(_child->close(state));
293
867k
    }
294
5.54M
    auto result = state->get_local_state_result(operator_id());
295
5.54M
    if (!result) {
296
0
        return result.error();
297
0
    }
298
5.54M
    return result.value()->close(state);
299
5.54M
}
300
301
306k
void PipelineXLocalStateBase::clear_origin_block() {
302
306k
    _origin_block.clear_column_data(_parent->intermediate_row_desc().num_materialized_slots());
303
306k
}
304
305
535k
Status PipelineXLocalStateBase::filter_block(const VExprContextSPtrs& expr_contexts, Block* block) {
306
535k
    RETURN_IF_ERROR(VExprContext::filter_block(expr_contexts, block, block->columns()));
307
308
535k
    _estimate_memory_usage += VExprContext::get_memory_usage(expr_contexts);
309
535k
    return Status::OK();
310
535k
}
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
307k
                                     Block* output_block) const {
319
307k
    auto* local_state = state->get_local_state(operator_id());
320
307k
    SCOPED_TIMER(local_state->exec_time_counter());
321
307k
    SCOPED_TIMER(local_state->_projection_timer);
322
307k
    const size_t rows = origin_block->rows();
323
307k
    if (rows == 0) {
324
159k
        return Status::OK();
325
159k
    }
326
147k
    Block input_block = *origin_block;
327
328
147k
    size_t bytes_usage = 0;
329
147k
    ColumnsWithTypeAndName new_columns;
330
147k
    for (const auto& projections : local_state->_intermediate_projections) {
331
2.06k
        if (projections.empty()) {
332
0
            return Status::InternalError("meet empty intermediate projection, node id: {}",
333
0
                                         node_id());
334
0
        }
335
2.06k
        new_columns.resize(projections.size());
336
15.6k
        for (int i = 0; i < projections.size(); i++) {
337
13.5k
            RETURN_IF_ERROR(projections[i]->execute(&input_block, new_columns[i]));
338
13.5k
            if (new_columns[i].column->size() != rows) {
339
0
                return Status::InternalError(
340
0
                        "intermediate projection result column size {} not equal input rows {}, "
341
0
                        "expr: {}",
342
0
                        new_columns[i].column->size(), rows,
343
0
                        projections[i]->root()->debug_string());
344
0
            }
345
13.5k
        }
346
2.06k
        Block tmp_block {new_columns};
347
2.06k
        bytes_usage += tmp_block.allocated_bytes();
348
2.06k
        input_block.swap(tmp_block);
349
2.06k
    }
350
351
147k
    if (input_block.rows() != rows) {
352
0
        return Status::InternalError(
353
0
                "after intermediate projections input block rows {} not equal origin rows {}, "
354
0
                "input_block: {}",
355
0
                input_block.rows(), rows, input_block.dump_structure());
356
0
    }
357
682k
    auto insert_column_datas = [&](auto& to, ColumnPtr& from, size_t rows) {
358
682k
        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
682k
        } else {
368
682k
            if (_keep_origin || !from->is_exclusive()) {
369
682k
                to->insert_range_from(*from, 0, rows);
370
682k
                bytes_usage += from->allocated_bytes();
371
18.4E
            } else {
372
18.4E
                to = from->assert_mutable();
373
18.4E
            }
374
682k
        }
375
682k
    };
376
377
147k
    auto scoped_mutable_block = VectorizedUtils::build_scoped_mutable_mem_reuse_block(
378
147k
            output_block, *_output_row_descriptor);
379
147k
    auto& mutable_block = scoped_mutable_block.mutable_block();
380
147k
    auto& mutable_columns = mutable_block.mutable_columns();
381
147k
    if (rows != 0) {
382
147k
        DCHECK_EQ(mutable_columns.size(), local_state->_projections.size()) << debug_string();
383
829k
        for (int i = 0; i < mutable_columns.size(); ++i) {
384
682k
            ColumnPtr column_ptr;
385
682k
            RETURN_IF_ERROR(local_state->_projections[i]->execute(&input_block, column_ptr));
386
682k
            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
682k
            column_ptr = column_ptr->convert_to_full_column_if_const();
393
682k
            bytes_usage += column_ptr->allocated_bytes();
394
682k
            insert_column_datas(mutable_columns[i], column_ptr, rows);
395
682k
        }
396
147k
        DCHECK(mutable_block.rows() == rows);
397
147k
    }
398
147k
    local_state->_estimate_memory_usage += bytes_usage;
399
400
147k
    return Status::OK();
401
147k
}
402
403
4.58M
Status OperatorXBase::get_block_after_projects(RuntimeState* state, Block* block, bool* eos) {
404
4.58M
    DBUG_EXECUTE_IF("Pipeline::return_empty_block", {
405
4.58M
        if (this->_op_name == "AGGREGATION_OPERATOR" || this->_op_name == "HASH_JOIN_OPERATOR" ||
406
4.58M
            this->_op_name == "PARTITIONED_AGGREGATION_OPERATOR" ||
407
4.58M
            this->_op_name == "PARTITIONED_HASH_JOIN_OPERATOR" ||
408
4.58M
            this->_op_name == "CROSS_JOIN_OPERATOR" || this->_op_name == "SORT_OPERATOR") {
409
4.58M
            if (_debug_point_count++ % 2 == 0) {
410
4.58M
                return Status::OK();
411
4.58M
            }
412
4.58M
        }
413
4.58M
    });
414
415
4.58M
    Status status;
416
4.58M
    auto* local_state = state->get_local_state(operator_id());
417
4.58M
    Defer defer([&]() {
418
4.58M
        if (status.ok()) {
419
4.58M
            local_state->update_output_block_counters(*block);
420
4.58M
        }
421
4.58M
    });
422
4.58M
    if (_output_row_descriptor) {
423
306k
        local_state->clear_origin_block();
424
306k
        status = get_block(state, &local_state->_origin_block, eos);
425
306k
        if (UNLIKELY(!status.ok())) {
426
25
            return status;
427
25
        }
428
306k
        status = do_projections(state, &local_state->_origin_block, block);
429
306k
        return status;
430
306k
    }
431
4.27M
    status = get_block(state, block, eos);
432
4.27M
    RETURN_IF_ERROR(block->check_type_and_column());
433
4.27M
    return status;
434
4.27M
}
435
436
3.20M
void PipelineXLocalStateBase::reached_limit(Block* block, bool* eos) {
437
3.20M
    if (_parent->_limit != -1 and _num_rows_returned + block->rows() >= _parent->_limit) {
438
6.87k
        block->set_num_rows(_parent->_limit - _num_rows_returned);
439
6.87k
        *eos = true;
440
6.87k
    }
441
442
3.20M
    DBUG_EXECUTE_IF("Pipeline::reached_limit_early", {
443
3.20M
        auto op_name = to_lower(_parent->_op_name);
444
3.20M
        auto arg_op_name = dp->param<std::string>("op_name");
445
3.20M
        arg_op_name = to_lower(arg_op_name);
446
447
3.20M
        if (op_name == arg_op_name) {
448
3.20M
            *eos = true;
449
3.20M
        }
450
3.20M
    });
451
452
3.20M
    if (auto rows = block->rows()) {
453
923k
        _num_rows_returned += rows;
454
923k
        _state->get_query_ctx()->resource_ctx()->io_context()->update_process_rows(rows);
455
923k
    }
456
3.20M
}
457
458
29.5k
Status DataSinkOperatorXBase::terminate(RuntimeState* state) {
459
29.5k
    auto result = state->get_sink_local_state_result();
460
29.5k
    if (!result) {
461
0
        return result.error();
462
0
    }
463
29.5k
    return result.value()->terminate(state);
464
29.5k
}
465
466
19.7k
std::string DataSinkOperatorXBase::debug_string(int indentation_level) const {
467
19.7k
    fmt::memory_buffer debug_string_buffer;
468
469
19.7k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, _is_serial_operator={}",
470
19.7k
                   std::string(indentation_level * 2, ' '), _name, node_id(), _is_serial_operator);
471
19.7k
    return fmt::to_string(debug_string_buffer);
472
19.7k
}
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.00M
                                                            LocalSinkStateInfo& info) {
500
2.00M
    auto local_state = LocalStateType::create_unique(this, state);
501
2.00M
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.00M
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.00M
    return Status::OK();
504
2.00M
}
_ZN5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
122k
                                                            LocalSinkStateInfo& info) {
500
122k
    auto local_state = LocalStateType::create_unique(this, state);
501
122k
    RETURN_IF_ERROR(local_state->init(state, info));
502
122k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
122k
    return Status::OK();
504
122k
}
_ZN5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
397k
                                                            LocalSinkStateInfo& info) {
500
397k
    auto local_state = LocalStateType::create_unique(this, state);
501
397k
    RETURN_IF_ERROR(local_state->init(state, info));
502
397k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
397k
    return Status::OK();
504
397k
}
_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
510
                                                            LocalSinkStateInfo& info) {
500
510
    auto local_state = LocalStateType::create_unique(this, state);
501
510
    RETURN_IF_ERROR(local_state->init(state, info));
502
510
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
510
    return Status::OK();
504
510
}
_ZN5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
46.8k
                                                            LocalSinkStateInfo& info) {
500
46.8k
    auto local_state = LocalStateType::create_unique(this, state);
501
46.8k
    RETURN_IF_ERROR(local_state->init(state, info));
502
46.8k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
46.8k
    return Status::OK();
504
46.8k
}
_ZN5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.70k
                                                            LocalSinkStateInfo& info) {
500
9.70k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.70k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.70k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.70k
    return Status::OK();
504
9.70k
}
_ZN5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
5.05k
                                                            LocalSinkStateInfo& info) {
500
5.05k
    auto local_state = LocalStateType::create_unique(this, state);
501
5.05k
    RETURN_IF_ERROR(local_state->init(state, info));
502
5.05k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
5.05k
    return Status::OK();
504
5.05k
}
_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.01k
                                                            LocalSinkStateInfo& info) {
500
4.01k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.01k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.01k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.01k
    return Status::OK();
504
4.01k
}
_ZN5doris17DataSinkOperatorXINS_31SpillIcebergTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
48
                                                            LocalSinkStateInfo& info) {
500
48
    auto local_state = LocalStateType::create_unique(this, state);
501
48
    RETURN_IF_ERROR(local_state->init(state, info));
502
48
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
48
    return Status::OK();
504
48
}
_ZN5doris17DataSinkOperatorXINS_27IcebergDeleteSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
704
                                                            LocalSinkStateInfo& info) {
500
704
    auto local_state = LocalStateType::create_unique(this, state);
501
704
    RETURN_IF_ERROR(local_state->init(state, info));
502
704
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
704
    return Status::OK();
504
704
}
_ZN5doris17DataSinkOperatorXINS_26IcebergMergeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
1.71k
                                                            LocalSinkStateInfo& info) {
500
1.71k
    auto local_state = LocalStateType::create_unique(this, state);
501
1.71k
    RETURN_IF_ERROR(local_state->init(state, info));
502
1.71k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
1.71k
    return Status::OK();
504
1.71k
}
Unexecuted instantiation: _ZN5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
7.48k
                                                            LocalSinkStateInfo& info) {
500
7.48k
    auto local_state = LocalStateType::create_unique(this, state);
501
7.48k
    RETURN_IF_ERROR(local_state->init(state, info));
502
7.48k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
7.48k
    return Status::OK();
504
7.48k
}
_ZN5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE17setup_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_18SortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
279k
                                                            LocalSinkStateInfo& info) {
500
279k
    auto local_state = LocalStateType::create_unique(this, state);
501
279k
    RETURN_IF_ERROR(local_state->init(state, info));
502
279k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
279k
    return Status::OK();
504
279k
}
_ZN5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
32
                                                            LocalSinkStateInfo& info) {
500
32
    auto local_state = LocalStateType::create_unique(this, state);
501
32
    RETURN_IF_ERROR(local_state->init(state, info));
502
32
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
32
    return Status::OK();
504
32
}
_ZN5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
252k
                                                            LocalSinkStateInfo& info) {
500
252k
    auto local_state = LocalStateType::create_unique(this, state);
501
252k
    RETURN_IF_ERROR(local_state->init(state, info));
502
252k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
252k
    return Status::OK();
504
252k
}
_ZN5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
164k
                                                            LocalSinkStateInfo& info) {
500
164k
    auto local_state = LocalStateType::create_unique(this, state);
501
164k
    RETURN_IF_ERROR(local_state->init(state, info));
502
164k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
164k
    return Status::OK();
504
164k
}
_ZN5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
533
                                                            LocalSinkStateInfo& info) {
500
533
    auto local_state = LocalStateType::create_unique(this, state);
501
533
    RETURN_IF_ERROR(local_state->init(state, info));
502
533
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
533
    return Status::OK();
504
533
}
_ZN5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
190
                                                            LocalSinkStateInfo& info) {
500
190
    auto local_state = LocalStateType::create_unique(this, state);
501
190
    RETURN_IF_ERROR(local_state->init(state, info));
502
190
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
190
    return Status::OK();
504
190
}
_ZN5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
676k
                                                            LocalSinkStateInfo& info) {
500
676k
    auto local_state = LocalStateType::create_unique(this, state);
501
676k
    RETURN_IF_ERROR(local_state->init(state, info));
502
676k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
676k
    return Status::OK();
504
676k
}
_ZN5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.61k
                                                            LocalSinkStateInfo& info) {
500
9.61k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.61k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.61k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.61k
    return Status::OK();
504
9.61k
}
_ZN5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
7.74k
                                                            LocalSinkStateInfo& info) {
500
7.74k
    auto local_state = LocalStateType::create_unique(this, state);
501
7.74k
    RETURN_IF_ERROR(local_state->init(state, info));
502
7.74k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
7.74k
    return Status::OK();
504
7.74k
}
_ZN5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3.91k
                                                            LocalSinkStateInfo& info) {
500
3.91k
    auto local_state = LocalStateType::create_unique(this, state);
501
3.91k
    RETURN_IF_ERROR(local_state->init(state, info));
502
3.91k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3.91k
    return Status::OK();
504
3.91k
}
_ZN5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
197
                                                            LocalSinkStateInfo& info) {
500
197
    auto local_state = LocalStateType::create_unique(this, state);
501
197
    RETURN_IF_ERROR(local_state->init(state, info));
502
197
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
197
    return Status::OK();
504
197
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
4.65k
                                                            LocalSinkStateInfo& info) {
500
4.65k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.65k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.65k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.65k
    return Status::OK();
504
4.65k
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.46k
                                                            LocalSinkStateInfo& info) {
500
2.46k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.46k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.46k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.46k
    return Status::OK();
504
2.46k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.56k
                                                            LocalSinkStateInfo& info) {
500
2.56k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.56k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.56k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.56k
    return Status::OK();
504
2.56k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.43k
                                                            LocalSinkStateInfo& info) {
500
2.43k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.43k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.43k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.43k
    return Status::OK();
504
2.43k
}
_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
569
                                                            LocalSinkStateInfo& info) {
500
569
    auto local_state = LocalStateType::create_unique(this, state);
501
569
    RETURN_IF_ERROR(local_state->init(state, info));
502
569
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
569
    return Status::OK();
504
569
}
_ZN5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
14
                                                            LocalSinkStateInfo& info) {
500
14
    auto local_state = LocalStateType::create_unique(this, state);
501
14
    RETURN_IF_ERROR(local_state->init(state, info));
502
14
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
14
    return Status::OK();
504
14
}
_ZN5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
101
                                                            LocalSinkStateInfo& info) {
500
101
    auto local_state = LocalStateType::create_unique(this, state);
501
101
    RETURN_IF_ERROR(local_state->init(state, info));
502
101
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
101
    return Status::OK();
504
101
}
_ZN5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
164
                                                            LocalSinkStateInfo& info) {
500
164
    auto local_state = LocalStateType::create_unique(this, state);
501
164
    RETURN_IF_ERROR(local_state->init(state, info));
502
164
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
164
    return Status::OK();
504
164
}
_ZN5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
164
                                                            LocalSinkStateInfo& info) {
500
164
    auto local_state = LocalStateType::create_unique(this, state);
501
164
    RETURN_IF_ERROR(local_state->init(state, info));
502
164
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
164
    return Status::OK();
504
164
}
505
506
template <typename LocalStateType>
507
1.71M
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.71M
    } else {
515
1.71M
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.71M
        ss->id = operator_id();
517
1.71M
        for (auto& dest : dests_id()) {
518
1.70M
            ss->related_op_ids.insert(dest);
519
1.70M
        }
520
1.71M
        return ss;
521
1.71M
    }
522
1.71M
}
_ZNK5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
99.0k
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.0k
    } else {
515
99.0k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
99.0k
        ss->id = operator_id();
517
99.0k
        for (auto& dest : dests_id()) {
518
98.9k
            ss->related_op_ids.insert(dest);
519
98.9k
        }
520
99.0k
        return ss;
521
99.0k
    }
522
99.0k
}
_ZNK5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
397k
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
397k
    } else {
515
397k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
397k
        ss->id = operator_id();
517
397k
        for (auto& dest : dests_id()) {
518
396k
            ss->related_op_ids.insert(dest);
519
396k
        }
520
397k
        return ss;
521
397k
    }
522
397k
}
_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
510
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
510
    } else {
515
510
        auto ss = LocalStateType::SharedStateType::create_shared();
516
510
        ss->id = operator_id();
517
510
        for (auto& dest : dests_id()) {
518
510
            ss->related_op_ids.insert(dest);
519
510
        }
520
510
        return ss;
521
510
    }
522
510
}
_ZNK5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
46.8k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
46.8k
    } else {
515
46.8k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
46.8k
        ss->id = operator_id();
517
46.8k
        for (auto& dest : dests_id()) {
518
46.5k
            ss->related_op_ids.insert(dest);
519
46.5k
        }
520
46.8k
        return ss;
521
46.8k
    }
522
46.8k
}
_ZNK5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.70k
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.70k
    } else {
515
9.70k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.70k
        ss->id = operator_id();
517
9.70k
        for (auto& dest : dests_id()) {
518
9.70k
            ss->related_op_ids.insert(dest);
519
9.70k
        }
520
9.70k
        return ss;
521
9.70k
    }
522
9.70k
}
_ZNK5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
5.05k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
5.05k
    } else {
515
5.05k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
5.05k
        ss->id = operator_id();
517
5.05k
        for (auto& dest : dests_id()) {
518
5.05k
            ss->related_op_ids.insert(dest);
519
5.05k
        }
520
5.05k
        return ss;
521
5.05k
    }
522
5.05k
}
_ZNK5doris17DataSinkOperatorXINS_22TVFTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
156
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
156
    } else {
515
156
        auto ss = LocalStateType::SharedStateType::create_shared();
516
156
        ss->id = operator_id();
517
156
        for (auto& dest : dests_id()) {
518
156
            ss->related_op_ids.insert(dest);
519
156
        }
520
156
        return ss;
521
156
    }
522
156
}
_ZNK5doris17DataSinkOperatorXINS_26IcebergTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
4.01k
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.01k
    } else {
515
4.01k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
4.01k
        ss->id = operator_id();
517
4.01k
        for (auto& dest : dests_id()) {
518
4.01k
            ss->related_op_ids.insert(dest);
519
4.01k
        }
520
4.01k
        return ss;
521
4.01k
    }
522
4.01k
}
_ZNK5doris17DataSinkOperatorXINS_31SpillIcebergTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
48
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
48
    } else {
515
48
        auto ss = LocalStateType::SharedStateType::create_shared();
516
48
        ss->id = operator_id();
517
48
        for (auto& dest : dests_id()) {
518
48
            ss->related_op_ids.insert(dest);
519
48
        }
520
48
        return ss;
521
48
    }
522
48
}
_ZNK5doris17DataSinkOperatorXINS_27IcebergDeleteSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
704
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
704
    } else {
515
704
        auto ss = LocalStateType::SharedStateType::create_shared();
516
704
        ss->id = operator_id();
517
704
        for (auto& dest : dests_id()) {
518
704
            ss->related_op_ids.insert(dest);
519
704
        }
520
704
        return ss;
521
704
    }
522
704
}
_ZNK5doris17DataSinkOperatorXINS_26IcebergMergeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
1.71k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
1.71k
    } else {
515
1.71k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.71k
        ss->id = operator_id();
517
1.71k
        for (auto& dest : dests_id()) {
518
1.71k
            ss->related_op_ids.insert(dest);
519
1.71k
        }
520
1.71k
        return ss;
521
1.71k
    }
522
1.71k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
7.53k
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.53k
    } else {
515
7.53k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
7.53k
        ss->id = operator_id();
517
7.53k
        for (auto& dest : dests_id()) {
518
7.52k
            ss->related_op_ids.insert(dest);
519
7.52k
        }
520
7.53k
        return ss;
521
7.53k
    }
522
7.53k
}
_ZNK5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE19create_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_18SortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
280k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
280k
    } else {
515
280k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
280k
        ss->id = operator_id();
517
280k
        for (auto& dest : dests_id()) {
518
279k
            ss->related_op_ids.insert(dest);
519
279k
        }
520
280k
        return ss;
521
280k
    }
522
280k
}
_ZNK5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
34
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
34
    } else {
515
34
        auto ss = LocalStateType::SharedStateType::create_shared();
516
34
        ss->id = operator_id();
517
34
        for (auto& dest : dests_id()) {
518
34
            ss->related_op_ids.insert(dest);
519
34
        }
520
34
        return ss;
521
34
    }
522
34
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
165k
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
165k
    } else {
515
165k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
165k
        ss->id = operator_id();
517
165k
        for (auto& dest : dests_id()) {
518
165k
            ss->related_op_ids.insert(dest);
519
165k
        }
520
165k
        return ss;
521
165k
    }
522
165k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
189
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
189
    } else {
515
189
        auto ss = LocalStateType::SharedStateType::create_shared();
516
189
        ss->id = operator_id();
517
189
        for (auto& dest : dests_id()) {
518
189
            ss->related_op_ids.insert(dest);
519
189
        }
520
189
        return ss;
521
189
    }
522
189
}
_ZNK5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
676k
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
676k
    } else {
515
676k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
676k
        ss->id = operator_id();
517
676k
        for (auto& dest : dests_id()) {
518
671k
            ss->related_op_ids.insert(dest);
519
671k
        }
520
676k
        return ss;
521
676k
    }
522
676k
}
_ZNK5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.62k
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.62k
    } else {
515
9.62k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.62k
        ss->id = operator_id();
517
9.62k
        for (auto& dest : dests_id()) {
518
9.61k
            ss->related_op_ids.insert(dest);
519
9.61k
        }
520
9.62k
        return ss;
521
9.62k
    }
522
9.62k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
299
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
299
    } else {
515
299
        auto ss = LocalStateType::SharedStateType::create_shared();
516
299
        ss->id = operator_id();
517
299
        for (auto& dest : dests_id()) {
518
299
            ss->related_op_ids.insert(dest);
519
299
        }
520
299
        return ss;
521
299
    }
522
299
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE19create_shared_stateEv
Line
Count
Source
507
2.53k
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.53k
    } else {
515
2.53k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.53k
        ss->id = operator_id();
517
2.53k
        for (auto& dest : dests_id()) {
518
2.51k
            ss->related_op_ids.insert(dest);
519
2.51k
        }
520
2.53k
        return ss;
521
2.53k
    }
522
2.53k
}
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE19create_shared_stateEv
Line
Count
Source
507
2.41k
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.41k
    } else {
515
2.41k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.41k
        ss->id = operator_id();
517
2.41k
        for (auto& dest : dests_id()) {
518
2.40k
            ss->related_op_ids.insert(dest);
519
2.40k
        }
520
2.41k
        return ss;
521
2.41k
    }
522
2.41k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33PartitionedHashJoinSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_30GroupCommitBlockSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
564
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
564
    } else {
515
564
        auto ss = LocalStateType::SharedStateType::create_shared();
516
564
        ss->id = operator_id();
517
564
        for (auto& dest : dests_id()) {
518
562
            ss->related_op_ids.insert(dest);
519
562
        }
520
564
        return ss;
521
564
    }
522
564
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
101
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
101
    } else {
515
101
        auto ss = LocalStateType::SharedStateType::create_shared();
516
101
        ss->id = operator_id();
517
101
        for (auto& dest : dests_id()) {
518
101
            ss->related_op_ids.insert(dest);
519
101
        }
520
101
        return ss;
521
101
    }
522
101
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE19create_shared_stateEv
523
524
template <typename LocalStateType>
525
2.36M
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.36M
    auto local_state = LocalStateType::create_unique(state, this);
527
2.36M
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.36M
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.36M
    return Status::OK();
530
2.36M
}
_ZN5doris9OperatorXINS_23HashJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
74.7k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
74.7k
    auto local_state = LocalStateType::create_unique(state, this);
527
74.7k
    RETURN_IF_ERROR(local_state->init(state, info));
528
74.7k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
74.7k
    return Status::OK();
530
74.7k
}
_ZN5doris9OperatorXINS_18OlapScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
320k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
320k
    auto local_state = LocalStateType::create_unique(state, this);
527
320k
    RETURN_IF_ERROR(local_state->init(state, info));
528
320k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
320k
    return Status::OK();
530
320k
}
_ZN5doris9OperatorXINS_21GroupCommitLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
165
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
165
    auto local_state = LocalStateType::create_unique(state, this);
527
165
    RETURN_IF_ERROR(local_state->init(state, info));
528
165
    state->emplace_local_state(operator_id(), std::move(local_state));
529
165
    return Status::OK();
530
165
}
Unexecuted instantiation: _ZN5doris9OperatorXINS_18JDBCScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris9OperatorXINS_18FileScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
37.9k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
37.9k
    auto local_state = LocalStateType::create_unique(state, this);
527
37.9k
    RETURN_IF_ERROR(local_state->init(state, info));
528
37.9k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
37.9k
    return Status::OK();
530
37.9k
}
_ZN5doris9OperatorXINS_18AnalyticLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.45k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.45k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.45k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.45k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.45k
    return Status::OK();
530
7.45k
}
_ZN5doris9OperatorXINS_14SortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.72k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.72k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.72k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.72k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.72k
    return Status::OK();
530
7.72k
}
_ZN5doris9OperatorXINS_19SpillSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
25
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
25
    auto local_state = LocalStateType::create_unique(state, this);
527
25
    RETURN_IF_ERROR(local_state->init(state, info));
528
25
    state->emplace_local_state(operator_id(), std::move(local_state));
529
25
    return Status::OK();
530
25
}
_ZN5doris9OperatorXINS_24LocalMergeSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
270k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
270k
    auto local_state = LocalStateType::create_unique(state, this);
527
270k
    RETURN_IF_ERROR(local_state->init(state, info));
528
270k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
270k
    return Status::OK();
530
270k
}
_ZN5doris9OperatorXINS_13AggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
164k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
164k
    auto local_state = LocalStateType::create_unique(state, this);
527
164k
    RETURN_IF_ERROR(local_state->init(state, info));
528
164k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
164k
    return Status::OK();
530
164k
}
_ZN5doris9OperatorXINS_21BucketedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
539
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
539
    auto local_state = LocalStateType::create_unique(state, this);
527
539
    RETURN_IF_ERROR(local_state->init(state, info));
528
539
    state->emplace_local_state(operator_id(), std::move(local_state));
529
539
    return Status::OK();
530
539
}
_ZN5doris9OperatorXINS_24PartitionedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
180
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
180
    auto local_state = LocalStateType::create_unique(state, this);
527
180
    RETURN_IF_ERROR(local_state->init(state, info));
528
180
    state->emplace_local_state(operator_id(), std::move(local_state));
529
180
    return Status::OK();
530
180
}
_ZN5doris9OperatorXINS_23TableFunctionLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
4.24k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
4.24k
    auto local_state = LocalStateType::create_unique(state, this);
527
4.24k
    RETURN_IF_ERROR(local_state->init(state, info));
528
4.24k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
4.24k
    return Status::OK();
530
4.24k
}
_ZN5doris9OperatorXINS_18ExchangeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
349k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
349k
    auto local_state = LocalStateType::create_unique(state, this);
527
349k
    RETURN_IF_ERROR(local_state->init(state, info));
528
349k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
349k
    return Status::OK();
530
349k
}
_ZN5doris9OperatorXINS_16RepeatLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.36k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.36k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.36k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.36k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.36k
    return Status::OK();
530
1.36k
}
_ZN5doris9OperatorXINS_29NestedLoopJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
9.60k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
9.60k
    auto local_state = LocalStateType::create_unique(state, this);
527
9.60k
    RETURN_IF_ERROR(local_state->init(state, info));
528
9.60k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
9.60k
    return Status::OK();
530
9.60k
}
_ZN5doris9OperatorXINS_23AssertNumRowsLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
221
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
221
    auto local_state = LocalStateType::create_unique(state, this);
527
221
    RETURN_IF_ERROR(local_state->init(state, info));
528
221
    state->emplace_local_state(operator_id(), std::move(local_state));
529
221
    return Status::OK();
530
221
}
_ZN5doris9OperatorXINS_18EmptySetLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.99k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.99k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.99k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.99k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.99k
    return Status::OK();
530
1.99k
}
_ZN5doris9OperatorXINS_21UnionSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
56.9k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
56.9k
    auto local_state = LocalStateType::create_unique(state, this);
527
56.9k
    RETURN_IF_ERROR(local_state->init(state, info));
528
56.9k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
56.9k
    return Status::OK();
530
56.9k
}
_ZN5doris9OperatorXINS_35MultiCastDataStreamSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
11.0k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
11.0k
    auto local_state = LocalStateType::create_unique(state, this);
527
11.0k
    RETURN_IF_ERROR(local_state->init(state, info));
528
11.0k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
11.0k
    return Status::OK();
530
11.0k
}
_ZN5doris9OperatorXINS_29PartitionSortSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
197
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
197
    auto local_state = LocalStateType::create_unique(state, this);
527
197
    RETURN_IF_ERROR(local_state->init(state, info));
528
197
    state->emplace_local_state(operator_id(), std::move(local_state));
529
197
    return Status::OK();
530
197
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.58k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.58k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.58k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.58k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.58k
    return Status::OK();
530
2.58k
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.46k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.46k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.46k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.46k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.46k
    return Status::OK();
530
2.46k
}
_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
6.71k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
6.71k
    auto local_state = LocalStateType::create_unique(state, this);
527
6.71k
    RETURN_IF_ERROR(local_state->init(state, info));
528
6.71k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
6.71k
    return Status::OK();
530
6.71k
}
_ZN5doris9OperatorXINS_29LocalExchangeSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
688k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
688k
    auto local_state = LocalStateType::create_unique(state, this);
527
688k
    RETURN_IF_ERROR(local_state->init(state, info));
528
688k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
688k
    return Status::OK();
530
688k
}
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.97k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.97k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.97k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.97k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.97k
    return Status::OK();
530
2.97k
}
_ZN5doris9OperatorXINS_22StreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
11.9k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
11.9k
    auto local_state = LocalStateType::create_unique(state, this);
527
11.9k
    RETURN_IF_ERROR(local_state->init(state, info));
528
11.9k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
11.9k
    return Status::OK();
530
11.9k
}
_ZN5doris9OperatorXINS_30DistinctStreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
324k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
324k
    auto local_state = LocalStateType::create_unique(state, this);
527
324k
    RETURN_IF_ERROR(local_state->init(state, info));
528
324k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
324k
    return Status::OK();
530
324k
}
531
532
PipelineXSinkLocalStateBase::PipelineXSinkLocalStateBase(DataSinkOperatorXBase* parent,
533
                                                         RuntimeState* state)
534
2.00M
        : _parent(parent), _state(state) {}
535
536
PipelineXLocalStateBase::PipelineXLocalStateBase(RuntimeState* state, OperatorXBase* parent)
537
2.36M
        : _num_rows_returned(0),
538
2.36M
          _rows_returned_counter(nullptr),
539
2.36M
          _parent(parent),
540
2.36M
          _state(state),
541
2.36M
          _budget(state->batch_size(), state->preferred_block_size_bytes()) {}
542
543
template <typename SharedStateArg>
544
2.36M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
2.36M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
2.36M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
2.36M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
2.36M
    _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.36M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
2.36M
    _operator_profile->add_child(_common_profile.get(), true);
553
2.36M
    _operator_profile->add_child(_custom_profile.get(), true);
554
2.36M
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
2.36M
    if constexpr (!is_fake_shared) {
556
1.30M
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
707k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
707k
                                    .first.get()
559
707k
                                    ->template cast<SharedStateArg>();
560
561
707k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
707k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
707k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
707k
        } else if (info.shared_state) {
565
521k
            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
521k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
521k
            _dependency = _shared_state->create_source_dependency(
572
521k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
521k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
521k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
521k
        } else {
576
73.2k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
7.14k
                DCHECK(false);
578
7.14k
            }
579
73.2k
        }
580
1.30M
    }
581
582
2.36M
    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.36M
    _rows_returned_counter =
587
2.36M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
2.36M
    _blocks_returned_counter =
589
2.36M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
2.36M
    _output_block_bytes_counter =
591
2.36M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
2.36M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
2.36M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
2.36M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
2.36M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
2.36M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
2.36M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
2.36M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
2.36M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
2.36M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
2.36M
    _memory_used_counter =
602
2.36M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
2.36M
    _common_profile->add_info_string("IsColocate",
604
2.36M
                                     std::to_string(_parent->is_colocated_operator()));
605
2.36M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
2.36M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
2.36M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
2.36M
    return Status::OK();
609
2.36M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
74.9k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
74.9k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
74.9k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
74.9k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
74.9k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
74.9k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
74.9k
    _operator_profile->add_child(_common_profile.get(), true);
553
74.9k
    _operator_profile->add_child(_custom_profile.get(), true);
554
74.9k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
74.9k
    if constexpr (!is_fake_shared) {
556
74.9k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
23.6k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
23.6k
                                    .first.get()
559
23.6k
                                    ->template cast<SharedStateArg>();
560
561
23.6k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
23.6k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
23.6k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
51.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
50.5k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
50.5k
            _dependency = _shared_state->create_source_dependency(
572
50.5k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
50.5k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
50.5k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
50.5k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
753
        }
580
74.9k
    }
581
582
74.9k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
74.9k
    _rows_returned_counter =
587
74.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
74.9k
    _blocks_returned_counter =
589
74.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
74.9k
    _output_block_bytes_counter =
591
74.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
74.9k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
74.9k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
74.9k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
74.9k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
74.9k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
74.9k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
74.9k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
74.9k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
74.9k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
74.9k
    _memory_used_counter =
602
74.9k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
74.9k
    _common_profile->add_info_string("IsColocate",
604
74.9k
                                     std::to_string(_parent->is_colocated_operator()));
605
74.9k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
74.9k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
74.9k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
74.9k
    return Status::OK();
609
74.9k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
1
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1
    _operator_profile->add_child(_common_profile.get(), true);
553
1
    _operator_profile->add_child(_custom_profile.get(), true);
554
1
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
1
    if constexpr (!is_fake_shared) {
556
1
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
1
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
1
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
1
            _dependency = _shared_state->create_source_dependency(
572
1
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
1
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
1
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
1
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
1
    }
581
582
1
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
1
    _rows_returned_counter =
587
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1
    _blocks_returned_counter =
589
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1
    _output_block_bytes_counter =
591
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1
    _memory_used_counter =
602
1
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1
    _common_profile->add_info_string("IsColocate",
604
1
                                     std::to_string(_parent->is_colocated_operator()));
605
1
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1
    return Status::OK();
609
1
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
279k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
279k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
279k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
279k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
279k
    _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
279k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
279k
    _operator_profile->add_child(_common_profile.get(), true);
553
279k
    _operator_profile->add_child(_custom_profile.get(), true);
554
279k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
279k
    if constexpr (!is_fake_shared) {
556
279k
        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
279k
        } 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
270k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
270k
            _dependency = _shared_state->create_source_dependency(
572
270k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
270k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
270k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
270k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
9.65k
        }
580
279k
    }
581
582
279k
    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
279k
    _rows_returned_counter =
587
279k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
279k
    _blocks_returned_counter =
589
279k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
279k
    _output_block_bytes_counter =
591
279k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
279k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
279k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
279k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
279k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
279k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
279k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
279k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
279k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
279k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
279k
    _memory_used_counter =
602
279k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
279k
    _common_profile->add_info_string("IsColocate",
604
279k
                                     std::to_string(_parent->is_colocated_operator()));
605
279k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
279k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
279k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
279k
    return Status::OK();
609
279k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
25
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
25
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
25
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
25
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
25
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
25
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
25
    _operator_profile->add_child(_common_profile.get(), true);
553
25
    _operator_profile->add_child(_custom_profile.get(), true);
554
25
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
25
    if constexpr (!is_fake_shared) {
556
25
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
25
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
25
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
25
            _dependency = _shared_state->create_source_dependency(
572
25
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
25
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
25
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
25
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
25
    }
581
582
25
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
25
    _rows_returned_counter =
587
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
25
    _blocks_returned_counter =
589
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
25
    _output_block_bytes_counter =
591
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
25
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
25
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
25
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
25
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
25
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
25
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
25
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
25
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
25
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
25
    _memory_used_counter =
602
25
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
25
    _common_profile->add_info_string("IsColocate",
604
25
                                     std::to_string(_parent->is_colocated_operator()));
605
25
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
25
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
25
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
25
    return Status::OK();
609
25
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
9.61k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
9.61k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
9.61k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
9.61k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
9.61k
    _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.61k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
9.61k
    _operator_profile->add_child(_common_profile.get(), true);
553
9.61k
    _operator_profile->add_child(_custom_profile.get(), true);
554
9.61k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
9.61k
    if constexpr (!is_fake_shared) {
556
9.61k
        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.61k
        } 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.55k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
9.55k
            _dependency = _shared_state->create_source_dependency(
572
9.55k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
9.55k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
9.55k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
9.55k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
59
        }
580
9.61k
    }
581
582
9.61k
    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.61k
    _rows_returned_counter =
587
9.61k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
9.61k
    _blocks_returned_counter =
589
9.61k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
9.61k
    _output_block_bytes_counter =
591
9.61k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
9.61k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
9.61k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
9.61k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
9.61k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
9.61k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
9.61k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
9.61k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
9.61k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
9.61k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
9.61k
    _memory_used_counter =
602
9.61k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
9.61k
    _common_profile->add_info_string("IsColocate",
604
9.61k
                                     std::to_string(_parent->is_colocated_operator()));
605
9.61k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
9.61k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
9.61k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
9.61k
    return Status::OK();
609
9.61k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
7.53k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
7.53k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
7.53k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
7.53k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
7.53k
    _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.53k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
7.53k
    _operator_profile->add_child(_common_profile.get(), true);
553
7.53k
    _operator_profile->add_child(_custom_profile.get(), true);
554
7.53k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
7.53k
    if constexpr (!is_fake_shared) {
556
7.53k
        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.53k
        } 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.28k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
7.28k
            _dependency = _shared_state->create_source_dependency(
572
7.28k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
7.28k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
7.28k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
7.28k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
245
        }
580
7.53k
    }
581
582
7.53k
    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.53k
    _rows_returned_counter =
587
7.53k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
7.53k
    _blocks_returned_counter =
589
7.53k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
7.53k
    _output_block_bytes_counter =
591
7.53k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
7.53k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
7.53k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
7.53k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
7.53k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
7.53k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
7.53k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
7.53k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
7.53k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
7.53k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
7.53k
    _memory_used_counter =
602
7.53k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
7.53k
    _common_profile->add_info_string("IsColocate",
604
7.53k
                                     std::to_string(_parent->is_colocated_operator()));
605
7.53k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
7.53k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
7.53k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
7.53k
    return Status::OK();
609
7.53k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
165k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
165k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
165k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
165k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
165k
    _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
165k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
165k
    _operator_profile->add_child(_common_profile.get(), true);
553
165k
    _operator_profile->add_child(_custom_profile.get(), true);
554
165k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
165k
    if constexpr (!is_fake_shared) {
556
165k
        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
165k
        } 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
163k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
163k
            _dependency = _shared_state->create_source_dependency(
572
163k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
163k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
163k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
163k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
1.88k
        }
580
165k
    }
581
582
165k
    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
165k
    _rows_returned_counter =
587
165k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
165k
    _blocks_returned_counter =
589
165k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
165k
    _output_block_bytes_counter =
591
165k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
165k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
165k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
165k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
165k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
165k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
165k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
165k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
165k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
165k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
165k
    _memory_used_counter =
602
165k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
165k
    _common_profile->add_info_string("IsColocate",
604
165k
                                     std::to_string(_parent->is_colocated_operator()));
605
165k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
165k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
165k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
165k
    return Status::OK();
609
165k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
545
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
545
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
545
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
545
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
545
    _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
545
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
545
    _operator_profile->add_child(_common_profile.get(), true);
553
545
    _operator_profile->add_child(_custom_profile.get(), true);
554
545
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
545
    if constexpr (!is_fake_shared) {
556
545
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
519
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
519
                                    .first.get()
559
519
                                    ->template cast<SharedStateArg>();
560
561
519
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
519
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
519
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
519
        } 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
26
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
26
        }
580
545
    }
581
582
545
    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
545
    _rows_returned_counter =
587
545
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
545
    _blocks_returned_counter =
589
545
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
545
    _output_block_bytes_counter =
591
545
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
545
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
545
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
545
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
545
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
545
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
545
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
545
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
545
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
545
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
545
    _memory_used_counter =
602
545
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
545
    _common_profile->add_info_string("IsColocate",
604
545
                                     std::to_string(_parent->is_colocated_operator()));
605
545
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
545
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
545
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
545
    return Status::OK();
609
545
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
180
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
180
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
180
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
180
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
180
    _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
180
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
180
    _operator_profile->add_child(_common_profile.get(), true);
553
180
    _operator_profile->add_child(_custom_profile.get(), true);
554
180
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
180
    if constexpr (!is_fake_shared) {
556
180
        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
180
        } 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
180
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
180
            _dependency = _shared_state->create_source_dependency(
572
180
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
180
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
180
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
180
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
180
    }
581
582
180
    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
180
    _rows_returned_counter =
587
180
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
180
    _blocks_returned_counter =
589
180
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
180
    _output_block_bytes_counter =
591
180
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
180
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
180
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
180
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
180
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
180
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
180
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
180
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
180
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
180
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
180
    _memory_used_counter =
602
180
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
180
    _common_profile->add_info_string("IsColocate",
604
180
                                     std::to_string(_parent->is_colocated_operator()));
605
180
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
180
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
180
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
180
    return Status::OK();
609
180
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1.06M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1.06M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1.06M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1.06M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1.06M
    _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.06M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1.06M
    _operator_profile->add_child(_common_profile.get(), true);
553
1.06M
    _operator_profile->add_child(_custom_profile.get(), true);
554
1.06M
    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.06M
    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.06M
    _rows_returned_counter =
587
1.06M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1.06M
    _blocks_returned_counter =
589
1.06M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1.06M
    _output_block_bytes_counter =
591
1.06M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1.06M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1.06M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1.06M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1.06M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1.06M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1.06M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1.06M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1.06M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1.06M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1.06M
    _memory_used_counter =
602
1.06M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1.06M
    _common_profile->add_info_string("IsColocate",
604
1.06M
                                     std::to_string(_parent->is_colocated_operator()));
605
1.06M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1.06M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1.06M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1.06M
    return Status::OK();
609
1.06M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
56.8k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
56.8k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
56.8k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
56.8k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
56.8k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
56.8k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
56.8k
    _operator_profile->add_child(_common_profile.get(), true);
553
56.8k
    _operator_profile->add_child(_custom_profile.get(), true);
554
56.8k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
56.8k
    if constexpr (!is_fake_shared) {
556
56.8k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
56.8k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
3.44k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
3.44k
            _dependency = _shared_state->create_source_dependency(
572
3.44k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
3.44k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
3.44k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
53.4k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
53.4k
        }
580
56.8k
    }
581
582
56.8k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
56.8k
    _rows_returned_counter =
587
56.8k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
56.8k
    _blocks_returned_counter =
589
56.8k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
56.8k
    _output_block_bytes_counter =
591
56.8k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
56.8k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
56.8k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
56.8k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
56.8k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
56.8k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
56.8k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
56.8k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
56.8k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
56.8k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
56.8k
    _memory_used_counter =
602
56.8k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
56.8k
    _common_profile->add_info_string("IsColocate",
604
56.8k
                                     std::to_string(_parent->is_colocated_operator()));
605
56.8k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
56.8k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
56.8k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
56.8k
    return Status::OK();
609
56.8k
}
_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
11.0k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
11.0k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
11.0k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
11.0k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
11.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
11.0k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
11.0k
    _operator_profile->add_child(_common_profile.get(), true);
553
11.0k
    _operator_profile->add_child(_custom_profile.get(), true);
554
11.0k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
11.0k
    if constexpr (!is_fake_shared) {
556
11.0k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
11.0k
        } 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.9k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
10.9k
            _dependency = _shared_state->create_source_dependency(
572
10.9k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
10.9k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
10.9k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
10.9k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
27
        }
580
11.0k
    }
581
582
11.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
11.0k
    _rows_returned_counter =
587
11.0k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
11.0k
    _blocks_returned_counter =
589
11.0k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
11.0k
    _output_block_bytes_counter =
591
11.0k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
11.0k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
11.0k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
11.0k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
11.0k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
11.0k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
11.0k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
11.0k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
11.0k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
11.0k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
11.0k
    _memory_used_counter =
602
11.0k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
11.0k
    _common_profile->add_info_string("IsColocate",
604
11.0k
                                     std::to_string(_parent->is_colocated_operator()));
605
11.0k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
11.0k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
11.0k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
11.0k
    return Status::OK();
609
11.0k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
299
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
299
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
299
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
299
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
299
    _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
299
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
299
    _operator_profile->add_child(_common_profile.get(), true);
553
299
    _operator_profile->add_child(_custom_profile.get(), true);
554
299
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
299
    if constexpr (!is_fake_shared) {
556
299
        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
299
        } 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
299
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
299
            _dependency = _shared_state->create_source_dependency(
572
299
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
299
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
299
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
299
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
299
    }
581
582
299
    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
299
    _rows_returned_counter =
587
299
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
299
    _blocks_returned_counter =
589
299
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
299
    _output_block_bytes_counter =
591
299
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
299
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
299
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
299
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
299
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
299
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
299
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
299
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
299
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
299
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
299
    _memory_used_counter =
602
299
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
299
    _common_profile->add_info_string("IsColocate",
604
299
                                     std::to_string(_parent->is_colocated_operator()));
605
299
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
299
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
299
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
299
    return Status::OK();
609
299
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
5.06k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
5.06k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
5.06k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
5.06k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
5.06k
    _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.06k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
5.06k
    _operator_profile->add_child(_common_profile.get(), true);
553
5.06k
    _operator_profile->add_child(_custom_profile.get(), true);
554
5.06k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
5.06k
    if constexpr (!is_fake_shared) {
556
5.06k
        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.06k
        } 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.03k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
5.03k
            _dependency = _shared_state->create_source_dependency(
572
5.03k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
5.03k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
5.03k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
5.03k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
28
        }
580
5.06k
    }
581
582
5.06k
    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.06k
    _rows_returned_counter =
587
5.06k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
5.06k
    _blocks_returned_counter =
589
5.06k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
5.06k
    _output_block_bytes_counter =
591
5.06k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
5.06k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
5.06k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
5.06k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
5.06k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
5.06k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
5.06k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
5.06k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
5.06k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
5.06k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
5.06k
    _memory_used_counter =
602
5.06k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
5.06k
    _common_profile->add_info_string("IsColocate",
604
5.06k
                                     std::to_string(_parent->is_colocated_operator()));
605
5.06k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
5.06k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
5.06k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
5.06k
    return Status::OK();
609
5.06k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
690k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
690k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
690k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
690k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
690k
    _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
690k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
690k
    _operator_profile->add_child(_common_profile.get(), true);
553
690k
    _operator_profile->add_child(_custom_profile.get(), true);
554
690k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
690k
    if constexpr (!is_fake_shared) {
556
690k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
683k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
683k
                                    .first.get()
559
683k
                                    ->template cast<SharedStateArg>();
560
561
683k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
683k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
683k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
683k
        } 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
7.14k
        } else {
576
7.14k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
7.14k
                DCHECK(false);
578
7.14k
            }
579
7.14k
        }
580
690k
    }
581
582
690k
    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
690k
    _rows_returned_counter =
587
690k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
690k
    _blocks_returned_counter =
589
690k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
690k
    _output_block_bytes_counter =
591
690k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
690k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
690k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
690k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
690k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
690k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
690k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
690k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
690k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
690k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
690k
    _memory_used_counter =
602
690k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
690k
    _common_profile->add_info_string("IsColocate",
604
690k
                                     std::to_string(_parent->is_colocated_operator()));
605
690k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
690k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
690k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
690k
    return Status::OK();
609
690k
}
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.37M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
2.37M
    _conjuncts.resize(_parent->_conjuncts.size());
614
2.37M
    _projections.resize(_parent->_projections.size());
615
2.91M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
542k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
542k
    }
618
5.23M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.85M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.85M
    }
621
2.37M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
2.39M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
15.5k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
116k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
100k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
100k
                    state, _intermediate_projections[i][j]));
627
100k
        }
628
15.5k
    }
629
2.37M
    return Status::OK();
630
2.37M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
74.9k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
74.9k
    _conjuncts.resize(_parent->_conjuncts.size());
614
74.9k
    _projections.resize(_parent->_projections.size());
615
75.8k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
842
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
842
    }
618
366k
    for (size_t i = 0; i < _projections.size(); i++) {
619
291k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
291k
    }
621
74.9k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
78.0k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
3.03k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
40.2k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
37.2k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
37.2k
                    state, _intermediate_projections[i][j]));
627
37.2k
        }
628
3.03k
    }
629
74.9k
    return Status::OK();
630
74.9k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
3
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
3
    _conjuncts.resize(_parent->_conjuncts.size());
614
3
    _projections.resize(_parent->_projections.size());
615
3
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
3
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
3
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
3
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
3
    return Status::OK();
630
3
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
280k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
280k
    _conjuncts.resize(_parent->_conjuncts.size());
614
280k
    _projections.resize(_parent->_projections.size());
615
280k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
280k
    for (size_t i = 0; i < _projections.size(); i++) {
619
365
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
365
    }
621
280k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
280k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
280k
    return Status::OK();
630
280k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
24
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
24
    _conjuncts.resize(_parent->_conjuncts.size());
614
24
    _projections.resize(_parent->_projections.size());
615
24
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
24
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
24
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
24
    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
24
    return Status::OK();
630
24
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
9.62k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
9.62k
    _conjuncts.resize(_parent->_conjuncts.size());
614
9.62k
    _projections.resize(_parent->_projections.size());
615
9.67k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
53
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
53
    }
618
64.2k
    for (size_t i = 0; i < _projections.size(); i++) {
619
54.6k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
54.6k
    }
621
9.62k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
9.75k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
136
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
820
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
684
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
684
                    state, _intermediate_projections[i][j]));
627
684
        }
628
136
    }
629
9.62k
    return Status::OK();
630
9.62k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
7.56k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
7.56k
    _conjuncts.resize(_parent->_conjuncts.size());
614
7.56k
    _projections.resize(_parent->_projections.size());
615
8.27k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
711
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
711
    }
618
20.6k
    for (size_t i = 0; i < _projections.size(); i++) {
619
13.0k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
13.0k
    }
621
7.56k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
7.65k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
95
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
725
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
630
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
630
                    state, _intermediate_projections[i][j]));
627
630
        }
628
95
    }
629
7.56k
    return Status::OK();
630
7.56k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
165k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
165k
    _conjuncts.resize(_parent->_conjuncts.size());
614
165k
    _projections.resize(_parent->_projections.size());
615
170k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
5.02k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
5.02k
    }
618
433k
    for (size_t i = 0; i < _projections.size(); i++) {
619
268k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
268k
    }
621
165k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
165k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
287
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
2.01k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
1.72k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
1.72k
                    state, _intermediate_projections[i][j]));
627
1.72k
        }
628
287
    }
629
165k
    return Status::OK();
630
165k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
547
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
547
    _conjuncts.resize(_parent->_conjuncts.size());
614
547
    _projections.resize(_parent->_projections.size());
615
547
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
1.54k
    for (size_t i = 0; i < _projections.size(); i++) {
619
1.00k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
1.00k
    }
621
547
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
547
    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
547
    return Status::OK();
630
547
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
184
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
184
    _conjuncts.resize(_parent->_conjuncts.size());
614
184
    _projections.resize(_parent->_projections.size());
615
184
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
516
    for (size_t i = 0; i < _projections.size(); i++) {
619
332
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
332
    }
621
184
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
184
    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
184
    return Status::OK();
630
184
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
1.07M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
1.07M
    _conjuncts.resize(_parent->_conjuncts.size());
614
1.07M
    _projections.resize(_parent->_projections.size());
615
1.60M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
531k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
531k
    }
618
3.20M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.13M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.13M
    }
621
1.07M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
1.08M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
12.0k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
72.6k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
60.5k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
60.5k
                    state, _intermediate_projections[i][j]));
627
60.5k
        }
628
12.0k
    }
629
1.07M
    return Status::OK();
630
1.07M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
57.0k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
57.0k
    _conjuncts.resize(_parent->_conjuncts.size());
614
57.0k
    _projections.resize(_parent->_projections.size());
615
57.0k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
153k
    for (size_t i = 0; i < _projections.size(); i++) {
619
96.7k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
96.7k
    }
621
57.0k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
57.0k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
57.0k
    return Status::OK();
630
57.0k
}
_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
11.0k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
11.0k
    _conjuncts.resize(_parent->_conjuncts.size());
614
11.0k
    _projections.resize(_parent->_projections.size());
615
15.2k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
4.26k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
4.26k
    }
618
11.0k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
11.0k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
11.0k
    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
11.0k
    return Status::OK();
630
11.0k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
299
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
299
    _conjuncts.resize(_parent->_conjuncts.size());
614
299
    _projections.resize(_parent->_projections.size());
615
299
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
299
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
299
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
299
    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
299
    return Status::OK();
630
299
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
5.06k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
5.06k
    _conjuncts.resize(_parent->_conjuncts.size());
614
5.06k
    _projections.resize(_parent->_projections.size());
615
5.06k
    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.23k
    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.06k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
5.06k
    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.06k
    return Status::OK();
630
5.06k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
692k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
692k
    _conjuncts.resize(_parent->_conjuncts.size());
614
692k
    _projections.resize(_parent->_projections.size());
615
692k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
692k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
692k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
692k
    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
692k
    return Status::OK();
630
692k
}
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
6.63k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
6.63k
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
6.63k
    _terminated = true;
638
6.63k
    return Status::OK();
639
6.63k
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
341
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
341
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
341
    _terminated = true;
638
341
    return Status::OK();
639
341
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
53
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
53
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
53
    _terminated = true;
638
53
    return Status::OK();
639
53
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
47
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
47
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
47
    _terminated = true;
638
47
    return Status::OK();
639
47
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_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_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
207
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
207
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
207
    _terminated = true;
638
207
    return Status::OK();
639
207
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
4.93k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
4.93k
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
4.93k
    _terminated = true;
638
4.93k
    return Status::OK();
639
4.93k
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
8
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
8
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
8
    _terminated = true;
638
8
    return Status::OK();
639
8
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
13
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
13
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
13
    _terminated = true;
638
13
    return Status::OK();
639
13
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
1
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
1
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
1
    _terminated = true;
638
1
    return Status::OK();
639
1
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
33
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
33
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
33
    _terminated = true;
638
33
    return Status::OK();
639
33
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
984
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
984
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
984
    _terminated = true;
638
984
    return Status::OK();
639
984
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
13
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
13
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
13
    _terminated = true;
638
13
    return Status::OK();
639
13
}
640
641
template <typename SharedStateArg>
642
2.68M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
2.68M
    if (_closed) {
644
312k
        return Status::OK();
645
312k
    }
646
2.37M
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
1.30M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
1.30M
    }
649
2.37M
    _closed = true;
650
2.37M
    return Status::OK();
651
2.68M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
74.8k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
74.8k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
74.8k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
74.8k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
74.8k
    }
649
74.8k
    _closed = true;
650
74.8k
    return Status::OK();
651
74.8k
}
_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
557k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
557k
    if (_closed) {
644
279k
        return Status::OK();
645
279k
    }
646
277k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
277k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
277k
    }
649
277k
    _closed = true;
650
277k
    return Status::OK();
651
557k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
25
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
25
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
25
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
25
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
25
    }
649
25
    _closed = true;
650
25
    return Status::OK();
651
25
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
9.62k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
9.62k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
9.62k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
9.62k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
9.62k
    }
649
9.62k
    _closed = true;
650
9.62k
    return Status::OK();
651
9.62k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
15.2k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
15.2k
    if (_closed) {
644
7.70k
        return Status::OK();
645
7.70k
    }
646
7.54k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
7.54k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
7.54k
    }
649
7.54k
    _closed = true;
650
7.54k
    return Status::OK();
651
15.2k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
164k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
164k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
164k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
164k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
164k
    }
649
164k
    _closed = true;
650
164k
    return Status::OK();
651
164k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
546
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
546
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
546
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
546
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
546
    }
649
546
    _closed = true;
650
546
    return Status::OK();
651
546
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
179
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
179
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
179
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
179
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
179
    }
649
179
    _closed = true;
650
179
    return Status::OK();
651
179
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
1.09M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
1.09M
    if (_closed) {
644
20.2k
        return Status::OK();
645
20.2k
    }
646
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
    }
649
1.07M
    _closed = true;
650
1.07M
    return Status::OK();
651
1.09M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
57.1k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
57.1k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
57.1k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
57.1k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
57.1k
    }
649
57.1k
    _closed = true;
650
57.1k
    return Status::OK();
651
57.1k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
28
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
28
    if (_closed) {
644
14
        return Status::OK();
645
14
    }
646
14
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
14
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
14
    }
649
14
    _closed = true;
650
14
    return Status::OK();
651
28
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
10.9k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
10.9k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
10.9k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
10.9k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
10.9k
    }
649
10.9k
    _closed = true;
650
10.9k
    return Status::OK();
651
10.9k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
391
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
391
    if (_closed) {
644
197
        return Status::OK();
645
197
    }
646
194
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
194
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
194
    }
649
194
    _closed = true;
650
194
    return Status::OK();
651
391
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
10.1k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
10.1k
    if (_closed) {
644
5.13k
        return Status::OK();
645
5.13k
    }
646
5.04k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
5.04k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
5.04k
    }
649
5.04k
    _closed = true;
650
5.04k
    return Status::OK();
651
10.1k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
694k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
694k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
694k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
694k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
694k
    }
649
694k
    _closed = true;
650
694k
    return Status::OK();
651
694k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
331
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
331
    if (_closed) {
644
176
        return Status::OK();
645
176
    }
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
331
}
652
653
template <typename SharedState>
654
2.00M
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
2.00M
    _operator_profile =
657
2.00M
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
2.00M
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
2.00M
    _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.00M
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
2.00M
    _operator_profile->add_child(_common_profile, true);
666
2.00M
    _operator_profile->add_child(_custom_profile, true);
667
668
2.00M
    _operator_profile->set_metadata(_parent->node_id());
669
2.00M
    _wait_for_finish_dependency_timer =
670
2.00M
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
2.00M
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
2.00M
    if constexpr (!is_fake_shared) {
673
1.32M
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
1.32M
            info.shared_state_map.end()) {
675
276k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
252k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
252k
            }
678
276k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
276k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
276k
                                                  ? 0
681
276k
                                                  : info.task_idx]
682
276k
                                  .get();
683
276k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
1.05M
        } else {
685
1.05M
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
106
                DCHECK(false);
687
106
            }
688
1.05M
            _shared_state = info.shared_state->template cast<SharedState>();
689
1.05M
            _dependency = _shared_state->create_sink_dependency(
690
1.05M
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
1.05M
        }
692
1.32M
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
1.32M
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
1.32M
    }
695
696
2.00M
    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.00M
    _rows_input_counter =
701
2.00M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
2.00M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
2.00M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
2.00M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
2.00M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
2.00M
    _memory_used_counter =
707
2.00M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
2.00M
    _common_profile->add_info_string("IsColocate",
709
2.00M
                                     std::to_string(_parent->is_colocated_operator()));
710
2.00M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
2.00M
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
2.00M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
2.00M
    return Status::OK();
714
2.00M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
122k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
122k
    _operator_profile =
657
122k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
122k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
122k
    _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
122k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
122k
    _operator_profile->add_child(_common_profile, true);
666
122k
    _operator_profile->add_child(_custom_profile, true);
667
668
122k
    _operator_profile->set_metadata(_parent->node_id());
669
122k
    _wait_for_finish_dependency_timer =
670
122k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
122k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
122k
    if constexpr (!is_fake_shared) {
673
122k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
122k
            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
23.7k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
23.7k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
23.7k
                                                  ? 0
681
23.7k
                                                  : info.task_idx]
682
23.7k
                                  .get();
683
23.7k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
99.0k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
99.0k
            _shared_state = info.shared_state->template cast<SharedState>();
689
99.0k
            _dependency = _shared_state->create_sink_dependency(
690
99.0k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
99.0k
        }
692
122k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
122k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
122k
    }
695
696
122k
    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
122k
    _rows_input_counter =
701
122k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
122k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
122k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
122k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
122k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
122k
    _memory_used_counter =
707
122k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
122k
    _common_profile->add_info_string("IsColocate",
709
122k
                                     std::to_string(_parent->is_colocated_operator()));
710
122k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
122k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
122k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
122k
    return Status::OK();
714
122k
}
_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
279k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
279k
    _operator_profile =
657
279k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
279k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
279k
    _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
279k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
279k
    _operator_profile->add_child(_common_profile, true);
666
279k
    _operator_profile->add_child(_custom_profile, true);
667
668
279k
    _operator_profile->set_metadata(_parent->node_id());
669
279k
    _wait_for_finish_dependency_timer =
670
279k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
279k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
279k
    if constexpr (!is_fake_shared) {
673
279k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
279k
            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
279k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
279k
            _shared_state = info.shared_state->template cast<SharedState>();
689
279k
            _dependency = _shared_state->create_sink_dependency(
690
279k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
279k
        }
692
279k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
279k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
279k
    }
695
696
279k
    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
279k
    _rows_input_counter =
701
279k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
279k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
279k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
279k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
279k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
279k
    _memory_used_counter =
707
279k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
279k
    _common_profile->add_info_string("IsColocate",
709
279k
                                     std::to_string(_parent->is_colocated_operator()));
710
279k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
279k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
279k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
279k
    return Status::OK();
714
279k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
32
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
32
    _operator_profile =
657
32
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
32
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
32
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
32
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
32
    _operator_profile->add_child(_common_profile, true);
666
32
    _operator_profile->add_child(_custom_profile, true);
667
668
32
    _operator_profile->set_metadata(_parent->node_id());
669
32
    _wait_for_finish_dependency_timer =
670
32
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
32
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
32
    if constexpr (!is_fake_shared) {
673
32
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
32
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
32
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
32
            _shared_state = info.shared_state->template cast<SharedState>();
689
32
            _dependency = _shared_state->create_sink_dependency(
690
32
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
32
        }
692
32
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
32
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
32
    }
695
696
32
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
32
    _rows_input_counter =
701
32
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
32
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
32
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
32
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
32
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
32
    _memory_used_counter =
707
32
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
32
    _common_profile->add_info_string("IsColocate",
709
32
                                     std::to_string(_parent->is_colocated_operator()));
710
32
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
32
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
32
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
32
    return Status::OK();
714
32
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
9.61k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
9.61k
    _operator_profile =
657
9.61k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
9.61k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
9.61k
    _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.61k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
9.61k
    _operator_profile->add_child(_common_profile, true);
666
9.61k
    _operator_profile->add_child(_custom_profile, true);
667
668
9.61k
    _operator_profile->set_metadata(_parent->node_id());
669
9.61k
    _wait_for_finish_dependency_timer =
670
9.61k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
9.61k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
9.61k
    if constexpr (!is_fake_shared) {
673
9.61k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
9.61k
            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.61k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
9.61k
            _shared_state = info.shared_state->template cast<SharedState>();
689
9.61k
            _dependency = _shared_state->create_sink_dependency(
690
9.61k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
9.61k
        }
692
9.61k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
9.61k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
9.61k
    }
695
696
9.61k
    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.61k
    _rows_input_counter =
701
9.61k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
9.61k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
9.61k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
9.61k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
9.61k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
9.61k
    _memory_used_counter =
707
9.61k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
9.61k
    _common_profile->add_info_string("IsColocate",
709
9.61k
                                     std::to_string(_parent->is_colocated_operator()));
710
9.61k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
9.61k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
9.61k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
9.61k
    return Status::OK();
714
9.61k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
7.51k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
7.51k
    _operator_profile =
657
7.51k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
7.51k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
7.51k
    _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.51k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
7.51k
    _operator_profile->add_child(_common_profile, true);
666
7.51k
    _operator_profile->add_child(_custom_profile, true);
667
668
7.51k
    _operator_profile->set_metadata(_parent->node_id());
669
7.51k
    _wait_for_finish_dependency_timer =
670
7.51k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
7.51k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
7.51k
    if constexpr (!is_fake_shared) {
673
7.51k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
7.51k
            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.51k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
7.51k
            _shared_state = info.shared_state->template cast<SharedState>();
689
7.51k
            _dependency = _shared_state->create_sink_dependency(
690
7.51k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
7.51k
        }
692
7.51k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
7.51k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
7.51k
    }
695
696
7.51k
    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.51k
    _rows_input_counter =
701
7.51k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
7.51k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
7.51k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
7.51k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
7.51k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
7.51k
    _memory_used_counter =
707
7.51k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
7.51k
    _common_profile->add_info_string("IsColocate",
709
7.51k
                                     std::to_string(_parent->is_colocated_operator()));
710
7.51k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
7.51k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
7.51k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
7.51k
    return Status::OK();
714
7.51k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
165k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
165k
    _operator_profile =
657
165k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
165k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
165k
    _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
165k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
165k
    _operator_profile->add_child(_common_profile, true);
666
165k
    _operator_profile->add_child(_custom_profile, true);
667
668
165k
    _operator_profile->set_metadata(_parent->node_id());
669
165k
    _wait_for_finish_dependency_timer =
670
165k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
165k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
165k
    if constexpr (!is_fake_shared) {
673
165k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
165k
            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
165k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
165k
            _shared_state = info.shared_state->template cast<SharedState>();
689
165k
            _dependency = _shared_state->create_sink_dependency(
690
165k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
165k
        }
692
165k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
165k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
165k
    }
695
696
165k
    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
165k
    _rows_input_counter =
701
165k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
165k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
165k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
165k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
165k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
165k
    _memory_used_counter =
707
165k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
165k
    _common_profile->add_info_string("IsColocate",
709
165k
                                     std::to_string(_parent->is_colocated_operator()));
710
165k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
165k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
165k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
165k
    return Status::OK();
714
165k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
541
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
541
    _operator_profile =
657
541
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
541
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
541
    _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
541
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
541
    _operator_profile->add_child(_common_profile, true);
666
541
    _operator_profile->add_child(_custom_profile, true);
667
668
541
    _operator_profile->set_metadata(_parent->node_id());
669
541
    _wait_for_finish_dependency_timer =
670
541
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
541
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
541
    if constexpr (!is_fake_shared) {
673
541
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
541
            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
538
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
538
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
538
                                                  ? 0
681
538
                                                  : info.task_idx]
682
538
                                  .get();
683
538
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
538
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
3
            _shared_state = info.shared_state->template cast<SharedState>();
689
3
            _dependency = _shared_state->create_sink_dependency(
690
3
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
3
        }
692
541
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
541
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
541
    }
695
696
541
    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
541
    _rows_input_counter =
701
541
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
541
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
541
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
541
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
541
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
541
    _memory_used_counter =
707
541
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
541
    _common_profile->add_info_string("IsColocate",
709
541
                                     std::to_string(_parent->is_colocated_operator()));
710
541
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
541
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
541
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
541
    return Status::OK();
714
541
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
190
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
190
    _operator_profile =
657
190
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
190
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
190
    _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
190
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
190
    _operator_profile->add_child(_common_profile, true);
666
190
    _operator_profile->add_child(_custom_profile, true);
667
668
190
    _operator_profile->set_metadata(_parent->node_id());
669
190
    _wait_for_finish_dependency_timer =
670
190
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
190
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
190
    if constexpr (!is_fake_shared) {
673
190
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
190
            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
190
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
190
            _shared_state = info.shared_state->template cast<SharedState>();
689
190
            _dependency = _shared_state->create_sink_dependency(
690
190
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
190
        }
692
190
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
190
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
190
    }
695
696
190
    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
190
    _rows_input_counter =
701
190
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
190
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
190
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
190
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
190
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
190
    _memory_used_counter =
707
190
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
190
    _common_profile->add_info_string("IsColocate",
709
190
                                     std::to_string(_parent->is_colocated_operator()));
710
190
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
190
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
190
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
190
    return Status::OK();
714
190
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
678k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
678k
    _operator_profile =
657
678k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
678k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
678k
    _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
678k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
678k
    _operator_profile->add_child(_common_profile, true);
666
678k
    _operator_profile->add_child(_custom_profile, true);
667
668
678k
    _operator_profile->set_metadata(_parent->node_id());
669
678k
    _wait_for_finish_dependency_timer =
670
678k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
678k
    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
678k
    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
678k
    _rows_input_counter =
701
678k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
678k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
678k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
678k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
678k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
678k
    _memory_used_counter =
707
678k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
678k
    _common_profile->add_info_string("IsColocate",
709
678k
                                     std::to_string(_parent->is_colocated_operator()));
710
678k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
678k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
678k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
678k
    return Status::OK();
714
678k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
7.74k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
7.74k
    _operator_profile =
657
7.74k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
7.74k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
7.74k
    _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.74k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
7.74k
    _operator_profile->add_child(_common_profile, true);
666
7.74k
    _operator_profile->add_child(_custom_profile, true);
667
668
7.74k
    _operator_profile->set_metadata(_parent->node_id());
669
7.74k
    _wait_for_finish_dependency_timer =
670
7.74k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
7.74k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
7.74k
    if constexpr (!is_fake_shared) {
673
7.74k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
7.74k
            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.74k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
7.74k
            _shared_state = info.shared_state->template cast<SharedState>();
689
7.74k
            _dependency = _shared_state->create_sink_dependency(
690
7.74k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
7.74k
        }
692
7.74k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
7.74k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
7.74k
    }
695
696
7.74k
    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.74k
    _rows_input_counter =
701
7.74k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
7.74k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
7.74k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
7.74k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
7.74k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
7.74k
    _memory_used_counter =
707
7.74k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
7.74k
    _common_profile->add_info_string("IsColocate",
709
7.74k
                                     std::to_string(_parent->is_colocated_operator()));
710
7.74k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
7.74k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
7.74k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
7.74k
    return Status::OK();
714
7.74k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
298
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
298
    _operator_profile =
657
298
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
298
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
298
    _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
298
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
298
    _operator_profile->add_child(_common_profile, true);
666
298
    _operator_profile->add_child(_custom_profile, true);
667
668
298
    _operator_profile->set_metadata(_parent->node_id());
669
298
    _wait_for_finish_dependency_timer =
670
298
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
298
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
298
    if constexpr (!is_fake_shared) {
673
298
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
298
            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
298
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
298
            _shared_state = info.shared_state->template cast<SharedState>();
689
298
            _dependency = _shared_state->create_sink_dependency(
690
298
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
298
        }
692
298
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
298
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
298
    }
695
696
298
    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
298
    _rows_input_counter =
701
298
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
298
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
298
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
298
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
298
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
298
    _memory_used_counter =
707
298
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
298
    _common_profile->add_info_string("IsColocate",
709
298
                                     std::to_string(_parent->is_colocated_operator()));
710
298
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
298
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
298
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
298
    return Status::OK();
714
298
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
3.91k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
3.91k
    _operator_profile =
657
3.91k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
3.91k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
3.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
3.91k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
3.91k
    _operator_profile->add_child(_common_profile, true);
666
3.91k
    _operator_profile->add_child(_custom_profile, true);
667
668
3.91k
    _operator_profile->set_metadata(_parent->node_id());
669
3.91k
    _wait_for_finish_dependency_timer =
670
3.91k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
3.91k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
3.91k
    if constexpr (!is_fake_shared) {
673
3.91k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
3.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
3.91k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
3.91k
            _shared_state = info.shared_state->template cast<SharedState>();
689
3.91k
            _dependency = _shared_state->create_sink_dependency(
690
3.91k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
3.91k
        }
692
3.91k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
3.91k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
3.91k
    }
695
696
3.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
3.91k
    _rows_input_counter =
701
3.91k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
3.91k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
3.91k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
3.91k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
3.91k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
3.91k
    _memory_used_counter =
707
3.91k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
3.91k
    _common_profile->add_info_string("IsColocate",
709
3.91k
                                     std::to_string(_parent->is_colocated_operator()));
710
3.91k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
3.91k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
3.91k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
3.91k
    return Status::OK();
714
3.91k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
12.2k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
12.2k
    _operator_profile =
657
12.2k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
12.2k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
12.2k
    _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.2k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
12.2k
    _operator_profile->add_child(_common_profile, true);
666
12.2k
    _operator_profile->add_child(_custom_profile, true);
667
668
12.2k
    _operator_profile->set_metadata(_parent->node_id());
669
12.2k
    _wait_for_finish_dependency_timer =
670
12.2k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
12.2k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
12.2k
    if constexpr (!is_fake_shared) {
673
12.2k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
12.2k
            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.2k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
12.2k
            _shared_state = info.shared_state->template cast<SharedState>();
689
12.2k
            _dependency = _shared_state->create_sink_dependency(
690
12.2k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
12.2k
        }
692
12.2k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
12.2k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
12.2k
    }
695
696
12.2k
    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.2k
    _rows_input_counter =
701
12.2k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
12.2k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
12.2k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
12.2k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
12.2k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
12.2k
    _memory_used_counter =
707
12.2k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
12.2k
    _common_profile->add_info_string("IsColocate",
709
12.2k
                                     std::to_string(_parent->is_colocated_operator()));
710
12.2k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
12.2k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
12.2k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
12.2k
    return Status::OK();
714
12.2k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
252k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
252k
    _operator_profile =
657
252k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
252k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
252k
    _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
252k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
252k
    _operator_profile->add_child(_common_profile, true);
666
252k
    _operator_profile->add_child(_custom_profile, true);
667
668
252k
    _operator_profile->set_metadata(_parent->node_id());
669
252k
    _wait_for_finish_dependency_timer =
670
252k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
252k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
252k
    if constexpr (!is_fake_shared) {
673
252k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
252k
            info.shared_state_map.end()) {
675
252k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
252k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
252k
            }
678
252k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
252k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
252k
                                                  ? 0
681
252k
                                                  : info.task_idx]
682
252k
                                  .get();
683
252k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
252k
        } else {
685
106
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
106
                DCHECK(false);
687
106
            }
688
106
            _shared_state = info.shared_state->template cast<SharedState>();
689
106
            _dependency = _shared_state->create_sink_dependency(
690
106
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
106
        }
692
252k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
252k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
252k
    }
695
696
252k
    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
252k
    _rows_input_counter =
701
252k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
252k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
252k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
252k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
252k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
252k
    _memory_used_counter =
707
252k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
252k
    _common_profile->add_info_string("IsColocate",
709
252k
                                     std::to_string(_parent->is_colocated_operator()));
710
252k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
252k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
252k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
252k
    return Status::OK();
714
252k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
465k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
465k
    _operator_profile =
657
465k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
465k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
465k
    _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
465k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
465k
    _operator_profile->add_child(_common_profile, true);
666
465k
    _operator_profile->add_child(_custom_profile, true);
667
668
465k
    _operator_profile->set_metadata(_parent->node_id());
669
465k
    _wait_for_finish_dependency_timer =
670
465k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
465k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
465k
    if constexpr (!is_fake_shared) {
673
465k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
465k
            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
465k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
465k
            _shared_state = info.shared_state->template cast<SharedState>();
689
465k
            _dependency = _shared_state->create_sink_dependency(
690
465k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
465k
        }
692
465k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
465k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
465k
    }
695
696
465k
    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
465k
    _rows_input_counter =
701
465k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
465k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
465k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
465k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
465k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
465k
    _memory_used_counter =
707
465k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
465k
    _common_profile->add_info_string("IsColocate",
709
465k
                                     std::to_string(_parent->is_colocated_operator()));
710
465k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
465k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
465k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
465k
    return Status::OK();
714
465k
}
_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.01M
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
2.01M
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
2.01M
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
1.33M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
1.33M
    }
724
2.01M
    _closed = true;
725
2.01M
    return Status::OK();
726
2.01M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
122k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
122k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
122k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
122k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
122k
    }
724
122k
    _closed = true;
725
122k
    return Status::OK();
726
122k
}
_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
279k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
279k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
279k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
279k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
279k
    }
724
279k
    _closed = true;
725
279k
    return Status::OK();
726
279k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
23
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
23
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
21
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
21
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
21
    }
724
21
    _closed = true;
725
21
    return Status::OK();
726
23
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
9.60k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
9.60k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
9.60k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
9.60k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
9.60k
    }
724
9.60k
    _closed = true;
725
9.60k
    return Status::OK();
726
9.60k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
7.52k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
7.52k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
7.52k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
7.52k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
7.52k
    }
724
7.52k
    _closed = true;
725
7.52k
    return Status::OK();
726
7.52k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
164k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
164k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
164k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
164k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
164k
    }
724
164k
    _closed = true;
725
164k
    return Status::OK();
726
164k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
539
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
539
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
539
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
539
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
539
    }
724
539
    _closed = true;
725
539
    return Status::OK();
726
539
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
179
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
179
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
179
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
179
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
179
    }
724
179
    _closed = true;
725
179
    return Status::OK();
726
179
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
680k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
680k
    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
680k
    _closed = true;
725
680k
    return Status::OK();
726
680k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
7.75k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
7.75k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
7.75k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
7.75k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
7.75k
    }
724
7.75k
    _closed = true;
725
7.75k
    return Status::OK();
726
7.75k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
195
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
195
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
195
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
195
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
195
    }
724
195
    _closed = true;
725
195
    return Status::OK();
726
195
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
3.92k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
3.92k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
3.92k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
3.92k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
3.92k
    }
724
3.92k
    _closed = true;
725
3.92k
    return Status::OK();
726
3.92k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
12.3k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
12.3k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
12.3k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
12.3k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
12.3k
    }
724
12.3k
    _closed = true;
725
12.3k
    return Status::OK();
726
12.3k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
253k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
253k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
253k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
253k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
253k
    }
724
253k
    _closed = true;
725
253k
    return Status::OK();
726
253k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
468k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
468k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
468k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
468k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
468k
    }
724
468k
    _closed = true;
725
468k
    return Status::OK();
726
468k
}
_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
16.3k
                                                          bool* eos) {
731
16.3k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
16.3k
    return pull(state, block, eos);
733
16.3k
}
_ZN5doris18StreamingOperatorXINS_23AssertNumRowsLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
730
432
                                                          bool* eos) {
731
432
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
432
    return pull(state, block, eos);
733
432
}
_ZN5doris18StreamingOperatorXINS_16SelectLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
730
15.9k
                                                          bool* eos) {
731
15.9k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
15.9k
    return pull(state, block, eos);
733
15.9k
}
734
735
template <typename LocalStateType>
736
Status StatefulOperatorX<LocalStateType>::get_block_impl(RuntimeState* state, Block* block,
737
612k
                                                         bool* eos) {
738
612k
    auto& local_state = get_local_state(state);
739
612k
    if (need_more_input_data(state)) {
740
579k
        local_state._child_block->clear_column_data(
741
579k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
579k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
579k
                state, local_state._child_block.get(), &local_state._child_eos));
744
579k
        *eos = local_state._child_eos;
745
579k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
68.8k
            return Status::OK();
747
68.8k
        }
748
510k
        {
749
510k
            SCOPED_TIMER(local_state.exec_time_counter());
750
510k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
510k
        }
752
510k
    }
753
754
543k
    if (!need_more_input_data(state)) {
755
492k
        SCOPED_TIMER(local_state.exec_time_counter());
756
492k
        bool new_eos = false;
757
492k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
492k
        if (new_eos) {
759
403k
            *eos = true;
760
403k
        } else if (!need_more_input_data(state)) {
761
25.2k
            *eos = false;
762
25.2k
        }
763
492k
    }
764
543k
    return Status::OK();
765
543k
}
_ZN5doris17StatefulOperatorXINS_23HashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
153k
                                                         bool* eos) {
738
153k
    auto& local_state = get_local_state(state);
739
153k
    if (need_more_input_data(state)) {
740
134k
        local_state._child_block->clear_column_data(
741
134k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
134k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
134k
                state, local_state._child_block.get(), &local_state._child_eos));
744
134k
        *eos = local_state._child_eos;
745
134k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
39.3k
            return Status::OK();
747
39.3k
        }
748
95.1k
        {
749
95.1k
            SCOPED_TIMER(local_state.exec_time_counter());
750
95.1k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
95.1k
        }
752
95.1k
    }
753
754
114k
    if (!need_more_input_data(state)) {
755
114k
        SCOPED_TIMER(local_state.exec_time_counter());
756
114k
        bool new_eos = false;
757
114k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
114k
        if (new_eos) {
759
50.4k
            *eos = true;
760
63.6k
        } else if (!need_more_input_data(state)) {
761
10.2k
            *eos = false;
762
10.2k
        }
763
114k
    }
764
114k
    return Status::OK();
765
114k
}
Unexecuted instantiation: _ZN5doris17StatefulOperatorXINS_34PartitionedHashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
_ZN5doris17StatefulOperatorXINS_16RepeatLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.16k
                                                         bool* eos) {
738
4.16k
    auto& local_state = get_local_state(state);
739
4.16k
    if (need_more_input_data(state)) {
740
2.30k
        local_state._child_block->clear_column_data(
741
2.30k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
2.30k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
2.30k
                state, local_state._child_block.get(), &local_state._child_eos));
744
2.30k
        *eos = local_state._child_eos;
745
2.30k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
386
            return Status::OK();
747
386
        }
748
1.91k
        {
749
1.91k
            SCOPED_TIMER(local_state.exec_time_counter());
750
1.91k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
1.91k
        }
752
1.91k
    }
753
754
3.79k
    if (!need_more_input_data(state)) {
755
3.79k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.79k
        bool new_eos = false;
757
3.79k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.79k
        if (new_eos) {
759
1.35k
            *eos = true;
760
2.44k
        } else if (!need_more_input_data(state)) {
761
1.87k
            *eos = false;
762
1.87k
        }
763
3.79k
    }
764
3.78k
    return Status::OK();
765
3.78k
}
_ZN5doris17StatefulOperatorXINS_25MaterializationLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.94k
                                                         bool* eos) {
738
4.94k
    auto& local_state = get_local_state(state);
739
4.94k
    if (need_more_input_data(state)) {
740
4.94k
        local_state._child_block->clear_column_data(
741
4.94k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
4.94k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
4.94k
                state, local_state._child_block.get(), &local_state._child_eos));
744
4.94k
        *eos = local_state._child_eos;
745
4.94k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
1.71k
            return Status::OK();
747
1.71k
        }
748
3.22k
        {
749
3.22k
            SCOPED_TIMER(local_state.exec_time_counter());
750
3.22k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
3.22k
        }
752
3.22k
    }
753
754
3.22k
    if (!need_more_input_data(state)) {
755
3.22k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.22k
        bool new_eos = false;
757
3.22k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.22k
        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.22k
    }
764
3.22k
    return Status::OK();
765
3.22k
}
_ZN5doris17StatefulOperatorXINS_22StreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
38.5k
                                                         bool* eos) {
738
38.5k
    auto& local_state = get_local_state(state);
739
38.5k
    if (need_more_input_data(state)) {
740
38.5k
        local_state._child_block->clear_column_data(
741
38.5k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
38.5k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
38.5k
                state, local_state._child_block.get(), &local_state._child_eos));
744
38.5k
        *eos = local_state._child_eos;
745
38.5k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
6.42k
            return Status::OK();
747
6.42k
        }
748
32.1k
        {
749
32.1k
            SCOPED_TIMER(local_state.exec_time_counter());
750
32.1k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
32.1k
        }
752
32.1k
    }
753
754
32.1k
    if (!need_more_input_data(state)) {
755
11.9k
        SCOPED_TIMER(local_state.exec_time_counter());
756
11.9k
        bool new_eos = false;
757
11.9k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
11.9k
        if (new_eos) {
759
11.8k
            *eos = true;
760
11.8k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
11.9k
    }
764
32.1k
    return Status::OK();
765
32.1k
}
_ZN5doris17StatefulOperatorXINS_30DistinctStreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
374k
                                                         bool* eos) {
738
374k
    auto& local_state = get_local_state(state);
739
374k
    if (need_more_input_data(state)) {
740
374k
        local_state._child_block->clear_column_data(
741
374k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
374k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
374k
                state, local_state._child_block.get(), &local_state._child_eos));
744
374k
        *eos = local_state._child_eos;
745
374k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
17.7k
            return Status::OK();
747
17.7k
        }
748
357k
        {
749
357k
            SCOPED_TIMER(local_state.exec_time_counter());
750
357k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
357k
        }
752
357k
    }
753
754
356k
    if (!need_more_input_data(state)) {
755
325k
        SCOPED_TIMER(local_state.exec_time_counter());
756
325k
        bool new_eos = false;
757
325k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
325k
        if (new_eos) {
759
324k
            *eos = true;
760
324k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
325k
    }
764
356k
    return Status::OK();
765
356k
}
_ZN5doris17StatefulOperatorXINS_29NestedLoopJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
30.9k
                                                         bool* eos) {
738
30.9k
    auto& local_state = get_local_state(state);
739
30.9k
    if (need_more_input_data(state)) {
740
18.2k
        local_state._child_block->clear_column_data(
741
18.2k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
18.2k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
18.2k
                state, local_state._child_block.get(), &local_state._child_eos));
744
18.2k
        *eos = local_state._child_eos;
745
18.2k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
2.93k
            return Status::OK();
747
2.93k
        }
748
15.3k
        {
749
15.3k
            SCOPED_TIMER(local_state.exec_time_counter());
750
15.3k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
15.3k
        }
752
15.3k
    }
753
754
28.0k
    if (!need_more_input_data(state)) {
755
27.4k
        SCOPED_TIMER(local_state.exec_time_counter());
756
27.4k
        bool new_eos = false;
757
27.4k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
27.4k
        if (new_eos) {
759
9.57k
            *eos = true;
760
17.9k
        } else if (!need_more_input_data(state)) {
761
12.7k
            *eos = false;
762
12.7k
        }
763
27.4k
    }
764
28.0k
    return Status::OK();
765
28.0k
}
_ZN5doris17StatefulOperatorXINS_23TableFunctionLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
6.67k
                                                         bool* eos) {
738
6.67k
    auto& local_state = get_local_state(state);
739
6.67k
    if (need_more_input_data(state)) {
740
6.31k
        local_state._child_block->clear_column_data(
741
6.31k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
6.31k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
6.31k
                state, local_state._child_block.get(), &local_state._child_eos));
744
6.31k
        *eos = local_state._child_eos;
745
6.31k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
397
            return Status::OK();
747
397
        }
748
5.92k
        {
749
5.92k
            SCOPED_TIMER(local_state.exec_time_counter());
750
5.92k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
5.92k
        }
752
5.92k
    }
753
754
6.28k
    if (!need_more_input_data(state)) {
755
6.28k
        SCOPED_TIMER(local_state.exec_time_counter());
756
6.28k
        bool new_eos = false;
757
6.28k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
6.28k
        if (new_eos) {
759
4.15k
            *eos = true;
760
4.15k
        } else if (!need_more_input_data(state)) {
761
366
            *eos = false;
762
366
        }
763
6.28k
    }
764
6.27k
    return Status::OK();
765
6.27k
}
766
767
template <typename Writer, typename Parent>
768
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
769
68.6k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
68.6k
    RETURN_IF_ERROR(Base::init(state, info));
771
68.6k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
68.6k
                                                         "AsyncWriterDependency", true);
773
68.6k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
68.6k
                             _finish_dependency));
775
776
68.6k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
68.6k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
68.6k
    return Status::OK();
779
68.6k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
510
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
510
    RETURN_IF_ERROR(Base::init(state, info));
771
510
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
510
                                                         "AsyncWriterDependency", true);
773
510
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
510
                             _finish_dependency));
775
776
510
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
510
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
510
    return Status::OK();
779
510
}
_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
46.7k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
46.7k
    RETURN_IF_ERROR(Base::init(state, info));
771
46.7k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
46.7k
                                                         "AsyncWriterDependency", true);
773
46.7k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
46.7k
                             _finish_dependency));
775
776
46.7k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
46.7k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
46.7k
    return Status::OK();
779
46.7k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
9.70k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
9.70k
    RETURN_IF_ERROR(Base::init(state, info));
771
9.70k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
9.70k
                                                         "AsyncWriterDependency", true);
773
9.70k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
9.70k
                             _finish_dependency));
775
776
9.70k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
9.70k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
9.70k
    return Status::OK();
779
9.70k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
5.05k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
5.05k
    RETURN_IF_ERROR(Base::init(state, info));
771
5.05k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
5.05k
                                                         "AsyncWriterDependency", true);
773
5.05k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
5.05k
                             _finish_dependency));
775
776
5.05k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
5.05k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
5.05k
    return Status::OK();
779
5.05k
}
_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.71k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
1.71k
    RETURN_IF_ERROR(Base::init(state, info));
771
1.71k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
1.71k
                                                         "AsyncWriterDependency", true);
773
1.71k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
1.71k
                             _finish_dependency));
775
776
1.71k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
1.71k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
1.71k
    return Status::OK();
779
1.71k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
156
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
156
    RETURN_IF_ERROR(Base::init(state, info));
771
156
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
156
                                                         "AsyncWriterDependency", true);
773
156
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
156
                             _finish_dependency));
775
776
156
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
156
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
156
    return Status::OK();
779
156
}
780
781
template <typename Writer, typename Parent>
782
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
783
68.9k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
68.9k
    RETURN_IF_ERROR(Base::open(state));
785
68.9k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
599k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
530k
        RETURN_IF_ERROR(
788
530k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
530k
    }
790
68.9k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
68.9k
    return Status::OK();
792
68.9k
}
_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
47.0k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
47.0k
    RETURN_IF_ERROR(Base::open(state));
785
47.0k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
339k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
292k
        RETURN_IF_ERROR(
788
292k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
292k
    }
790
47.0k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
47.0k
    return Status::OK();
792
47.0k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
9.64k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
9.64k
    RETURN_IF_ERROR(Base::open(state));
785
9.64k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
59.8k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
50.1k
        RETURN_IF_ERROR(
788
50.1k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
50.1k
    }
790
9.64k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
9.64k
    return Status::OK();
792
9.64k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
5.04k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
5.04k
    RETURN_IF_ERROR(Base::open(state));
785
5.04k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
135k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
130k
        RETURN_IF_ERROR(
788
130k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
130k
    }
790
5.04k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
5.04k
    return Status::OK();
792
5.04k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
4.01k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
4.01k
    RETURN_IF_ERROR(Base::open(state));
785
4.01k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
44.8k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
40.7k
        RETURN_IF_ERROR(
788
40.7k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
40.7k
    }
790
4.01k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
4.01k
    return Status::OK();
792
4.01k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
48
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
48
    RETURN_IF_ERROR(Base::open(state));
785
48
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
204
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
156
        RETURN_IF_ERROR(
788
156
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
156
    }
790
48
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
48
    return Status::OK();
792
48
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
704
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
704
    RETURN_IF_ERROR(Base::open(state));
785
704
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
2.10k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
1.40k
        RETURN_IF_ERROR(
788
1.40k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
1.40k
    }
790
704
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
704
    return Status::OK();
792
704
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
1.71k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
1.71k
    RETURN_IF_ERROR(Base::open(state));
785
1.71k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
13.4k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
11.7k
        RETURN_IF_ERROR(
788
11.7k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
11.7k
    }
790
1.71k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
1.71k
    return Status::OK();
792
1.71k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4openEPNS_12RuntimeStateE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
156
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
156
    RETURN_IF_ERROR(Base::open(state));
785
156
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
786
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
630
        RETURN_IF_ERROR(
788
630
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
630
    }
790
156
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
156
    return Status::OK();
792
156
}
793
794
template <typename Writer, typename Parent>
795
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
796
94.3k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
94.3k
    return _writer->sink(block, eos);
798
94.3k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
2.10k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
2.10k
    return _writer->sink(block, eos);
798
2.10k
}
_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
63.9k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
63.9k
    return _writer->sink(block, eos);
798
63.9k
}
_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.30k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
7.30k
    return _writer->sink(block, eos);
798
7.30k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
6.40k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
6.40k
    return _writer->sink(block, eos);
798
6.40k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
60
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
60
    return _writer->sink(block, eos);
798
60
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
794
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
794
    return _writer->sink(block, eos);
798
794
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
2.18k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
2.18k
    return _writer->sink(block, eos);
798
2.18k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
310
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
310
    return _writer->sink(block, eos);
798
310
}
799
800
template <typename Writer, typename Parent>
801
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
802
69.1k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
69.1k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
69.1k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
69.1k
    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
69.1k
    if (_writer) {
810
69.1k
        Status st = _writer->get_writer_status();
811
69.1k
        if (exec_status.ok()) {
812
69.0k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
69.0k
                                                       : Status::Cancelled("force close"));
814
69.0k
        } else {
815
175
            _writer->force_close(exec_status);
816
175
        }
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
69.1k
        RETURN_IF_ERROR(st);
821
69.1k
    }
822
69.0k
    return Base::close(state, exec_status);
823
69.1k
}
_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
47.1k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
47.1k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
47.1k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
47.1k
    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
47.2k
    if (_writer) {
810
47.2k
        Status st = _writer->get_writer_status();
811
47.2k
        if (exec_status.ok()) {
812
47.1k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
47.1k
                                                       : Status::Cancelled("force close"));
814
47.1k
        } else {
815
69
            _writer->force_close(exec_status);
816
69
        }
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
47.2k
        RETURN_IF_ERROR(st);
821
47.2k
    }
822
47.1k
    return Base::close(state, exec_status);
823
47.1k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
9.68k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
9.68k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
9.68k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
9.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
9.70k
    if (_writer) {
810
9.70k
        Status st = _writer->get_writer_status();
811
9.70k
        if (exec_status.ok()) {
812
9.60k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
9.60k
                                                       : Status::Cancelled("force close"));
814
9.60k
        } else {
815
102
            _writer->force_close(exec_status);
816
102
        }
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.70k
        RETURN_IF_ERROR(st);
821
9.70k
    }
822
9.68k
    return Base::close(state, exec_status);
823
9.68k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
5.04k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
5.04k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
5.04k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
5.04k
    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.05k
    if (_writer) {
810
5.05k
        Status st = _writer->get_writer_status();
811
5.05k
        if (exec_status.ok()) {
812
5.04k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
5.04k
                                                       : Status::Cancelled("force close"));
814
5.04k
        } else {
815
4
            _writer->force_close(exec_status);
816
4
        }
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.05k
        RETURN_IF_ERROR(st);
821
5.05k
    }
822
5.04k
    return Base::close(state, exec_status);
823
5.04k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
4.01k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
4.01k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
4.01k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
4.01k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
4.01k
    if (_writer) {
810
4.01k
        Status st = _writer->get_writer_status();
811
4.01k
        if (exec_status.ok()) {
812
4.01k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
4.01k
                                                       : Status::Cancelled("force close"));
814
4.01k
        } 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.01k
        RETURN_IF_ERROR(st);
821
4.01k
    }
822
4.01k
    return Base::close(state, exec_status);
823
4.01k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
48
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
48
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
48
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
48
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
48
    if (_writer) {
810
48
        Status st = _writer->get_writer_status();
811
48
        if (exec_status.ok()) {
812
48
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
48
                                                       : Status::Cancelled("force close"));
814
48
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
48
        RETURN_IF_ERROR(st);
821
48
    }
822
48
    return Base::close(state, exec_status);
823
48
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
704
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
704
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
704
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
704
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
704
    if (_writer) {
810
704
        Status st = _writer->get_writer_status();
811
704
        if (exec_status.ok()) {
812
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
704
    return Base::close(state, exec_status);
823
704
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
1.71k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
1.71k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
1.71k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
1.71k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
1.71k
    if (_writer) {
810
1.71k
        Status st = _writer->get_writer_status();
811
1.71k
        if (exec_status.ok()) {
812
1.71k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
1.71k
                                                       : Status::Cancelled("force close"));
814
1.71k
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
1.71k
        RETURN_IF_ERROR(st);
821
1.71k
    }
822
1.71k
    return Base::close(state, exec_status);
823
1.71k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
156
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
156
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
156
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
156
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
156
    if (_writer) {
810
156
        Status st = _writer->get_writer_status();
811
156
        if (exec_status.ok()) {
812
156
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
156
                                                       : Status::Cancelled("force close"));
814
156
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
156
        RETURN_IF_ERROR(st);
821
156
    }
822
156
    return Base::close(state, exec_status);
823
156
}
824
825
#define DECLARE_OPERATOR(LOCAL_STATE) template class DataSinkOperatorX<LOCAL_STATE>;
826
DECLARE_OPERATOR(HashJoinBuildSinkLocalState)
827
DECLARE_OPERATOR(ResultSinkLocalState)
828
DECLARE_OPERATOR(JdbcTableSinkLocalState)
829
DECLARE_OPERATOR(MemoryScratchSinkLocalState)
830
DECLARE_OPERATOR(ResultFileSinkLocalState)
831
DECLARE_OPERATOR(OlapTableSinkLocalState)
832
DECLARE_OPERATOR(OlapTableSinkV2LocalState)
833
DECLARE_OPERATOR(HiveTableSinkLocalState)
834
DECLARE_OPERATOR(TVFTableSinkLocalState)
835
DECLARE_OPERATOR(IcebergTableSinkLocalState)
836
DECLARE_OPERATOR(SpillIcebergTableSinkLocalState)
837
DECLARE_OPERATOR(IcebergDeleteSinkLocalState)
838
DECLARE_OPERATOR(IcebergMergeSinkLocalState)
839
DECLARE_OPERATOR(MCTableSinkLocalState)
840
DECLARE_OPERATOR(AnalyticSinkLocalState)
841
DECLARE_OPERATOR(BlackholeSinkLocalState)
842
DECLARE_OPERATOR(SortSinkLocalState)
843
DECLARE_OPERATOR(SpillSortSinkLocalState)
844
DECLARE_OPERATOR(LocalExchangeSinkLocalState)
845
DECLARE_OPERATOR(AggSinkLocalState)
846
DECLARE_OPERATOR(BucketedAggSinkLocalState)
847
DECLARE_OPERATOR(PartitionedAggSinkLocalState)
848
DECLARE_OPERATOR(ExchangeSinkLocalState)
849
DECLARE_OPERATOR(NestedLoopJoinBuildSinkLocalState)
850
DECLARE_OPERATOR(UnionSinkLocalState)
851
DECLARE_OPERATOR(MultiCastDataStreamSinkLocalState)
852
DECLARE_OPERATOR(PartitionSortSinkLocalState)
853
DECLARE_OPERATOR(SetProbeSinkLocalState<true>)
854
DECLARE_OPERATOR(SetProbeSinkLocalState<false>)
855
DECLARE_OPERATOR(SetSinkLocalState<true>)
856
DECLARE_OPERATOR(SetSinkLocalState<false>)
857
DECLARE_OPERATOR(PartitionedHashJoinSinkLocalState)
858
DECLARE_OPERATOR(GroupCommitBlockSinkLocalState)
859
DECLARE_OPERATOR(CacheSinkLocalState)
860
DECLARE_OPERATOR(DictSinkLocalState)
861
DECLARE_OPERATOR(RecCTESinkLocalState)
862
DECLARE_OPERATOR(RecCTEAnchorSinkLocalState)
863
864
#undef DECLARE_OPERATOR
865
866
#define DECLARE_OPERATOR(LOCAL_STATE) template class OperatorX<LOCAL_STATE>;
867
DECLARE_OPERATOR(HashJoinProbeLocalState)
868
DECLARE_OPERATOR(OlapScanLocalState)
869
DECLARE_OPERATOR(GroupCommitLocalState)
870
DECLARE_OPERATOR(JDBCScanLocalState)
871
DECLARE_OPERATOR(FileScanLocalState)
872
DECLARE_OPERATOR(AnalyticLocalState)
873
DECLARE_OPERATOR(SortLocalState)
874
DECLARE_OPERATOR(SpillSortLocalState)
875
DECLARE_OPERATOR(LocalMergeSortLocalState)
876
DECLARE_OPERATOR(AggLocalState)
877
DECLARE_OPERATOR(BucketedAggLocalState)
878
DECLARE_OPERATOR(PartitionedAggLocalState)
879
DECLARE_OPERATOR(TableFunctionLocalState)
880
DECLARE_OPERATOR(ExchangeLocalState)
881
DECLARE_OPERATOR(RepeatLocalState)
882
DECLARE_OPERATOR(NestedLoopJoinProbeLocalState)
883
DECLARE_OPERATOR(AssertNumRowsLocalState)
884
DECLARE_OPERATOR(EmptySetLocalState)
885
DECLARE_OPERATOR(UnionSourceLocalState)
886
DECLARE_OPERATOR(MultiCastDataStreamSourceLocalState)
887
DECLARE_OPERATOR(PartitionSortSourceLocalState)
888
DECLARE_OPERATOR(SetSourceLocalState<true>)
889
DECLARE_OPERATOR(SetSourceLocalState<false>)
890
DECLARE_OPERATOR(DataGenLocalState)
891
DECLARE_OPERATOR(SchemaScanLocalState)
892
DECLARE_OPERATOR(MetaScanLocalState)
893
DECLARE_OPERATOR(LocalExchangeSourceLocalState)
894
DECLARE_OPERATOR(PartitionedHashJoinProbeLocalState)
895
DECLARE_OPERATOR(CacheSourceLocalState)
896
DECLARE_OPERATOR(RecCTESourceLocalState)
897
DECLARE_OPERATOR(RecCTEScanLocalState)
898
899
#ifdef BE_TEST
900
DECLARE_OPERATOR(MockLocalState)
901
DECLARE_OPERATOR(MockScanLocalState)
902
#endif
903
#undef DECLARE_OPERATOR
904
905
template class StreamingOperatorX<AssertNumRowsLocalState>;
906
template class StreamingOperatorX<SelectLocalState>;
907
908
template class StatefulOperatorX<HashJoinProbeLocalState>;
909
template class StatefulOperatorX<PartitionedHashJoinProbeLocalState>;
910
template class StatefulOperatorX<RepeatLocalState>;
911
template class StatefulOperatorX<MaterializationLocalState>;
912
template class StatefulOperatorX<StreamingAggLocalState>;
913
template class StatefulOperatorX<DistinctStreamingAggLocalState>;
914
template class StatefulOperatorX<NestedLoopJoinProbeLocalState>;
915
template class StatefulOperatorX<TableFunctionLocalState>;
916
917
template class PipelineXSinkLocalState<HashJoinSharedState>;
918
template class PipelineXSinkLocalState<PartitionedHashJoinSharedState>;
919
template class PipelineXSinkLocalState<SortSharedState>;
920
template class PipelineXSinkLocalState<SpillSortSharedState>;
921
template class PipelineXSinkLocalState<NestedLoopJoinSharedState>;
922
template class PipelineXSinkLocalState<AnalyticSharedState>;
923
template class PipelineXSinkLocalState<AggSharedState>;
924
template class PipelineXSinkLocalState<BucketedAggSharedState>;
925
template class PipelineXSinkLocalState<PartitionedAggSharedState>;
926
template class PipelineXSinkLocalState<FakeSharedState>;
927
template class PipelineXSinkLocalState<UnionSharedState>;
928
template class PipelineXSinkLocalState<PartitionSortNodeSharedState>;
929
template class PipelineXSinkLocalState<MultiCastSharedState>;
930
template class PipelineXSinkLocalState<SetSharedState>;
931
template class PipelineXSinkLocalState<LocalExchangeSharedState>;
932
template class PipelineXSinkLocalState<BasicSharedState>;
933
template class PipelineXSinkLocalState<DataQueueSharedState>;
934
template class PipelineXSinkLocalState<RecCTESharedState>;
935
936
template class PipelineXLocalState<HashJoinSharedState>;
937
template class PipelineXLocalState<PartitionedHashJoinSharedState>;
938
template class PipelineXLocalState<SortSharedState>;
939
template class PipelineXLocalState<SpillSortSharedState>;
940
template class PipelineXLocalState<NestedLoopJoinSharedState>;
941
template class PipelineXLocalState<AnalyticSharedState>;
942
template class PipelineXLocalState<AggSharedState>;
943
template class PipelineXLocalState<BucketedAggSharedState>;
944
template class PipelineXLocalState<PartitionedAggSharedState>;
945
template class PipelineXLocalState<FakeSharedState>;
946
template class PipelineXLocalState<UnionSharedState>;
947
template class PipelineXLocalState<DataQueueSharedState>;
948
template class PipelineXLocalState<MultiCastSharedState>;
949
template class PipelineXLocalState<PartitionSortNodeSharedState>;
950
template class PipelineXLocalState<SetSharedState>;
951
template class PipelineXLocalState<LocalExchangeSharedState>;
952
template class PipelineXLocalState<BasicSharedState>;
953
template class PipelineXLocalState<RecCTESharedState>;
954
955
template class AsyncWriterSink<doris::VFileResultWriter, ResultFileSinkOperatorX>;
956
template class AsyncWriterSink<doris::VJdbcTableWriter, JdbcTableSinkOperatorX>;
957
template class AsyncWriterSink<doris::VTabletWriter, OlapTableSinkOperatorX>;
958
template class AsyncWriterSink<doris::VTabletWriterV2, OlapTableSinkV2OperatorX>;
959
template class AsyncWriterSink<doris::VHiveTableWriter, HiveTableSinkOperatorX>;
960
template class AsyncWriterSink<doris::VIcebergTableWriter, IcebergTableSinkOperatorX>;
961
template class AsyncWriterSink<doris::VIcebergTableWriter, SpillIcebergTableSinkOperatorX>;
962
template class AsyncWriterSink<doris::VIcebergDeleteSink, IcebergDeleteSinkOperatorX>;
963
template class AsyncWriterSink<doris::VIcebergMergeSink, IcebergMergeSinkOperatorX>;
964
template class AsyncWriterSink<doris::VMCTableWriter, MCTableSinkOperatorX>;
965
template class AsyncWriterSink<doris::VTVFTableWriter, TVFTableSinkOperatorX>;
966
967
#ifdef BE_TEST
968
template class OperatorX<DummyOperatorLocalState>;
969
template class DataSinkOperatorX<DummySinkLocalState>;
970
#endif
971
972
} // namespace doris