Coverage Report

Created: 2026-08-07 05:23

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