commit 2d48f93a48dde3764d68f02da10c67dfce7c891f
parent 29023a6ade3da48075f4084350fd61067f405fbc
Author: Karl Tomlinson <karlt+@karlt.net>
Date: Tue, 7 Oct 2025 20:25:46 +0000
Bug 1992922 Trace MediaTrackGraph advance even from ThreadedDriver r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D267730
Diffstat:
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/dom/media/GraphDriver.cpp b/dom/media/GraphDriver.cpp
@@ -942,10 +942,6 @@ long AudioCallbackDriver::DataCallback(const AudioDataValue* aInputBuffer,
GraphTime nextStateComputedTime =
MediaTrackGraphImpl::RoundUpToEndOfAudioBlock(mStateComputedTime +
mBuffer.Available());
- TRACE_AUDIO_CALLBACK_FRAME_COUNT("AudioCallbackDriver graph advance",
- nextStateComputedTime - mStateComputedTime,
- mSampleRate);
-
auto iterationStart = mIterationEnd;
// inGraph is the number of audio frames there is between the state time and
// the current time, i.e. the maximum theoretical length of the interval we
diff --git a/dom/media/MediaTrackGraph.cpp b/dom/media/MediaTrackGraph.cpp
@@ -1646,6 +1646,8 @@ auto MediaTrackGraphImpl::OneIterationImpl(
GraphTime aStateTime, GraphTime aIterationEnd,
MixerCallbackReceiver* aMixerReceiver) -> IterationResult {
TRACE("MTG::OneIterationImpl");
+ TRACE_AUDIO_CALLBACK_FRAME_COUNT(
+ "MTG graph advance", aStateTime - mStateComputedTime, mSampleRate);
if (SoftRealTimeLimitReached()) {
TRACE("MTG::Demoting real-time thread!");