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

Issue 2108163003: Fix dead-lock issue attempting to decode (Closed)

Created:
4 years, 5 months ago by scroggo
Modified:
4 years, 5 months ago
CC:
chromium-reviews, krit, pdr+graphicswatchlist_chromium.org, drott+blinkwatch_chromium.org, blink-reviews-platform-graphics_chromium.org, dshwang, jbroman, Justin Novosad, Rik, f(malita), blink-reviews, Stephen Chennney, ajuma+watch_chromium.org, danakj+watch_chromium.org, rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/src.git@componentBuild
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix dead-lock issue attempting to decode During serialization, if DecodingImageGenerator::onRefEncodedData() returns nullptr, this may require the serialization code to decode so it can have something to then encode and serialize. This can cause a deadlock if the DecodingImageGenerator is using discardable memory, which cannot be used from certain threads (where serialization may be occurring). Currently, onRefEncodedData() returns nullptr if !m_allDataReceived. This was to fix crbug.com/568016, but that has been further fixed by crrev.com/1970773002, which avoids calling onRefEncodedData() to pass it to the GPU, since even if m_allDataReceived is true, we do not yet support any GPU texture formats. This change returns the encoded data even if the data has not all been received, except if the GrContext argument is not NULL for the future when the GPU starts calling it again. This will result in serializing the existing data and avoid the deadlock. BUG=607227, 623475 Committed: https://crrev.com/7ba0aa90179d42ac4806386a88d50ed3778ae30b Cr-Commit-Position: refs/heads/master@{#402963}

Patch Set 1 #

Total comments: 4

Patch Set 2 : Add a TODO #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -1 line) Patch
M third_party/WebKit/Source/platform/graphics/DecodingImageGenerator.cpp View 1 1 chunk +13 lines, -1 line 0 comments Download

Messages

Total messages: 18 (8 generated)
scroggo_chromium
4 years, 5 months ago (2016-06-29 17:16:31 UTC) #2
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2108163003/1
4 years, 5 months ago (2016-06-29 17:17:48 UTC) #4
f(malita)
Thanks for fixing the regression, LGTM. I wonder whether there are other serialization cases which ...
4 years, 5 months ago (2016-06-29 17:38:38 UTC) #5
reed1
https://codereview.chromium.org/2108163003/diff/1/third_party/WebKit/Source/platform/graphics/DecodingImageGenerator.cpp File third_party/WebKit/Source/platform/graphics/DecodingImageGenerator.cpp (right): https://codereview.chromium.org/2108163003/diff/1/third_party/WebKit/Source/platform/graphics/DecodingImageGenerator.cpp#newcode60 third_party/WebKit/Source/platform/graphics/DecodingImageGenerator.cpp:60: // crbug.com/568016 for details about such a slowdown.) On ...
4 years, 5 months ago (2016-06-29 17:57:46 UTC) #7
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 5 months ago (2016-06-29 18:36:19 UTC) #9
scroggo_chromium
On 2016/06/29 17:38:38, f(malita) wrote: > Thanks for fixing the regression, LGTM. > > I ...
4 years, 5 months ago (2016-06-29 19:21:21 UTC) #10
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/2108163003/20001
4 years, 5 months ago (2016-06-29 19:22:16 UTC) #13
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 5 months ago (2016-06-29 22:36:23 UTC) #15
commit-bot: I haz the power
CQ bit was unchecked.
4 years, 5 months ago (2016-06-29 22:36:41 UTC) #16
commit-bot: I haz the power
4 years, 5 months ago (2016-06-29 22:37:37 UTC) #18
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/7ba0aa90179d42ac4806386a88d50ed3778ae30b
Cr-Commit-Position: refs/heads/master@{#402963}

Powered by Google App Engine
This is Rietveld 408576698