#include "src/trace_processor/util/trace_type.h"
#include <algorithm>
#include <cstddef>
#include <cstdint>
#include <string>
#include "perfetto/base/logging.h"
#include "perfetto/ext/base/string_utils.h"
#include "perfetto/ext/base/string_view.h"
#include "src/trace_processor/importers/android_bugreport/android_log_event.h"
#include "protos/perfetto/trace/trace.pbzero.h"
#include "protos/perfetto/trace/trace_packet.pbzero.h"
namespace perfetto::trace_processor {
namespace {
constexpr char kFuchsiaMagic[] = …;
constexpr char kPerfMagic[] = …;
constexpr char kZipMagic[] = …;
constexpr char kGzipMagic[] = …;
constexpr uint8_t kTracePacketTag = …;
constexpr uint16_t kModuleSymbolsTag = …;
inline bool isspace(unsigned char c) { … }
std::string RemoveWhitespace(std::string str) { … }
template <size_t N>
bool MatchesMagic(const uint8_t* data, size_t size, const char (&magic)[N]) { … }
bool IsProtoTraceWithSymbols(const uint8_t* ptr, size_t size) { … }
}
const char* TraceTypeToString(TraceType trace_type) { … }
TraceType GuessTraceType(const uint8_t* data, size_t size) { … }
}