Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(204)

Side by Side Diff: base/trace_event/memory_infra_background_whitelist.cc

Issue 2674203003: [memory-infra] Whitelist TabRestoreService MDP. (Closed)
Patch Set: Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_infra_background_whitelist.h" 5 #include "base/trace_event/memory_infra_background_whitelist.h"
6 6
7 #include <ctype.h> 7 #include <ctype.h>
8 #include <string.h> 8 #include <string.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 17 matching lines...) Expand all
28 "LeveldbValueStore", 28 "LeveldbValueStore",
29 "Malloc", 29 "Malloc",
30 "MemoryCache", 30 "MemoryCache",
31 "PartitionAlloc", 31 "PartitionAlloc",
32 "ProcessMemoryMetrics", 32 "ProcessMemoryMetrics",
33 "Skia", 33 "Skia",
34 "Sql", 34 "Sql",
35 "V8Isolate", 35 "V8Isolate",
36 "WinHeap", 36 "WinHeap",
37 "SyncDirectory", 37 "SyncDirectory",
38 "TabRestoreServiceHelper",
ssid 2017/02/07 18:58:59 TabRestore service creates dumps even if there are
DmitrySkiba 2017/02/07 23:17:04 Done.
38 nullptr // End of list marker. 39 nullptr // End of list marker.
39 }; 40 };
40 41
41 // A list of string names that are allowed for the memory allocator dumps in 42 // A list of string names that are allowed for the memory allocator dumps in
42 // background mode. 43 // background mode.
43 const char* const kAllocatorDumpNameWhitelist[] = { 44 const char* const kAllocatorDumpNameWhitelist[] = {
44 "blink_gc", 45 "blink_gc",
45 "blink_gc/allocated_objects", 46 "blink_gc/allocated_objects",
46 "discardable", 47 "discardable",
47 "discardable/child_0x?", 48 "discardable/child_0x?",
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 "sync/0x?/model_type/PRIORITY_PREFERENCE", 118 "sync/0x?/model_type/PRIORITY_PREFERENCE",
118 "sync/0x?/model_type/READING_LIST", 119 "sync/0x?/model_type/READING_LIST",
119 "sync/0x?/model_type/SEARCH_ENGINE", 120 "sync/0x?/model_type/SEARCH_ENGINE",
120 "sync/0x?/model_type/SESSION", 121 "sync/0x?/model_type/SESSION",
121 "sync/0x?/model_type/SYNCED_NOTIFICATION", 122 "sync/0x?/model_type/SYNCED_NOTIFICATION",
122 "sync/0x?/model_type/SYNCED_NOTIFICATION_APP_INFO", 123 "sync/0x?/model_type/SYNCED_NOTIFICATION_APP_INFO",
123 "sync/0x?/model_type/THEME", 124 "sync/0x?/model_type/THEME",
124 "sync/0x?/model_type/TYPED_URL", 125 "sync/0x?/model_type/TYPED_URL",
125 "sync/0x?/model_type/WALLET_METADATA", 126 "sync/0x?/model_type/WALLET_METADATA",
126 "sync/0x?/model_type/WIFI_CREDENTIAL", 127 "sync/0x?/model_type/WIFI_CREDENTIAL",
128 "tab_restore/service_helper_0x?/entries/tab_0x?",
129 "tab_restore/service_helper_0x?/entries/window_0x?",
ssid 2017/02/07 18:58:59 Is there a maximum number of service helpers and e
DmitrySkiba 2017/02/07 23:17:04 Maximum value is 25, see TabRestoreServiceHelper::
127 nullptr // End of list marker. 130 nullptr // End of list marker.
128 }; 131 };
129 132
130 const char* const* g_dump_provider_whitelist = kDumpProviderWhitelist; 133 const char* const* g_dump_provider_whitelist = kDumpProviderWhitelist;
131 const char* const* g_allocator_dump_name_whitelist = 134 const char* const* g_allocator_dump_name_whitelist =
132 kAllocatorDumpNameWhitelist; 135 kAllocatorDumpNameWhitelist;
133 136
134 } // namespace 137 } // namespace
135 138
136 bool IsMemoryDumpProviderWhitelisted(const char* mdp_name) { 139 bool IsMemoryDumpProviderWhitelisted(const char* mdp_name) {
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 void SetDumpProviderWhitelistForTesting(const char* const* list) { 175 void SetDumpProviderWhitelistForTesting(const char* const* list) {
173 g_dump_provider_whitelist = list; 176 g_dump_provider_whitelist = list;
174 } 177 }
175 178
176 void SetAllocatorDumpNameWhitelistForTesting(const char* const* list) { 179 void SetAllocatorDumpNameWhitelistForTesting(const char* const* list) {
177 g_allocator_dump_name_whitelist = list; 180 g_allocator_dump_name_whitelist = list;
178 } 181 }
179 182
180 } // namespace trace_event 183 } // namespace trace_event
181 } // namespace base 184 } // namespace base
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698