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 #ifndef COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_ | 5 #ifndef COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_ |
6 #define COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_ | 6 #define COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_ |
7 | 7 |
| 8 #include <stddef.h> |
| 9 |
8 #include <string> | 10 #include <string> |
9 | 11 |
10 #include "base/containers/hash_tables.h" | 12 #include "base/containers/hash_tables.h" |
11 #include "base/gtest_prod_util.h" | 13 #include "base/gtest_prod_util.h" |
| 14 #include "base/macros.h" |
12 #include "base/memory/singleton.h" | 15 #include "base/memory/singleton.h" |
13 #include "base/trace_event/memory_dump_provider.h" | 16 #include "base/trace_event/memory_dump_provider.h" |
14 #include "components/tracing/tracing_export.h" | 17 #include "components/tracing/tracing_export.h" |
15 | 18 |
16 namespace tracing { | 19 namespace tracing { |
17 | 20 |
18 // Dump provider which collects memory stats about graphics memory on Android. | 21 // Dump provider which collects memory stats about graphics memory on Android. |
19 // This requires the presence of the memtrack_helper daemon, which must be | 22 // This requires the presence of the memtrack_helper daemon, which must be |
20 // executed separetely via a (root) adb shell command. The dump provider will | 23 // executed separetely via a (root) adb shell command. The dump provider will |
21 // fail (and hence disabled by the MemoryDumpManager) in absence of the helper. | 24 // fail (and hence disabled by the MemoryDumpManager) in absence of the helper. |
(...skipping 23 matching lines...) Expand all Loading... |
45 // Stores key names coming from the memtrack helper in long-lived storage. | 48 // Stores key names coming from the memtrack helper in long-lived storage. |
46 // This is to allow using cheap char* strings in tracing without copies. | 49 // This is to allow using cheap char* strings in tracing without copies. |
47 base::hash_set<std::string> key_names_; | 50 base::hash_set<std::string> key_names_; |
48 | 51 |
49 DISALLOW_COPY_AND_ASSIGN(GraphicsMemoryDumpProvider); | 52 DISALLOW_COPY_AND_ASSIGN(GraphicsMemoryDumpProvider); |
50 }; | 53 }; |
51 | 54 |
52 } // namespace tracing | 55 } // namespace tracing |
53 | 56 |
54 #endif // COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_ | 57 #endif // COMPONENTS_TRACING_GRAPHICS_MEMORY_DUMP_PROVIDER_ANDROID_H_ |
OLD | NEW |