1 /*
2 * Copyright (C) 2023 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 #include "src/trace_processor/db/column/dummy_storage.h"
18
19 #include <cstdint>
20 #include <optional>
21
22 #include "perfetto/base/logging.h"
23 #include "perfetto/trace_processor/basic_types.h"
24 #include "src/trace_processor/db/column/data_layer.h"
25 #include "src/trace_processor/db/column/types.h"
26
27 namespace perfetto::trace_processor::column {
28
SingleSearch(FilterOp,SqlValue,uint32_t) const29 SingleSearchResult DummyStorage::ChainImpl::SingleSearch(FilterOp,
30 SqlValue,
31 uint32_t) const {
32 PERFETTO_FATAL("Shouldn't be called");
33 }
34
ValidateSearchConstraints(FilterOp,SqlValue) const35 SearchValidationResult DummyStorage::ChainImpl::ValidateSearchConstraints(
36 FilterOp,
37 SqlValue) const {
38 PERFETTO_FATAL("Shouldn't be called");
39 }
40
SearchValidated(FilterOp,SqlValue,Range) const41 RangeOrBitVector DummyStorage::ChainImpl::SearchValidated(FilterOp,
42 SqlValue,
43 Range) const {
44 PERFETTO_FATAL("Shouldn't be called");
45 }
46
IndexSearchValidated(FilterOp,SqlValue,Indices &) const47 void DummyStorage::ChainImpl::IndexSearchValidated(FilterOp,
48 SqlValue,
49 Indices&) const {
50 PERFETTO_FATAL("Shouldn't be called");
51 }
52
StableSort(SortToken *,SortToken *,SortDirection) const53 void DummyStorage::ChainImpl::StableSort(SortToken*,
54 SortToken*,
55 SortDirection) const {
56 PERFETTO_FATAL("Shouldn't be called");
57 }
58
Distinct(Indices &) const59 void DummyStorage::ChainImpl::Distinct(Indices&) const {
60 PERFETTO_FATAL("Shouldn't be called");
61 }
62
size() const63 uint32_t DummyStorage::ChainImpl::size() const {
64 return 0;
65 }
66
MaxElement(Indices &) const67 std::optional<Token> DummyStorage::ChainImpl::MaxElement(Indices&) const {
68 PERFETTO_FATAL("Shouldn't be called");
69 }
70
MinElement(Indices &) const71 std::optional<Token> DummyStorage::ChainImpl::MinElement(Indices&) const {
72 PERFETTO_FATAL("Shouldn't be called");
73 }
74
Get_AvoidUsingBecauseSlow(uint32_t) const75 SqlValue DummyStorage::ChainImpl::Get_AvoidUsingBecauseSlow(uint32_t) const {
76 PERFETTO_FATAL("Shouldn't be called");
77 }
78
Serialize(StorageProto *) const79 void DummyStorage::ChainImpl::Serialize(StorageProto*) const {
80 PERFETTO_FATAL("Shouldn't be called");
81 }
82
83 } // namespace perfetto::trace_processor::column
84