[webkit-changes] [WebKit/WebKit] 3fb057: tracePoint(ScheduleRenderingUpdate) should not be ...

Antti Koivisto noreply at github.com
Tue Jul 4 23:17:46 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 3fb0572dade240e736dff2250c248bd680bd58be
      https://github.com/WebKit/WebKit/commit/3fb0572dade240e736dff2250c248bd680bd58be
  Author: Antti Koivisto <antti at apple.com>
  Date:   2023-07-04 (Tue, 04 Jul 2023)

  Changed paths:
    M Source/WebCore/page/RenderingUpdateScheduler.cpp
    M Source/WebCore/page/RenderingUpdateScheduler.h

  Log Message:
  -----------
  tracePoint(ScheduleRenderingUpdate) should not be invoked if there is a scheduled rendering update already
https://bugs.webkit.org/show_bug.cgi?id=258849
rdar://110032497

Reviewed by Simon Fraser.

Firing tracepoints is not free, especially on non-production kernels.

* Source/WebCore/page/RenderingUpdateScheduler.cpp:
(WebCore::RenderingUpdateScheduler::adjustRenderingUpdateFrequency):
(WebCore::RenderingUpdateScheduler::isScheduled const):

Make isScheduled() work in all cases, not just for the timer fallback.
This way we bail out early if there a scheduled update already.

(WebCore::RenderingUpdateScheduler::startTimer):

Get rid of the unneeded and confusing m_scheduled bit.

(WebCore::RenderingUpdateScheduler::clearScheduled):
* Source/WebCore/page/RenderingUpdateScheduler.h:

Canonical link: https://commits.webkit.org/265761@main




More information about the webkit-changes mailing list