Commit ce582e32 authored by Miguel Casas's avatar Miguel Casas Committed by Commit Bot

media/gpu/vaapi: Add TRACE for Decode() call

The new direct Vaapi VideoDecoder doesn't have tracing, this CL adds the
first such meas, for the Decode() call, similar to
https://source.chromium.org/chromium/chromium/src/+/master:media/gpu/vaapi/vaapi_video_decode_accelerator.cc;l=446

Bug: 1040291
Change-Id: I25b70cecb48435cd5539cbf927c0f2547d584649
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2283249
Auto-Submit: Miguel Casas <mcasas@chromium.org>
Reviewed-by: default avatarMiguel Casas <mcasas@chromium.org>
Reviewed-by: default avatarHirokazu Honda <hiroh@chromium.org>
Commit-Queue: Hirokazu Honda <hiroh@chromium.org>
Cr-Commit-Position: refs/heads/master@{#785864}
parent c3772d7f
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
#include "base/bind.h" #include "base/bind.h"
#include "base/bind_helpers.h" #include "base/bind_helpers.h"
#include "base/memory/ptr_util.h" #include "base/memory/ptr_util.h"
#include "base/trace_event/trace_event.h"
#include "media/base/bind_to_current_loop.h" #include "media/base/bind_to_current_loop.h"
#include "media/base/format_utils.h" #include "media/base/format_utils.h"
#include "media/base/video_frame.h" #include "media/base/video_frame.h"
...@@ -222,7 +223,9 @@ void VaapiVideoDecoder::HandleDecodeTask() { ...@@ -222,7 +223,9 @@ void VaapiVideoDecoder::HandleDecodeTask() {
return; return;
} }
TRACE_EVENT_BEGIN0("media,gpu", "VaapiVideoDecoder::Decode");
AcceleratedVideoDecoder::DecodeResult decode_result = decoder_->Decode(); AcceleratedVideoDecoder::DecodeResult decode_result = decoder_->Decode();
TRACE_EVENT_END0("media,gpu", "VaapiVideoDecoder::Decode");
switch (decode_result) { switch (decode_result) {
case AcceleratedVideoDecoder::kRanOutOfStreamData: case AcceleratedVideoDecoder::kRanOutOfStreamData:
// Decoding was successful, notify client and try to schedule the next // Decoding was successful, notify client and try to schedule the next
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment