Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2006, Google Inc. | 1 // Copyright (c) 2006, Google Inc. |
| 2 // All rights reserved. | 2 // All rights reserved. |
| 3 // | 3 // |
| 4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
| 5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
| 6 // met: | 6 // met: |
| 7 // | 7 // |
| 8 // * Redistributions of source code must retain the above copyright | 8 // * Redistributions of source code must retain the above copyright |
| 9 // notice, this list of conditions and the following disclaimer. | 9 // notice, this list of conditions and the following disclaimer. |
| 10 // * Redistributions in binary form must reproduce the above | 10 // * Redistributions in binary form must reproduce the above |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 52 #endif | 52 #endif |
| 53 #include <errno.h> | 53 #include <errno.h> |
| 54 #include <stdarg.h> | 54 #include <stdarg.h> |
| 55 #include <string> | 55 #include <string> |
| 56 #include <map> | 56 #include <map> |
| 57 #include <algorithm> // for sort(), equal(), and copy() | 57 #include <algorithm> // for sort(), equal(), and copy() |
| 58 | 58 |
| 59 #include "heap-profile-table.h" | 59 #include "heap-profile-table.h" |
| 60 | 60 |
| 61 #include "base/logging.h" | 61 #include "base/logging.h" |
| 62 #include "deep-heap-profile.h" | |
|
Alexander Potapenko
2011/12/20 13:57:23
Do you need to include deep-heap-profile.h here?
Dai Mikurube (NOT FULLTIME)
2011/12/21 09:13:49
Thanks, and removed. I forgot to remove it after
| |
| 62 #include "memory_region_map.h" | 63 #include "memory_region_map.h" |
| 63 #include "raw_printer.h" | 64 #include "raw_printer.h" |
| 64 #include "symbolize.h" | 65 #include "symbolize.h" |
| 65 #include <google/stacktrace.h> | 66 #include <google/stacktrace.h> |
| 66 #include <google/malloc_hook.h> | 67 #include <google/malloc_hook.h> |
| 67 #include "base/commandlineflags.h" | 68 #include "base/commandlineflags.h" |
| 68 #include "base/logging.h" // for the RawFD I/O commands | 69 #include "base/logging.h" // for the RawFD I/O commands |
| 69 #include "base/sysinfo.h" | 70 #include "base/sysinfo.h" |
| 70 | 71 |
| 71 using std::sort; | 72 using std::sort; |
| (...skipping 627 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 699 char* unused) { | 700 char* unused) { |
| 700 // Perhaps also log the allocation stack trace (unsymbolized) | 701 // Perhaps also log the allocation stack trace (unsymbolized) |
| 701 // on this line in case somebody finds it useful. | 702 // on this line in case somebody finds it useful. |
| 702 RAW_LOG(ERROR, "leaked %"PRIuS" byte object %p", v->bytes, ptr); | 703 RAW_LOG(ERROR, "leaked %"PRIuS" byte object %p", v->bytes, ptr); |
| 703 } | 704 } |
| 704 | 705 |
| 705 void HeapProfileTable::Snapshot::ReportIndividualObjects() { | 706 void HeapProfileTable::Snapshot::ReportIndividualObjects() { |
| 706 char unused; | 707 char unused; |
| 707 map_.Iterate(ReportObject, &unused); | 708 map_.Iterate(ReportObject, &unused); |
| 708 } | 709 } |
| OLD | NEW |