Coverage Report

Created: 2026-07-24 06:40

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.32M
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
2.32M
    if (_parent->nereids_id() == -1) {
122
1.24M
        return fmt::format("(id={})", _parent->node_id());
123
1.24M
    } else {
124
1.08M
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
1.08M
    }
126
2.32M
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
75.4k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
75.4k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
75.4k
    } else {
124
75.4k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
75.4k
    }
126
75.4k
}
_ZNK5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
1
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
1
    if (_parent->nereids_id() == -1) {
122
1
        return fmt::format("(id={})", _parent->node_id());
123
1
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
1
}
_ZNK5doris19PipelineXLocalStateINS_15SortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
259k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
259k
    if (_parent->nereids_id() == -1) {
122
12
        return fmt::format("(id={})", _parent->node_id());
123
259k
    } else {
124
259k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
259k
    }
126
259k
}
_ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
24
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
24
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
24
    } else {
124
24
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
24
    }
126
24
}
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
12.3k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
12.3k
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
12.3k
    } else {
124
12.3k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
12.3k
    }
126
12.3k
}
_ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
6.64k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
6.64k
    if (_parent->nereids_id() == -1) {
122
11
        return fmt::format("(id={})", _parent->node_id());
123
6.62k
    } else {
124
6.62k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
6.62k
    }
126
6.64k
}
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
166k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
166k
    if (_parent->nereids_id() == -1) {
122
29
        return fmt::format("(id={})", _parent->node_id());
123
166k
    } else {
124
166k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
166k
    }
126
166k
}
_ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
687
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
687
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
687
    } else {
124
687
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
687
    }
126
687
}
_ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
144
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
144
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
144
    } else {
124
144
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
144
    }
126
144
}
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
909k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
909k
    if (_parent->nereids_id() == -1) {
122
410k
        return fmt::format("(id={})", _parent->node_id());
123
499k
    } else {
124
499k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
499k
    }
126
909k
}
_ZNK5doris19PipelineXLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
56.8k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
56.8k
    if (_parent->nereids_id() == -1) {
122
2
        return fmt::format("(id={})", _parent->node_id());
123
56.8k
    } else {
124
56.8k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
56.8k
    }
126
56.8k
}
_ZNK5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
26
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
26
    if (_parent->nereids_id() == -1) {
122
26
        return fmt::format("(id={})", _parent->node_id());
123
26
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
26
}
_ZNK5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
12.9k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
12.9k
    if (_parent->nereids_id() == -1) {
122
12.9k
        return fmt::format("(id={})", _parent->node_id());
123
12.9k
    } else {
124
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
0
    }
126
12.9k
}
_ZNK5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
361
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
361
    if (_parent->nereids_id() == -1) {
122
102
        return fmt::format("(id={})", _parent->node_id());
123
259
    } else {
124
259
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
259
    }
126
361
}
_ZNK5doris19PipelineXLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
5.26k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
5.26k
    if (_parent->nereids_id() == -1) {
122
13
        return fmt::format("(id={})", _parent->node_id());
123
5.24k
    } else {
124
5.24k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
5.24k
    }
126
5.26k
}
_ZNK5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
817k
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
817k
    if (_parent->nereids_id() == -1) {
122
817k
        return fmt::format("(id={})", _parent->node_id());
123
817k
    } else {
124
233
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
233
    }
126
817k
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_16BasicSharedStateEE11name_suffixB5cxx11Ev
_ZNK5doris19PipelineXLocalStateINS_17RecCTESharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
120
163
std::string PipelineXLocalState<SharedStateArg>::name_suffix() const {
121
163
    if (_parent->nereids_id() == -1) {
122
0
        return fmt::format("(id={})", _parent->node_id());
123
163
    } else {
124
163
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
125
163
    }
126
163
}
127
128
template <typename SharedStateArg>
129
1.44M
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
1.44M
    if (_parent->nereids_id() == -1) {
131
862k
        return fmt::format("(id={})", _parent->node_id());
132
862k
    } else {
133
583k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
583k
    }
135
1.44M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
124k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
124k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
124k
    } else {
133
124k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
124k
    }
135
124k
}
_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
262k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
262k
    if (_parent->nereids_id() == -1) {
131
9
        return fmt::format("(id={})", _parent->node_id());
132
262k
    } else {
133
262k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
262k
    }
135
262k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
31
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
31
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
31
    } else {
133
31
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
31
    }
135
31
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
12.4k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
12.4k
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
12.4k
    } else {
133
12.4k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
12.4k
    }
135
12.4k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
6.66k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
6.66k
    if (_parent->nereids_id() == -1) {
131
11
        return fmt::format("(id={})", _parent->node_id());
132
6.65k
    } else {
133
6.65k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
6.65k
    }
135
6.66k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
167k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
167k
    if (_parent->nereids_id() == -1) {
131
29
        return fmt::format("(id={})", _parent->node_id());
132
167k
    } else {
133
167k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
167k
    }
135
167k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
687
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
687
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
687
    } else {
133
687
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
687
    }
135
687
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
154
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
154
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
154
    } else {
133
154
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
154
    }
135
154
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
99
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
99
    if (_parent->nereids_id() == -1) {
131
98
        return fmt::format("(id={})", _parent->node_id());
132
98
    } else {
133
1
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
1
    }
135
99
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
7.64k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
7.64k
    if (_parent->nereids_id() == -1) {
131
3
        return fmt::format("(id={})", _parent->node_id());
132
7.64k
    } else {
133
7.64k
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
7.64k
    }
135
7.64k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
363
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
363
    if (_parent->nereids_id() == -1) {
131
102
        return fmt::format("(id={})", _parent->node_id());
132
261
    } else {
133
261
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
261
    }
135
363
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE11name_suffixB5cxx11Ev
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
12.4k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
12.4k
    if (_parent->nereids_id() == -1) {
131
12.4k
        return fmt::format("(id={})", _parent->node_id());
132
12.4k
    } else {
133
0
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
0
    }
135
12.4k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
319k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
319k
    if (_parent->nereids_id() == -1) {
131
319k
        return fmt::format("(id={})", _parent->node_id());
132
319k
    } else {
133
4
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
4
    }
135
319k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE11name_suffixB5cxx11Ev
Line
Count
Source
129
530k
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
530k
    if (_parent->nereids_id() == -1) {
131
530k
        return fmt::format("(id={})", _parent->node_id());
132
530k
    } else {
133
551
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
551
    }
135
530k
}
_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
327
std::string PipelineXSinkLocalState<SharedStateArg>::name_suffix() {
130
327
    if (_parent->nereids_id() == -1) {
131
0
        return fmt::format("(id={})", _parent->node_id());
132
327
    } else {
133
327
        return fmt::format("(nereids_id={}, id={})", _parent->nereids_id(), _parent->node_id());
134
327
    }
135
327
}
136
137
template <typename SharedStateArg>
138
28.5k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
28.5k
    if (_terminated) {
140
1
        return Status::OK();
141
1
    }
142
28.5k
    _terminated = true;
143
28.5k
    return Status::OK();
144
28.5k
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
24.0k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
24.0k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
24.0k
    _terminated = true;
143
24.0k
    return Status::OK();
144
24.0k
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
817
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
817
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
817
    _terminated = true;
143
817
    return Status::OK();
144
817
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
3
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
3
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
3
    _terminated = true;
143
3
    return Status::OK();
144
3
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
2.09k
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
2.09k
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
2.09k
    _terminated = true;
143
2.09k
    return Status::OK();
144
2.09k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
3
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
3
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
3
    _terminated = true;
143
3
    return Status::OK();
144
3
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
762
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
762
    if (_terminated) {
140
1
        return Status::OK();
141
1
    }
142
761
    _terminated = true;
143
761
    return Status::OK();
144
762
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
49
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
49
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
49
    _terminated = true;
143
49
    return Status::OK();
144
49
}
_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
566
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
566
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
566
    _terminated = true;
143
566
    return Status::OK();
144
566
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE9terminateEPNS_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
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
96
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
96
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
96
    _terminated = true;
143
96
    return Status::OK();
144
96
}
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
Unexecuted instantiation: _ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
138
144
Status PipelineXSinkLocalState<SharedStateArg>::terminate(RuntimeState* state) {
139
144
    if (_terminated) {
140
0
        return Status::OK();
141
0
    }
142
144
    _terminated = true;
143
144
    return Status::OK();
144
144
}
145
146
428k
DataDistribution OperatorBase::required_data_distribution(RuntimeState* /*state*/) const {
147
428k
    return _child && _child->is_serial_operator() && !is_source()
148
428k
                   ? DataDistribution(TLocalPartitionType::PASSTHROUGH)
149
428k
                   : DataDistribution(TLocalPartitionType::NOOP);
150
428k
}
151
152
35.2k
bool OperatorBase::child_breaks_local_key_distribution(RuntimeState* state) const {
153
35.2k
    if (!_child) {
154
30.1k
        return false;
155
30.1k
    }
156
5.08k
    if (_child->is_serial_operator()) {
157
179
        return true;
158
179
    }
159
4.91k
    const auto child_distribution = _child->required_data_distribution(state);
160
4.91k
    return child_distribution.need_local_exchange() &&
161
4.91k
           !is_shuffled_exchange(child_distribution.distribution_type);
162
5.08k
}
163
164
82.6k
const RowDescriptor& OperatorBase::row_desc() const {
165
82.6k
    return _child->row_desc();
166
82.6k
}
167
168
template <typename SharedStateArg>
169
19.8k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
19.8k
    fmt::memory_buffer debug_string_buffer;
171
19.8k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
19.8k
    return fmt::to_string(debug_string_buffer);
173
19.8k
}
_ZNK5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
26
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
26
    fmt::memory_buffer debug_string_buffer;
171
26
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
26
    return fmt::to_string(debug_string_buffer);
173
26
}
_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
12
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
12
    fmt::memory_buffer debug_string_buffer;
171
12
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
12
    return fmt::to_string(debug_string_buffer);
173
12
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
11
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
11
    fmt::memory_buffer debug_string_buffer;
171
11
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
11
    return fmt::to_string(debug_string_buffer);
173
11
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
23
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
23
    fmt::memory_buffer debug_string_buffer;
171
23
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
23
    return fmt::to_string(debug_string_buffer);
173
23
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
19.7k
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
19.7k
    fmt::memory_buffer debug_string_buffer;
171
19.7k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
19.7k
    return fmt::to_string(debug_string_buffer);
173
19.7k
}
_ZNK5doris19PipelineXLocalStateINS_16UnionSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
1
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
1
    fmt::memory_buffer debug_string_buffer;
171
1
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
1
    return fmt::to_string(debug_string_buffer);
173
1
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_14SetSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
169
23
std::string PipelineXLocalState<SharedStateArg>::debug_string(int indentation_level) const {
170
23
    fmt::memory_buffer debug_string_buffer;
171
23
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
172
23
    return fmt::to_string(debug_string_buffer);
173
23
}
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris19PipelineXLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
174
175
template <typename SharedStateArg>
176
19.7k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
19.7k
    fmt::memory_buffer debug_string_buffer;
178
19.7k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
19.7k
    return fmt::to_string(debug_string_buffer);
180
19.7k
}
_ZNK5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
6
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
6
    fmt::memory_buffer debug_string_buffer;
178
6
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
6
    return fmt::to_string(debug_string_buffer);
180
6
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
12
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
12
    fmt::memory_buffer debug_string_buffer;
178
12
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
12
    return fmt::to_string(debug_string_buffer);
180
12
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
23
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
23
    fmt::memory_buffer debug_string_buffer;
178
23
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
23
    return fmt::to_string(debug_string_buffer);
180
23
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
25
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
25
    fmt::memory_buffer debug_string_buffer;
178
25
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
25
    return fmt::to_string(debug_string_buffer);
180
25
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE12debug_stringB5cxx11Ei
_ZNK5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
12
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
12
    fmt::memory_buffer debug_string_buffer;
178
12
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
12
    return fmt::to_string(debug_string_buffer);
180
12
}
_ZNK5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE12debug_stringB5cxx11Ei
Line
Count
Source
176
19.6k
std::string PipelineXSinkLocalState<SharedStateArg>::debug_string(int indentation_level) const {
177
19.6k
    fmt::memory_buffer debug_string_buffer;
178
19.6k
    fmt::format_to(debug_string_buffer, "{}", _parent->debug_string(indentation_level));
179
19.6k
    return fmt::to_string(debug_string_buffer);
180
19.6k
}
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE12debug_stringB5cxx11Ei
Unexecuted instantiation: _ZNK5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE12debug_stringB5cxx11Ei
181
182
19.8k
std::string OperatorXBase::debug_string(int indentation_level) const {
183
19.8k
    fmt::memory_buffer debug_string_buffer;
184
19.8k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, parallel_tasks={}, _is_serial_operator={}",
185
19.8k
                   std::string(indentation_level * 2, ' '), _op_name, node_id(), _parallel_tasks,
186
19.8k
                   _is_serial_operator);
187
19.8k
    return fmt::to_string(debug_string_buffer);
188
19.8k
}
189
190
19.8k
std::string OperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
191
19.8k
    return state->get_local_state(operator_id())->debug_string(indentation_level);
192
19.8k
}
193
194
844k
Status OperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
195
844k
    std::string node_name = print_plan_node_type(tnode.node_type);
196
844k
    _nereids_id = tnode.nereids_id;
