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

Issue 2529353002: [wrapper-tracing] Avoid GC during PostMessageTimer construction (Closed)

Created:
4 years ago by Michael Lippautz
Modified:
4 years ago
Reviewers:
haraken, sof, Marcel Hlopko
CC:
blink-reviews, chromium-reviews
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[wrapper-tracing] Avoid GC during PostMessageTimer construction BUG=chromium:668742, chromium:668059, chromium:668060 Committed: https://crrev.com/ca07ee393934e403d0bb2e0d8790d8edbbe3df96 Cr-Commit-Position: refs/heads/master@{#434638}

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+4 lines, -3 lines) Patch
M third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp View 1 chunk +4 lines, -3 lines 2 comments Download

Messages

Total messages: 25 (13 generated)
Michael Lippautz
This one should deal with the vast majority of CHECK failures on current Canaries.
4 years ago (2016-11-28 10:35:09 UTC) #5
Michael Lippautz
On 2016/11/28 10:35:09, Michael Lippautz wrote: > This one should deal with the vast majority ...
4 years ago (2016-11-28 10:35:21 UTC) #6
Marcel Hlopko
LGTM, that must've been hard to spot!
4 years ago (2016-11-28 10:39:12 UTC) #7
haraken
LGTM That said, we should add a more generic mechanism to avoid triggering an incremental ...
4 years ago (2016-11-28 10:56:26 UTC) #10
Michael Lippautz
On 2016/11/28 10:56:26, haraken wrote: > LGTM > > That said, we should add a ...
4 years ago (2016-11-28 11:48:04 UTC) #11
haraken
On 2016/11/28 11:48:04, Michael Lippautz wrote: > On 2016/11/28 10:56:26, haraken wrote: > > LGTM ...
4 years ago (2016-11-28 11:55:17 UTC) #12
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/2529353002/1
4 years ago (2016-11-28 12:04:11 UTC) #16
Michael Lippautz
On 2016/11/28 11:55:17, haraken wrote: > On 2016/11/28 11:48:04, Michael Lippautz wrote: > > On ...
4 years ago (2016-11-28 12:06:06 UTC) #17
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years ago (2016-11-28 12:07:52 UTC) #20
commit-bot: I haz the power
Patchset 1 (id:??) landed as https://crrev.com/ca07ee393934e403d0bb2e0d8790d8edbbe3df96 Cr-Commit-Position: refs/heads/master@{#434638}
4 years ago (2016-11-28 12:12:26 UTC) #22
sof
https://codereview.chromium.org/2529353002/diff/1/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp File third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp (right): https://codereview.chromium.org/2529353002/diff/1/third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp#newcode628 third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp:628: std::unique_ptr<SourceLocation> location = SourceLocation::capture(source); Subtle staging of allocations going ...
4 years ago (2016-11-29 09:15:45 UTC) #24
Michael Lippautz
4 years ago (2016-11-29 09:51:41 UTC) #25
Message was sent while issue was closed.
https://codereview.chromium.org/2529353002/diff/1/third_party/WebKit/Source/c...
File third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp (right):

https://codereview.chromium.org/2529353002/diff/1/third_party/WebKit/Source/c...
third_party/WebKit/Source/core/frame/LocalDOMWindow.cpp:628:
std::unique_ptr<SourceLocation> location = SourceLocation::capture(source);
On 2016/11/29 09:15:44, sof wrote:
> Subtle staging of allocations going on here wrt 'new'; an explanatory comment
> covering why the allocation needs to be lifted out, would have been helpful.
> 

Sorry, for not leaving a comment. The rationale is that we cannot call into V8
from a gcForbidden scope, because V8 can now trace through blink, effectively
requiring some of its marking infrastructure.

> Even better, following the standard pattern of having a create() factory
method
> would have prevented the problem from arising, i think.

I will add (D)CHECKs that would immediately fail (even without triggering a GC)
when calling into V8 from such scopes. Only those call sites require
refactoring. 

Using ::create might mitigate this scenario, but people could still call it from
ctors before vtable poitners are available.

Powered by Google App Engine
This is Rietveld 408576698