Coverage Report

Created: 2026-06-18 06:30

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