197
844k
    if (!tnode.intermediate_output_tuple_id_list.empty()) {
198
4.10k
        if (!tnode.__isset.output_tuple_id) {
199
0
            return Status::InternalError("no final output tuple id");
200
0
        }
201
4.10k
        if (tnode.intermediate_output_tuple_id_list.size() !=
202
4.10k
            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.10k
    }
210
844k
    auto substr = node_name.substr(0, node_name.find("_NODE"));
211
844k
    _op_name = substr + "_OPERATOR";
212
213
844k
    if (tnode.__isset.vconjunct) {
214
0
        return Status::InternalError("vconjunct is not supported yet");
215
844k
    } else if (tnode.__isset.conjuncts) {
216
477k
        for (const auto& conjunct : tnode.conjuncts) {
217
477k
            VExprContextSPtr context;
218
477k
            RETURN_IF_ERROR(VExpr::create_expr_tree(conjunct, context));
219
477k
            _conjuncts.emplace_back(context);
220
477k
        }
221
154k
    }
222
223
    // create the projections expr
224
844k
    if (tnode.__isset.projections) {
225
330k
        DCHECK(tnode.__isset.output_tuple_id);
226
330k
        RETURN_IF_ERROR(VExpr::create_expr_trees(tnode.projections, _projections));
227
330k
    }
228
844k
    if (!tnode.intermediate_projections_list.empty()) {
229
4.10k
        DCHECK(tnode.__isset.projections) << "no final projections";
230
4.10k
        _intermediate_projections.reserve(tnode.intermediate_projections_list.size());
231
8.34k
        for (const auto& tnode_projections : tnode.intermediate_projections_list) {
232
8.34k
            VExprContextSPtrs projections;
233
8.34k
            RETURN_IF_ERROR(VExpr::create_expr_trees(tnode_projections, projections));
234
8.34k
            _intermediate_projections.push_back(projections);
235
8.34k
        }
236
4.10k
    }
237
844k
    return Status::OK();
238
844k
}
239
240
876k
Status OperatorXBase::prepare(RuntimeState* state) {
241
876k
    for (auto& conjunct : _conjuncts) {
242
477k
        RETURN_IF_ERROR(conjunct->prepare(state, intermediate_row_desc()));
243
477k
    }
244
876k
    if (state->enable_adjust_conjunct_order_by_cost()) {
245
823k
        std::ranges::stable_sort(_conjuncts, [](const auto& a, const auto& b) {
246
633k
            return a->execute_cost() < b->execute_cost();
247
633k
        });
248
823k
    };
249
250
884k
    for (int i = 0; i < _intermediate_projections.size(); i++) {
251
8.35k
        RETURN_IF_ERROR(
252
8.35k
                VExpr::prepare(_intermediate_projections[i], state, intermediate_row_desc(i)));
253
8.35k
    }
254
876k
    RETURN_IF_ERROR(VExpr::prepare(_projections, state, projections_row_desc()));
255
256
876k
    if (has_output_row_desc()) {
257
330k
        RETURN_IF_ERROR(VExpr::check_expr_output_type(_projections, *_output_row_descriptor));
258
330k
    }
259
260
876k
    for (auto& conjunct : _conjuncts) {
261
477k
        RETURN_IF_ERROR(conjunct->open(state));
262
477k
    }
263
876k
    RETURN_IF_ERROR(VExpr::open(_projections, state));
264
876k
    for (auto& projections : _intermediate_projections) {
265
8.35k
        RETURN_IF_ERROR(VExpr::open(projections, state));
266
8.35k
    }
267
876k
    if (_child && !is_source()) {
268
130k
        RETURN_IF_ERROR(_child->prepare(state));
269
130k
    }
270
271
876k
    if (VExpr::contains_blockable_function(_conjuncts) ||
272
876k
        VExpr::contains_blockable_function(_projections)) {
273
0
        _blockable = true;
274
0
    }
275
276
876k
    return Status::OK();
277
876k
}
278
279
5.67k
Status OperatorXBase::terminate(RuntimeState* state) {
280
5.67k
    if (_child && !is_source()) {
281
1.09k
        RETURN_IF_ERROR(_child->terminate(state));
282
1.09k
    }
283
5.67k
    auto result = state->get_local_state_result(operator_id());
284
5.67k
    if (!result) {
285
0
        return result.error();
286
0
    }
287
5.67k
    return result.value()->terminate(state);
288
5.67k
}
289
290
6.51M
Status OperatorXBase::close(RuntimeState* state) {
291
6.51M
    if (_child && !is_source()) {
292
1.16M
        RETURN_IF_ERROR(_child->close(state));
293
1.16M
    }
294
6.51M
    auto result = state->get_local_state_result(operator_id());
295
6.51M
    if (!result) {
296
0
        return result.error();
297
0
    }
298
6.51M
    return result.value()->close(state);
299
6.51M
}
300
301
318k
void PipelineXLocalStateBase::clear_origin_block() {
302
318k
    _origin_block.clear_column_data(_parent->intermediate_row_desc().num_materialized_slots());
303
318k
}
304
305
665k
Status PipelineXLocalStateBase::filter_block(const VExprContextSPtrs& expr_contexts, Block* block) {
306
665k
    RETURN_IF_ERROR(VExprContext::filter_block(expr_contexts, block, block->columns()));
307
308
665k
    _estimate_memory_usage += VExprContext::get_memory_usage(expr_contexts);
309
665k
    return Status::OK();
310
665k
}
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
318k
                                     Block* output_block) const {
319
318k
    auto* local_state = state->get_local_state(operator_id());
320
318k
    SCOPED_TIMER(local_state->exec_time_counter());
321
318k
    SCOPED_TIMER(local_state->_projection_timer);
322
318k
    const size_t rows = origin_block->rows();
323
318k
    if (rows == 0) {
324
167k
        return Status::OK();
325
167k
    }
326
151k
    Block input_block = *origin_block;
327
328
151k
    size_t bytes_usage = 0;
329
151k
    ColumnsWithTypeAndName new_columns;
330
151k
    for (const auto& projections : local_state->_intermediate_projections) {
331
1.81k
        if (projections.empty()) {
332
0
            return Status::InternalError("meet empty intermediate projection, node id: {}",
333
0
                                         node_id());
334
0
        }
335
1.81k
        new_columns.resize(projections.size());
336
13.6k
        for (int i = 0; i < projections.size(); i++) {
337
11.8k
            RETURN_IF_ERROR(projections[i]->execute(&input_block, new_columns[i]));
338
11.8k
            if (new_columns[i].column->size() != rows) {
339
0
                return Status::InternalError(
340
0
                        "intermediate projection result column size {} not equal input rows {}, "
341
0
                        "expr: {}",
342
0
                        new_columns[i].column->size(), rows,
343
0
                        projections[i]->root()->debug_string());
344
0
            }
345
11.8k
        }
346
1.81k
        Block tmp_block {new_columns};
347
1.81k
        bytes_usage += tmp_block.allocated_bytes();
348
1.81k
        input_block.swap(tmp_block);
349
1.81k
    }
350
351
151k
    if (input_block.rows() != rows) {
352
0
        return Status::InternalError(
353
0
                "after intermediate projections input block rows {} not equal origin rows {}, "
354
0
                "input_block: {}",
355
0
                input_block.rows(), rows, input_block.dump_structure());
356
0
    }
357
711k
    auto insert_column_datas = [&](auto& to, ColumnPtr& from, size_t rows) {
358
711k
        if (is_column_nullable(*to) && !is_column_nullable(*from)) {
359
0
            if (_keep_origin || !from->is_exclusive()) {
360
0
                auto& null_column = reinterpret_cast<ColumnNullable&>(*to);
361
0
                null_column.get_nested_column().insert_range_from(*from, 0, rows);
362
0
                null_column.get_null_map_column().get_data().resize_fill(rows, 0);
363
0
                bytes_usage += null_column.allocated_bytes();
364
0
            } else {
365
0
                to = make_nullable(from, false)->assert_mutable();
366
0
            }
367
711k
        } else {
368
711k
            if (_keep_origin || !from->is_exclusive()) {
369
711k
                to->insert_range_from(*from, 0, rows);
370
711k
                bytes_usage += from->allocated_bytes();
371
18.4E
            } else {
372
18.4E
                to = from->assert_mutable();
373
18.4E
            }
374
711k
        }
375
711k
    };
376
377
151k
    auto scoped_mutable_block = VectorizedUtils::build_scoped_mutable_mem_reuse_block(
378
151k
            output_block, *_output_row_descriptor);
379
151k
    auto& mutable_block = scoped_mutable_block.mutable_block();
380
151k
    auto& mutable_columns = mutable_block.mutable_columns();
381
151k
    if (rows != 0) {
382
151k
        DCHECK_EQ(mutable_columns.size(), local_state->_projections.size()) << debug_string();
383
863k
        for (int i = 0; i < mutable_columns.size(); ++i) {
384
711k
            ColumnPtr column_ptr;
385
711k
            RETURN_IF_ERROR(local_state->_projections[i]->execute(&input_block, column_ptr));
386
711k
            if (column_ptr->size() != rows) {
387
0
                return Status::InternalError(
388
0
                        "projection result column size {} not equal input rows {}, expr: {}",
389
0
                        column_ptr->size(), rows,
390
0
                        local_state->_projections[i]->root()->debug_string());
391
0
            }
392
711k
            column_ptr = column_ptr->convert_to_full_column_if_const();
393
711k
            bytes_usage += column_ptr->allocated_bytes();
394
711k
            insert_column_datas(mutable_columns[i], column_ptr, rows);
395
711k
        }
396
151k
        DCHECK(mutable_block.rows() == rows);
397
151k
    }
398
151k
    local_state->_estimate_memory_usage += bytes_usage;
399
400
151k
    return Status::OK();
401
151k
}
402
403
4.90M
Status OperatorXBase::get_block_after_projects(RuntimeState* state, Block* block, bool* eos) {
404
4.90M
    DBUG_EXECUTE_IF("Pipeline::return_empty_block", {
405
4.90M
        if (this->_op_name == "AGGREGATION_OPERATOR" || this->_op_name == "HASH_JOIN_OPERATOR" ||
406
4.90M
            this->_op_name == "PARTITIONED_AGGREGATION_OPERATOR" ||
407
4.90M
            this->_op_name == "PARTITIONED_HASH_JOIN_OPERATOR" ||
408
4.90M
            this->_op_name == "CROSS_JOIN_OPERATOR" || this->_op_name == "SORT_OPERATOR") {
409
4.90M
            if (_debug_point_count++ % 2 == 0) {
410
4.90M
                return Status::OK();
411
4.90M
            }
412
4.90M
        }
413
4.90M
    });
414
415
4.90M
    Status status;
416
4.90M
    auto* local_state = state->get_local_state(operator_id());
417
4.90M
    Defer defer([&]() {
418
4.90M
        if (status.ok()) {
419
4.90M
            local_state->update_output_block_counters(*block);
420
4.90M
        }
421
4.90M
    });
422
4.90M
    if (_output_row_descriptor) {
423
318k
        local_state->clear_origin_block();
424
318k
        status = get_block(state, &local_state->_origin_block, eos);
425
318k
        if (UNLIKELY(!status.ok())) {
426
24
            return status;
427
24
        }
428
318k
        status = do_projections(state, &local_state->_origin_block, block);
429
318k
        return status;
430
318k
    }
431
4.58M
    status = get_block(state, block, eos);
432
4.58M
    RETURN_IF_ERROR(block->check_type_and_column());
433
4.58M
    return status;
434
4.58M
}
435
436
3.35M
void PipelineXLocalStateBase::reached_limit(Block* block, bool* eos) {
437
3.35M
    if (_parent->_limit != -1 and _num_rows_returned + block->rows() >= _parent->_limit) {
438
7.29k
        block->set_num_rows(_parent->_limit - _num_rows_returned);
439
7.29k
        *eos = true;
440
7.29k
    }
441
442
3.35M
    DBUG_EXECUTE_IF("Pipeline::reached_limit_early", {
443
3.35M
        auto op_name = to_lower(_parent->_op_name);
444
3.35M
        auto arg_op_name = dp->param<std::string>("op_name");
445
3.35M
        arg_op_name = to_lower(arg_op_name);
446
447
3.35M
        if (op_name == arg_op_name) {
448
3.35M
            *eos = true;
449
3.35M
        }
450
3.35M
    });
451
452
3.35M
    if (auto rows = block->rows()) {
453
955k
        _num_rows_returned += rows;
454
955k
        _state->get_query_ctx()->resource_ctx()->io_context()->update_process_rows(rows);
455
955k
    }
456
3.35M
}
457
458
28.5k
Status DataSinkOperatorXBase::terminate(RuntimeState* state) {
459
28.5k
    auto result = state->get_sink_local_state_result();
460
28.5k
    if (!result) {
461
0
        return result.error();
462
0
    }
463
28.5k
    return result.value()->terminate(state);
464
28.5k
}
465
466
19.7k
std::string DataSinkOperatorXBase::debug_string(int indentation_level) const {
467
19.7k
    fmt::memory_buffer debug_string_buffer;
468
469
19.7k
    fmt::format_to(debug_string_buffer, "{}{}: id={}, _is_serial_operator={}",
470
19.7k
                   std::string(indentation_level * 2, ' '), _name, node_id(), _is_serial_operator);
471
19.7k
    return fmt::to_string(debug_string_buffer);
472
19.7k
}
473
474
19.7k
std::string DataSinkOperatorXBase::debug_string(RuntimeState* state, int indentation_level) const {
475
19.7k
    return state->get_sink_local_state()->debug_string(indentation_level);
476
19.7k
}
477
478
473k
Status DataSinkOperatorXBase::init(const TDataSink& tsink) {
479
473k
    std::string op_name = "UNKNOWN_SINK";
480
473k
    auto it = _TDataSinkType_VALUES_TO_NAMES.find(tsink.type);
481
482
473k
    if (it != _TDataSinkType_VALUES_TO_NAMES.end()) {
483
473k
        op_name = it->second;
484
473k
    }
485
473k
    _name = op_name + "_OPERATOR";
486
473k
    return Status::OK();
487
473k
}
488
489
318k
Status DataSinkOperatorXBase::init(const TPlanNode& tnode, RuntimeState* state) {
490
318k
    std::string op_name = print_plan_node_type(tnode.node_type);
491
318k
    _nereids_id = tnode.nereids_id;
492
318k
    auto substr = op_name.substr(0, op_name.find("_NODE"));
493
318k
    _name = substr + "_SINK_OPERATOR";
494
318k
    return Status::OK();
495
318k
}
496
497
template <typename LocalStateType>
498
Status DataSinkOperatorX<LocalStateType>::setup_local_state(RuntimeState* state,
499
2.18M
                                                            LocalSinkStateInfo& info) {
500
2.18M
    auto local_state = LocalStateType::create_unique(this, state);
501
2.18M
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.18M
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.18M
    return Status::OK();
504
2.18M
}
_ZN5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
124k
                                                            LocalSinkStateInfo& info) {
500
124k
    auto local_state = LocalStateType::create_unique(this, state);
501
124k
    RETURN_IF_ERROR(local_state->init(state, info));
502
124k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
124k
    return Status::OK();
504
124k
}
_ZN5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
463k
                                                            LocalSinkStateInfo& info) {
500
463k
    auto local_state = LocalStateType::create_unique(this, state);
501
463k
    RETURN_IF_ERROR(local_state->init(state, info));
502
463k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
463k
    return Status::OK();
504
463k
}
_ZN5doris17DataSinkOperatorXINS_23JdbcTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
86
                                                            LocalSinkStateInfo& info) {
500
86
    auto local_state = LocalStateType::create_unique(this, state);
501
86
    RETURN_IF_ERROR(local_state->init(state, info));
502
86
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
86
    return Status::OK();
504
86
}
_ZN5doris17DataSinkOperatorXINS_27MemoryScratchSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3
                                                            LocalSinkStateInfo& info) {
500
3
    auto local_state = LocalStateType::create_unique(this, state);
501
3
    RETURN_IF_ERROR(local_state->init(state, info));
502
3
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3
    return Status::OK();
504
3
}
_ZN5doris17DataSinkOperatorXINS_24ResultFileSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
513
                                                            LocalSinkStateInfo& info) {
500
513
    auto local_state = LocalStateType::create_unique(this, state);
501
513
    RETURN_IF_ERROR(local_state->init(state, info));
502
513
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
513
    return Status::OK();
504
513
}
_ZN5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
47.0k
                                                            LocalSinkStateInfo& info) {
500
47.0k
    auto local_state = LocalStateType::create_unique(this, state);
501
47.0k
    RETURN_IF_ERROR(local_state->init(state, info));
502
47.0k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
47.0k
    return Status::OK();
504
47.0k
}
_ZN5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
9.58k
                                                            LocalSinkStateInfo& info) {
500
9.58k
    auto local_state = LocalStateType::create_unique(this, state);
501
9.58k
    RETURN_IF_ERROR(local_state->init(state, info));
502
9.58k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
9.58k
    return Status::OK();
504
9.58k
}
_ZN5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
5.17k
                                                            LocalSinkStateInfo& info) {
500
5.17k
    auto local_state = LocalStateType::create_unique(this, state);
501
5.17k
    RETURN_IF_ERROR(local_state->init(state, info));
502
5.17k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
5.17k
    return Status::OK();
504
5.17k
}
_ZN5doris17DataSinkOperatorXINS_22TVFTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
156
                                                            LocalSinkStateInfo& info) {
500
156
    auto local_state = LocalStateType::create_unique(this, state);
501
156
    RETURN_IF_ERROR(local_state->init(state, info));
502
156
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
156
    return Status::OK();
504
156
}
_ZN5doris17DataSinkOperatorXINS_26IcebergTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
3.71k
                                                            LocalSinkStateInfo& info) {
500
3.71k
    auto local_state = LocalStateType::create_unique(this, state);
501
3.71k
    RETURN_IF_ERROR(local_state->init(state, info));
502
3.71k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
3.71k
    return Status::OK();
504
3.71k
}
_ZN5doris17DataSinkOperatorXINS_31SpillIcebergTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
32
                                                            LocalSinkStateInfo& info) {
500
32
    auto local_state = LocalStateType::create_unique(this, state);
501
32
    RETURN_IF_ERROR(local_state->init(state, info));
502
32
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
32
    return Status::OK();
504
32
}
_ZN5doris17DataSinkOperatorXINS_27IcebergDeleteSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
656
                                                            LocalSinkStateInfo& info) {
500
656
    auto local_state = LocalStateType::create_unique(this, state);
501
656
    RETURN_IF_ERROR(local_state->init(state, info));
502
656
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
656
    return Status::OK();
504
656
}
_ZN5doris17DataSinkOperatorXINS_26IcebergMergeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
1.50k
                                                            LocalSinkStateInfo& info) {
500
1.50k
    auto local_state = LocalStateType::create_unique(this, state);
501
1.50k
    RETURN_IF_ERROR(local_state->init(state, info));
502
1.50k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
1.50k
    return Status::OK();
504
1.50k
}
Unexecuted instantiation: _ZN5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
6.66k
                                                            LocalSinkStateInfo& info) {
500
6.66k
    auto local_state = LocalStateType::create_unique(this, state);
501
6.66k
    RETURN_IF_ERROR(local_state->init(state, info));
502
6.66k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
6.66k
    return Status::OK();
504
6.66k
}
_ZN5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
96
                                                            LocalSinkStateInfo& info) {
500
96
    auto local_state = LocalStateType::create_unique(this, state);
501
96
    RETURN_IF_ERROR(local_state->init(state, info));
502
96
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
96
    return Status::OK();
504
96
}
_ZN5doris17DataSinkOperatorXINS_18SortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
263k
                                                            LocalSinkStateInfo& info) {
500
263k
    auto local_state = LocalStateType::create_unique(this, state);
501
263k
    RETURN_IF_ERROR(local_state->init(state, info));
502
263k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
263k
    return Status::OK();
504
263k
}
_ZN5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
31
                                                            LocalSinkStateInfo& info) {
500
31
    auto local_state = LocalStateType::create_unique(this, state);
501
31
    RETURN_IF_ERROR(local_state->init(state, info));
502
31
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
31
    return Status::OK();
504
31
}
_ZN5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
319k
                                                            LocalSinkStateInfo& info) {
500
319k
    auto local_state = LocalStateType::create_unique(this, state);
501
319k
    RETURN_IF_ERROR(local_state->init(state, info));
502
319k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
319k
    return Status::OK();
504
319k
}
_ZN5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
167k
                                                            LocalSinkStateInfo& info) {
500
167k
    auto local_state = LocalStateType::create_unique(this, state);
501
167k
    RETURN_IF_ERROR(local_state->init(state, info));
502
167k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
167k
    return Status::OK();
504
167k
}
_ZN5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
686
                                                            LocalSinkStateInfo& info) {
500
686
    auto local_state = LocalStateType::create_unique(this, state);
501
686
    RETURN_IF_ERROR(local_state->init(state, info));
502
686
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
686
    return Status::OK();
504
686
}
_ZN5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
154
                                                            LocalSinkStateInfo& info) {
500
154
    auto local_state = LocalStateType::create_unique(this, state);
501
154
    RETURN_IF_ERROR(local_state->init(state, info));
502
154
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
154
    return Status::OK();
504
154
}
_ZN5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
736k
                                                            LocalSinkStateInfo& info) {
500
736k
    auto local_state = LocalStateType::create_unique(this, state);
501
736k
    RETURN_IF_ERROR(local_state->init(state, info));
502
736k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
736k
    return Status::OK();
504
736k
}
_ZN5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
12.5k
                                                            LocalSinkStateInfo& info) {
500
12.5k
    auto local_state = LocalStateType::create_unique(this, state);
501
12.5k
    RETURN_IF_ERROR(local_state->init(state, info));
502
12.5k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
12.5k
    return Status::OK();
504
12.5k
}
_ZN5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
7.63k
                                                            LocalSinkStateInfo& info) {
500
7.63k
    auto local_state = LocalStateType::create_unique(this, state);
501
7.63k
    RETURN_IF_ERROR(local_state->init(state, info));
502
7.63k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
7.63k
    return Status::OK();
504
7.63k
}
_ZN5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
4.77k
                                                            LocalSinkStateInfo& info) {
500
4.77k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.77k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.77k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.77k
    return Status::OK();
504
4.77k
}
_ZN5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
260
                                                            LocalSinkStateInfo& info) {
500
260
    auto local_state = LocalStateType::create_unique(this, state);
501
260
    RETURN_IF_ERROR(local_state->init(state, info));
502
260
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
260
    return Status::OK();
504
260
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
4.82k
                                                            LocalSinkStateInfo& info) {
500
4.82k
    auto local_state = LocalStateType::create_unique(this, state);
501
4.82k
    RETURN_IF_ERROR(local_state->init(state, info));
502
4.82k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
4.82k
    return Status::OK();
504
4.82k
}
_ZN5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.52k
                                                            LocalSinkStateInfo& info) {
500
2.52k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.52k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.52k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.52k
    return Status::OK();
504
2.52k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.68k
                                                            LocalSinkStateInfo& info) {
500
2.68k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.68k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.68k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.68k
    return Status::OK();
504
2.68k
}
_ZN5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
2.51k
                                                            LocalSinkStateInfo& info) {
500
2.51k
    auto local_state = LocalStateType::create_unique(this, state);
501
2.51k
    RETURN_IF_ERROR(local_state->init(state, info));
502
2.51k
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
2.51k
    return Status::OK();
504
2.51k
}
_ZN5doris17DataSinkOperatorXINS_33PartitionedHashJoinSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
1
                                                            LocalSinkStateInfo& info) {
500
1
    auto local_state = LocalStateType::create_unique(this, state);
501
1
    RETURN_IF_ERROR(local_state->init(state, info));
502
1
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
1
    return Status::OK();
504
1
}
_ZN5doris17DataSinkOperatorXINS_30GroupCommitBlockSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
563
                                                            LocalSinkStateInfo& info) {
500
563
    auto local_state = LocalStateType::create_unique(this, state);
501
563
    RETURN_IF_ERROR(local_state->init(state, info));
502
563
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
563
    return Status::OK();
504
563
}
_ZN5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
14
                                                            LocalSinkStateInfo& info) {
500
14
    auto local_state = LocalStateType::create_unique(this, state);
501
14
    RETURN_IF_ERROR(local_state->init(state, info));
502
14
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
14
    return Status::OK();
504
14
}
_ZN5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
104
                                                            LocalSinkStateInfo& info) {
500
104
    auto local_state = LocalStateType::create_unique(this, state);
501
104
    RETURN_IF_ERROR(local_state->init(state, info));
502
104
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
104
    return Status::OK();
504
104
}
_ZN5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
163
                                                            LocalSinkStateInfo& info) {
500
163
    auto local_state = LocalStateType::create_unique(this, state);
501
163
    RETURN_IF_ERROR(local_state->init(state, info));
502
163
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
163
    return Status::OK();
504
163
}
_ZN5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
499
164
                                                            LocalSinkStateInfo& info) {
500
164
    auto local_state = LocalStateType::create_unique(this, state);
501
164
    RETURN_IF_ERROR(local_state->init(state, info));
502
164
    state->emplace_sink_local_state(operator_id(), std::move(local_state));
503
164
    return Status::OK();
504
164
}
505
506
template <typename LocalStateType>
507
1.82M
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
0
                                 LocalExchangeSharedState>) {
510
0
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
0
                                        MultiCastSharedState>) {
513
0
        throw Exception(Status::FatalError("should not reach here!"));
514
1.82M
    } else {
515
1.82M
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.82M
        ss->id = operator_id();
517
1.82M
        for (auto& dest : dests_id()) {
518
1.82M
            ss->related_op_ids.insert(dest);
519
1.82M
        }
520
1.82M
        return ss;
521
1.82M
    }
522
1.82M
}
_ZNK5doris17DataSinkOperatorXINS_27HashJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
101k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
101k
    } else {
515
101k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
101k
        ss->id = operator_id();
517
101k
        for (auto& dest : dests_id()) {
518
101k
            ss->related_op_ids.insert(dest);
519
101k
        }
520
101k
        return ss;
521
101k
    }
522
101k
}
_ZNK5doris17DataSinkOperatorXINS_20ResultSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
463k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
463k
    } else {
515
463k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
463k
        ss->id = operator_id();
517
463k
        for (auto& dest : dests_id()) {
518
462k
            ss->related_op_ids.insert(dest);
519
462k
        }
520
463k
        return ss;
521
463k
    }
522
463k
}
_ZNK5doris17DataSinkOperatorXINS_23JdbcTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
86
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
86
    } else {
515
86
        auto ss = LocalStateType::SharedStateType::create_shared();
516
86
        ss->id = operator_id();
517
86
        for (auto& dest : dests_id()) {
518
86
            ss->related_op_ids.insert(dest);
519
86
        }
520
86
        return ss;
521
86
    }
