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

Issue 7316015: Support Closure in ALL the loops! (Closed)

Created:
9 years, 5 months ago by awong
Modified:
9 years, 5 months ago
CC:
chromium-reviews, Paweł Hajdan Jr., brettw-cc_chromium.org
Visibility:
Public.

Description

Support Closure in ALL the loops! Add an overload for PostTask into MessageLoopProxy, and WorkerPool. BUG=35223 TEST=unittests. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=94129

Patch Set 1 #

Patch Set 2 : worker pool for windows #

Patch Set 3 : BrowserThreads are go! #

Patch Set 4 : win fix #

Patch Set 5 : small cleanups #

Patch Set 6 : cleanup idle wait. #

Total comments: 10

Patch Set 7 : Address Darin's comments and make refcounted threadsafe. #

Patch Set 8 : fix typo #

Total comments: 26

Patch Set 9 : Address Will's coments. #

Patch Set 10 : Test no tally at death #

Patch Set 11 : blah #

Patch Set 12 : I AM NOT A NUMBER TO BE TALLIED (remove all object tracking for right now). #

Total comments: 9

Patch Set 13 : reenable tracking the birth #

Patch Set 14 : object tracking removed. addressed will's comments #

Patch Set 15 : another change #

Patch Set 16 : clangity clang clang #

Patch Set 17 : rebased #

Total comments: 3

Patch Set 18 : Address Will's comments #

Patch Set 19 : win compile fix #

Total comments: 6

Patch Set 20 : addressed nit and rebased. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+441 lines, -123 lines) Patch
M base/message_loop.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 7 chunks +16 lines, -55 lines 0 comments Download
M base/message_loop_proxy.h View 1 2 3 4 5 6 7 8 2 chunks +23 lines, -1 line 0 comments Download
M base/message_loop_proxy_impl.h View 1 2 3 4 5 6 7 8 3 chunks +21 lines, -3 lines 0 comments Download
M base/message_loop_proxy_impl.cc View 1 2 3 4 5 6 7 2 chunks +40 lines, -0 lines 0 comments Download
M base/message_loop_proxy_impl_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 6 chunks +44 lines, -4 lines 0 comments Download
M base/task.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 1 chunk +38 lines, -0 lines 0 comments Download
M base/task.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +29 lines, -0 lines 0 comments Download
M base/threading/worker_pool.h View 2 chunks +6 lines, -0 lines 0 comments Download
M base/threading/worker_pool_posix.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 4 chunks +30 lines, -4 lines 0 comments Download
M base/threading/worker_pool_posix.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 7 chunks +72 lines, -30 lines 0 comments Download
M base/threading/worker_pool_posix_unittest.cc View 6 chunks +17 lines, -15 lines 0 comments Download
M base/threading/worker_pool_win.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +54 lines, -11 lines 0 comments Download
M base/tracked_objects.h View 1 2 3 4 5 6 7 8 1 chunk +7 lines, -0 lines 0 comments Download
M base/tracked_objects.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +20 lines, -0 lines 0 comments Download
M content/browser/browser_thread.cc View 1 2 3 4 1 chunk +24 lines, -0 lines 0 comments Download

Messages

