| Index: third_party/tcmalloc/chromium/src/deep-heap-profile.cc
|
| diff --git a/third_party/tcmalloc/chromium/src/deep-heap-profile.cc b/third_party/tcmalloc/chromium/src/deep-heap-profile.cc
|
| index 9037d3c0edae165461054edaac94e79e7a9c54c4..35e88462e6a7d46f20d72e4a77acd6b8797f912c 100644
|
| --- a/third_party/tcmalloc/chromium/src/deep-heap-profile.cc
|
| +++ b/third_party/tcmalloc/chromium/src/deep-heap-profile.cc
|
| @@ -664,15 +664,20 @@ void DeepHeapProfile::GlobalStats::SnapshotMaps(
|
| bool first = true;
|
|
|
| do {
|
| - Bucket* bucket = NULL;
|
| - DeepBucket* deep_bucket = NULL;
|
| if (!first) {
|
| + cursor = mmap_iter->end_addr;
|
| + ++mmap_iter;
|
| + // Don't break here even if mmap_iter == EndRegionLocked().
|
| + }
|
| + first = false;
|
| +
|
| + DeepBucket* deep_bucket = NULL;
|
| + if (mmap_iter != MemoryRegionMap::EndRegionLocked()) {
|
| size_t committed = deep_profile->memory_residence_info_getter_->
|
| CommittedSize(mmap_iter->start_addr, mmap_iter->end_addr - 1);
|
| // TODO(dmikurube): Store a reference to the bucket in region.
|
| Bucket* bucket = MemoryRegionMap::GetBucket(
|
| mmap_iter->call_stack_depth, mmap_iter->call_stack);
|
| - DeepBucket* deep_bucket = NULL;
|
| if (bucket != NULL) {
|
| deep_bucket = deep_profile->deep_table_.Lookup(
|
| bucket,
|
| @@ -687,12 +692,7 @@ void DeepHeapProfile::GlobalStats::SnapshotMaps(
|
| profiled_mmap_.AddToVirtualBytes(
|
| mmap_iter->end_addr - mmap_iter->start_addr);
|
| profiled_mmap_.AddToCommittedBytes(committed);
|
| -
|
| - cursor = mmap_iter->end_addr;
|
| - ++mmap_iter;
|
| - // Don't break here even if mmap_iter == EndRegionLocked().
|
| }
|
| - first = false;
|
|
|
| uint64 last_address_of_unhooked;
|
| // If the next mmap entry is away from the current maps line.
|
|
|