522
86
}
_ZNK5doris17DataSinkOperatorXINS_27MemoryScratchSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
3
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
3
    } else {
515
3
        auto ss = LocalStateType::SharedStateType::create_shared();
516
3
        ss->id = operator_id();
517
3
        for (auto& dest : dests_id()) {
518
3
            ss->related_op_ids.insert(dest);
519
3
        }
520
3
        return ss;
521
3
    }
522
3
}
_ZNK5doris17DataSinkOperatorXINS_24ResultFileSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
513
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
513
    } else {
515
513
        auto ss = LocalStateType::SharedStateType::create_shared();
516
513
        ss->id = operator_id();
517
513
        for (auto& dest : dests_id()) {
518
512
            ss->related_op_ids.insert(dest);
519
512
        }
520
513
        return ss;
521
513
    }
522
513
}
_ZNK5doris17DataSinkOperatorXINS_23OlapTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
46.9k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
46.9k
    } else {
515
46.9k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
46.9k
        ss->id = operator_id();
517
46.9k
        for (auto& dest : dests_id()) {
518
46.7k
            ss->related_op_ids.insert(dest);
519
46.7k
        }
520
46.9k
        return ss;
521
46.9k
    }
522
46.9k
}
_ZNK5doris17DataSinkOperatorXINS_25OlapTableSinkV2LocalStateEE19create_shared_stateEv
Line
Count
Source
507
9.58k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
9.58k
    } else {
515
9.58k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
9.58k
        ss->id = operator_id();
517
9.58k
        for (auto& dest : dests_id()) {
518
9.58k
            ss->related_op_ids.insert(dest);
519
9.58k
        }
520
9.58k
        return ss;
521
9.58k
    }
522
9.58k
}
_ZNK5doris17DataSinkOperatorXINS_23HiveTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
5.17k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
5.17k
    } else {
515
5.17k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
5.17k
        ss->id = operator_id();
517
5.17k
        for (auto& dest : dests_id()) {
518
5.17k
            ss->related_op_ids.insert(dest);
519
5.17k
        }
520
5.17k
        return ss;
521
5.17k
    }
522
5.17k
}
_ZNK5doris17DataSinkOperatorXINS_22TVFTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
156
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
156
    } else {
515
156
        auto ss = LocalStateType::SharedStateType::create_shared();
516
156
        ss->id = operator_id();
517
156
        for (auto& dest : dests_id()) {
518
156
            ss->related_op_ids.insert(dest);
519
156
        }
520
156
        return ss;
521
156
    }
522
156
}
_ZNK5doris17DataSinkOperatorXINS_26IcebergTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
3.71k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
3.71k
    } else {
515
3.71k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
3.71k
        ss->id = operator_id();
517
3.71k
        for (auto& dest : dests_id()) {
518
3.70k
            ss->related_op_ids.insert(dest);
519
3.70k
        }
520
3.71k
        return ss;
521
3.71k
    }
522
3.71k
}
_ZNK5doris17DataSinkOperatorXINS_31SpillIcebergTableSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
32
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
32
    } else {
515
32
        auto ss = LocalStateType::SharedStateType::create_shared();
516
32
        ss->id = operator_id();
517
32
        for (auto& dest : dests_id()) {
518
32
            ss->related_op_ids.insert(dest);
519
32
        }
520
32
        return ss;
521
32
    }
522
32
}
_ZNK5doris17DataSinkOperatorXINS_27IcebergDeleteSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
656
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
656
    } else {
515
656
        auto ss = LocalStateType::SharedStateType::create_shared();
516
656
        ss->id = operator_id();
517
656
        for (auto& dest : dests_id()) {
518
656
            ss->related_op_ids.insert(dest);
519
656
        }
520
656
        return ss;
521
656
    }
522
656
}
_ZNK5doris17DataSinkOperatorXINS_26IcebergMergeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
1.50k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
1.50k
    } else {
515
1.50k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
1.50k
        ss->id = operator_id();
517
1.50k
        for (auto& dest : dests_id()) {
518
1.50k
            ss->related_op_ids.insert(dest);
519
1.50k
        }
520
1.50k
        return ss;
521
1.50k
    }
522
1.50k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_21MCTableSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_22AnalyticSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
6.68k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
6.68k
    } else {
515
6.68k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
6.68k
        ss->id = operator_id();
517
6.68k
        for (auto& dest : dests_id()) {
518
6.68k
            ss->related_op_ids.insert(dest);
519
6.68k
        }
520
6.68k
        return ss;
521
6.68k
    }
522
6.68k
}
_ZNK5doris17DataSinkOperatorXINS_23BlackholeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
94
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
94
    } else {
515
94
        auto ss = LocalStateType::SharedStateType::create_shared();
516
94
        ss->id = operator_id();
517
96
        for (auto& dest : dests_id()) {
518
96
            ss->related_op_ids.insert(dest);
519
96
        }
520
94
        return ss;
521
94
    }
522
94
}
_ZNK5doris17DataSinkOperatorXINS_18SortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
264k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
264k
    } else {
515
264k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
264k
        ss->id = operator_id();
517
264k
        for (auto& dest : dests_id()) {
518
263k
            ss->related_op_ids.insert(dest);
519
263k
        }
520
264k
        return ss;
521
264k
    }
522
264k
}
_ZNK5doris17DataSinkOperatorXINS_23SpillSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
33
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
33
    } else {
515
33
        auto ss = LocalStateType::SharedStateType::create_shared();
516
33
        ss->id = operator_id();
517
33
        for (auto& dest : dests_id()) {
518
33
            ss->related_op_ids.insert(dest);
519
33
        }
520
33
        return ss;
521
33
    }
522
33
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_27LocalExchangeSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17AggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
167k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
167k
    } else {
515
167k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
167k
        ss->id = operator_id();
517
167k
        for (auto& dest : dests_id()) {
518
167k
            ss->related_op_ids.insert(dest);
519
167k
        }
520
167k
        return ss;
521
167k
    }
522
167k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_25BucketedAggSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_28PartitionedAggSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
153
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
153
    } else {
515
153
        auto ss = LocalStateType::SharedStateType::create_shared();
516
153
        ss->id = operator_id();
517
153
        for (auto& dest : dests_id()) {
518
153
            ss->related_op_ids.insert(dest);
519
153
        }
520
153
        return ss;
521
153
    }
522
153
}
_ZNK5doris17DataSinkOperatorXINS_22ExchangeSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
736k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
736k
    } else {
515
736k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
736k
        ss->id = operator_id();
517
736k
        for (auto& dest : dests_id()) {
518
734k
            ss->related_op_ids.insert(dest);
519
734k
        }
520
736k
        return ss;
521
736k
    }
522
736k
}
_ZNK5doris17DataSinkOperatorXINS_33NestedLoopJoinBuildSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
12.5k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
12.5k
    } else {
515
12.5k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
12.5k
        ss->id = operator_id();
517
12.5k
        for (auto& dest : dests_id()) {
518
12.5k
            ss->related_op_ids.insert(dest);
519
12.5k
        }
520
12.5k
        return ss;
521
12.5k
    }
522
12.5k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19UnionSinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33MultiCastDataStreamSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_27PartitionSortSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
363
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
363
    } else {
515
363
        auto ss = LocalStateType::SharedStateType::create_shared();
516
363
        ss->id = operator_id();
517
363
        for (auto& dest : dests_id()) {
518
362
            ss->related_op_ids.insert(dest);
519
362
        }
520
363
        return ss;
521
363
    }
522
363
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb1EEEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_22SetProbeSinkLocalStateILb0EEEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb1EEEE19create_shared_stateEv
Line
Count
Source
507
2.67k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
2.67k
    } else {
515
2.67k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.67k
        ss->id = operator_id();
517
2.67k
        for (auto& dest : dests_id()) {
518
2.66k
            ss->related_op_ids.insert(dest);
519
2.66k
        }
520
2.67k
        return ss;
521
2.67k
    }
522
2.67k
}
_ZNK5doris17DataSinkOperatorXINS_17SetSinkLocalStateILb0EEEE19create_shared_stateEv
Line
Count
Source
507
2.50k
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
2.50k
    } else {
515
2.50k
        auto ss = LocalStateType::SharedStateType::create_shared();
516
2.50k
        ss->id = operator_id();
517
2.50k
        for (auto& dest : dests_id()) {
518
2.49k
            ss->related_op_ids.insert(dest);
519
2.49k
        }
520
2.50k
        return ss;
521
2.50k
    }
522
2.50k
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_33PartitionedHashJoinSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_30GroupCommitBlockSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
566
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
566
    } else {
515
566
        auto ss = LocalStateType::SharedStateType::create_shared();
516
566
        ss->id = operator_id();
517
566
        for (auto& dest : dests_id()) {
518
558
            ss->related_op_ids.insert(dest);
519
558
        }
520
566
        return ss;
521
566
    }
522
566
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_19CacheSinkLocalStateEE19create_shared_stateEv
_ZNK5doris17DataSinkOperatorXINS_18DictSinkLocalStateEE19create_shared_stateEv
Line
Count
Source
507
104
std::shared_ptr<BasicSharedState> DataSinkOperatorX<LocalStateType>::create_shared_state() const {
508
    if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
509
                                 LocalExchangeSharedState>) {
510
        return nullptr;
511
    } else if constexpr (std::is_same_v<typename LocalStateType::SharedStateType,
512
                                        MultiCastSharedState>) {
513
        throw Exception(Status::FatalError("should not reach here!"));
514
104
    } else {
515
104
        auto ss = LocalStateType::SharedStateType::create_shared();
516
104
        ss->id = operator_id();
517
104
        for (auto& dest : dests_id()) {
518
104
            ss->related_op_ids.insert(dest);
519
104
        }
520
104
        return ss;
521
104
    }
522
104
}
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_20RecCTESinkLocalStateEE19create_shared_stateEv
Unexecuted instantiation: _ZNK5doris17DataSinkOperatorXINS_26RecCTEAnchorSinkLocalStateEE19create_shared_stateEv
523
524
template <typename LocalStateType>
525
2.69M
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.69M
    auto local_state = LocalStateType::create_unique(state, this);
527
2.69M
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.69M
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.69M
    return Status::OK();
530
2.69M
}
_ZN5doris9OperatorXINS_23HashJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
75.7k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
75.7k
    auto local_state = LocalStateType::create_unique(state, this);
527
75.7k
    RETURN_IF_ERROR(local_state->init(state, info));
528
75.7k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
75.7k
    return Status::OK();
530
75.7k
}
_ZN5doris9OperatorXINS_18OlapScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
318k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
318k
    auto local_state = LocalStateType::create_unique(state, this);
527
318k
    RETURN_IF_ERROR(local_state->init(state, info));
528
318k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
318k
    return Status::OK();
530
318k
}
_ZN5doris9OperatorXINS_21GroupCommitLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
143
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
143
    auto local_state = LocalStateType::create_unique(state, this);
527
143
    RETURN_IF_ERROR(local_state->init(state, info));
528
143
    state->emplace_local_state(operator_id(), std::move(local_state));
529
143
    return Status::OK();
530
143
}
Unexecuted instantiation: _ZN5doris9OperatorXINS_18JDBCScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris9OperatorXINS_18FileScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
36.7k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
36.7k
    auto local_state = LocalStateType::create_unique(state, this);
527
36.7k
    RETURN_IF_ERROR(local_state->init(state, info));
528
36.7k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
36.7k
    return Status::OK();
530
36.7k
}
_ZN5doris9OperatorXINS_18AnalyticLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
6.64k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
6.64k
    auto local_state = LocalStateType::create_unique(state, this);
527
6.64k
    RETURN_IF_ERROR(local_state->init(state, info));
528
6.64k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
6.64k
    return Status::OK();
530
6.64k
}
_ZN5doris9OperatorXINS_14SortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
6.93k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
6.93k
    auto local_state = LocalStateType::create_unique(state, this);
527
6.93k
    RETURN_IF_ERROR(local_state->init(state, info));
528
6.93k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
6.93k
    return Status::OK();
530
6.93k
}
_ZN5doris9OperatorXINS_19SpillSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
24
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
24
    auto local_state = LocalStateType::create_unique(state, this);
527
24
    RETURN_IF_ERROR(local_state->init(state, info));
528
24
    state->emplace_local_state(operator_id(), std::move(local_state));
529
24
    return Status::OK();
530
24
}
_ZN5doris9OperatorXINS_24LocalMergeSortLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
255k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
255k
    auto local_state = LocalStateType::create_unique(state, this);
527
255k
    RETURN_IF_ERROR(local_state->init(state, info));
528
255k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
255k
    return Status::OK();
530
255k
}
_ZN5doris9OperatorXINS_13AggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
167k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
167k
    auto local_state = LocalStateType::create_unique(state, this);
527
167k
    RETURN_IF_ERROR(local_state->init(state, info));
528
167k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
167k
    return Status::OK();
530
167k
}
_ZN5doris9OperatorXINS_21BucketedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
688
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
688
    auto local_state = LocalStateType::create_unique(state, this);
527
688
    RETURN_IF_ERROR(local_state->init(state, info));
528
688
    state->emplace_local_state(operator_id(), std::move(local_state));
529
688
    return Status::OK();
530
688
}
_ZN5doris9OperatorXINS_24PartitionedAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
144
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
144
    auto local_state = LocalStateType::create_unique(state, this);
527
144
    RETURN_IF_ERROR(local_state->init(state, info));
528
144
    state->emplace_local_state(operator_id(), std::move(local_state));
529
144
    return Status::OK();
530
144
}
_ZN5doris9OperatorXINS_23TableFunctionLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.94k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.94k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.94k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.94k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.94k
    return Status::OK();
530
2.94k
}
_ZN5doris9OperatorXINS_18ExchangeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
412k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
412k
    auto local_state = LocalStateType::create_unique(state, this);
527
412k
    RETURN_IF_ERROR(local_state->init(state, info));
528
412k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
412k
    return Status::OK();
530
412k
}
_ZN5doris9OperatorXINS_16RepeatLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.06k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.06k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.06k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.06k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.06k
    return Status::OK();
530
1.06k
}
_ZN5doris9OperatorXINS_29NestedLoopJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
12.2k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
12.2k
    auto local_state = LocalStateType::create_unique(state, this);
527
12.2k
    RETURN_IF_ERROR(local_state->init(state, info));
528
12.2k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
12.2k
    return Status::OK();
530
12.2k
}
_ZN5doris9OperatorXINS_23AssertNumRowsLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
221
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
221
    auto local_state = LocalStateType::create_unique(state, this);
527
221
    RETURN_IF_ERROR(local_state->init(state, info));
528
221
    state->emplace_local_state(operator_id(), std::move(local_state));
529
221
    return Status::OK();
530
221
}
_ZN5doris9OperatorXINS_18EmptySetLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.98k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.98k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.98k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.98k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.98k
    return Status::OK();
530
1.98k
}
_ZN5doris9OperatorXINS_21UnionSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
57.0k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
57.0k
    auto local_state = LocalStateType::create_unique(state, this);
527
57.0k
    RETURN_IF_ERROR(local_state->init(state, info));
528
57.0k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
57.0k
    return Status::OK();
530
57.0k
}
_ZN5doris9OperatorXINS_35MultiCastDataStreamSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
12.9k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
12.9k
    auto local_state = LocalStateType::create_unique(state, this);
527
12.9k
    RETURN_IF_ERROR(local_state->init(state, info));
528
12.9k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
12.9k
    return Status::OK();
530
12.9k
}
_ZN5doris9OperatorXINS_29PartitionSortSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
260
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
260
    auto local_state = LocalStateType::create_unique(state, this);
527
260
    RETURN_IF_ERROR(local_state->init(state, info));
528
260
    state->emplace_local_state(operator_id(), std::move(local_state));
529
260
    return Status::OK();
530
260
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb1EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.70k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.70k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.70k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.70k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.70k
    return Status::OK();
530
2.70k
}
_ZN5doris9OperatorXINS_19SetSourceLocalStateILb0EEEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.55k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.55k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.55k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.55k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.55k
    return Status::OK();
530
2.55k
}
_ZN5doris9OperatorXINS_17DataGenLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
506
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
506
    auto local_state = LocalStateType::create_unique(state, this);
527
506
    RETURN_IF_ERROR(local_state->init(state, info));
528
506
    state->emplace_local_state(operator_id(), std::move(local_state));
529
506
    return Status::OK();
530
506
}
_ZN5doris9OperatorXINS_20SchemaScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.22k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.22k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.22k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.22k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.22k
    return Status::OK();
530
2.22k
}
_ZN5doris9OperatorXINS_18MetaScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
7.21k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
7.21k
    auto local_state = LocalStateType::create_unique(state, this);
527
7.21k
    RETURN_IF_ERROR(local_state->init(state, info));
528
7.21k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
7.21k
    return Status::OK();
530
7.21k
}
_ZN5doris9OperatorXINS_29LocalExchangeSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
824k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
824k
    auto local_state = LocalStateType::create_unique(state, this);
527
824k
    RETURN_IF_ERROR(local_state->init(state, info));
528
824k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
824k
    return Status::OK();
530
824k
}
Unexecuted instantiation: _ZN5doris9OperatorXINS_34PartitionedHashJoinProbeLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris9OperatorXINS_21CacheSourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
14
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
14
    auto local_state = LocalStateType::create_unique(state, this);
527
14
    RETURN_IF_ERROR(local_state->init(state, info));
528
14
    state->emplace_local_state(operator_id(), std::move(local_state));
529
14
    return Status::OK();
530
14
}
_ZN5doris9OperatorXINS_22RecCTESourceLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
164
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
164
    auto local_state = LocalStateType::create_unique(state, this);
527
164
    RETURN_IF_ERROR(local_state->init(state, info));
528
164
    state->emplace_local_state(operator_id(), std::move(local_state));
529
164
    return Status::OK();
530
164
}
_ZN5doris9OperatorXINS_20RecCTEScanLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.18k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.18k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.18k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.18k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.18k
    return Status::OK();
530
2.18k
}
_ZN5doris9OperatorXINS_25MaterializationLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
1.73k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
1.73k
    auto local_state = LocalStateType::create_unique(state, this);
527
1.73k
    RETURN_IF_ERROR(local_state->init(state, info));
528
1.73k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
1.73k
    return Status::OK();
530
1.73k
}
_ZN5doris9OperatorXINS_16SelectLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
2.84k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
2.84k
    auto local_state = LocalStateType::create_unique(state, this);
527
2.84k
    RETURN_IF_ERROR(local_state->init(state, info));
528
2.84k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
2.84k
    return Status::OK();
530
2.84k
}
_ZN5doris9OperatorXINS_22StreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
11.2k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
11.2k
    auto local_state = LocalStateType::create_unique(state, this);
527
11.2k
    RETURN_IF_ERROR(local_state->init(state, info));
528
11.2k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
11.2k
    return Status::OK();
530
11.2k
}
_ZN5doris9OperatorXINS_30DistinctStreamingAggLocalStateEE17setup_local_stateEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
525
470k
Status OperatorX<LocalStateType>::setup_local_state(RuntimeState* state, LocalStateInfo& info) {
526
470k
    auto local_state = LocalStateType::create_unique(state, this);
527
470k
    RETURN_IF_ERROR(local_state->init(state, info));
528
470k
    state->emplace_local_state(operator_id(), std::move(local_state));
529
470k
    return Status::OK();
530
470k
}
531
532
PipelineXSinkLocalStateBase::PipelineXSinkLocalStateBase(DataSinkOperatorXBase* parent,
533
                                                         RuntimeState* state)
534
2.19M
        : _parent(parent), _state(state) {}
535
536
PipelineXLocalStateBase::PipelineXLocalStateBase(RuntimeState* state, OperatorXBase* parent)
537
2.69M
        : _num_rows_returned(0),
538
2.69M
          _rows_returned_counter(nullptr),
539
2.69M
          _parent(parent),
540
2.69M
          _state(state),