Total messages: 20 (0 generated)
awong
Add in PostTask to MessageLoopProxy and WorkerPool.
9 years, 5 months ago (2011-07-07 21:20:10 UTC) #1
darin (slow to review)
http://codereview.chromium.org/7316015/diff/7001/base/message_loop_proxy_impl.cc File base/message_loop_proxy_impl.cc (right): http://codereview.chromium.org/7316015/diff/7001/base/message_loop_proxy_impl.cc#newcode133 base/message_loop_proxy_impl.cc:133: { the extra nesting here can be removed. it ...
9 years, 5 months ago (2011-07-07 21:54:01 UTC) #2
awong
Comments addressed. FYI, Mac tests seems to be consistently failing on this change due to ...
9 years, 5 months ago (2011-07-08 00:38:39 UTC) #3
willchan no longer on Chromium
I'm not sure if my analysis of the LazyInstance bug is 100% spot on, but ...
9 years, 5 months ago (2011-07-08 12:04:21 UTC) #4
awong
Doing test on try servers with death tally code removed now. http://codereview.chromium.org/7316015/diff/6022/base/message_loop_proxy.h File base/message_loop_proxy.h (right): ...
9 years, 5 months ago (2011-07-08 18:36:51 UTC) #5
willchan no longer on Chromium
http://codereview.chromium.org/7316015/diff/6022/base/message_loop_proxy_impl_unittest.cc File base/message_loop_proxy_impl_unittest.cc (right): http://codereview.chromium.org/7316015/diff/6022/base/message_loop_proxy_impl_unittest.cc#newcode8 base/message_loop_proxy_impl_unittest.cc:8: #include "base/message_loop_proxy_impl.h" On 2011/07/08 18:36:51, awong wrote: > On ...
9 years, 5 months ago (2011-07-10 16:47:32 UTC) #6
akalin
You may want to fix the clang errors: http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=linux_clang&number=4251 (try job for my patch which ...
9 years, 5 months ago (2011-07-14 00:50:56 UTC) #7
awong
Okay, I gave up and just removed the object tracking code for right now. Any ...
9 years, 5 months ago (2011-07-14 23:03:30 UTC) #8
awong
ping...ready for another review.
9 years, 5 months ago (2011-07-18 19:49:54 UTC) #9
willchan no longer on Chromium
LGTM, actually I defer the controversial point to Darin :) http://codereview.chromium.org/7316015/diff/6022/base/message_loop_proxy_impl_unittest.cc File base/message_loop_proxy_impl_unittest.cc (right): http://codereview.chromium.org/7316015/diff/6022/base/message_loop_proxy_impl_unittest.cc#newcode8 ...
9 years, 5 months ago (2011-07-19 12:18:26 UTC) #10
awong
Addressed Will's comments. Darin, do you want to chime in on me killing object tracking ...
9 years, 5 months ago (2011-07-19 21:08:20 UTC) #11
akalin
http://codereview.chromium.org/7316015/diff/35001/base/message_loop_proxy.h File base/message_loop_proxy.h (right): http://codereview.chromium.org/7316015/diff/35001/base/message_loop_proxy.h#newcode11 base/message_loop_proxy.h:11: #include "base/callback.h" Can you remove this and instead forward-declare ...
9 years, 5 months ago (2011-07-20 07:52:03 UTC) #12
akalin
That should be: template <typename Sig> class Callback<Sig>; typedef Callback<void()> Closure;
9 years, 5 months ago (2011-07-20 07:52:43 UTC) #13
akalin
Or more correctly: template <typename Sig> class Callback<Sig>; typedef Callback<void(void)> Closure;
9 years, 5 months ago (2011-07-20 07:53:31 UTC) #14
akalin
On 2011/07/20 07:53:31, akalin wrote: > Or more correctly: > > template <typename Sig> class ...
9 years, 5 months ago (2011-07-20 07:54:06 UTC) #15
awong
Darin, soft ping. Note that this will block the WeakHandle CL. http://codereview.chromium.org/7316015/diff/35001/base/message_loop_proxy.h File base/message_loop_proxy.h (right): ...
9 years, 5 months ago (2011-07-20 21:17:41 UTC) #16
akalin
On 2011/07/20 21:17:41, awong wrote: > Darin, soft ping. LGTM Ping, Darin?
9 years, 5 months ago (2011-07-22 17:11:33 UTC) #17
darin (slow to review)
LGTM http://codereview.chromium.org/7316015/diff/35001/base/threading/worker_pool_posix.h File base/threading/worker_pool_posix.h (right): http://codereview.chromium.org/7316015/diff/35001/base/threading/worker_pool_posix.h#newcode44 base/threading/worker_pool_posix.h:44: class BASE_API PosixDynamicThreadPool note: this class name doesn't ...
9 years, 5 months ago (2011-07-25 19:47:37 UTC) #18
awong
thanks everyone! Going to run through try bots and then try to commit. http://codereview.chromium.org/7316015/diff/35001/base/threading/worker_pool_posix.h File ...
9 years, 5 months ago (2011-07-26 01:38:13 UTC) #19
commit-bot: I haz the power
9 years, 5 months ago (2011-07-26 18:25:19 UTC) #20
Change committed as 94129

Powered by Google App Engine
This is Rietveld 408576698