Skip to content

Add experimental Media Performance Workloads - #582

Open
SyedAbuTalib wants to merge 1 commit into
WebKit:mainfrom
SyedAbuTalib:add-media-performance-workloads
Open

SyedAbuTalib wants to merge 1 commit into
WebKit:mainfrom
SyedAbuTalib:add-media-performance-workloads

Conversation

@SyedAbuTalib

@SyedAbuTalib SyedAbuTalib commented Aug 10, 2026 •

Copy link
Copy Markdown

This benchmark suite measures the performance, responsiveness, and processing throughput of modern web media APIs.


1. Media-Streaming (streaming.html / streaming.js)

InitialPlayback

Tests standard video playback initialization latency via Media Source Extensions (MSE) to simulate typical streaming user journeys on platforms like YouTube or Vimeo. The time measured is from the initial-playback step starting until the first video frame is decoded and verified via canvas pixel readback.

Seek

Measures the latency of performing a quick skip-ahead action within an already loaded media stream. This simulates a common user interaction, such as scrubbing through a video timeline or double-tapping right to skip forward on a streaming platform. The time measured is from the seek step starting until the target video frame is decoded and verified via canvas pixel readback.


2. Media-Conferencing (conferencing.html / conferencing.js)

VideoChat

Tests real-time video encoding and decoding pipelines using WebCodecs. While the UI simulates a Video Chat call, WebRTC is not tested; the focus is purely on measuring VideoEncoder and VideoDecoder throughput. The time measured is from the video-benchmark button clicked until all video frames have been encoded, decoded, and the session is torn down.

VoiceChat

Tests real-time audio encoding, decoding using WebCodecs and audio routing and effects processing using WebAudio. It measures the browser's efficiency in processing audio streams and applying standard audio nodes. The time measured is from the voice-benchmark button clicked until all audio frames have been encoded/decoded and the WebAudio offline rendering completes.

@netlify

netlify Bot commented Aug 10, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for webkit-speedometer-preview ready!

Name Link
🔨 Latest commit e7f55a5
🔍 Latest deploy log https://app.netlify.com/projects/webkit-speedometer-preview/deploys/6ac4069ce166fa0008c03148
😎 Deploy Preview https://deploy-preview-582--webkit-speedometer-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@SyedAbuTalib
SyedAbuTalib force-pushed the add-media-performance-workloads branch from 9dc7045 to c0c708e Compare August 10, 2026 21:30
@camillobruni

Copy link
Copy Markdown
Contributor

The media-streaming workload does not seem to work on safari:

Unhandled Promise Rejection: NotAllowedError: The request is not allowed by the user agent or the platform in the current context, possibly because the user denied permission.
Screenshot 2026-08-18 at 12 04 53

Could we figure out a mode that makes it possible to work out of the box there too?

Comment thread suites-experimental/suites.mjs Outdated
else
video.requestVideoFrameCallback(checkFrame);
};
video.requestVideoFrameCallback(checkFrame);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I interpret this correctly, requestVideoFrameCallback is likey display refresh-rate bound? [1]

One thing to bear in mind is that requestVideoFrameCallback() does not offer any strict guarantees that the output from your callback will remain in sync with the video frame rate. It may end up being fired one vertical synchronization (v-sync) later than when the new video frame was presented. (V-sync is a graphics technology that synchronizes the frame rate of a video with the refresh rate of a monitor.)

If this is the case we need to find another way to measure this. Speedometer is menat to be refresh-rate agnositc for the measurement part.

[1] https://developer.mozilla.org/en-US/docs/Web/API/HTMLVideoElement/requestVideoFrameCallback

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed to no longer use rVFC, but to use Canvas instead. Let me know what you think.

…ocessing throughput of modern web media APIs.

---

Tests standard video playback initialization latency via Media Source Extensions (MSE) to simulate typical streaming user journeys on platforms like YouTube or Vimeo. The time measured is from the `initial-playback` step starting until the first video frame is decoded and verified via canvas pixel readback.

Measures the latency of performing a quick skip-ahead action within an already loaded media stream. This simulates a common user interaction, such as scrubbing through a video timeline or double-tapping right to skip forward on a streaming platform. The time measured is from the `seek` step starting until the target video frame is decoded and verified via canvas pixel readback.

---

Tests real-time video encoding and decoding pipelines using WebCodecs. While the UI simulates a Video Chat call, WebRTC is not tested; the focus is purely on measuring VideoEncoder and VideoDecoder throughput. The time measured is from the `video-benchmark` button clicked until all video frames have been encoded, decoded, and the session is torn down.

Tests real-time audio encoding, decoding using WebCodecs and audio routing and effects processing using WebAudio. It measures the browser's efficiency in processing audio streams and applying standard audio nodes. The two stages run sequentially in a simulated media pipeline: audio routing and effects processing complete via WebAudio, and the resulting rendered audio buffer is directly encoded and decoded via WebCodecs. The time measured is from the `voice-benchmark` button clicked until all audio frames have been encoded/decoded and the WebAudio offline rendering completes.
@SyedAbuTalib
SyedAbuTalib force-pushed the add-media-performance-workloads branch from 5fe7286 to e7f55a5 Compare October 5, 2026 20:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants