Coverage Report

Created: 2026-07-01 04:37

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