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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.h

Issue 2350423003: [Tentaive patch for discussion] Add Purge+Suspend metrics as UMA.
Patch Set: Add UMA to tab_manager 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_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 int cdm_id) const override; 177 int cdm_id) const override;
178 #endif 178 #endif
179 bool IsProcessBackgrounded() const override; 179 bool IsProcessBackgrounded() const override;
180 void IncrementServiceWorkerRefCount() override; 180 void IncrementServiceWorkerRefCount() override;
181 void DecrementServiceWorkerRefCount() override; 181 void DecrementServiceWorkerRefCount() override;
182 void IncrementSharedWorkerRefCount() override; 182 void IncrementSharedWorkerRefCount() override;
183 void DecrementSharedWorkerRefCount() override; 183 void DecrementSharedWorkerRefCount() override;
184 void ForceReleaseWorkerRefCounts() override; 184 void ForceReleaseWorkerRefCounts() override;
185 bool IsWorkerRefCountDisabled() override; 185 bool IsWorkerRefCountDisabled() override;
186 void PurgeAndSuspend() override; 186 void PurgeAndSuspend() override;
187 const base::TimeTicks& GetLastPurgeAndSuspendTime() const override;
187 188
188 mojom::RouteProvider* GetRemoteRouteProvider(); 189 mojom::RouteProvider* GetRemoteRouteProvider();
189 190
190 // IPC::Sender via RenderProcessHost. 191 // IPC::Sender via RenderProcessHost.
191 bool Send(IPC::Message* msg) override; 192 bool Send(IPC::Message* msg) override;
192 193
193 // IPC::Listener via RenderProcessHost. 194 // IPC::Listener via RenderProcessHost.
194 bool OnMessageReceived(const IPC::Message& msg) override; 195 bool OnMessageReceived(const IPC::Message& msg) override;
195 void OnChannelConnected(int32_t peer_pid) override; 196 void OnChannelConnected(int32_t peer_pid) override;
196 void OnChannelError() override; 197 void OnChannelError() override;
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
484 std::unique_ptr<base::Thread> in_process_renderer_; 485 std::unique_ptr<base::Thread> in_process_renderer_;
485 486
486 // True after Init() has been called. We can't just check channel_ because we 487 // True after Init() has been called. We can't just check channel_ because we
487 // also reset that in the case of process termination. 488 // also reset that in the case of process termination.
488 bool is_initialized_; 489 bool is_initialized_;
489 490
490 // PlzNavigate 491 // PlzNavigate
491 // Stores the time at which the first call to Init happened. 492 // Stores the time at which the first call to Init happened.
492 base::TimeTicks init_time_; 493 base::TimeTicks init_time_;
493 494
495 base::TimeTicks last_purge_and_suspend_time_;
496
494 // Used to launch and terminate the process without blocking the UI thread. 497 // Used to launch and terminate the process without blocking the UI thread.
495 std::unique_ptr<ChildProcessLauncher> child_process_launcher_; 498 std::unique_ptr<ChildProcessLauncher> child_process_launcher_;
496 499
497 // Messages we queue before the ChannelProxy is created. 500 // Messages we queue before the ChannelProxy is created.
498 using MessageQueue = std::queue<std::unique_ptr<IPC::Message>>; 501 using MessageQueue = std::queue<std::unique_ptr<IPC::Message>>;
499 MessageQueue queued_messages_; 502 MessageQueue queued_messages_;
500 503
501 // The globally-unique identifier for this RPH. 504 // The globally-unique identifier for this RPH.
502 const int id_; 505 const int id_;
503 506
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
609 instance_weak_factory_; 612 instance_weak_factory_;
610 613
611 base::WeakPtrFactory<RenderProcessHostImpl> weak_factory_; 614 base::WeakPtrFactory<RenderProcessHostImpl> weak_factory_;
612 615
613 DISALLOW_COPY_AND_ASSIGN(RenderProcessHostImpl); 616 DISALLOW_COPY_AND_ASSIGN(RenderProcessHostImpl);
614 }; 617 };
615 618
616 } // namespace content 619 } // namespace content
617 620
618 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_ 621 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_PROCESS_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698