541
2.69M
          _budget(state->batch_size(), state->preferred_block_size_bytes()) {}
542
543
template <typename SharedStateArg>
544
2.70M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
2.70M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
2.70M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
2.70M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
2.70M
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
2.70M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
2.70M
    _operator_profile->add_child(_common_profile.get(), true);
553
2.70M
    _operator_profile->add_child(_custom_profile.get(), true);
554
2.70M
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
2.70M
    if constexpr (!is_fake_shared) {
556
1.43M
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
840k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
840k
                                    .first.get()
559
840k
                                    ->template cast<SharedStateArg>();
560
561
840k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
840k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
840k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
840k
        } else if (info.shared_state) {
565
510k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
0
                DCHECK(false);
567
0
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
510k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
510k
            _dependency = _shared_state->create_source_dependency(
572
510k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
510k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
510k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
510k
        } else {
576
80.7k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
11.2k
                DCHECK(false);
578
11.2k
            }
579
80.7k
        }
580
1.43M
    }
581
582
2.70M
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
2.70M
    _rows_returned_counter =
587
2.70M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
2.70M
    _blocks_returned_counter =
589
2.70M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
2.70M
    _output_block_bytes_counter =
591
2.70M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
2.70M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
2.70M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
2.70M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
2.70M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
2.70M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
2.70M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
2.70M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
2.70M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
2.70M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
2.70M
    _memory_used_counter =
602
2.70M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
2.70M
    _common_profile->add_info_string("IsColocate",
604
2.70M
                                     std::to_string(_parent->is_colocated_operator()));
605
2.70M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
2.70M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
2.70M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
2.70M
    return Status::OK();
609
2.70M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
76.4k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
76.4k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
76.4k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
76.4k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
76.4k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
76.4k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
76.4k
    _operator_profile->add_child(_common_profile.get(), true);
553
76.4k
    _operator_profile->add_child(_custom_profile.get(), true);
554
76.4k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
76.4k
    if constexpr (!is_fake_shared) {
556
76.4k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
22.2k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
22.2k
                                    .first.get()
559
22.2k
                                    ->template cast<SharedStateArg>();
560
561
22.2k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
22.2k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
22.2k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
54.2k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
51.9k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
51.9k
            _dependency = _shared_state->create_source_dependency(
572
51.9k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
51.9k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
51.9k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
51.9k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
2.29k
        }
580
76.4k
    }
581
582
76.4k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
76.4k
    _rows_returned_counter =
587
76.4k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
76.4k
    _blocks_returned_counter =
589
76.4k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
76.4k
    _output_block_bytes_counter =
591
76.4k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
76.4k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
76.4k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
76.4k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
76.4k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
76.4k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
76.4k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
76.4k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
76.4k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
76.4k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
76.4k
    _memory_used_counter =
602
76.4k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
76.4k
    _common_profile->add_info_string("IsColocate",
604
76.4k
                                     std::to_string(_parent->is_colocated_operator()));
605
76.4k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
76.4k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
76.4k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
76.4k
    return Status::OK();
609
76.4k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
1
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1
    _operator_profile->add_child(_common_profile.get(), true);
553
1
    _operator_profile->add_child(_custom_profile.get(), true);
554
1
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
1
    if constexpr (!is_fake_shared) {
556
1
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
1
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
1
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
1
            _dependency = _shared_state->create_source_dependency(
572
1
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
1
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
1
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
1
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
1
    }
581
582
1
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
1
    _rows_returned_counter =
587
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1
    _blocks_returned_counter =
589
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1
    _output_block_bytes_counter =
591
1
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1
    _memory_used_counter =
602
1
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1
    _common_profile->add_info_string("IsColocate",
604
1
                                     std::to_string(_parent->is_colocated_operator()));
605
1
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1
    return Status::OK();
609
1
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
263k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
263k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
263k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
263k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
263k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
263k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
263k
    _operator_profile->add_child(_common_profile.get(), true);
553
263k
    _operator_profile->add_child(_custom_profile.get(), true);
554
263k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
263k
    if constexpr (!is_fake_shared) {
556
263k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
263k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
253k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
253k
            _dependency = _shared_state->create_source_dependency(
572
253k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
253k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
253k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
253k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
10.1k
        }
580
263k
    }
581
582
263k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
263k
    _rows_returned_counter =
587
263k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
263k
    _blocks_returned_counter =
589
263k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
263k
    _output_block_bytes_counter =
591
263k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
263k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
263k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
263k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
263k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
263k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
263k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
263k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
263k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
263k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
263k
    _memory_used_counter =
602
263k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
263k
    _common_profile->add_info_string("IsColocate",
604
263k
                                     std::to_string(_parent->is_colocated_operator()));
605
263k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
263k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
263k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
263k
    return Status::OK();
609
263k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
24
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
24
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
24
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
24
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
24
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
24
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
24
    _operator_profile->add_child(_common_profile.get(), true);
553
24
    _operator_profile->add_child(_custom_profile.get(), true);
554
24
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
24
    if constexpr (!is_fake_shared) {
556
24
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
24
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
24
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
24
            _dependency = _shared_state->create_source_dependency(
572
24
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
24
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
24
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
24
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
24
    }
581
582
24
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
24
    _rows_returned_counter =
587
24
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
24
    _blocks_returned_counter =
589
24
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
24
    _output_block_bytes_counter =
591
24
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
24
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
24
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
24
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
24
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
24
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
24
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
24
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
24
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
24
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
24
    _memory_used_counter =
602
24
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
24
    _common_profile->add_info_string("IsColocate",
604
24
                                     std::to_string(_parent->is_colocated_operator()));
605
24
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
24
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
24
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
24
    return Status::OK();
609
24
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
12.4k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
12.4k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
12.4k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
12.4k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
12.4k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
12.4k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
12.4k
    _operator_profile->add_child(_common_profile.get(), true);
553
12.4k
    _operator_profile->add_child(_custom_profile.get(), true);
554
12.4k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
12.4k
    if constexpr (!is_fake_shared) {
556
12.4k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
12.4k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
11.8k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
11.8k
            _dependency = _shared_state->create_source_dependency(
572
11.8k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
11.8k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
11.8k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
11.8k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
599
        }
580
12.4k
    }
581
582
12.4k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
12.4k
    _rows_returned_counter =
587
12.4k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
12.4k
    _blocks_returned_counter =
589
12.4k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
12.4k
    _output_block_bytes_counter =
591
12.4k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
12.4k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
12.4k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
12.4k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
12.4k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
12.4k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
12.4k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
12.4k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
12.4k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
12.4k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
12.4k
    _memory_used_counter =
602
12.4k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
12.4k
    _common_profile->add_info_string("IsColocate",
604
12.4k
                                     std::to_string(_parent->is_colocated_operator()));
605
12.4k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
12.4k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
12.4k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
12.4k
    return Status::OK();
609
12.4k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
6.67k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
6.67k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
6.67k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
6.67k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
6.67k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
6.67k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
6.67k
    _operator_profile->add_child(_common_profile.get(), true);
553
6.67k
    _operator_profile->add_child(_custom_profile.get(), true);
554
6.67k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
6.67k
    if constexpr (!is_fake_shared) {
556
6.67k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
6.67k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
6.59k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
6.59k
            _dependency = _shared_state->create_source_dependency(
572
6.59k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
6.59k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
6.59k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
6.59k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
72
        }
580
6.67k
    }
581
582
6.67k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
6.67k
    _rows_returned_counter =
587
6.67k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
6.67k
    _blocks_returned_counter =
589
6.67k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
6.67k
    _output_block_bytes_counter =
591
6.67k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
6.67k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
6.67k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
6.67k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
6.67k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
6.67k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
6.67k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
6.67k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
6.67k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
6.67k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
6.67k
    _memory_used_counter =
602
6.67k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
6.67k
    _common_profile->add_info_string("IsColocate",
604
6.67k
                                     std::to_string(_parent->is_colocated_operator()));
605
6.67k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
6.67k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
6.67k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
6.67k
    return Status::OK();
609
6.67k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
167k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
167k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
167k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
167k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
167k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
167k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
167k
    _operator_profile->add_child(_common_profile.get(), true);
553
167k
    _operator_profile->add_child(_custom_profile.get(), true);
554
167k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
167k
    if constexpr (!is_fake_shared) {
556
167k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
167k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
164k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
164k
            _dependency = _shared_state->create_source_dependency(
572
164k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
164k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
164k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
164k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
2.79k
        }
580
167k
    }
581
582
167k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
167k
    _rows_returned_counter =
587
167k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
167k
    _blocks_returned_counter =
589
167k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
167k
    _output_block_bytes_counter =
591
167k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
167k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
167k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
167k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
167k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
167k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
167k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
167k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
167k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
167k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
167k
    _memory_used_counter =
602
167k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
167k
    _common_profile->add_info_string("IsColocate",
604
167k
                                     std::to_string(_parent->is_colocated_operator()));
605
167k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
167k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
167k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
167k
    return Status::OK();
609
167k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
691
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
691
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
691
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
691
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
691
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
691
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
691
    _operator_profile->add_child(_common_profile.get(), true);
553
691
    _operator_profile->add_child(_custom_profile.get(), true);
554
691
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
691
    if constexpr (!is_fake_shared) {
556
691
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
679
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
679
                                    .first.get()
559
679
                                    ->template cast<SharedStateArg>();
560
561
679
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
679
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
679
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
679
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
0
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
0
            _dependency = _shared_state->create_source_dependency(
572
0
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
12
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
12
        }
580
691
    }
581
582
691
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
691
    _rows_returned_counter =
587
691
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
691
    _blocks_returned_counter =
589
691
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
691
    _output_block_bytes_counter =
591
691
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
691
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
691
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
691
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
691
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
691
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
691
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
691
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
691
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
691
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
691
    _memory_used_counter =
602
691
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
691
    _common_profile->add_info_string("IsColocate",
604
691
                                     std::to_string(_parent->is_colocated_operator()));
605
691
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
691
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
691
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
691
    return Status::OK();
609
691
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
144
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
144
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
144
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
144
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
144
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
144
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
144
    _operator_profile->add_child(_common_profile.get(), true);
553
144
    _operator_profile->add_child(_custom_profile.get(), true);
554
144
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
144
    if constexpr (!is_fake_shared) {
556
144
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
144
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
144
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
144
            _dependency = _shared_state->create_source_dependency(
572
144
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
144
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
144
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
144
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
144
    }
581
582
144
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
144
    _rows_returned_counter =
587
144
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
144
    _blocks_returned_counter =
589
144
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
144
    _output_block_bytes_counter =
591
144
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
144
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
144
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
144
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
144
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
144
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
144
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
144
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
144
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
144
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
144
    _memory_used_counter =
602
144
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
144
    _common_profile->add_info_string("IsColocate",
604
144
                                     std::to_string(_parent->is_colocated_operator()));
605
144
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
144
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
144
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
144
    return Status::OK();
609
144
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
1.26M
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
1.26M
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
1.26M
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
1.26M
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
1.26M
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
1.26M
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
1.26M
    _operator_profile->add_child(_common_profile.get(), true);
553
1.26M
    _operator_profile->add_child(_custom_profile.get(), true);
554
1.26M
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
    if constexpr (!is_fake_shared) {
556
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
                                    .first.get()
559
                                    ->template cast<SharedStateArg>();
560
561
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
            _dependency = _shared_state->create_source_dependency(
572
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
        }
580
    }
581
582
1.26M
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
1.26M
    _rows_returned_counter =
587
1.26M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
1.26M
    _blocks_returned_counter =
589
1.26M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
1.26M
    _output_block_bytes_counter =
591
1.26M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
1.26M
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
1.26M
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
1.26M
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
1.26M
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
1.26M
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
1.26M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
1.26M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
1.26M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
1.26M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
1.26M
    _memory_used_counter =
602
1.26M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
1.26M
    _common_profile->add_info_string("IsColocate",
604
1.26M
                                     std::to_string(_parent->is_colocated_operator()));
605
1.26M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
1.26M
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
1.26M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
1.26M
    return Status::OK();
609
1.26M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
56.9k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
56.9k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
56.9k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
56.9k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
56.9k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
56.9k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
56.9k
    _operator_profile->add_child(_common_profile.get(), true);
553
56.9k
    _operator_profile->add_child(_custom_profile.get(), true);
554
56.9k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
56.9k
    if constexpr (!is_fake_shared) {
556
56.9k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
56.9k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
3.55k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
3.55k
            _dependency = _shared_state->create_source_dependency(
572
3.55k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
3.55k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
3.55k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
53.3k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
53.3k
        }
580
56.9k
    }
581
582
56.9k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
56.9k
    _rows_returned_counter =
587
56.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
56.9k
    _blocks_returned_counter =
589
56.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
56.9k
    _output_block_bytes_counter =
591
56.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
56.9k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
56.9k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
56.9k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
56.9k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
56.9k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
56.9k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
56.9k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
56.9k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
56.9k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
56.9k
    _memory_used_counter =
602
56.9k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
56.9k
    _common_profile->add_info_string("IsColocate",
604
56.9k
                                     std::to_string(_parent->is_colocated_operator()));
605
56.9k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
56.9k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
56.9k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
56.9k
    return Status::OK();
609
56.9k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
26
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
26
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
26
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
26
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
26
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
26
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
26
    _operator_profile->add_child(_common_profile.get(), true);
553
26
    _operator_profile->add_child(_custom_profile.get(), true);
554
26
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
26
    if constexpr (!is_fake_shared) {
556
26
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
26
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
26
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
26
            _dependency = _shared_state->create_source_dependency(
572
26
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
26
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
26
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
26
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
26
    }
581
582
26
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
26
    _rows_returned_counter =
587
26
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
26
    _blocks_returned_counter =
589
26
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
26
    _output_block_bytes_counter =
591
26
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
26
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
26
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
26
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
26
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
26
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
26
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
26
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
26
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
26
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
26
    _memory_used_counter =
602
26
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
26
    _common_profile->add_info_string("IsColocate",
604
26
                                     std::to_string(_parent->is_colocated_operator()));
605
26
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
26
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
26
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
26
    return Status::OK();
609
26
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
12.9k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
12.9k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
12.9k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
12.9k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
12.9k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
12.9k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
12.9k
    _operator_profile->add_child(_common_profile.get(), true);
553
12.9k
    _operator_profile->add_child(_custom_profile.get(), true);
554
12.9k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
12.9k
    if constexpr (!is_fake_shared) {
556
12.9k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
12.9k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
12.8k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
12.8k
            _dependency = _shared_state->create_source_dependency(
572
12.8k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
12.8k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
12.8k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
12.8k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
153
        }
580
12.9k
    }
581
582
12.9k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
12.9k
    _rows_returned_counter =
587
12.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
12.9k
    _blocks_returned_counter =
589
12.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
12.9k
    _output_block_bytes_counter =
591
12.9k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
12.9k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
12.9k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
12.9k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
12.9k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
12.9k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
12.9k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
12.9k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
12.9k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
12.9k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
12.9k
    _memory_used_counter =
602
12.9k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
12.9k
    _common_profile->add_info_string("IsColocate",
604
12.9k
                                     std::to_string(_parent->is_colocated_operator()));
605
12.9k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
12.9k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
12.9k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
12.9k
    return Status::OK();
609
12.9k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
363
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
363
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
363
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
363
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
363
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
363
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
363
    _operator_profile->add_child(_common_profile.get(), true);
553
363
    _operator_profile->add_child(_custom_profile.get(), true);
554
363
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
363
    if constexpr (!is_fake_shared) {
556
363
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
363
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
361
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
361
            _dependency = _shared_state->create_source_dependency(
572
361
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
361
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
361
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
361
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
2
        }
580
363
    }
581
582
363
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
363
    _rows_returned_counter =
587
363
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
363
    _blocks_returned_counter =
589
363
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
363
    _output_block_bytes_counter =
591
363
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
363
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
363
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
363
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
363
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
363
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
363
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
363
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
363
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
363
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
363
    _memory_used_counter =
602
363
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
363
    _common_profile->add_info_string("IsColocate",
604
363
                                     std::to_string(_parent->is_colocated_operator()));
605
363
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
363
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
363
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
363
    return Status::OK();
609
363
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
5.29k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
5.29k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
5.29k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
5.29k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
5.29k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
5.29k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
5.29k
    _operator_profile->add_child(_common_profile.get(), true);
553
5.29k
    _operator_profile->add_child(_custom_profile.get(), true);
554
5.29k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
5.29k
    if constexpr (!is_fake_shared) {
556
5.29k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
5.29k
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
5.23k
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
5.23k
            _dependency = _shared_state->create_source_dependency(
572
5.23k
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
5.23k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
5.23k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
5.23k
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
61
        }
580
5.29k
    }
581
582
5.29k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
5.29k
    _rows_returned_counter =
587
5.29k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
5.29k
    _blocks_returned_counter =
589
5.29k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
5.29k
    _output_block_bytes_counter =
591
5.29k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
5.29k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
5.29k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
5.29k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
5.29k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
5.29k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
5.29k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
5.29k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
5.29k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
5.29k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
5.29k
    _memory_used_counter =
602
5.29k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
5.29k
    _common_profile->add_info_string("IsColocate",
604
5.29k
                                     std::to_string(_parent->is_colocated_operator()));
605
5.29k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
5.29k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
5.29k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
5.29k
    return Status::OK();
609
5.29k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
829k
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
829k
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
829k
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
829k
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
829k
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
829k
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
829k
    _operator_profile->add_child(_common_profile.get(), true);
553
829k
    _operator_profile->add_child(_custom_profile.get(), true);
554
829k
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
829k
    if constexpr (!is_fake_shared) {
556
829k
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
817k
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
817k
                                    .first.get()
559
817k
                                    ->template cast<SharedStateArg>();
560
561
817k
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
817k
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
817k
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
817k
        } else if (info.shared_state) {
565
0
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
0
                DCHECK(false);
567
0
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
0
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
0
            _dependency = _shared_state->create_source_dependency(
572
0
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
11.2k
        } else {
576
11.2k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
11.2k
                DCHECK(false);
578
11.2k
            }
579
11.2k
        }
580
829k
    }
581
582
829k
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
829k
    _rows_returned_counter =
587
829k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
829k
    _blocks_returned_counter =
589
829k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
829k
    _output_block_bytes_counter =
591
829k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
829k
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
829k
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
829k
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
829k
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
829k
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
829k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
829k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
829k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
829k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
829k
    _memory_used_counter =
602
829k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
829k
    _common_profile->add_info_string("IsColocate",
604
829k
                                     std::to_string(_parent->is_colocated_operator()));
605
829k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
829k
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
829k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
829k
    return Status::OK();
609
829k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE4initEPNS_12RuntimeStateERNS_14LocalStateInfoE
Line
Count
Source
544
164
Status PipelineXLocalState<SharedStateArg>::init(RuntimeState* state, LocalStateInfo& info) {
545
164
    _operator_profile.reset(new RuntimeProfile(_parent->get_name() + name_suffix()));
546
164
    _common_profile.reset(new RuntimeProfile(profile::COMMON_COUNTERS));
547
164
    _custom_profile.reset(new RuntimeProfile(profile::CUSTOM_COUNTERS));
548
164
    _operator_profile->set_metadata(_parent->node_id());
549
    // indent is false so that source operator will have same
550
    // indentation_level with its parent operator.
551
164
    info.parent_profile->add_child(_operator_profile.get(), /*indent=*/false);
552
164
    _operator_profile->add_child(_common_profile.get(), true);
553
164
    _operator_profile->add_child(_custom_profile.get(), true);
554
164
    constexpr auto is_fake_shared = std::is_same_v<SharedStateArg, FakeSharedState>;
555
164
    if constexpr (!is_fake_shared) {
556
164
        if (info.shared_state_map.find(_parent->operator_id()) != info.shared_state_map.end()) {
557
0
            _shared_state = info.shared_state_map.at(_parent->operator_id())
558
0
                                    .first.get()
559
0
                                    ->template cast<SharedStateArg>();
560
561
0
            _dependency = _shared_state->get_dep_by_channel_id(info.task_idx).front().get();
562
0
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
563
0
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
564
164
        } else if (info.shared_state) {
565
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
566
                DCHECK(false);
567
            }
568
            // For UnionSourceOperator without children, there is no shared state.
569
164
            _shared_state = info.shared_state->template cast<SharedStateArg>();
570
571
164
            _dependency = _shared_state->create_source_dependency(
572
164
                    _parent->operator_id(), _parent->node_id(), _parent->get_name());
573
164
            _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
574
164
                    _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
575
164
        } else {
576
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedStateArg>) {
577
                DCHECK(false);
578
            }
579
0
        }
580
164
    }
581
582
164
    if (must_set_shared_state() && _shared_state == nullptr) {
583
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
584
0
    }
585
586
164
    _rows_returned_counter =
587
164
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::ROWS_PRODUCED, TUnit::UNIT, 1);
588
164
    _blocks_returned_counter =
589
164
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::BLOCKS_PRODUCED, TUnit::UNIT, 1);
590
164
    _output_block_bytes_counter =
