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

Issue 1502093002: Improve ScriptForbiddenScope handling in cross-threaded code. (Closed)

Created:
5 years ago by sof
Modified:
5 years ago
Reviewers:
oilpan-reviews, haraken
CC:
chromium-reviews, oilpan-reviews, Mads Ager (chromium), blink-reviews-bindings_chromium.org, blink-reviews, kouhei+heap_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Improve ScriptForbiddenScope handling in cross-threaded code. For code that is used by multiple threads, we currently have to resort to explicit main thread checks and manually adjust script forbidden counts depending. Introduce ScriptForbiddenIfMainThreadScope that reliably takes care of the details instead, entering&leaving a script forbidden scope iff on the main thread. R=haraken BUG= Committed: https://crrev.com/ac80984e24fa520ca86ad9fd0954bd00fbcf075a Cr-Commit-Position: refs/heads/master@{#363454}

Patch Set 1 #

Patch Set 2 : remove unnecessary include #

Total comments: 2

Patch Set 3 : rebased up past r363426 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+47 lines, -52 lines) Patch
M third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp View 1 chunk +1 line, -2 lines 0 comments Download
M third_party/WebKit/Source/platform/ScriptForbiddenScope.h View 1 2 chunks +18 lines, -1 line 0 comments Download
M third_party/WebKit/Source/platform/ScriptForbiddenScope.cpp View 2 chunks +13 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/Heap.cpp View 1 2 2 chunks +1 line, -6 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/HeapPage.cpp View 1 chunk +3 lines, -9 lines 0 comments Download
M third_party/WebKit/Source/platform/heap/ThreadState.cpp View 1 2 9 chunks +11 lines, -29 lines 0 comments Download

Messages

Total messages: 21 (12 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1502093002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1502093002/20001
5 years ago (2015-12-06 16:04:28 UTC) #3
sof
please take a look.
5 years ago (2015-12-06 16:04:47 UTC) #5
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/150729)
5 years ago (2015-12-06 17:35:46 UTC) #7
haraken
LGTM https://codereview.chromium.org/1502093002/diff/20001/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp File third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp (right): https://codereview.chromium.org/1502093002/diff/20001/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp#newcode285 third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp:285: ScriptForbiddenScope::enter(); Don't we want to use ScriptForbiddenIfMainThreadScope?
5 years ago (2015-12-06 23:12:28 UTC) #9
sof
https://codereview.chromium.org/1502093002/diff/20001/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp File third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp (right): https://codereview.chromium.org/1502093002/diff/20001/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp#newcode285 third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp:285: ScriptForbiddenScope::enter(); On 2015/12/06 23:12:28, haraken wrote: > > Don't ...
5 years ago (2015-12-07 05:59:17 UTC) #10
haraken
On 2015/12/07 05:59:17, sof wrote: > https://codereview.chromium.org/1502093002/diff/20001/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp > File third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp (right): > > https://codereview.chromium.org/1502093002/diff/20001/third_party/WebKit/Source/bindings/core/v8/V8GCController.cpp#newcode285 > ...
5 years ago (2015-12-07 06:00:13 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1502093002/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1502093002/40001
5 years ago (2015-12-07 10:47:49 UTC) #17
commit-bot: I haz the power
Committed patchset #3 (id:40001)
5 years ago (2015-12-07 11:57:00 UTC) #19
commit-bot: I haz the power
5 years ago (2015-12-07 11:58:22 UTC) #21
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/ac80984e24fa520ca86ad9fd0954bd00fbcf075a
Cr-Commit-Position: refs/heads/master@{#363454}

Powered by Google App Engine
This is Rietveld 408576698