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

Side by Side Diff: content/public/browser/render_process_host.h

Issue 2350423003: [Tentaive patch for discussion] Add Purge+Suspend metrics as UMA.
Patch Set: Fixed misuse of CanPurgeAndSuspend Created 4 years, 2 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_
6 #define CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ 6 #define CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 // After this is called, the Increment/DecrementWorkerRefCount functions must 310 // After this is called, the Increment/DecrementWorkerRefCount functions must
311 // not be called. 311 // not be called.
312 virtual void ForceReleaseWorkerRefCounts() = 0; 312 virtual void ForceReleaseWorkerRefCounts() = 0;
313 313
314 // Returns true if ForceReleaseWorkerRefCounts was called. 314 // Returns true if ForceReleaseWorkerRefCounts was called.
315 virtual bool IsWorkerRefCountDisabled() = 0; 315 virtual bool IsWorkerRefCountDisabled() = 0;
316 316
317 // Purges and suspends the renderer process. 317 // Purges and suspends the renderer process.
318 virtual void PurgeAndSuspend() = 0; 318 virtual void PurgeAndSuspend() = 0;
319 319
320 virtual const base::TimeTicks& GetLastPurgeAndSuspendTime() const = 0;
321
320 // Returns the current number of active views in this process. Excludes 322 // Returns the current number of active views in this process. Excludes
321 // any RenderViewHosts that are swapped out. 323 // any RenderViewHosts that are swapped out.
322 size_t GetActiveViewCount(); 324 size_t GetActiveViewCount();
323 325
324 // Static management functions ----------------------------------------------- 326 // Static management functions -----------------------------------------------
325 327
326 // Flag to run the renderer in process. This is primarily 328 // Flag to run the renderer in process. This is primarily
327 // for debugging purposes. When running "in process", the 329 // for debugging purposes. When running "in process", the
328 // browser maintains a single RenderProcessHost which communicates 330 // browser maintains a single RenderProcessHost which communicates
329 // to a RenderProcess which is instantiated in the same process 331 // to a RenderProcess which is instantiated in the same process
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 static void SetMaxRendererProcessCount(size_t count); 374 static void SetMaxRendererProcessCount(size_t count);
373 375
374 // Returns the current maximum number of renderer process hosts kept by the 376 // Returns the current maximum number of renderer process hosts kept by the
375 // content module. 377 // content module.
376 static size_t GetMaxRendererProcessCount(); 378 static size_t GetMaxRendererProcessCount();
377 }; 379 };
378 380
379 } // namespace content. 381 } // namespace content.
380 382
381 #endif // CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_ 383 #endif // CONTENT_PUBLIC_BROWSER_RENDER_PROCESS_HOST_H_
OLDNEW
« no previous file with comments | « content/child/child_discardable_shared_memory_manager.cc ('k') | content/public/common/content_features.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698