591
164
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
592
164
    _max_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
593
164
            _common_profile, profile::MAX_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
594
164
    _min_output_block_bytes_counter = ADD_COUNTER_WITH_LEVEL(
595
164
            _common_profile, profile::MIN_OUTPUT_BLOCK_BYTES, TUnit::BYTES, 1);
596
164
    _projection_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::PROJECTION_TIME, 2);
597
164
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
598
164
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
599
164
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
600
164
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
601
164
    _memory_used_counter =
602
164
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
603
164
    _common_profile->add_info_string("IsColocate",
604
164
                                     std::to_string(_parent->is_colocated_operator()));
605
164
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
606
164
    _common_profile->add_info_string("FollowedByShuffledOperator",
607
164
                                     std::to_string(_parent->followed_by_shuffled_operator()));
608
164
    return Status::OK();
609
164
}
610
611
template <typename SharedStateArg>
612
2.71M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
2.71M
    _conjuncts.resize(_parent->_conjuncts.size());
614
2.71M
    _projections.resize(_parent->_projections.size());
615
3.24M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
530k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
530k
    }
618
5.59M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.88M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.88M
    }
621
2.71M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
2.73M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
17.5k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
122k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
105k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
105k
                    state, _intermediate_projections[i][j]));
627
105k
        }
628
17.5k
    }
629
2.71M
    return Status::OK();
630
2.71M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
77.0k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
77.0k
    _conjuncts.resize(_parent->_conjuncts.size());
614
77.0k
    _projections.resize(_parent->_projections.size());
615
78.4k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
1.43k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
1.43k
    }
618
419k
    for (size_t i = 0; i < _projections.size(); i++) {
619
342k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
342k
    }
621
77.0k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
79.7k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
2.73k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
34.9k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
32.1k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
32.1k
                    state, _intermediate_projections[i][j]));
627
32.1k
        }
628
2.73k
    }
629
77.0k
    return Status::OK();
630
77.0k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
3
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
3
    _conjuncts.resize(_parent->_conjuncts.size());
614
3
    _projections.resize(_parent->_projections.size());
615
3
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
3
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
3
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
3
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
3
    return Status::OK();
630
3
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
264k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
264k
    _conjuncts.resize(_parent->_conjuncts.size());
614
264k
    _projections.resize(_parent->_projections.size());
615
264k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
265k
    for (size_t i = 0; i < _projections.size(); i++) {
619
365
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
365
    }
621
264k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
264k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
264k
    return Status::OK();
630
264k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
24
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
24
    _conjuncts.resize(_parent->_conjuncts.size());
614
24
    _projections.resize(_parent->_projections.size());
615
24
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
24
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
24
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
24
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
24
    return Status::OK();
630
24
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
12.5k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
12.5k
    _conjuncts.resize(_parent->_conjuncts.size());
614
12.5k
    _projections.resize(_parent->_projections.size());
615
12.6k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
103
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
103
    }
618
77.8k
    for (size_t i = 0; i < _projections.size(); i++) {
619
65.3k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
65.3k
    }
621
12.5k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
12.7k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
144
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
913
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
769
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
769
                    state, _intermediate_projections[i][j]));
627
769
        }
628
144
    }
629
12.5k
    return Status::OK();
630
12.5k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
6.68k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
6.68k
    _conjuncts.resize(_parent->_conjuncts.size());
614
6.68k
    _projections.resize(_parent->_projections.size());
615
7.32k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
642
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
642
    }
618
17.8k
    for (size_t i = 0; i < _projections.size(); i++) {
619
11.2k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
11.2k
    }
621
6.68k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
6.76k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
82
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
614
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
532
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
532
                    state, _intermediate_projections[i][j]));
627
532
        }
628
82
    }
629
6.68k
    return Status::OK();
630
6.68k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
167k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
167k
    _conjuncts.resize(_parent->_conjuncts.size());
614
167k
    _projections.resize(_parent->_projections.size());
615
171k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
4.16k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
4.16k
    }
618
436k
    for (size_t i = 0; i < _projections.size(); i++) {
619
268k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
268k
    }
621
167k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
167k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
275
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
1.76k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
1.49k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
1.49k
                    state, _intermediate_projections[i][j]));
627
1.49k
        }
628
275
    }
629
167k
    return Status::OK();
630
167k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
692
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
692
    _conjuncts.resize(_parent->_conjuncts.size());
614
692
    _projections.resize(_parent->_projections.size());
615
703
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
11
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
11
    }
618
1.94k
    for (size_t i = 0; i < _projections.size(); i++) {
619
1.24k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
1.24k
    }
621
692
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
692
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
692
    return Status::OK();
630
692
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
148
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
148
    _conjuncts.resize(_parent->_conjuncts.size());
614
148
    _projections.resize(_parent->_projections.size());
615
148
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
404
    for (size_t i = 0; i < _projections.size(); i++) {
619
256
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
256
    }
621
148
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
148
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
148
    return Status::OK();
630
148
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
1.27M
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
1.27M
    _conjuncts.resize(_parent->_conjuncts.size());
614
1.27M
    _projections.resize(_parent->_projections.size());
615
1.79M
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
520k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
520k
    }
618
3.37M
    for (size_t i = 0; i < _projections.size(); i++) {
619
2.09M
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
2.09M
    }
621
1.27M
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
1.29M
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
14.2k
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
84.6k
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
70.3k
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
70.3k
                    state, _intermediate_projections[i][j]));
627
70.3k
        }
628
14.2k
    }
629
1.27M
    return Status::OK();
630
1.27M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
57.2k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
57.2k
    _conjuncts.resize(_parent->_conjuncts.size());
614
57.2k
    _projections.resize(_parent->_projections.size());
615
57.2k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
153k
    for (size_t i = 0; i < _projections.size(); i++) {
619
96.3k
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
96.3k
    }
621
57.2k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
57.2k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
57.2k
    return Status::OK();
630
57.2k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
25
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
25
    _conjuncts.resize(_parent->_conjuncts.size());
614
25
    _projections.resize(_parent->_projections.size());
615
25
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
25
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
25
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
25
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
25
    return Status::OK();
630
25
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
12.9k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
12.9k
    _conjuncts.resize(_parent->_conjuncts.size());
614
12.9k
    _projections.resize(_parent->_projections.size());
615
16.6k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
3.63k
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
3.63k
    }
618
12.9k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
12.9k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
12.9k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
12.9k
    return Status::OK();
630
12.9k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
363
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
363
    _conjuncts.resize(_parent->_conjuncts.size());
614
363
    _projections.resize(_parent->_projections.size());
615
363
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
363
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
363
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
363
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
363
    return Status::OK();
630
363
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
5.29k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
5.29k
    _conjuncts.resize(_parent->_conjuncts.size());
614
5.29k
    _projections.resize(_parent->_projections.size());
615
5.29k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
5.45k
    for (size_t i = 0; i < _projections.size(); i++) {
619
168
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
168
    }
621
5.29k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
5.29k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
5.29k
    return Status::OK();
630
5.29k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
832k
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
832k
    _conjuncts.resize(_parent->_conjuncts.size());
614
832k
    _projections.resize(_parent->_projections.size());
615
832k
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
0
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
0
    }
618
832k
    for (size_t i = 0; i < _projections.size(); i++) {
619
0
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
0
    }
621
832k
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
832k
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
0
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
0
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
0
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
0
                    state, _intermediate_projections[i][j]));
627
0
        }
628
0
    }
629
832k
    return Status::OK();
630
832k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE4openEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE4openEPNS_12RuntimeStateE
Line
Count
Source
612
164
Status PipelineXLocalState<SharedStateArg>::open(RuntimeState* state) {
613
164
    _conjuncts.resize(_parent->_conjuncts.size());
614
164
    _projections.resize(_parent->_projections.size());
615
171
    for (size_t i = 0; i < _conjuncts.size(); i++) {
616
7
        RETURN_IF_ERROR(_parent->_conjuncts[i]->clone(state, _conjuncts[i]));
617
7
    }
618
483
    for (size_t i = 0; i < _projections.size(); i++) {
619
319
        RETURN_IF_ERROR(_parent->_projections[i]->clone(state, _projections[i]));
620
319
    }
621
164
    _intermediate_projections.resize(_parent->_intermediate_projections.size());
622
167
    for (int i = 0; i < _parent->_intermediate_projections.size(); i++) {
623
3
        _intermediate_projections[i].resize(_parent->_intermediate_projections[i].size());
624
11
        for (int j = 0; j < _parent->_intermediate_projections[i].size(); j++) {
625
8
            RETURN_IF_ERROR(_parent->_intermediate_projections[i][j]->clone(
626
8
                    state, _intermediate_projections[i][j]));
627
8
        }
628
3
    }
629
164
    return Status::OK();
630
164
}
631
632
template <typename SharedStateArg>
633
5.67k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
5.67k
    if (_terminated) {
635
2
        return Status::OK();
636
2
    }
637
5.67k
    _terminated = true;
638
5.67k
    return Status::OK();
639
5.67k
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
246
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
246
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
246
    _terminated = true;
638
246
    return Status::OK();
639
246
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
75
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
75
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
75
    _terminated = true;
638
75
    return Status::OK();
639
75
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
58
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
58
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
58
    _terminated = true;
638
58
    return Status::OK();
639
58
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
2
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
2
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
2
    _terminated = true;
638
2
    return Status::OK();
639
2
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
43
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
43
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
43
    _terminated = true;
638
43
    return Status::OK();
639
43
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
2
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
2
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
2
    _terminated = true;
638
2
    return Status::OK();
639
2
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
4.22k
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
4.22k
    if (_terminated) {
635
1
        return Status::OK();
636
1
    }
637
4.22k
    _terminated = true;
638
4.22k
    return Status::OK();
639
4.22k
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
4
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
4
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
4
    _terminated = true;
638
4
    return Status::OK();
639
4
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
25
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
25
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
25
    _terminated = true;
638
25
    return Status::OK();
639
25
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
1
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
1
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
1
    _terminated = true;
638
1
    return Status::OK();
639
1
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
17
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
17
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
17
    _terminated = true;
638
17
    return Status::OK();
639
17
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
965
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
965
    if (_terminated) {
635
1
        return Status::OK();
636
1
    }
637
964
    _terminated = true;
638
964
    return Status::OK();
639
965
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE9terminateEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE9terminateEPNS_12RuntimeStateE
Line
Count
Source
633
12
Status PipelineXLocalState<SharedStateArg>::terminate(RuntimeState* state) {
634
12
    if (_terminated) {
635
0
        return Status::OK();
636
0
    }
637
12
    _terminated = true;
638
12
    return Status::OK();
639
12
}
640
641
template <typename SharedStateArg>
642
3.00M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
3.00M
    if (_closed) {
644
293k
        return Status::OK();
645
293k
    }
646
2.71M
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
1.43M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
1.43M
    }
649
2.71M
    _closed = true;
650
2.71M
    return Status::OK();
651
3.00M
}
_ZN5doris19PipelineXLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
76.9k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
76.9k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
76.9k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
76.9k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
76.9k
    }
649
76.9k
    _closed = true;
650
76.9k
    return Status::OK();
651
76.9k
}
_ZN5doris19PipelineXLocalStateINS_30PartitionedHashJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
4
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
4
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
4
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
4
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
4
    }
649
4
    _closed = true;
650
4
    return Status::OK();
651
4
}
_ZN5doris19PipelineXLocalStateINS_15SortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
525k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
525k
    if (_closed) {
644
262k
        return Status::OK();
645
262k
    }
646
262k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
262k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
262k
    }
649
262k
    _closed = true;
650
262k
    return Status::OK();
651
525k
}
_ZN5doris19PipelineXLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
24
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
24
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
24
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
24
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
24
    }
649
24
    _closed = true;
650
24
    return Status::OK();
651
24
}
_ZN5doris19PipelineXLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
12.5k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
12.5k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
12.5k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
12.5k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
12.5k
    }
649
12.5k
    _closed = true;
650
12.5k
    return Status::OK();
651
12.5k
}
_ZN5doris19PipelineXLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
13.5k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
13.5k
    if (_closed) {
644
6.84k
        return Status::OK();
645
6.84k
    }
646
6.67k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
6.67k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
6.67k
    }
649
6.67k
    _closed = true;
650
6.67k
    return Status::OK();
651
13.5k
}
_ZN5doris19PipelineXLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
167k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
167k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
167k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
167k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
167k
    }
649
167k
    _closed = true;
650
167k
    return Status::OK();
651
167k
}
_ZN5doris19PipelineXLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
690
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
690
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
690
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
690
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
690
    }
649
690
    _closed = true;
650
690
    return Status::OK();
651
690
}
_ZN5doris19PipelineXLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
143
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
143
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
143
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
143
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
143
    }
649
143
    _closed = true;
650
143
    return Status::OK();
651
143
}
_ZN5doris19PipelineXLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
1.29M
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
1.29M
    if (_closed) {
644
17.3k
        return Status::OK();
645
17.3k
    }
646
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
    }
649
1.27M
    _closed = true;
650
1.27M
    return Status::OK();
651
1.29M
}
_ZN5doris19PipelineXLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
57.2k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
57.2k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
57.2k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
57.2k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
57.2k
    }
649
57.2k
    _closed = true;
650
57.2k
    return Status::OK();
651
57.2k
}
_ZN5doris19PipelineXLocalStateINS_20DataQueueSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
28
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
28
    if (_closed) {
644
14
        return Status::OK();
645
14
    }
646
14
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
14
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
14
    }
649
14
    _closed = true;
650
14
    return Status::OK();
651
28
}
_ZN5doris19PipelineXLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
12.9k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
12.9k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
12.9k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
12.9k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
12.9k
    }
649
12.9k
    _closed = true;
650
12.9k
    return Status::OK();
651
12.9k
}
_ZN5doris19PipelineXLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
520
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
520
    if (_closed) {
644
261
        return Status::OK();
645
261
    }
646
259
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
259
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
259
    }
649
259
    _closed = true;
650
259
    return Status::OK();
651
520
}
_ZN5doris19PipelineXLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
10.8k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
10.8k
    if (_closed) {
644
5.59k
        return Status::OK();
645
5.59k
    }
646
5.27k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
5.27k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
5.27k
    }
649
5.27k
    _closed = true;
650
5.27k
    return Status::OK();
651
10.8k
}
_ZN5doris19PipelineXLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
834k
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
834k
    if (_closed) {
644
0
        return Status::OK();
645
0
    }
646
834k
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
834k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
834k
    }
649
834k
    _closed = true;
650
834k
    return Status::OK();
651
834k
}
Unexecuted instantiation: _ZN5doris19PipelineXLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateE
_ZN5doris19PipelineXLocalStateINS_17RecCTESharedStateEE5closeEPNS_12RuntimeStateE
Line
Count
Source
642
334
Status PipelineXLocalState<SharedStateArg>::close(RuntimeState* state) {
643
334
    if (_closed) {
644
179
        return Status::OK();
645
179
    }
646
155
    if constexpr (!std::is_same_v<SharedStateArg, FakeSharedState>) {
647
155
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
648
155
    }
649
155
    _closed = true;
650
155
    return Status::OK();
651
334
}
652
653
template <typename SharedState>
654
2.19M
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
2.19M
    _operator_profile =
657
2.19M
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
2.19M
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
2.19M
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
2.19M
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
2.19M
    _operator_profile->add_child(_common_profile, true);
666
2.19M
    _operator_profile->add_child(_custom_profile, true);
667
668
2.19M
    _operator_profile->set_metadata(_parent->node_id());
669
2.19M
    _wait_for_finish_dependency_timer =
670
2.19M
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
2.19M
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
2.19M
    if constexpr (!is_fake_shared) {
673
1.45M
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
1.45M
            info.shared_state_map.end()) {
675
344k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
320k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
320k
            }
678
344k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
344k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
344k
                                                  ? 0
681
344k
                                                  : info.task_idx]
682
344k
                                  .get();
683
344k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
1.10M
        } else {
685
18.4E
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
18.4E
                DCHECK(false);
687
18.4E
            }
688
1.10M
            _shared_state = info.shared_state->template cast<SharedState>();
689
1.10M
            _dependency = _shared_state->create_sink_dependency(
690
1.10M
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
1.10M
        }
692
1.45M
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
1.45M
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
1.45M
    }
695
696
2.19M
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
2.19M
    _rows_input_counter =
701
2.19M
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
2.19M
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
2.19M
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
2.19M
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
2.19M
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
2.19M
    _memory_used_counter =
707
2.19M
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
2.19M
    _common_profile->add_info_string("IsColocate",
709
2.19M
                                     std::to_string(_parent->is_colocated_operator()));
710
2.19M
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
2.19M
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
2.19M
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
2.19M
    return Status::OK();
714
2.19M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
124k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
124k
    _operator_profile =
657
124k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
124k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
124k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
124k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
124k
    _operator_profile->add_child(_common_profile, true);
666
124k
    _operator_profile->add_child(_custom_profile, true);
667
668
124k
    _operator_profile->set_metadata(_parent->node_id());
669
124k
    _wait_for_finish_dependency_timer =
670
124k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
124k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
124k
    if constexpr (!is_fake_shared) {
673
124k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
124k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
23.5k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
23.5k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
23.5k
                                                  ? 0
681
23.5k
                                                  : info.task_idx]
682
23.5k
                                  .get();
683
23.5k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
101k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
101k
            _shared_state = info.shared_state->template cast<SharedState>();
689
101k
            _dependency = _shared_state->create_sink_dependency(
690
101k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
101k
        }
692
124k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
124k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
124k
    }
695
696
124k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
124k
    _rows_input_counter =
701
124k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
124k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
124k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
124k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
124k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
124k
    _memory_used_counter =
707
124k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
124k
    _common_profile->add_info_string("IsColocate",
709
124k
                                     std::to_string(_parent->is_colocated_operator()));
710
124k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
124k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
124k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
124k
    return Status::OK();
714
124k
}
_ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
2
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
2
    _operator_profile =
657
2
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
2
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
2
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
2
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
2
    _operator_profile->add_child(_common_profile, true);
666
2
    _operator_profile->add_child(_custom_profile, true);
667
668
2
    _operator_profile->set_metadata(_parent->node_id());
669
2
    _wait_for_finish_dependency_timer =
670
2
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
2
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
2
    if constexpr (!is_fake_shared) {
673
2
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
2
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
2
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
2
            _shared_state = info.shared_state->template cast<SharedState>();
689
2
            _dependency = _shared_state->create_sink_dependency(
690
2
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
2
        }
692
2
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
2
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
2
    }
695
696
2
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
2
    _rows_input_counter =
701
2
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
2
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
2
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
2
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
2
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
2
    _memory_used_counter =
707
2
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
2
    _common_profile->add_info_string("IsColocate",
709
2
                                     std::to_string(_parent->is_colocated_operator()));
710
2
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
2
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
2
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
2
    return Status::OK();
714
2
}
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
263k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
263k
    _operator_profile =
657
263k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
263k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
263k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
263k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
263k
    _operator_profile->add_child(_common_profile, true);
666
263k
    _operator_profile->add_child(_custom_profile, true);
