Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(123)

Issue 2530493003: V4L2VDA: do not allocate input buffers in GPU child thread. (Closed)

Created:
4 years ago by wuchengli
Modified:
4 years ago
Reviewers:
Owen Lin, kcwu, Pawel Osciak
CC:
chromium-reviews, posciak+watch_chromium.org, piman+watch_chromium.org, feature-media-reviews_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

V4L2VDA: do not allocate input buffers in GPU child thread. Allocating input buffers can be very slow. Doing it in GPU child thread can cause gpu process watchdog timeout. Move it to decoder thread. BUG=chrome-os-partner:56452 TEST=Run VDA unittest and play video. CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Committed: https://crrev.com/f160854f267cb8bc627b2043182d11161eb478f2 Cr-Commit-Position: refs/heads/master@{#434910}

Patch Set 1 #

Total comments: 4

Patch Set 2 : address Pawel's comments #

Total comments: 5

Patch Set 3 : address Kuang-che's comments #

Total comments: 2

Patch Set 4 : address Kuang-che's comment #

Total comments: 2

Patch Set 5 : address Kuang-che's comment #

Unified diffs Side-by-side diffs Delta from patch set Stats (+29 lines, -15 lines) Patch
M media/gpu/v4l2_video_decode_accelerator.h View 1 2 3 4 1 chunk +3 lines, -0 lines 0 comments Download
M media/gpu/v4l2_video_decode_accelerator.cc View 1 2 3 3 chunks +26 lines, -15 lines 0 comments Download

Messages

Total messages: 27 (9 generated)
wuchengli
PTAL.
4 years ago (2016-11-24 07:25:46 UTC) #3
wuchengli
V4L2SVDA already allocates in decoder thread. This changes V4L2VDA to be the same as V4L2SVDA.
4 years ago (2016-11-24 07:28:32 UTC) #5
Owen Lin
lgtm % 1 nit. https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc#newcode313 media/gpu/v4l2_video_decode_accelerator.cc:313: if (!StartDevicePoll()) Add a comment ...
4 years ago (2016-11-24 07:44:23 UTC) #6
wuchengli
https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc#newcode313 media/gpu/v4l2_video_decode_accelerator.cc:313: if (!StartDevicePoll()) On 2016/11/24 07:44:23, Owen Lin wrote: > ...
4 years ago (2016-11-24 08:20:09 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2530493003/1
4 years ago (2016-11-24 08:20:45 UTC) #9
Pawel Osciak
https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc#newcode287 media/gpu/v4l2_video_decode_accelerator.cc:287: decoder_cmd_supported_ = IsDecoderCmdSupported(); Could this and the subscribe event ...
4 years ago (2016-11-24 08:28:35 UTC) #10
wuchengli
PTAL. https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/1/media/gpu/v4l2_video_decode_accelerator.cc#newcode287 media/gpu/v4l2_video_decode_accelerator.cc:287: decoder_cmd_supported_ = IsDecoderCmdSupported(); On 2016/11/24 08:28:35, Pawel Osciak ...
4 years ago (2016-11-28 06:13:58 UTC) #12
kcwu
https://codereview.chromium.org/2530493003/diff/20001/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/20001/media/gpu/v4l2_video_decode_accelerator.cc#newcode206 media/gpu/v4l2_video_decode_accelerator.cc:206: DCHECK_EQ(decoder_state_, kUninitialized); Two questions, 1. should we add kInitializing ...
4 years ago (2016-11-28 06:31:14 UTC) #13
wuchengli
https://codereview.chromium.org/2530493003/diff/20001/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/20001/media/gpu/v4l2_video_decode_accelerator.cc#newcode206 media/gpu/v4l2_video_decode_accelerator.cc:206: DCHECK_EQ(decoder_state_, kUninitialized); On 2016/11/28 06:31:14, kcwu wrote: > Two ...
4 years ago (2016-11-28 07:04:49 UTC) #14
wuchengli
Done. PTAL. https://codereview.chromium.org/2530493003/diff/20001/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/20001/media/gpu/v4l2_video_decode_accelerator.cc#newcode206 media/gpu/v4l2_video_decode_accelerator.cc:206: DCHECK_EQ(decoder_state_, kUninitialized); On 2016/11/28 07:04:49, wuchengli wrote: ...
4 years ago (2016-11-28 09:03:19 UTC) #15
kcwu
https://codereview.chromium.org/2530493003/diff/40001/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/40001/media/gpu/v4l2_video_decode_accelerator.cc#newcode300 media/gpu/v4l2_video_decode_accelerator.cc:300: DCHECK_EQ(decoder_state_, kUninitialized); You added line 286, then this DCHECK ...
4 years ago (2016-11-28 10:53:51 UTC) #16
wuchengli
Done. PTAL. https://codereview.chromium.org/2530493003/diff/40001/media/gpu/v4l2_video_decode_accelerator.cc File media/gpu/v4l2_video_decode_accelerator.cc (right): https://codereview.chromium.org/2530493003/diff/40001/media/gpu/v4l2_video_decode_accelerator.cc#newcode300 media/gpu/v4l2_video_decode_accelerator.cc:300: DCHECK_EQ(decoder_state_, kUninitialized); On 2016/11/28 10:53:51, kcwu wrote: ...
4 years ago (2016-11-28 12:58:16 UTC) #17
kcwu
lgtm; nits https://codereview.chromium.org/2530493003/diff/60001/media/gpu/v4l2_video_decode_accelerator.h File media/gpu/v4l2_video_decode_accelerator.h (right): https://codereview.chromium.org/2530493003/diff/60001/media/gpu/v4l2_video_decode_accelerator.h#newcode139 media/gpu/v4l2_video_decode_accelerator.h:139: kInitialized, // InitializeTask() succeeds; ready to start ...
4 years ago (2016-11-29 03:51:46 UTC) #18
wuchengli
https://codereview.chromium.org/2530493003/diff/60001/media/gpu/v4l2_video_decode_accelerator.h File media/gpu/v4l2_video_decode_accelerator.h (right): https://codereview.chromium.org/2530493003/diff/60001/media/gpu/v4l2_video_decode_accelerator.h#newcode139 media/gpu/v4l2_video_decode_accelerator.h:139: kInitialized, // InitializeTask() succeeds; ready to start decoding. On ...
4 years ago (2016-11-29 05:18:22 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2530493003/80001
4 years ago (2016-11-29 05:18:38 UTC) #22
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years ago (2016-11-29 06:18:13 UTC) #24
commit-bot: I haz the power
Patchset 5 (id:??) landed as https://crrev.com/f160854f267cb8bc627b2043182d11161eb478f2 Cr-Commit-Position: refs/heads/master@{#434910}
4 years ago (2016-11-29 06:19:47 UTC) #26
Daniel Kurtz
4 years ago (2016-11-29 06:52:24 UTC) #27
Message was sent while issue was closed.
On 2016/11/29 06:19:47, commit-bot: I haz the power wrote:
> Patchset 5 (id:??) landed as
> https://crrev.com/f160854f267cb8bc627b2043182d11161eb478f2
> Cr-Commit-Position: refs/heads/master@{#434910}

GPU process WDOG timeout occurs after 10 seconds.
It what scenario does allocating buffers take ~10 seconds?
What kind of buffers are we allocating here, how big are they, and how long does
it normally take?
How often do we allocate these buffers?

I guess what I am trying to ask is if this is exposing another issue where v4l2
buffer allocation is [always? sometimes?] super slow on elm.

Powered by Google App Engine
This is Rietveld 408576698