#include "components/performance_manager/public/performance_manager.h"
#include <utility>
#include "base/functional/bind.h"
#include "base/functional/callback.h"
#include "base/task/sequenced_task_runner.h"
#include "components/performance_manager/graph/frame_node_impl.h"
#include "components/performance_manager/graph/page_node_impl.h"
#include "components/performance_manager/graph/process_node_impl.h"
#include "components/performance_manager/graph/worker_node_impl.h"
#include "components/performance_manager/performance_manager_impl.h"
#include "components/performance_manager/performance_manager_registry_impl.h"
#include "components/performance_manager/performance_manager_tab_helper.h"
#include "components/performance_manager/public/performance_manager_owned.h"
#include "components/performance_manager/resource_attribution/query_scheduler.h"
#include "content/public/browser/browser_child_process_host.h"
#include "content/public/browser/child_process_data.h"
#include "content/public/browser/render_process_host.h"
namespace performance_manager {
PerformanceManager::PerformanceManager() = default;
PerformanceManager::~PerformanceManager() = default;
void PerformanceManager::CallOnGraph(const base::Location& from_here,
base::OnceClosure callback) { … }
void PerformanceManager::CallOnGraph(const base::Location& from_here,
GraphCallback callback) { … }
void PerformanceManager::PassToGraph(const base::Location& from_here,
std::unique_ptr<GraphOwned> graph_owned) { … }
base::WeakPtr<PageNode> PerformanceManager::GetPrimaryPageNodeForWebContents(
content::WebContents* wc) { … }
base::WeakPtr<FrameNode> PerformanceManager::GetFrameNodeForRenderFrameHost(
content::RenderFrameHost* rfh) { … }
base::WeakPtr<ProcessNode>
PerformanceManager::GetProcessNodeForBrowserProcess() { … }
base::WeakPtr<ProcessNode>
PerformanceManager::GetProcessNodeForRenderProcessHost(
content::RenderProcessHost* rph) { … }
base::WeakPtr<ProcessNode>
PerformanceManager::GetProcessNodeForRenderProcessHostId(
RenderProcessHostId id) { … }
base::WeakPtr<ProcessNode>
PerformanceManager::GetProcessNodeForBrowserChildProcessHost(
content::BrowserChildProcessHost* bcph) { … }
base::WeakPtr<ProcessNode>
PerformanceManager::GetProcessNodeForBrowserChildProcessHostId(
BrowserChildProcessHostId id) { … }
base::WeakPtr<WorkerNode> PerformanceManager::GetWorkerNodeForToken(
const blink::WorkerToken& token) { … }
void PerformanceManager::AddObserver(
PerformanceManagerMainThreadObserver* observer) { … }
void PerformanceManager::RemoveObserver(
PerformanceManagerMainThreadObserver* observer) { … }
void PerformanceManager::AddMechanism(
PerformanceManagerMainThreadMechanism* mechanism) { … }
void PerformanceManager::RemoveMechanism(
PerformanceManagerMainThreadMechanism* mechanism) { … }
bool PerformanceManager::HasMechanism(
PerformanceManagerMainThreadMechanism* mechanism) { … }
void PerformanceManager::PassToPM(
std::unique_ptr<PerformanceManagerOwned> pm_owned) { … }
std::unique_ptr<PerformanceManagerOwned> PerformanceManager::TakeFromPM(
PerformanceManagerOwned* pm_owned) { … }
void PerformanceManager::RegisterObject(
PerformanceManagerRegistered* pm_object) { … }
void PerformanceManager::UnregisterObject(
PerformanceManagerRegistered* pm_object) { … }
PerformanceManagerRegistered* PerformanceManager::GetRegisteredObject(
uintptr_t type_id) { … }
scoped_refptr<base::SequencedTaskRunner> PerformanceManager::GetTaskRunner() { … }
void PerformanceManager::RecordMemoryMetrics() { … }
}