#include <algorithm>
#include <cstring>
#include <ios>
#include <iostream>
#include <map>
#include <optional>
#include <string>
#include <unordered_map>
#include <vector>
#include "base/check_op.h"
#include "base/debug/proc_maps_linux.h"
#include "base/files/file.h"
#include "base/files/file_enumerator.h"
#include "base/logging.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/stringprintf.h"
#include "base/thread_annotations.h"
#include "base/threading/platform_thread.h"
#include "base/time/time.h"
#include "build/build_config.h"
#include "partition_alloc/partition_root.h"
#include "partition_alloc/thread_cache.h"
#include "tools/memory/partition_allocator/inspect_utils.h"
namespace partition_alloc::tools {
namespace {
BucketIndexLookup;
kNumBuckets;
constexpr const char* kDumpName = …;
constexpr const char* kTmpDumpName = …;
uintptr_t FindAllocInfoAddress(RemoteProcessMemoryReader& reader) { … }
void DisplayPerBucketData(
const std::unordered_map<uintptr_t, size_t>& live_allocs,
size_t allocations,
double allocations_per_second) { … }
}
}
int main(int argc, char** argv) { … }