#ifdef UNSAFE_BUFFERS_BUILD
#pragma allow_unsafe_buffers
#endif
#include "base/trace_event/category_registry.h"
#include <string.h>
#include <ostream>
#include <type_traits>
#include "base/check.h"
#include "base/debug/leak_annotations.h"
#include "base/notreached.h"
#include "third_party/abseil-cpp/absl/base/dynamic_annotations.h"
namespace base {
namespace trace_event {
namespace {
static_assert …;
}
TraceCategory CategoryRegistry::categories_[kMaxCategories] = …;
std::atomic<size_t> CategoryRegistry::category_index_{ … };
TraceCategory* const CategoryRegistry::kCategoryAlreadyShutdown = …;
TraceCategory* const CategoryRegistry::kCategoryMetadata = …;
void CategoryRegistry::Initialize() { … }
void CategoryRegistry::ResetForTesting() { … }
TraceCategory* CategoryRegistry::GetCategoryByName(const char* category_name) { … }
bool CategoryRegistry::GetOrCreateCategoryLocked(
const char* category_name,
CategoryInitializerFn category_initializer_fn,
TraceCategory** category) { … }
const TraceCategory* CategoryRegistry::GetCategoryByStatePtr(
const uint8_t* category_state) { … }
bool CategoryRegistry::IsMetaCategory(const TraceCategory* category) { … }
base::span<TraceCategory> CategoryRegistry::GetAllCategories() { … }
bool CategoryRegistry::IsValidCategoryPtr(const TraceCategory* category) { … }
}
}