summaryrefslogtreecommitdiff
path: root/chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h
diff options
context:
space:
mode:
Diffstat (limited to 'chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h')
-rw-r--r--chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h b/chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h
index 66abb4e0dc5..f9d874d1b9d 100644
--- a/chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h
+++ b/chromium/third_party/blink/renderer/platform/scheduler/main_thread/frame_scheduler_impl.h
@@ -18,6 +18,7 @@
#include "base/single_thread_task_runner.h"
#include "base/task/sequence_manager/task_queue.h"
#include "base/trace_event/trace_event.h"
+#include "components/power_scheduler/power_mode_voter.h"
#include "net/base/request_priority.h"
#include "services/metrics/public/cpp/ukm_source_id.h"
#include "third_party/blink/public/platform/task_type.h"
@@ -32,6 +33,7 @@
#include "third_party/blink/renderer/platform/scheduler/public/web_scheduling_priority.h"
#include "third_party/blink/renderer/platform/scheduler/worker/worker_scheduler_proxy.h"
#include "third_party/blink/renderer/platform/wtf/hash_map.h"
+#include "third_party/perfetto/include/perfetto/tracing/traced_value_forward.h"
namespace base {
namespace sequence_manager {
@@ -39,7 +41,6 @@ class TaskQueue;
} // namespace sequence_manager
namespace trace_event {
class BlameContext;
-class TracedValue;
} // namespace trace_event
} // namespace base
@@ -132,7 +133,6 @@ class PLATFORM_EXPORT FrameSchedulerImpl : public FrameScheduler,
// created by an SVGImage). Virtual for testing.
virtual bool IsOrdinary() const;
- void AsValueInto(base::trace_event::TracedValue* state) const;
bool IsExemptFromBudgetBasedThrottling() const override;
std::unique_ptr<blink::mojom::blink::PauseSubresourceLoadingHandle>
GetPauseSubresourceLoadingHandle() override;
@@ -203,6 +203,8 @@ class PLATFORM_EXPORT FrameSchedulerImpl : public FrameScheduler,
const base::UnguessableToken& GetAgentClusterId() const;
+ void WriteIntoTracedValue(perfetto::TracedValue context) const;
+
protected:
FrameSchedulerImpl(MainThreadSchedulerImpl* main_thread_scheduler,
PageSchedulerImpl* parent_page_scheduler,
@@ -258,11 +260,6 @@ class PLATFORM_EXPORT FrameSchedulerImpl : public FrameScheduler,
void UpdateQueuePolicy(
MainThreadTaskQueue* queue,
base::sequence_manager::TaskQueue::QueueEnabledVoter* voter);
- // Update throttling for |task_queue|. This changes the throttling ref counts
- // and should only be called for new queues if throttling is enabled, or if
- // the throttling state changes.
- void UpdateTaskQueueThrottling(MainThreadTaskQueue* task_queue,
- bool should_throttle);
void AddPauseSubresourceLoadingHandle();
void RemovePauseSubresourceLoadingHandle();
@@ -341,6 +338,7 @@ class PLATFORM_EXPORT FrameSchedulerImpl : public FrameScheduler,
TraceableState<bool, TracingCategoryName::kInfo> subresource_loading_paused_;
StateTracer<TracingCategoryName::kInfo> url_tracer_;
TraceableState<bool, TracingCategoryName::kInfo> task_queues_throttled_;
+ Vector<MainThreadTaskQueue::ThrottleHandle> throttled_task_queue_handles_;
TraceableState<bool, TracingCategoryName::kInfo>
preempted_for_cooperative_scheduling_;
// TODO(https://crbug.com/827113): Trace the count of opt-outs.
@@ -376,6 +374,8 @@ class PLATFORM_EXPORT FrameSchedulerImpl : public FrameScheduler,
TraceableState<bool, TracingCategoryName::kInfo>
waiting_for_meaningful_paint_;
+ std::unique_ptr<power_scheduler::PowerModeVoter> loading_power_mode_voter_;
+
// TODO(altimin): Remove after we have have 1:1 relationship between frames
// and documents.
base::WeakPtrFactory<FrameSchedulerImpl> document_bound_weak_factory_{this};