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

Issue 2268183005: Worker: Refine state management of WorkerThread (Closed)

Created:
4 years, 4 months ago by nhiroki
Modified:
4 years, 3 months ago
Reviewers:
haraken, yhirano
CC:
chromium-reviews, blink-reviews, falken, kinuko+worker_chromium.org, blink-worker-reviews_chromium.org, horo+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Worker: Refine state management of WorkerThread This CL... 1) introduces ThreadState enum that represents a state of the worker thread, 2) stops accessing |m_globalScope| from the main thread for detecting worker thread initialization and instead checks ThreadState, 3) renames |m_started| and |m_terminated| with |m_requestedToStart| and |m_requestedToTerminate| in order to emphasize that these fields represent not a state of the worker thread but facts that the worker thread has been requested to start/terminate from the main thread, and 4) removes mention of |m_microtaskRunner| from a comment about |m_threadStateMutex| because the member is accessed only from the worker thread. BUG=638877, 640843 Committed: https://crrev.com/aefae76fee3afe6cc9eabbe5d06cde009d317c16 Cr-Commit-Position: refs/heads/master@{#414336}

Patch Set 1 #

Total comments: 2

Patch Set 2 : rebase #

Patch Set 3 : revert a change of the comment about m_threadStateMutex #

Patch Set 4 : remove TODO comment to avoid patch confliction #

Unified diffs Side-by-side diffs Delta from patch set Stats (+58 lines, -49 lines) Patch
M third_party/WebKit/Source/core/workers/WorkerThread.h View 1 2 3 2 chunks +16 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/workers/WorkerThread.cpp View 1 2 18 chunks +42 lines, -42 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 34 (22 generated)
nhiroki
PTAL, thanks!
4 years, 4 months ago (2016-08-24 05:44:44 UTC) #13
haraken
https://codereview.chromium.org/2268183005/diff/60001/third_party/WebKit/Source/core/workers/WorkerThread.h File third_party/WebKit/Source/core/workers/WorkerThread.h (right): https://codereview.chromium.org/2268183005/diff/60001/third_party/WebKit/Source/core/workers/WorkerThread.h#newcode217 third_party/WebKit/Source/core/workers/WorkerThread.h:217: // - The main thread can read this with ...
4 years, 4 months ago (2016-08-24 06:07:44 UTC) #14
nhiroki
https://codereview.chromium.org/2268183005/diff/60001/third_party/WebKit/Source/core/workers/WorkerThread.h File third_party/WebKit/Source/core/workers/WorkerThread.h (right): https://codereview.chromium.org/2268183005/diff/60001/third_party/WebKit/Source/core/workers/WorkerThread.h#newcode217 third_party/WebKit/Source/core/workers/WorkerThread.h:217: // - The main thread can read this with ...
4 years, 4 months ago (2016-08-24 08:14:05 UTC) #17
haraken
On 2016/08/24 08:14:05, nhiroki wrote: > https://codereview.chromium.org/2268183005/diff/60001/third_party/WebKit/Source/core/workers/WorkerThread.h > File third_party/WebKit/Source/core/workers/WorkerThread.h (right): > > https://codereview.chromium.org/2268183005/diff/60001/third_party/WebKit/Source/core/workers/WorkerThread.h#newcode217 > ...
4 years, 4 months ago (2016-08-24 10:50:22 UTC) #18
nhiroki
JFYI: > 4) updates a comment about |m_threadStateMutex| as follows: > - Mention of |m_microtaskRunner| ...
4 years, 4 months ago (2016-08-25 01:11:18 UTC) #19
yhirano
lgtm
4 years, 4 months ago (2016-08-25 01:21:00 UTC) #21
nhiroki
Thank you for reviewing :)
4 years, 4 months ago (2016-08-25 01:29:27 UTC) #22
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/2268183005/120001
4 years, 4 months ago (2016-08-25 01:31:24 UTC) #26
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_x64_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_x64_rel_ng/builds/268300)
4 years, 3 months ago (2016-08-25 04:03:18 UTC) #28
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/2268183005/120001
4 years, 3 months ago (2016-08-25 04:11:47 UTC) #30
commit-bot: I haz the power
Committed patchset #4 (id:120001)
4 years, 3 months ago (2016-08-25 06:13:05 UTC) #32
commit-bot: I haz the power
4 years, 3 months ago (2016-08-25 06:15:15 UTC) #34
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/aefae76fee3afe6cc9eabbe5d06cde009d317c16
Cr-Commit-Position: refs/heads/master@{#414336}

Powered by Google App Engine
This is Rietveld 408576698