667
668
263k
    _operator_profile->set_metadata(_parent->node_id());
669
263k
    _wait_for_finish_dependency_timer =
670
263k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
263k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
263k
    if constexpr (!is_fake_shared) {
673
263k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
263k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
263k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
263k
            _shared_state = info.shared_state->template cast<SharedState>();
689
263k
            _dependency = _shared_state->create_sink_dependency(
690
263k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
263k
        }
692
263k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
263k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
263k
    }
695
696
263k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
263k
    _rows_input_counter =
701
263k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
263k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
263k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
263k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
263k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
263k
    _memory_used_counter =
707
263k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
263k
    _common_profile->add_info_string("IsColocate",
709
263k
                                     std::to_string(_parent->is_colocated_operator()));
710
263k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
263k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
263k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
263k
    return Status::OK();
714
263k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
31
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
31
    _operator_profile =
657
31
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
31
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
31
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
31
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
31
    _operator_profile->add_child(_common_profile, true);
666
31
    _operator_profile->add_child(_custom_profile, true);
667
668
31
    _operator_profile->set_metadata(_parent->node_id());
669
31
    _wait_for_finish_dependency_timer =
670
31
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
31
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
31
    if constexpr (!is_fake_shared) {
673
31
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
31
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
31
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
31
            _shared_state = info.shared_state->template cast<SharedState>();
689
31
            _dependency = _shared_state->create_sink_dependency(
690
31
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
31
        }
692
31
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
31
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
31
    }
695
696
31
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
31
    _rows_input_counter =
701
31
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
31
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
31
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
31
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
31
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
31
    _memory_used_counter =
707
31
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
31
    _common_profile->add_info_string("IsColocate",
709
31
                                     std::to_string(_parent->is_colocated_operator()));
710
31
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
31
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
31
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
31
    return Status::OK();
714
31
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
12.5k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
12.5k
    _operator_profile =
657
12.5k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
12.5k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
12.5k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
12.5k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
12.5k
    _operator_profile->add_child(_common_profile, true);
666
12.5k
    _operator_profile->add_child(_custom_profile, true);
667
668
12.5k
    _operator_profile->set_metadata(_parent->node_id());
669
12.5k
    _wait_for_finish_dependency_timer =
670
12.5k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
12.5k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
12.5k
    if constexpr (!is_fake_shared) {
673
12.5k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
12.5k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
12.5k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
12.5k
            _shared_state = info.shared_state->template cast<SharedState>();
689
12.5k
            _dependency = _shared_state->create_sink_dependency(
690
12.5k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
12.5k
        }
692
12.5k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
12.5k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
12.5k
    }
695
696
12.5k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
12.5k
    _rows_input_counter =
701
12.5k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
12.5k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
12.5k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
12.5k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
12.5k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
12.5k
    _memory_used_counter =
707
12.5k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
12.5k
    _common_profile->add_info_string("IsColocate",
709
12.5k
                                     std::to_string(_parent->is_colocated_operator()));
710
12.5k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
12.5k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
12.5k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
12.5k
    return Status::OK();
714
12.5k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
6.67k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
6.67k
    _operator_profile =
657
6.67k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
6.67k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
6.67k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
6.67k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
6.67k
    _operator_profile->add_child(_common_profile, true);
666
6.67k
    _operator_profile->add_child(_custom_profile, true);
667
668
6.67k
    _operator_profile->set_metadata(_parent->node_id());
669
6.67k
    _wait_for_finish_dependency_timer =
670
6.67k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
6.67k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
6.67k
    if constexpr (!is_fake_shared) {
673
6.67k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
6.67k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
6.67k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
6.67k
            _shared_state = info.shared_state->template cast<SharedState>();
689
6.67k
            _dependency = _shared_state->create_sink_dependency(
690
6.67k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
6.67k
        }
692
6.67k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
6.67k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
6.67k
    }
695
696
6.67k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
6.67k
    _rows_input_counter =
701
6.67k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
6.67k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
6.67k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
6.67k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
6.67k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
6.67k
    _memory_used_counter =
707
6.67k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
6.67k
    _common_profile->add_info_string("IsColocate",
709
6.67k
                                     std::to_string(_parent->is_colocated_operator()));
710
6.67k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
6.67k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
6.67k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
6.67k
    return Status::OK();
714
6.67k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
167k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
167k
    _operator_profile =
657
167k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
167k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
167k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
167k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
167k
    _operator_profile->add_child(_common_profile, true);
666
167k
    _operator_profile->add_child(_custom_profile, true);
667
668
167k
    _operator_profile->set_metadata(_parent->node_id());
669
167k
    _wait_for_finish_dependency_timer =
670
167k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
167k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
167k
    if constexpr (!is_fake_shared) {
673
167k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
167k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
167k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
167k
            _shared_state = info.shared_state->template cast<SharedState>();
689
167k
            _dependency = _shared_state->create_sink_dependency(
690
167k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
167k
        }
692
167k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
167k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
167k
    }
695
696
167k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
167k
    _rows_input_counter =
701
167k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
167k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
167k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
167k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
167k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
167k
    _memory_used_counter =
707
167k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
167k
    _common_profile->add_info_string("IsColocate",
709
167k
                                     std::to_string(_parent->is_colocated_operator()));
710
167k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
167k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
167k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
167k
    return Status::OK();
714
167k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
686
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
686
    _operator_profile =
657
686
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
686
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
686
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
686
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
686
    _operator_profile->add_child(_common_profile, true);
666
686
    _operator_profile->add_child(_custom_profile, true);
667
668
686
    _operator_profile->set_metadata(_parent->node_id());
669
686
    _wait_for_finish_dependency_timer =
670
686
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
686
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
686
    if constexpr (!is_fake_shared) {
673
686
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
686
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
682
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
682
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
682
                                                  ? 0
681
682
                                                  : info.task_idx]
682
682
                                  .get();
683
682
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
682
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
4
            _shared_state = info.shared_state->template cast<SharedState>();
689
4
            _dependency = _shared_state->create_sink_dependency(
690
4
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
4
        }
692
686
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
686
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
686
    }
695
696
686
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
686
    _rows_input_counter =
701
686
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
686
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
686
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
686
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
686
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
686
    _memory_used_counter =
707
686
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
686
    _common_profile->add_info_string("IsColocate",
709
686
                                     std::to_string(_parent->is_colocated_operator()));
710
686
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
686
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
686
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
686
    return Status::OK();
714
686
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
154
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
154
    _operator_profile =
657
154
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
154
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
154
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
154
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
154
    _operator_profile->add_child(_common_profile, true);
666
154
    _operator_profile->add_child(_custom_profile, true);
667
668
154
    _operator_profile->set_metadata(_parent->node_id());
669
154
    _wait_for_finish_dependency_timer =
670
154
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
154
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
154
    if constexpr (!is_fake_shared) {
673
154
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
154
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
154
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
154
            _shared_state = info.shared_state->template cast<SharedState>();
689
154
            _dependency = _shared_state->create_sink_dependency(
690
154
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
154
        }
692
154
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
154
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
154
    }
695
696
154
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
154
    _rows_input_counter =
701
154
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
154
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
154
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
154
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
154
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
154
    _memory_used_counter =
707
154
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
154
    _common_profile->add_info_string("IsColocate",
709
154
                                     std::to_string(_parent->is_colocated_operator()));
710
154
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
154
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
154
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
154
    return Status::OK();
714
154
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
741k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
741k
    _operator_profile =
657
741k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
741k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
741k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
741k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
741k
    _operator_profile->add_child(_common_profile, true);
666
741k
    _operator_profile->add_child(_custom_profile, true);
667
668
741k
    _operator_profile->set_metadata(_parent->node_id());
669
741k
    _wait_for_finish_dependency_timer =
670
741k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
741k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
    if constexpr (!is_fake_shared) {
673
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
                                                  ? 0
681
                                                  : info.task_idx]
682
                                  .get();
683
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
            _shared_state = info.shared_state->template cast<SharedState>();
689
            _dependency = _shared_state->create_sink_dependency(
690
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
        }
692
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
    }
695
696
741k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
741k
    _rows_input_counter =
701
741k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
741k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
741k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
741k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
741k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
741k
    _memory_used_counter =
707
741k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
741k
    _common_profile->add_info_string("IsColocate",
709
741k
                                     std::to_string(_parent->is_colocated_operator()));
710
741k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
741k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
741k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
741k
    return Status::OK();
714
741k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
7.66k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
7.66k
    _operator_profile =
657
7.66k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
7.66k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
7.66k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
7.66k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
7.66k
    _operator_profile->add_child(_common_profile, true);
666
7.66k
    _operator_profile->add_child(_custom_profile, true);
667
668
7.66k
    _operator_profile->set_metadata(_parent->node_id());
669
7.66k
    _wait_for_finish_dependency_timer =
670
7.66k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
7.66k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
7.66k
    if constexpr (!is_fake_shared) {
673
7.66k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
7.66k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
7.66k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
7.66k
            _shared_state = info.shared_state->template cast<SharedState>();
689
7.66k
            _dependency = _shared_state->create_sink_dependency(
690
7.66k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
7.66k
        }
692
7.66k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
7.66k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
7.66k
    }
695
696
7.66k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
7.66k
    _rows_input_counter =
701
7.66k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
7.66k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
7.66k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
7.66k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
7.66k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
7.66k
    _memory_used_counter =
707
7.66k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
7.66k
    _common_profile->add_info_string("IsColocate",
709
7.66k
                                     std::to_string(_parent->is_colocated_operator()));
710
7.66k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
7.66k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
7.66k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
7.66k
    return Status::OK();
714
7.66k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
362
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
362
    _operator_profile =
657
362
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
362
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
362
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
362
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
362
    _operator_profile->add_child(_common_profile, true);
666
362
    _operator_profile->add_child(_custom_profile, true);
667
668
362
    _operator_profile->set_metadata(_parent->node_id());
669
362
    _wait_for_finish_dependency_timer =
670
362
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
362
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
362
    if constexpr (!is_fake_shared) {
673
362
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
362
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
362
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
362
            _shared_state = info.shared_state->template cast<SharedState>();
689
362
            _dependency = _shared_state->create_sink_dependency(
690
362
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
362
        }
692
362
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
362
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
362
    }
695
696
362
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
362
    _rows_input_counter =
701
362
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
362
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
362
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
362
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
362
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
362
    _memory_used_counter =
707
362
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
362
    _common_profile->add_info_string("IsColocate",
709
362
                                     std::to_string(_parent->is_colocated_operator()));
710
362
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
362
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
362
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
362
    return Status::OK();
714
362
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
4.76k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
4.76k
    _operator_profile =
657
4.76k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
4.76k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
4.76k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
4.76k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
4.76k
    _operator_profile->add_child(_common_profile, true);
666
4.76k
    _operator_profile->add_child(_custom_profile, true);
667
668
4.76k
    _operator_profile->set_metadata(_parent->node_id());
669
4.76k
    _wait_for_finish_dependency_timer =
670
4.76k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
4.76k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
4.76k
    if constexpr (!is_fake_shared) {
673
4.76k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
4.76k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
4.76k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
4.76k
            _shared_state = info.shared_state->template cast<SharedState>();
689
4.76k
            _dependency = _shared_state->create_sink_dependency(
690
4.76k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
4.76k
        }
692
4.76k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
4.76k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
4.76k
    }
695
696
4.76k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
4.76k
    _rows_input_counter =
701
4.76k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
4.76k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
4.76k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
4.76k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
4.76k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
4.76k
    _memory_used_counter =
707
4.76k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
4.76k
    _common_profile->add_info_string("IsColocate",
709
4.76k
                                     std::to_string(_parent->is_colocated_operator()));
710
4.76k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
4.76k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
4.76k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
4.76k
    return Status::OK();
714
4.76k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
12.6k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
12.6k
    _operator_profile =
657
12.6k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
12.6k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
12.6k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
12.6k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
12.6k
    _operator_profile->add_child(_common_profile, true);
666
12.6k
    _operator_profile->add_child(_custom_profile, true);
667
668
12.6k
    _operator_profile->set_metadata(_parent->node_id());
669
12.6k
    _wait_for_finish_dependency_timer =
670
12.6k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
12.6k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
12.6k
    if constexpr (!is_fake_shared) {
673
12.6k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
12.6k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
12.6k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
12.6k
            _shared_state = info.shared_state->template cast<SharedState>();
689
12.6k
            _dependency = _shared_state->create_sink_dependency(
690
12.6k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
12.6k
        }
692
12.6k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
12.6k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
12.6k
    }
695
696
12.6k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
12.6k
    _rows_input_counter =
701
12.6k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
12.6k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
12.6k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
12.6k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
12.6k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
12.6k
    _memory_used_counter =
707
12.6k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
12.6k
    _common_profile->add_info_string("IsColocate",
709
12.6k
                                     std::to_string(_parent->is_colocated_operator()));
710
12.6k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
12.6k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
12.6k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
12.6k
    return Status::OK();
714
12.6k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
319k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
319k
    _operator_profile =
657
319k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
319k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
319k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
319k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
319k
    _operator_profile->add_child(_common_profile, true);
666
319k
    _operator_profile->add_child(_custom_profile, true);
667
668
319k
    _operator_profile->set_metadata(_parent->node_id());
669
319k
    _wait_for_finish_dependency_timer =
670
319k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
319k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
319k
    if constexpr (!is_fake_shared) {
673
319k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
320k
            info.shared_state_map.end()) {
675
320k
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
320k
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
320k
            }
678
320k
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
320k
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
320k
                                                  ? 0
681
320k
                                                  : info.task_idx]
682
320k
                                  .get();
683
320k
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
18.4E
        } else {
685
18.4E
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
18.4E
                DCHECK(false);
687
18.4E
            }
688
18.4E
            _shared_state = info.shared_state->template cast<SharedState>();
689
18.4E
            _dependency = _shared_state->create_sink_dependency(
690
18.4E
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
18.4E
        }
692
319k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
319k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
319k
    }
695
696
319k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
319k
    _rows_input_counter =
701
319k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
319k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
319k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
319k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
319k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
319k
    _memory_used_counter =
707
319k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
319k
    _common_profile->add_info_string("IsColocate",
709
319k
                                     std::to_string(_parent->is_colocated_operator()));
710
319k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
319k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
319k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
319k
    return Status::OK();
714
319k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
533k
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
533k
    _operator_profile =
657
533k
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
533k
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
533k
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
533k
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
533k
    _operator_profile->add_child(_common_profile, true);
666
533k
    _operator_profile->add_child(_custom_profile, true);
667
668
533k
    _operator_profile->set_metadata(_parent->node_id());
669
533k
    _wait_for_finish_dependency_timer =
670
533k
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
533k
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
533k
    if constexpr (!is_fake_shared) {
673
533k
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
533k
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
533k
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
533k
            _shared_state = info.shared_state->template cast<SharedState>();
689
533k
            _dependency = _shared_state->create_sink_dependency(
690
533k
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
533k
        }
692
533k
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
533k
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
533k
    }
695
696
533k
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
533k
    _rows_input_counter =
701
533k
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
533k
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
533k
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
533k
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
533k
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
533k
    _memory_used_counter =
707
533k
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
533k
    _common_profile->add_info_string("IsColocate",
709
533k
                                     std::to_string(_parent->is_colocated_operator()));
710
533k
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
533k
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
533k
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
533k
    return Status::OK();
714
533k
}
_ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
25
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
25
    _operator_profile =
657
25
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
25
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
25
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
25
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
25
    _operator_profile->add_child(_common_profile, true);
666
25
    _operator_profile->add_child(_custom_profile, true);
667
668
25
    _operator_profile->set_metadata(_parent->node_id());
669
25
    _wait_for_finish_dependency_timer =
670
25
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
25
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
25
    if constexpr (!is_fake_shared) {
673
25
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
25
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
25
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
25
            _shared_state = info.shared_state->template cast<SharedState>();
689
25
            _dependency = _shared_state->create_sink_dependency(
690
25
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
25
        }
692
25
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
25
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
25
    }
695
696
25
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
25
    _rows_input_counter =
701
25
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
25
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
25
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
25
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
25
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
25
    _memory_used_counter =
707
25
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
25
    _common_profile->add_info_string("IsColocate",
709
25
                                     std::to_string(_parent->is_colocated_operator()));
710
25
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
25
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
25
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
25
    return Status::OK();
714
25
}
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
654
327
Status PipelineXSinkLocalState<SharedState>::init(RuntimeState* state, LocalSinkStateInfo& info) {
655
    // create profile
656
327
    _operator_profile =
657
327
            state->obj_pool()->add(new RuntimeProfile(_parent->get_name() + name_suffix()));
658
327
    _common_profile = state->obj_pool()->add(new RuntimeProfile(profile::COMMON_COUNTERS));
659
327
    _custom_profile = state->obj_pool()->add(new RuntimeProfile(profile::CUSTOM_COUNTERS));
660
661
    // indentation is true
662
    // The parent profile of sink operator is usually a RuntimeProfile called PipelineTask.
663
    // So we should set the indentation to true.
664
327
    info.parent_profile->add_child(_operator_profile, /*indent=*/true);
665
327
    _operator_profile->add_child(_common_profile, true);
666
327
    _operator_profile->add_child(_custom_profile, true);
667
668
327
    _operator_profile->set_metadata(_parent->node_id());
669
327
    _wait_for_finish_dependency_timer =
670
327
            ADD_TIMER(_common_profile, profile::PENDING_FINISH_DEPENDENCY);
671
327
    constexpr auto is_fake_shared = std::is_same_v<SharedState, FakeSharedState>;
672
327
    if constexpr (!is_fake_shared) {
673
327
        if (info.shared_state_map.find(_parent->dests_id().front()) !=
674
327
            info.shared_state_map.end()) {
675
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
676
                DCHECK(info.shared_state_map.at(_parent->dests_id().front()).second.size() == 1);
677
            }
678
0
            _dependency = info.shared_state_map.at(_parent->dests_id().front())
679
0
                                  .second[std::is_same_v<LocalExchangeSharedState, SharedState>
680
0
                                                  ? 0
681
0
                                                  : info.task_idx]
682
0
                                  .get();
683
0
            _shared_state = _dependency->shared_state()->template cast<SharedState>();
684
327
        } else {
685
            if constexpr (std::is_same_v<LocalExchangeSharedState, SharedState>) {
686
                DCHECK(false);
687
            }
688
327
            _shared_state = info.shared_state->template cast<SharedState>();
689
327
            _dependency = _shared_state->create_sink_dependency(
690
327
                    _parent->dests_id().front(), _parent->node_id(), _parent->get_name());
691
327
        }
692
327
        _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
693
327
                _common_profile, "WaitForDependency[" + _dependency->name() + "]Time", 1);
694
327
    }
695
696
328
    if (must_set_shared_state() && _shared_state == nullptr) {
697
0
        return Status::InternalError("must set shared state, in {}", _parent->get_name());
698
0
    }
699
700
327
    _rows_input_counter =
701
327
            ADD_COUNTER_WITH_LEVEL(_common_profile, profile::INPUT_ROWS, TUnit::UNIT, 1);
702
327
    _init_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::INIT_TIME, 2);
703
327
    _open_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::OPEN_TIME, 2);
704
327
    _close_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::CLOSE_TIME, 2);
705
327
    _exec_timer = ADD_TIMER_WITH_LEVEL(_common_profile, profile::EXEC_TIME, 1);
706
327
    _memory_used_counter =
707
327
            _common_profile->AddHighWaterMarkCounter(profile::MEMORY_USAGE, TUnit::BYTES, "", 1);
708
327
    _common_profile->add_info_string("IsColocate",
709
327
                                     std::to_string(_parent->is_colocated_operator()));
710
327
    _common_profile->add_info_string("IsShuffled", std::to_string(_parent->is_shuffled_operator()));
711
327
    _common_profile->add_info_string("FollowedByShuffledOperator",
712
327
                                     std::to_string(_parent->followed_by_shuffled_operator()));
713
327
    return Status::OK();
714
327
}
715
716
template <typename SharedState>
717
2.20M
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
2.20M
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
2.20M
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
1.45M
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
1.45M
    }
