Coverage Report

Created: 2026-08-03 08:20

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