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

Side by Side Diff: third_party/WebKit/public/platform/WebMemoryDumpProvider.h

Issue 1995573003: [tracing] Introduce BACKGROUND mode in MemoryInfra (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: with periodic again. Created 4 years, 7 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
OLDNEW
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 WebMemoryDumpProvider_h 5 #ifndef WebMemoryDumpProvider_h
6 #define WebMemoryDumpProvider_h 6 #define WebMemoryDumpProvider_h
7 7
8 #include "WebCommon.h" 8 #include "WebCommon.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 class WebProcessMemoryDump; 12 class WebProcessMemoryDump;
13 13
14 // Used to specify the type of memory dump the WebMemoryDumpProvider should 14 // Used to specify the type of memory dump the WebMemoryDumpProvider should
15 // generate on dump requests. 15 // generate on dump requests.
16 // TODO(hajimehoshi): Remove this and use base::trace_event:: 16 // TODO(hajimehoshi): Remove this and use base::trace_event::
17 // MemoryDumpLevelOfDetail instead. 17 // MemoryDumpLevelOfDetail instead.
18 enum class WebMemoryDumpLevelOfDetail { 18 enum class WebMemoryDumpLevelOfDetail {
19 Background,
19 Light, 20 Light,
20 Detailed 21 Detailed
21 }; 22 };
22 23
23 // Base interface to be part of the memory tracing infrastructure. Blink classes 24 // Base interface to be part of the memory tracing infrastructure. Blink classes
24 // can implement this interface and register themselves (see 25 // can implement this interface and register themselves (see
25 // Platform::registerMemoryDumpProvider()) to dump stats for their allocators. 26 // Platform::registerMemoryDumpProvider()) to dump stats for their allocators.
26 class BLINK_PLATFORM_EXPORT WebMemoryDumpProvider { 27 class BLINK_PLATFORM_EXPORT WebMemoryDumpProvider {
27 public: 28 public:
28 // Function types for functions that can be called on alloc and free to do 29 // Function types for functions that can be called on alloc and free to do
(...skipping 19 matching lines...) Expand all
48 virtual bool supportsHeapProfiling() { return false; } 49 virtual bool supportsHeapProfiling() { return false; }
49 50
50 // Called by the memory dump manager to enable heap profiling (with true) or 51 // Called by the memory dump manager to enable heap profiling (with true) or
51 // called to disable heap profiling (with false). 52 // called to disable heap profiling (with false).
52 virtual void onHeapProfilingEnabled(bool enabled) {} 53 virtual void onHeapProfilingEnabled(bool enabled) {}
53 }; 54 };
54 55
55 } // namespace blink 56 } // namespace blink
56 57
57 #endif // WebMemoryDumpProvider_h 58 #endif // WebMemoryDumpProvider_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698