724
2.20M
    _closed = true;
725
2.20M
    return Status::OK();
726
2.20M
}
_ZN5doris23PipelineXSinkLocalStateINS_19HashJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
124k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
124k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
124k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
124k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
124k
    }
724
124k
    _closed = true;
725
124k
    return Status::OK();
726
124k
}
_ZN5doris23PipelineXSinkLocalStateINS_30PartitionedHashJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
1
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
1
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
1
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
1
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
1
    }
724
1
    _closed = true;
725
1
    return Status::OK();
726
1
}
_ZN5doris23PipelineXSinkLocalStateINS_15SortSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
263k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
263k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
263k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
263k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
263k
    }
724
263k
    _closed = true;
725
263k
    return Status::OK();
726
263k
}
_ZN5doris23PipelineXSinkLocalStateINS_20SpillSortSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
22
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
22
    if (_closed) {
719
2
        return Status::OK();
720
2
    }
721
20
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
20
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
20
    }
724
20
    _closed = true;
725
20
    return Status::OK();
726
22
}
_ZN5doris23PipelineXSinkLocalStateINS_25NestedLoopJoinSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
12.5k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
12.5k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
12.5k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
12.5k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
12.5k
    }
724
12.5k
    _closed = true;
725
12.5k
    return Status::OK();
726
12.5k
}
_ZN5doris23PipelineXSinkLocalStateINS_19AnalyticSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
6.66k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
6.66k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
6.66k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
6.66k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
6.66k
    }
724
6.66k
    _closed = true;
725
6.66k
    return Status::OK();
726
6.66k
}
_ZN5doris23PipelineXSinkLocalStateINS_14AggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
167k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
167k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
167k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
167k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
167k
    }
724
167k
    _closed = true;
725
167k
    return Status::OK();
726
167k
}
_ZN5doris23PipelineXSinkLocalStateINS_22BucketedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
686
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
686
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
686
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
686
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
686
    }
724
686
    _closed = true;
725
686
    return Status::OK();
726
686
}
_ZN5doris23PipelineXSinkLocalStateINS_25PartitionedAggSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
143
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
143
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
143
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
143
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
143
    }
724
143
    _closed = true;
725
143
    return Status::OK();
726
143
}
_ZN5doris23PipelineXSinkLocalStateINS_15FakeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
742k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
742k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
    }
724
742k
    _closed = true;
725
742k
    return Status::OK();
726
742k
}
_ZN5doris23PipelineXSinkLocalStateINS_16UnionSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
7.71k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
7.71k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
7.71k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
7.71k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
7.71k
    }
724
7.71k
    _closed = true;
725
7.71k
    return Status::OK();
726
7.71k
}
_ZN5doris23PipelineXSinkLocalStateINS_28PartitionSortNodeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
260
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
260
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
260
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
260
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
260
    }
724
260
    _closed = true;
725
260
    return Status::OK();
726
260
}
_ZN5doris23PipelineXSinkLocalStateINS_20MultiCastSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
4.84k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
4.84k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
4.84k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
4.84k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
4.84k
    }
724
4.84k
    _closed = true;
725
4.84k
    return Status::OK();
726
4.84k
}
_ZN5doris23PipelineXSinkLocalStateINS_14SetSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
12.7k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
12.7k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
12.7k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
12.7k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
12.7k
    }
724
12.7k
    _closed = true;
725
12.7k
    return Status::OK();
726
12.7k
}
_ZN5doris23PipelineXSinkLocalStateINS_24LocalExchangeSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
321k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
321k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
321k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
321k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
321k
    }
724
321k
    _closed = true;
725
321k
    return Status::OK();
726
321k
}
_ZN5doris23PipelineXSinkLocalStateINS_16BasicSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
535k
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
535k
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
535k
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
535k
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
535k
    }
724
535k
    _closed = true;
725
535k
    return Status::OK();
726
535k
}
_ZN5doris23PipelineXSinkLocalStateINS_20DataQueueSharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
14
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
14
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
14
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
14
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
14
    }
724
14
    _closed = true;
725
14
    return Status::OK();
726
14
}
_ZN5doris23PipelineXSinkLocalStateINS_17RecCTESharedStateEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
717
328
Status PipelineXSinkLocalState<SharedState>::close(RuntimeState* state, Status exec_status) {
718
328
    if (_closed) {
719
0
        return Status::OK();
720
0
    }
721
328
    if constexpr (!std::is_same_v<SharedState, FakeSharedState>) {
722
328
        COUNTER_SET(_wait_for_dependency_timer, _dependency->watcher_elapse_time());
723
328
    }
724
328
    _closed = true;
725
328
    return Status::OK();
726
328
}
727
728
template <typename LocalStateType>
729
Status StreamingOperatorX<LocalStateType>::get_block_impl(RuntimeState* state, Block* block,
730
16.0k
                                                          bool* eos) {
731
16.0k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
16.0k
    return pull(state, block, eos);
733
16.0k
}
_ZN5doris18StreamingOperatorXINS_23AssertNumRowsLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
730
432
                                                          bool* eos) {
731
432
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
432
    return pull(state, block, eos);
733
432
}
_ZN5doris18StreamingOperatorXINS_16SelectLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
730
15.6k
                                                          bool* eos) {
731
15.6k
    RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(state, block, eos));
732
15.5k
    return pull(state, block, eos);
733
15.6k
}
734
735
template <typename LocalStateType>
736
Status StatefulOperatorX<LocalStateType>::get_block_impl(RuntimeState* state, Block* block,
737
764k
                                                         bool* eos) {
738
764k
    auto& local_state = get_local_state(state);
739
764k
    if (need_more_input_data(state)) {
740
734k
        local_state._child_block->clear_column_data(
741
734k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
734k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
734k
                state, local_state._child_block.get(), &local_state._child_eos));
744
734k
        *eos = local_state._child_eos;
745
734k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
68.7k
            return Status::OK();
747
68.7k
        }
748
666k
        {
749
666k
            SCOPED_TIMER(local_state.exec_time_counter());
750
666k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
666k
        }
752
666k
    }
753
754
695k
    if (!need_more_input_data(state)) {
755
641k
        SCOPED_TIMER(local_state.exec_time_counter());
756
641k
        bool new_eos = false;
757
641k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
641k
        if (new_eos) {
759
553k
            *eos = true;
760
553k
        } else if (!need_more_input_data(state)) {
761
23.1k
            *eos = false;
762
23.1k
        }
763
641k
    }
764
695k
    return Status::OK();
765
695k
}
_ZN5doris17StatefulOperatorXINS_23HashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
159k
                                                         bool* eos) {
738
159k
    auto& local_state = get_local_state(state);
739
159k
    if (need_more_input_data(state)) {
740
142k
        local_state._child_block->clear_column_data(
741
142k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
142k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
142k
                state, local_state._child_block.get(), &local_state._child_eos));
744
142k
        *eos = local_state._child_eos;
745
142k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
44.6k
            return Status::OK();
747
44.6k
        }
748
98.1k
        {
749
98.1k
            SCOPED_TIMER(local_state.exec_time_counter());
750
98.1k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
98.1k
        }
752
98.1k
    }
753
754
114k
    if (!need_more_input_data(state)) {
755
114k
        SCOPED_TIMER(local_state.exec_time_counter());
756
114k
        bool new_eos = false;
757
114k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
114k
        if (new_eos) {
759
52.6k
            *eos = true;
760
62.3k
        } else if (!need_more_input_data(state)) {
761
8.89k
            *eos = false;
762
8.89k
        }
763
114k
    }
764
114k
    return Status::OK();
765
114k
}
Unexecuted instantiation: _ZN5doris17StatefulOperatorXINS_34PartitionedHashJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
_ZN5doris17StatefulOperatorXINS_16RepeatLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
3.80k
                                                         bool* eos) {
738
3.80k
    auto& local_state = get_local_state(state);
739
3.80k
    if (need_more_input_data(state)) {
740
2.04k
        local_state._child_block->clear_column_data(
741
2.04k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
2.04k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
2.04k
                state, local_state._child_block.get(), &local_state._child_eos));
744
2.04k
        *eos = local_state._child_eos;
745
2.04k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
360
            return Status::OK();
747
360
        }
748
1.68k
        {
749
1.68k
            SCOPED_TIMER(local_state.exec_time_counter());
750
1.68k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
1.68k
        }
752
1.68k
    }
753
754
3.45k
    if (!need_more_input_data(state)) {
755
3.45k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.45k
        bool new_eos = false;
757
3.45k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.45k
        if (new_eos) {
759
1.07k
            *eos = true;
760
2.38k
        } else if (!need_more_input_data(state)) {
761
1.76k
            *eos = false;
762
1.76k
        }
763
3.45k
    }
764
3.44k
    return Status::OK();
765
3.44k
}
_ZN5doris17StatefulOperatorXINS_25MaterializationLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
4.93k
                                                         bool* eos) {
738
4.93k
    auto& local_state = get_local_state(state);
739
4.93k
    if (need_more_input_data(state)) {
740
4.93k
        local_state._child_block->clear_column_data(
741
4.93k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
4.93k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
4.93k
                state, local_state._child_block.get(), &local_state._child_eos));
744
4.93k
        *eos = local_state._child_eos;
745
4.93k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
1.71k
            return Status::OK();
747
1.71k
        }
748
3.22k
        {
749
3.22k
            SCOPED_TIMER(local_state.exec_time_counter());
750
3.22k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
3.22k
        }
752
3.22k
    }
753
754
3.22k
    if (!need_more_input_data(state)) {
755
3.22k
        SCOPED_TIMER(local_state.exec_time_counter());
756
3.22k
        bool new_eos = false;
757
3.22k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
3.22k
        if (new_eos) {
759
1.73k
            *eos = true;
760
1.73k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
3.22k
    }
764
3.22k
    return Status::OK();
765
3.22k
}
_ZN5doris17StatefulOperatorXINS_22StreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
36.9k
                                                         bool* eos) {
738
36.9k
    auto& local_state = get_local_state(state);
739
37.0k
    if (need_more_input_data(state)) {
740
37.0k
        local_state._child_block->clear_column_data(
741
37.0k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
37.0k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
37.0k
                state, local_state._child_block.get(), &local_state._child_eos));
744
37.0k
        *eos = local_state._child_eos;
745
37.0k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
3.71k
            return Status::OK();
747
3.71k
        }
748
33.2k
        {
749
33.2k
            SCOPED_TIMER(local_state.exec_time_counter());
750
33.2k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
33.2k
        }
752
33.2k
    }
753
754
33.2k
    if (!need_more_input_data(state)) {
755
11.2k
        SCOPED_TIMER(local_state.exec_time_counter());
756
11.2k
        bool new_eos = false;
757
11.2k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
11.2k
        if (new_eos) {
759
11.0k
            *eos = true;
760
11.0k
        } else if (!need_more_input_data(state)) {
761
5
            *eos = false;
762
5
        }
763
11.2k
    }
764
33.2k
    return Status::OK();
765
33.2k
}
_ZN5doris17StatefulOperatorXINS_30DistinctStreamingAggLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
519k
                                                         bool* eos) {
738
519k
    auto& local_state = get_local_state(state);
739
521k
    if (need_more_input_data(state)) {
740
521k
        local_state._child_block->clear_column_data(
741
521k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
521k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
521k
                state, local_state._child_block.get(), &local_state._child_eos));
744
521k
        *eos = local_state._child_eos;
745
521k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
15.4k
            return Status::OK();
747
15.4k
        }
748
505k
        {
749
505k
            SCOPED_TIMER(local_state.exec_time_counter());
750
505k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
505k
        }
752
505k
    }
753
754
504k
    if (!need_more_input_data(state)) {
755
472k
        SCOPED_TIMER(local_state.exec_time_counter());
756
472k
        bool new_eos = false;
757
472k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
472k
        if (new_eos) {
759
471k
            *eos = true;
760
471k
        } else if (!need_more_input_data(state)) {
761
0
            *eos = false;
762
0
        }
763
472k
    }
764
504k
    return Status::OK();
765
504k
}
_ZN5doris17StatefulOperatorXINS_29NestedLoopJoinProbeLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
34.1k
                                                         bool* eos) {
738
34.1k
    auto& local_state = get_local_state(state);
739
34.1k
    if (need_more_input_data(state)) {
740
21.9k
        local_state._child_block->clear_column_data(
741
21.9k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
21.9k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
21.9k
                state, local_state._child_block.get(), &local_state._child_eos));
744
21.9k
        *eos = local_state._child_eos;
745
21.9k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
2.53k
            return Status::OK();
747
2.53k
        }
748
19.4k
        {
749
19.4k
            SCOPED_TIMER(local_state.exec_time_counter());
750
19.4k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
19.4k
        }
752
19.4k
    }
753
754
31.5k
    if (!need_more_input_data(state)) {
755
30.8k
        SCOPED_TIMER(local_state.exec_time_counter());
756
30.8k
        bool new_eos = false;
757
30.8k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
30.8k
        if (new_eos) {
759
12.5k
            *eos = true;
760
18.3k
        } else if (!need_more_input_data(state)) {
761
12.1k
            *eos = false;
762
12.1k
        }
763
30.8k
    }
764
31.5k
    return Status::OK();
765
31.5k
}
_ZN5doris17StatefulOperatorXINS_23TableFunctionLocalStateEE14get_block_implEPNS_12RuntimeStateEPNS_5BlockEPb
Line
Count
Source
737
5.29k
                                                         bool* eos) {
738
5.29k
    auto& local_state = get_local_state(state);
739
5.29k
    if (need_more_input_data(state)) {
740
4.92k
        local_state._child_block->clear_column_data(
741
4.92k
                OperatorX<LocalStateType>::_child->row_desc().num_materialized_slots());
742
4.92k
        RETURN_IF_ERROR(OperatorX<LocalStateType>::_child->get_block_after_projects(
743
4.92k
                state, local_state._child_block.get(), &local_state._child_eos));
744
4.92k
        *eos = local_state._child_eos;
745
4.92k
        if (local_state._child_block->rows() == 0 && !local_state._child_eos) {
746
264
            return Status::OK();
747
264
        }
748
4.66k
        {
749
4.66k
            SCOPED_TIMER(local_state.exec_time_counter());
750
4.66k
            RETURN_IF_ERROR(push(state, local_state._child_block.get(), local_state._child_eos));
751
4.66k
        }
752
4.66k
    }
753
754
5.02k
    if (!need_more_input_data(state)) {
755
5.02k
        SCOPED_TIMER(local_state.exec_time_counter());
756
5.02k
        bool new_eos = false;
757
5.02k
        RETURN_IF_ERROR(pull(state, block, &new_eos));
758
5.02k
        if (new_eos) {
759
2.93k
            *eos = true;
760
2.93k
        } else if (!need_more_input_data(state)) {
761
366
            *eos = false;
762
366
        }
763
5.02k
    }
764
5.02k
    return Status::OK();
765
5.02k
}
766
767
template <typename Writer, typename Parent>
768
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
769
68.1k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
68.1k
    RETURN_IF_ERROR(Base::init(state, info));
771
68.1k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
68.1k
                                                         "AsyncWriterDependency", true);
773
68.1k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
68.1k
                             _finish_dependency));
775
776
68.1k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
68.1k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
68.1k
    return Status::OK();
779
68.1k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
512
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
512
    RETURN_IF_ERROR(Base::init(state, info));
771
512
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
512
                                                         "AsyncWriterDependency", true);
773
512
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
512
                             _finish_dependency));
775
776
512
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
512
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
512
    return Status::OK();
779
512
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
86
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
86
    RETURN_IF_ERROR(Base::init(state, info));
771
86
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
86
                                                         "AsyncWriterDependency", true);
773
86
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
86
                             _finish_dependency));
775
776
86
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
86
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
86
    return Status::OK();
779
86
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
46.7k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
46.7k
    RETURN_IF_ERROR(Base::init(state, info));
771
46.7k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
46.7k
                                                         "AsyncWriterDependency", true);
773
46.7k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
46.7k
                             _finish_dependency));
775
776
46.7k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
46.7k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
46.7k
    return Status::OK();
779
46.7k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
9.58k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
9.58k
    RETURN_IF_ERROR(Base::init(state, info));
771
9.58k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
9.58k
                                                         "AsyncWriterDependency", true);
773
9.58k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
9.58k
                             _finish_dependency));
775
776
9.58k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
9.58k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
9.58k
    return Status::OK();
779
9.58k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
5.17k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
5.17k
    RETURN_IF_ERROR(Base::init(state, info));
771
5.17k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
5.17k
                                                         "AsyncWriterDependency", true);
773
5.17k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
5.17k
                             _finish_dependency));
775
776
5.17k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
5.17k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
5.17k
    return Status::OK();
779
5.17k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
3.70k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
3.70k
    RETURN_IF_ERROR(Base::init(state, info));
771
3.70k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
3.70k
                                                         "AsyncWriterDependency", true);
773
3.70k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
3.70k
                             _finish_dependency));
775
776
3.70k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
3.70k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
3.70k
    return Status::OK();
779
3.70k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
32
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
32
    RETURN_IF_ERROR(Base::init(state, info));
771
32
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
32
                                                         "AsyncWriterDependency", true);
773
32
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
32
                             _finish_dependency));
775
776
32
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
32
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
32
    return Status::OK();
779
32
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
656
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
656
    RETURN_IF_ERROR(Base::init(state, info));
771
656
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
656
                                                         "AsyncWriterDependency", true);
773
656
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
656
                             _finish_dependency));
775
776
656
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
656
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
656
    return Status::OK();
779
656
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
1.50k
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
1.50k
    RETURN_IF_ERROR(Base::init(state, info));
771
1.50k
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
1.50k
                                                         "AsyncWriterDependency", true);
773
1.50k
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
1.50k
                             _finish_dependency));
775
776
1.50k
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
1.50k
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
1.50k
    return Status::OK();
779
1.50k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4initEPNS_12RuntimeStateERNS_18LocalSinkStateInfoE
Line
Count
Source
769
156
Status AsyncWriterSink<Writer, Parent>::init(RuntimeState* state, LocalSinkStateInfo& info) {
770
156
    RETURN_IF_ERROR(Base::init(state, info));
771
156
    _async_writer_dependency = Dependency::create_shared(_parent->operator_id(), _parent->node_id(),
772
156
                                                         "AsyncWriterDependency", true);
773
156
    _writer.reset(new Writer(info.tsink, _output_vexpr_ctxs, _async_writer_dependency,
774
156
                             _finish_dependency));
775
776
156
    _wait_for_dependency_timer = ADD_TIMER_WITH_LEVEL(
777
156
            common_profile(), "WaitForDependency[" + _async_writer_dependency->name() + "]Time", 1);
778
156
    return Status::OK();
779
156
}
780
781
template <typename Writer, typename Parent>
782
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
783
68.6k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
68.6k
    RETURN_IF_ERROR(Base::open(state));
785
68.6k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
592k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
523k
        RETURN_IF_ERROR(
788
523k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
523k
    }
790
68.6k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
68.6k
    return Status::OK();
792
68.6k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
513
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
513
    RETURN_IF_ERROR(Base::open(state));
785
513
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
2.76k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
2.25k
        RETURN_IF_ERROR(
788
2.25k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
2.25k
    }
790
513
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
513
    return Status::OK();
792
513
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
86
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
86
    RETURN_IF_ERROR(Base::open(state));
785
86
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
402
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
316
        RETURN_IF_ERROR(
788
316
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
316
    }
790
86
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
86
    return Status::OK();
792
86
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
47.2k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
47.2k
    RETURN_IF_ERROR(Base::open(state));
785
47.2k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
337k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
290k
        RETURN_IF_ERROR(
788
290k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
290k
    }
790
47.2k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
47.2k
    return Status::OK();
792
47.2k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
9.55k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
9.55k
    RETURN_IF_ERROR(Base::open(state));
785
9.55k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
57.7k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
48.1k
        RETURN_IF_ERROR(
788
48.1k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
48.1k
    }
790
9.55k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
9.55k
    return Status::OK();
792
9.55k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
5.17k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
5.17k
    RETURN_IF_ERROR(Base::open(state));
