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

Issue 1369213002: Revert of Replace RawPtr with RefPtr on StylePendingImage (Closed)

Created:
5 years, 2 months ago by alancutter (OOO until 2018)
Modified:
5 years, 2 months ago
Reviewers:
Timothy Loh
CC:
blink-reviews, dglazkov
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Revert of Replace RawPtr with RefPtr on StylePendingImage (patchset #2 id:20001 of https://codereview.chromium.org/1368613002/ ) Reason for revert: Causing crashes in Canary. BUG=536655 Original issue's description: > Replace RawPtr with RefPtr on StylePendingImage > > This change ensures StylePendingImages set on ComputedStyles will keep > their corresponding CSSValue alive. > The PendingImagePropertyMap on ElementStyleResources was supposed to do > this however it only keeps alive one per property while properties can > have any number of images set on them (background-image). > > Prior to this change StylePendingImages held a RawPtr to their CSSValue > to avoid a ref loop because the CSSValue would hold a RefPtr to the > StylePendingImage as a cache. > > After this change StylePendingImages hold RefPtrs to their CSSValue > while CSSValues no longer cache StylePendingImages. Having multiple > StylePendingImages per CSSValue is equivalent to using cached > StylePendingImages as no state changes on the StylePendingImage > during the StyleResourceLoader pass. > > The old scenario is not currently a problem as all applied CSSValues > have their refs held elsewhere (style rules or AnimatableImages). > Future animation work intends to apply temporary CSSValue images and > must ensure StylePendingImages keep a ref to avoid a use after free. > > This patch is a refactor towards memory management correctness and has > no behavioural changes. > > BUG=437696 > > Committed: https://crrev.com/1dd18b7ea8db7d3344024277e04c8a5365c03cf1 > Cr-Commit-Position: refs/heads/master@{#350808} TBR=timloh@chromium.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=437696 Committed: https://crrev.com/950c0aca627fca67413569326c7eaec09c8ffa5d Cr-Commit-Position: refs/heads/master@{#351024}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+163 lines, -143 lines) Patch
M third_party/WebKit/Source/core/css/CSSCrossfadeValue.cpp View 2 chunks +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSCursorImageValue.h View 2 chunks +4 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSCursorImageValue.cpp View 6 chunks +32 lines, -36 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSImageSetValue.h View 3 chunks +14 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSImageSetValue.cpp View 5 chunks +38 lines, -32 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSImageValue.h View 3 chunks +7 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/css/CSSImageValue.cpp View 7 chunks +24 lines, -15 lines 0 comments Download
M third_party/WebKit/Source/core/css/resolver/ElementStyleResources.h View 3 chunks +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/css/resolver/ElementStyleResources.cpp View 2 chunks +16 lines, -16 lines 0 comments Download
M third_party/WebKit/Source/core/css/resolver/StyleResourceLoader.cpp View 3 chunks +15 lines, -10 lines 0 comments Download
M third_party/WebKit/Source/core/page/PageSerializer.cpp View 1 chunk +2 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/style/StylePendingImage.h View 3 chunks +6 lines, -6 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
alancutter (OOO until 2018)
Created Revert of Replace RawPtr with RefPtr on StylePendingImage
5 years, 2 months ago (2015-09-28 04:58:49 UTC) #1
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1369213002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1369213002/1
5 years, 2 months ago (2015-09-28 04:59:05 UTC) #2
commit-bot: I haz the power
Committed patchset #1 (id:1)
5 years, 2 months ago (2015-09-28 04:59:55 UTC) #3
commit-bot: I haz the power
5 years, 2 months ago (2015-09-28 05:01:09 UTC) #4
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/950c0aca627fca67413569326c7eaec09c8ffa5d
Cr-Commit-Position: refs/heads/master@{#351024}

Powered by Google App Engine
This is Rietveld 408576698