#include <inttypes.h>
#include <sys/mman.h>
#include "base/memory/madv_free_discardable_memory_allocator_posix.h"
#include "base/process/process_metrics.h"
#include "base/strings/string_number_conversions.h"
#include "base/task/single_thread_task_runner.h"
#include "base/tracing_buildflags.h"
#if BUILDFLAG(ENABLE_BASE_TRACING)
#include "base/trace_event/memory_dump_manager.h"
#endif
namespace base {
MadvFreeDiscardableMemoryAllocatorPosix::
MadvFreeDiscardableMemoryAllocatorPosix() { … }
MadvFreeDiscardableMemoryAllocatorPosix::
~MadvFreeDiscardableMemoryAllocatorPosix() { … }
std::unique_ptr<DiscardableMemory>
MadvFreeDiscardableMemoryAllocatorPosix::AllocateLockedDiscardableMemory(
size_t size) { … }
size_t MadvFreeDiscardableMemoryAllocatorPosix::GetBytesAllocated() const { … }
bool MadvFreeDiscardableMemoryAllocatorPosix::OnMemoryDump(
const trace_event::MemoryDumpArgs& args,
trace_event::ProcessMemoryDump* pmd) { … }
}