785
5.17k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
135k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
129k
        RETURN_IF_ERROR(
788
129k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
129k
    }
790
5.17k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
5.17k
    return Status::OK();
792
5.17k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
3.70k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
3.70k
    RETURN_IF_ERROR(Base::open(state));
785
3.70k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
44.5k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
40.8k
        RETURN_IF_ERROR(
788
40.8k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
40.8k
    }
790
3.70k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
3.70k
    return Status::OK();
792
3.70k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
32
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
32
    RETURN_IF_ERROR(Base::open(state));
785
32
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
128
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
96
        RETURN_IF_ERROR(
788
96
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
96
    }
790
32
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
32
    return Status::OK();
792
32
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
656
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
656
    RETURN_IF_ERROR(Base::open(state));
785
656
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
1.96k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
1.31k
        RETURN_IF_ERROR(
788
1.31k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
1.31k
    }
790
656
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
656
    return Status::OK();
792
656
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
1.50k
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
1.50k
    RETURN_IF_ERROR(Base::open(state));
785
1.50k
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
11.8k
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
10.3k
        RETURN_IF_ERROR(
788
10.3k
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
10.3k
    }
790
1.50k
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
1.50k
    return Status::OK();
792
1.50k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4openEPNS_12RuntimeStateE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4openEPNS_12RuntimeStateE
Line
Count
Source
783
156
Status AsyncWriterSink<Writer, Parent>::open(RuntimeState* state) {
784
156
    RETURN_IF_ERROR(Base::open(state));
785
156
    _output_vexpr_ctxs.resize(_parent->cast<Parent>()._output_vexpr_ctxs.size());
786
786
    for (size_t i = 0; i < _output_vexpr_ctxs.size(); i++) {
787
630
        RETURN_IF_ERROR(
788
630
                _parent->cast<Parent>()._output_vexpr_ctxs[i]->clone(state, _output_vexpr_ctxs[i]));
789
630
    }
790
156
    RETURN_IF_ERROR(_writer->start_writer(state, operator_profile()));
791
156
    return Status::OK();
792
156
}
793
794
template <typename Writer, typename Parent>
795
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
796
93.9k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
93.9k
    return _writer->sink(block, eos);
798
93.9k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
2.28k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
2.28k
    return _writer->sink(block, eos);
798
2.28k
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
110
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
110
    return _writer->sink(block, eos);
798
110
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
63.9k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
63.9k
    return _writer->sink(block, eos);
798
63.9k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
11.0k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
11.0k
    return _writer->sink(block, eos);
798
11.0k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
7.55k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
7.55k
    return _writer->sink(block, eos);
798
7.55k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
5.93k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
5.93k
    return _writer->sink(block, eos);
798
5.93k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
40
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
40
    return _writer->sink(block, eos);
798
40
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
738
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
738
    return _writer->sink(block, eos);
798
738
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
1.88k
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
1.88k
    return _writer->sink(block, eos);
798
1.88k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE4sinkEPNS_12RuntimeStateEPNS_5BlockEb
Line
Count
Source
796
310
Status AsyncWriterSink<Writer, Parent>::sink(RuntimeState* state, Block* block, bool eos) {
797
310
    return _writer->sink(block, eos);
798
310
}
799
800
template <typename Writer, typename Parent>
801
    requires(std::is_base_of_v<AsyncResultWriter, Writer>)
802
68.7k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
68.7k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
68.7k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
68.7k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
68.7k
    if (_writer) {
810
68.7k
        Status st = _writer->get_writer_status();
811
68.7k
        if (exec_status.ok()) {
812
68.6k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
68.6k
                                                       : Status::Cancelled("force close"));
814
68.6k
        } else {
815
130
            _writer->force_close(exec_status);
816
130
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
68.7k
        RETURN_IF_ERROR(st);
821
68.7k
    }
822
68.6k
    return Base::close(state, exec_status);
823
68.7k
}
_ZN5doris15AsyncWriterSinkINS_17VFileResultWriterENS_23ResultFileSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
501
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
501
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
501
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
501
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
501
    if (_writer) {
810
501
        Status st = _writer->get_writer_status();
811
501
        if (exec_status.ok()) {
812
501
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
501
                                                       : Status::Cancelled("force close"));
814
501
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
501
        RETURN_IF_ERROR(st);
821
501
    }
822
501
    return Base::close(state, exec_status);
823
501
}
_ZN5doris15AsyncWriterSinkINS_16VJdbcTableWriterENS_22JdbcTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
86
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
86
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
86
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
86
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
86
    if (_writer) {
810
86
        Status st = _writer->get_writer_status();
811
86
        if (exec_status.ok()) {
812
86
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
86
                                                       : Status::Cancelled("force close"));
814
86
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
86
        RETURN_IF_ERROR(st);
821
86
    }
822
78
    return Base::close(state, exec_status);
823
86
}
_ZN5doris15AsyncWriterSinkINS_13VTabletWriterENS_22OlapTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
47.3k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
47.3k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
47.3k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
47.3k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
47.3k
    if (_writer) {
810
47.3k
        Status st = _writer->get_writer_status();
811
47.3k
        if (exec_status.ok()) {
812
47.3k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
47.3k
                                                       : Status::Cancelled("force close"));
814
47.3k
        } else {
815
64
            _writer->force_close(exec_status);
816
64
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
47.3k
        RETURN_IF_ERROR(st);
821
47.3k
    }
822
47.2k
    return Base::close(state, exec_status);
823
47.3k
}
_ZN5doris15AsyncWriterSinkINS_15VTabletWriterV2ENS_24OlapTableSinkV2OperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
9.56k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
9.56k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
9.56k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
9.56k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
9.58k
    if (_writer) {
810
9.58k
        Status st = _writer->get_writer_status();
811
9.58k
        if (exec_status.ok()) {
812
9.52k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
9.52k
                                                       : Status::Cancelled("force close"));
814
9.52k
        } else {
815
62
            _writer->force_close(exec_status);
816
62
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
9.58k
        RETURN_IF_ERROR(st);
821
9.58k
    }
822
9.56k
    return Base::close(state, exec_status);
823
9.56k
}
_ZN5doris15AsyncWriterSinkINS_16VHiveTableWriterENS_22HiveTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
5.17k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
5.17k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
5.17k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
5.17k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
5.17k
    if (_writer) {
810
5.17k
        Status st = _writer->get_writer_status();
811
5.17k
        if (exec_status.ok()) {
812
5.17k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
5.17k
                                                       : Status::Cancelled("force close"));
814
5.17k
        } else {
815
2
            _writer->force_close(exec_status);
816
2
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
5.17k
        RETURN_IF_ERROR(st);
821
5.17k
    }
822
5.17k
    return Base::close(state, exec_status);
823
5.17k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_25IcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
3.70k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
3.70k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
3.70k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
3.70k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
3.71k
    if (_writer) {
810
3.71k
        Status st = _writer->get_writer_status();
811
3.71k
        if (exec_status.ok()) {
812
3.71k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
3.71k
                                                       : Status::Cancelled("force close"));
814
3.71k
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
3.71k
        RETURN_IF_ERROR(st);
821
3.71k
    }
822
3.70k
    return Base::close(state, exec_status);
823
3.70k
}
_ZN5doris15AsyncWriterSinkINS_19VIcebergTableWriterENS_30SpillIcebergTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
32
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
32
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
32
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
32
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
32
    if (_writer) {
810
32
        Status st = _writer->get_writer_status();
811
32
        if (exec_status.ok()) {
812
32
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
32
                                                       : Status::Cancelled("force close"));
814
32
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
32
        RETURN_IF_ERROR(st);
821
32
    }
822
32
    return Base::close(state, exec_status);
823
32
}
_ZN5doris15AsyncWriterSinkINS_18VIcebergDeleteSinkENS_26IcebergDeleteSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
656
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
656
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
656
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
656
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
656
    if (_writer) {
810
656
        Status st = _writer->get_writer_status();
811
656
        if (exec_status.ok()) {
812
656
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
656
                                                       : Status::Cancelled("force close"));
814
656
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
656
        RETURN_IF_ERROR(st);
821
656
    }
822
656
    return Base::close(state, exec_status);
823
656
}
_ZN5doris15AsyncWriterSinkINS_17VIcebergMergeSinkENS_25IcebergMergeSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
1.50k
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
1.50k
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
1.50k
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
1.50k
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
1.50k
    if (_writer) {
810
1.50k
        Status st = _writer->get_writer_status();
811
1.50k
        if (exec_status.ok()) {
812
1.50k
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
1.50k
                                                       : Status::Cancelled("force close"));
814
1.50k
        } else {
815
2
            _writer->force_close(exec_status);
816
2
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
1.50k
        RETURN_IF_ERROR(st);
821
1.50k
    }
822
1.50k
    return Base::close(state, exec_status);
823
1.50k
}
Unexecuted instantiation: _ZN5doris15AsyncWriterSinkINS_14VMCTableWriterENS_20MCTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
_ZN5doris15AsyncWriterSinkINS_15VTVFTableWriterENS_21TVFTableSinkOperatorXEE5closeEPNS_12RuntimeStateENS_6StatusE
Line
Count
Source
802
156
Status AsyncWriterSink<Writer, Parent>::close(RuntimeState* state, Status exec_status) {
803
156
    if (_closed) {
804
0
        return Status::OK();
805
0
    }
806
156
    COUNTER_SET(_wait_for_dependency_timer, _async_writer_dependency->watcher_elapse_time());
807
156
    COUNTER_SET(_wait_for_finish_dependency_timer, _finish_dependency->watcher_elapse_time());
808
    // if the init failed, the _writer may be nullptr. so here need check
809
156
    if (_writer) {
810
156
        Status st = _writer->get_writer_status();
811
156
        if (exec_status.ok()) {
812
156
            _writer->force_close(state->is_cancelled() ? state->cancel_reason()
813
156
                                                       : Status::Cancelled("force close"));
814
156
        } else {
815
0
            _writer->force_close(exec_status);
816
0
        }
817
        // If there is an error in process_block thread, then we should get the writer
818
        // status before call force_close. For example, the thread may failed in commit
819
        // transaction.
820
156
        RETURN_IF_ERROR(st);
821
156
    }
822
156
    return Base::close(state, exec_status);
823
156
}
824
825
#define DECLARE_OPERATOR(LOCAL_STATE) template class DataSinkOperatorX<LOCAL_STATE>;
826
DECLARE_OPERATOR(HashJoinBuildSinkLocalState)
827
DECLARE_OPERATOR(ResultSinkLocalState)
828
DECLARE_OPERATOR(JdbcTableSinkLocalState)
829
DECLARE_OPERATOR(MemoryScratchSinkLocalState)
830
DECLARE_OPERATOR(ResultFileSinkLocalState)
831
DECLARE_OPERATOR(OlapTableSinkLocalState)
832
DECLARE_OPERATOR(OlapTableSinkV2LocalState)
833
DECLARE_OPERATOR(HiveTableSinkLocalState)
834
DECLARE_OPERATOR(TVFTableSinkLocalState)
835
DECLARE_OPERATOR(IcebergTableSinkLocalState)
836
DECLARE_OPERATOR(SpillIcebergTableSinkLocalState)
837
DECLARE_OPERATOR(IcebergDeleteSinkLocalState)
838
DECLARE_OPERATOR(IcebergMergeSinkLocalState)
839
DECLARE_OPERATOR(MCTableSinkLocalState)
840
DECLARE_OPERATOR(AnalyticSinkLocalState)
841
DECLARE_OPERATOR(BlackholeSinkLocalState)
842
DECLARE_OPERATOR(SortSinkLocalState)
843
DECLARE_OPERATOR(SpillSortSinkLocalState)
844
DECLARE_OPERATOR(LocalExchangeSinkLocalState)
845
DECLARE_OPERATOR(AggSinkLocalState)
846
DECLARE_OPERATOR(BucketedAggSinkLocalState)
847
DECLARE_OPERATOR(PartitionedAggSinkLocalState)
848
DECLARE_OPERATOR(ExchangeSinkLocalState)
849
DECLARE_OPERATOR(NestedLoopJoinBuildSinkLocalState)
850
DECLARE_OPERATOR(UnionSinkLocalState)
851
DECLARE_OPERATOR(MultiCastDataStreamSinkLocalState)
852
DECLARE_OPERATOR(PartitionSortSinkLocalState)
853
DECLARE_OPERATOR(SetProbeSinkLocalState<true>)
854
DECLARE_OPERATOR(SetProbeSinkLocalState<false>)
855
DECLARE_OPERATOR(SetSinkLocalState<true>)
856
DECLARE_OPERATOR(SetSinkLocalState<false>)
857
DECLARE_OPERATOR(PartitionedHashJoinSinkLocalState)
858
DECLARE_OPERATOR(GroupCommitBlockSinkLocalState)
859
DECLARE_OPERATOR(CacheSinkLocalState)
860
DECLARE_OPERATOR(DictSinkLocalState)
861
DECLARE_OPERATOR(RecCTESinkLocalState)
862
DECLARE_OPERATOR(RecCTEAnchorSinkLocalState)
863
864
#undef DECLARE_OPERATOR
865
866
#define DECLARE_OPERATOR(LOCAL_STATE) template class OperatorX<LOCAL_STATE>;
867
DECLARE_OPERATOR(HashJoinProbeLocalState)
868
DECLARE_OPERATOR(OlapScanLocalState)
869
DECLARE_OPERATOR(GroupCommitLocalState)
870
DECLARE_OPERATOR(JDBCScanLocalState)
871
DECLARE_OPERATOR(FileScanLocalState)
872
DECLARE_OPERATOR(AnalyticLocalState)
873
DECLARE_OPERATOR(SortLocalState)
874
DECLARE_OPERATOR(SpillSortLocalState)
875
DECLARE_OPERATOR(LocalMergeSortLocalState)
876
DECLARE_OPERATOR(AggLocalState)
877
DECLARE_OPERATOR(BucketedAggLocalState)
878
DECLARE_OPERATOR(PartitionedAggLocalState)
879
DECLARE_OPERATOR(TableFunctionLocalState)
880
DECLARE_OPERATOR(ExchangeLocalState)
881
DECLARE_OPERATOR(RepeatLocalState)
882
DECLARE_OPERATOR(NestedLoopJoinProbeLocalState)
883
DECLARE_OPERATOR(AssertNumRowsLocalState)
884
DECLARE_OPERATOR(EmptySetLocalState)
885
DECLARE_OPERATOR(UnionSourceLocalState)
886
DECLARE_OPERATOR(MultiCastDataStreamSourceLocalState)
887
DECLARE_OPERATOR(PartitionSortSourceLocalState)
888
DECLARE_OPERATOR(SetSourceLocalState<true>)
889
DECLARE_OPERATOR(SetSourceLocalState<false>)
890
DECLARE_OPERATOR(DataGenLocalState)
891
DECLARE_OPERATOR(SchemaScanLocalState)
892
DECLARE_OPERATOR(MetaScanLocalState)
893
DECLARE_OPERATOR(LocalExchangeSourceLocalState)
894
DECLARE_OPERATOR(PartitionedHashJoinProbeLocalState)
895
DECLARE_OPERATOR(CacheSourceLocalState)
896
DECLARE_OPERATOR(RecCTESourceLocalState)
897
DECLARE_OPERATOR(RecCTEScanLocalState)
898
899
#ifdef BE_TEST
900
DECLARE_OPERATOR(MockLocalState)
901
DECLARE_OPERATOR(MockScanLocalState)
902
#endif
903
#undef DECLARE_OPERATOR
904
905
template class StreamingOperatorX<AssertNumRowsLocalState>;
906
template class StreamingOperatorX<SelectLocalState>;
907
908
template class StatefulOperatorX<HashJoinProbeLocalState>;
909
template class StatefulOperatorX<PartitionedHashJoinProbeLocalState>;
910
template class StatefulOperatorX<RepeatLocalState>;
911
template class StatefulOperatorX<MaterializationLocalState>;
912
template class StatefulOperatorX<StreamingAggLocalState>;
913
template class StatefulOperatorX<DistinctStreamingAggLocalState>;
914
template class StatefulOperatorX<NestedLoopJoinProbeLocalState>;
915
template class StatefulOperatorX<TableFunctionLocalState>;
916
917
template class PipelineXSinkLocalState<HashJoinSharedState>;
918
template class PipelineXSinkLocalState<PartitionedHashJoinSharedState>;
919
template class PipelineXSinkLocalState<SortSharedState>;
920
template class PipelineXSinkLocalState<SpillSortSharedState>;
921
template class PipelineXSinkLocalState<NestedLoopJoinSharedState>;
922
template class PipelineXSinkLocalState<AnalyticSharedState>;
923
template class PipelineXSinkLocalState<AggSharedState>;
924
template class PipelineXSinkLocalState<BucketedAggSharedState>;
925
template class PipelineXSinkLocalState<PartitionedAggSharedState>;
926
template class PipelineXSinkLocalState<FakeSharedState>;
927
template class PipelineXSinkLocalState<UnionSharedState>;
928
template class PipelineXSinkLocalState<PartitionSortNodeSharedState>;
929
template class PipelineXSinkLocalState<MultiCastSharedState>;
930
template class PipelineXSinkLocalState<SetSharedState>;
931
template class PipelineXSinkLocalState<LocalExchangeSharedState>;
932
template class PipelineXSinkLocalState<BasicSharedState>;
933
template class PipelineXSinkLocalState<DataQueueSharedState>;
934
template class PipelineXSinkLocalState<RecCTESharedState>;
935
936
template class PipelineXLocalState<HashJoinSharedState>;
937
template class PipelineXLocalState<PartitionedHashJoinSharedState>;
938
template class PipelineXLocalState<SortSharedState>;
939
template class PipelineXLocalState<SpillSortSharedState>;
940
template class PipelineXLocalState<NestedLoopJoinSharedState>;
941
template class PipelineXLocalState<AnalyticSharedState>;
942
template class PipelineXLocalState<AggSharedState>;
943
template class PipelineXLocalState<BucketedAggSharedState>;
944
template class PipelineXLocalState<PartitionedAggSharedState>;
945
template class PipelineXLocalState<FakeSharedState>;
946
template class PipelineXLocalState<UnionSharedState>;
947
template class PipelineXLocalState<DataQueueSharedState>;
948
template class PipelineXLocalState<MultiCastSharedState>;
949
template class PipelineXLocalState<PartitionSortNodeSharedState>;
950
template class PipelineXLocalState<SetSharedState>;
951
template class PipelineXLocalState<LocalExchangeSharedState>;
952
template class PipelineXLocalState<BasicSharedState>;
953
template class PipelineXLocalState<RecCTESharedState>;
954
955
template class AsyncWriterSink<doris::VFileResultWriter, ResultFileSinkOperatorX>;
956
template class AsyncWriterSink<doris::VJdbcTableWriter, JdbcTableSinkOperatorX>;
957
template class AsyncWriterSink<doris::VTabletWriter, OlapTableSinkOperatorX>;
958
template class AsyncWriterSink<doris::VTabletWriterV2, OlapTableSinkV2OperatorX>;
959
template class AsyncWriterSink<doris::VHiveTableWriter, HiveTableSinkOperatorX>;
960
template class AsyncWriterSink<doris::VIcebergTableWriter, IcebergTableSinkOperatorX>;
961
template class AsyncWriterSink<doris::VIcebergTableWriter, SpillIcebergTableSinkOperatorX>;
962
template class AsyncWriterSink<doris::VIcebergDeleteSink, IcebergDeleteSinkOperatorX>;
963
template class AsyncWriterSink<doris::VIcebergMergeSink, IcebergMergeSinkOperatorX>;
964
template class AsyncWriterSink<doris::VMCTableWriter, MCTableSinkOperatorX>;
965
template class AsyncWriterSink<doris::VTVFTableWriter, TVFTableSinkOperatorX>;
966
967
#ifdef BE_TEST
968
template class OperatorX<DummyOperatorLocalState>;
969
template class DataSinkOperatorX<DummySinkLocalState>;
970
#endif
971
972
} // namespace doris