| Index: components/leveldb/leveldb_database_impl.cc
|
| diff --git a/components/leveldb/leveldb_database_impl.cc b/components/leveldb/leveldb_database_impl.cc
|
| index d8ae4e25db235abfe7772f310d783def3e637536..f0f509a28c66dea0e215ccac63831ff90f14fdf8 100644
|
| --- a/components/leveldb/leveldb_database_impl.cc
|
| +++ b/components/leveldb/leveldb_database_impl.cc
|
| @@ -16,6 +16,7 @@
|
| #include "base/trace_event/memory_dump_manager.h"
|
| #include "components/leveldb/env_mojo.h"
|
| #include "components/leveldb/public/cpp/util.h"
|
| +#include "third_party/leveldatabase/env_chromium.h"
|
| #include "third_party/leveldatabase/src/include/leveldb/db.h"
|
| #include "third_party/leveldatabase/src/include/leveldb/write_batch.h"
|
|
|
| @@ -310,11 +311,10 @@ bool LevelDBDatabaseImpl::OnMemoryDump(
|
| cache_->TotalCharge());
|
| }
|
|
|
| - const char* system_allocator_name =
|
| - base::trace_event::MemoryDumpManager::GetInstance()
|
| - ->system_allocator_pool_name();
|
| - if (system_allocator_name)
|
| - pmd->AddSuballocation(mad->guid(), system_allocator_name);
|
| + // All leveldb databases are already dumped by leveldb_env::DBTracker. Add
|
| + // an edge to avoid double counting.
|
| + pmd->AddSuballocation(mad->guid(),
|
| + leveldb_env::DBTracker::GetMemoryDumpName(db_.get()));
|
|
|
| if (memory_dump_id_) {
|
| auto* global_dump = pmd->CreateSharedGlobalAllocatorDump(*memory_dump_id_);
|
|
|