OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/trace_event/memory_dump_manager.h" | 5 #include "base/trace_event/memory_dump_manager.h" |
6 | 6 |
7 #include <inttypes.h> | 7 #include <inttypes.h> |
8 #include <stdio.h> | 8 #include <stdio.h> |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
11 #include <utility> | 11 #include <utility> |
12 | 12 |
13 #include "base/allocator/features.h" | 13 #include "base/allocator/features.h" |
14 #include "base/atomic_sequence_num.h" | 14 #include "base/atomic_sequence_num.h" |
15 #include "base/base_switches.h" | 15 #include "base/base_switches.h" |
16 #include "base/command_line.h" | 16 #include "base/command_line.h" |
17 #include "base/compiler_specific.h" | 17 #include "base/compiler_specific.h" |
18 #include "base/debug/alias.h" | 18 #include "base/debug/alias.h" |
19 #include "base/debug/debugging_flags.h" | 19 #include "base/debug/debugging_flags.h" |
20 #include "base/debug/stack_trace.h" | 20 #include "base/debug/stack_trace.h" |
21 #include "base/debug/thread_heap_usage_tracker.h" | 21 #include "base/debug/thread_heap_usage_tracker.h" |
22 #include "base/memory/ptr_util.h" | 22 #include "base/memory/ptr_util.h" |
23 #include "base/optional.h" | 23 #include "base/optional.h" |
| 24 #include "base/sequenced_task_runner.h" |
24 #include "base/strings/pattern.h" | 25 #include "base/strings/pattern.h" |
25 #include "base/strings/string_piece.h" | 26 #include "base/strings/string_piece.h" |
26 #include "base/threading/thread.h" | 27 #include "base/threading/thread.h" |
27 #include "base/threading/thread_task_runner_handle.h" | 28 #include "base/threading/thread_task_runner_handle.h" |
28 #include "base/trace_event/heap_profiler.h" | 29 #include "base/trace_event/heap_profiler.h" |
29 #include "base/trace_event/heap_profiler_allocation_context_tracker.h" | 30 #include "base/trace_event/heap_profiler_allocation_context_tracker.h" |
30 #include "base/trace_event/heap_profiler_event_filter.h" | 31 #include "base/trace_event/heap_profiler_event_filter.h" |
31 #include "base/trace_event/heap_profiler_serialization_state.h" | 32 #include "base/trace_event/heap_profiler_serialization_state.h" |
32 #include "base/trace_event/heap_profiler_stack_frame_deduplicator.h" | 33 #include "base/trace_event/heap_profiler_stack_frame_deduplicator.h" |
33 #include "base/trace_event/heap_profiler_type_name_deduplicator.h" | 34 #include "base/trace_event/heap_profiler_type_name_deduplicator.h" |
(...skipping 869 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
903 if (iter == process_dumps.end()) { | 904 if (iter == process_dumps.end()) { |
904 std::unique_ptr<ProcessMemoryDump> new_pmd( | 905 std::unique_ptr<ProcessMemoryDump> new_pmd( |
905 new ProcessMemoryDump(heap_profiler_serialization_state, dump_args)); | 906 new ProcessMemoryDump(heap_profiler_serialization_state, dump_args)); |
906 iter = process_dumps.insert(std::make_pair(pid, std::move(new_pmd))).first; | 907 iter = process_dumps.insert(std::make_pair(pid, std::move(new_pmd))).first; |
907 } | 908 } |
908 return iter->second.get(); | 909 return iter->second.get(); |
909 } | 910 } |
910 | 911 |
911 } // namespace trace_event | 912 } // namespace trace_event |
912 } // namespace base | 913 } // namespace base |
OLD | NEW |