/* * Copyright (C) 2018 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef INCLUDE_PERFETTO_TRACE_PROCESSOR_BASIC_TYPES_H_ #define INCLUDE_PERFETTO_TRACE_PROCESSOR_BASIC_TYPES_H_ #include <assert.h> #include <math.h> #include <stdarg.h> #include <cstdint> #include <string> #include <unordered_map> #include <utility> #include <vector> #include "perfetto/base/export.h" #include "perfetto/base/logging.h" namespace perfetto { namespace trace_processor { // All metrics protos are in this directory. When loading metric extensions, the // protos are mounted onto a virtual path inside this directory. constexpr char kMetricProtoRoot[] = …; // Enum which encodes how trace processor should try to sort the ingested data. // Note that these options are only applicable to proto traces; other trace // types (e.g. JSON, Fuchsia) use full sorts. enum class SortingMode { … }; // Enum which encodes which event (if any) should be used to drop ftrace data // from before this timestamp of that event. enum class DropFtraceDataBefore { … }; // Specifies whether the ftrace data should be "soft-dropped" until a given // global timestamp, meaning we'll still populate the |ftrace_events| table // and some other internal storage, but won't persist derived info such as // slices. See also |DropFtraceDataBefore| above. // Note: this might behave in surprising ways for traces using >1 tracefs // instances, but those aren't seen in practice at the time of writing. enum class SoftDropFtraceDataBefore { … }; // Enum which encodes which timestamp source (if any) should be used to drop // track event data before this timestamp. enum class DropTrackEventDataBefore { … }; // Struct for configuring a TraceProcessor instance (see trace_processor.h). struct PERFETTO_EXPORT_COMPONENT Config { … }; // Represents a dynamically typed value returned by SQL. struct PERFETTO_EXPORT_COMPONENT SqlValue { … }; // Data used to register a new SQL module. struct SqlModule { … }; } // namespace trace_processor } // namespace perfetto #endif // INCLUDE_PERFETTO_TRACE_PROCESSOR_BASIC_TYPES_H_