⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 286537 in webkit


Ignore:
Timestamp:
Dec 5, 2021, 8:40:19 PM (5 years ago)
Author:
Simon Fraser
Message:

Add trace points for generated momentum events
https://bugs.webkit.org/show_bug.cgi?id=233857

Reviewed by Tim Horton.

Source/WebKit:

Add start/end points for synthetic momentum, and a trace point for each generated event.

  • WebProcess/WebPage/MomentumEventDispatcher.cpp:

(WebKit::MomentumEventDispatcher::dispatchSyntheticMomentumEvent):
(WebKit::MomentumEventDispatcher::didStartMomentumPhase):
(WebKit::MomentumEventDispatcher::didEndMomentumPhase):

Source/WTF:

  • wtf/SystemTracing.h:

Tools:

Add start/end points for synthetic momentum, and a trace point for each generated event.

  • Tracing/SystemTracePoints.plist:
Location:
trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WTF/ChangeLog

    r286514 r286537  
     12021-12-05  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add trace points for generated momentum events
     4        https://bugs.webkit.org/show_bug.cgi?id=233857
     5
     6        Reviewed by Tim Horton.
     7
     8        * wtf/SystemTracing.h:
     9
    1102021-12-03  Chris Dumez  <cdumez@apple.com>
    211
  • trunk/Source/WTF/wtf/SystemTracing.h

    r277633 r286537  
    128128    TakeSnapshotStart,
    129129    TakeSnapshotEnd,
     130    SyntheticMomentumStart,
     131    SyntheticMomentumEnd,
     132    SyntheticMomentumEvent,
    130133
    131134    UIProcessRange = 14000,
  • trunk/Source/WebKit/ChangeLog

    r286535 r286537  
     12021-12-05  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add trace points for generated momentum events
     4        https://bugs.webkit.org/show_bug.cgi?id=233857
     5
     6        Reviewed by Tim Horton.
     7
     8        Add start/end points for synthetic momentum, and a trace point for each generated event.
     9
     10        * WebProcess/WebPage/MomentumEventDispatcher.cpp:
     11        (WebKit::MomentumEventDispatcher::dispatchSyntheticMomentumEvent):
     12        (WebKit::MomentumEventDispatcher::didStartMomentumPhase):
     13        (WebKit::MomentumEventDispatcher::didEndMomentumPhase):
     14
    1152021-12-04  Myles C. Maxfield  <mmaxfield@apple.com>
    216
  • trunk/Source/WebKit/WebProcess/WebPage/MomentumEventDispatcher.cpp

    r286512 r286537  
    3535#include <WebCore/DisplayRefreshMonitor.h>
    3636#include <WebCore/Scrollbar.h>
     37#include <wtf/SystemTracing.h>
    3738
    3839namespace WebKit {
     
    145146void MomentumEventDispatcher::dispatchSyntheticMomentumEvent(WebWheelEvent::Phase phase, WebCore::FloatSize delta)
    146147{
     148    tracePoint(SyntheticMomentumEvent, static_cast<uint64_t>(phase), std::abs(delta.width()), std::abs(delta.height()));
     149
    147150    ASSERT(m_currentGesture.active);
    148151    ASSERT(m_currentGesture.initiatingEvent);
     
    183186void MomentumEventDispatcher::didStartMomentumPhase(WebCore::PageIdentifier pageIdentifier, const WebWheelEvent& event)
    184187{
     188    tracePoint(SyntheticMomentumStart);
     189
    185190    auto momentumStartInterval = event.ioHIDEventTimestamp() - m_lastEndedEventTimestamp;
    186191
     
    224229
    225230    m_currentGesture = { };
     231    tracePoint(SyntheticMomentumEnd);
    226232}
    227233
  • trunk/Tools/ChangeLog

    r286536 r286537  
     12021-12-05  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Add trace points for generated momentum events
     4        https://bugs.webkit.org/show_bug.cgi?id=233857
     5
     6        Reviewed by Tim Horton.
     7
     8        Add start/end points for synthetic momentum, and a trace point for each generated event.
     9
     10        * Tracing/SystemTracePoints.plist:
     11
    1122021-12-04  Andres Gonzalez  <andresg_22@apple.com>
    213
  • trunk/Tools/Tracing/SystemTracePoints.plist

    r280859 r286537  
    597597             <dict>
    598598                 <key>Name</key>
     599                 <string>Synthetic momentum</string>
     600                 <key>Type</key>
     601                 <string>Interval</string>
     602                 <key>Component</key>
     603                 <string>47</string>
     604                 <key>CodeBegin</key>
     605                 <string>12025</string>
     606                 <key>CodeEnd</key>
     607                 <string>12026</string>
     608                 <key>ArgNamesEnd</key>
     609                 <dict>
     610                     <key>Arg1</key>
     611                     <string>Initial Velocity X</string>
     612                     <key>Arg2</key>
     613                     <string>Initial Velocity Y</string>
     614                 </dict>
     615             </dict>
     616             <dict>
     617                 <key>Name</key>
     618                 <string>Synthetic momentum event</string>
     619                 <key>Type</key>
     620                 <string>Level</string>
     621                 <key>Component</key>
     622                 <string>47</string>
     623                 <key>Code</key>
     624                 <string>12027</string>
     625                 <key>ArgNames</key>
     626                 <dict>
     627                     <key>Arg1</key>
     628                     <string>Phase</string>
     629                     <key>Arg2</key>
     630                     <string>Delta X</string>
     631                     <key>Arg3</key>
     632                     <string>Delta Y</string>
     633                 </dict>
     634                 <key>LevelArg</key>
     635                 <string>Arg3</string>
     636                 <key>LevelDataType</key>
     637                 <string>UInt64</string>
     638             </dict>
     639             <dict>
     640                 <key>Name</key>
    599641                 <string>Commit RemoteLayerTree transaction</string>
    600642                 <key>Type</key>
Note: See TracChangeset for help on using the changeset viewer.