Chromium Code Reviews
[email protected] (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(138)

Issue 10910099: PPAPI: Make CompletionCallbacks work right on background threads. (Closed)

Created:
8 years, 3 months ago by dmichael (off chromium)
Modified:
8 years, 1 month ago
Reviewers:
teravest, brettw
CC:
chromium-reviews, teravest
Visibility:
Public.

Description

PPAPI: Make CompletionCallbacks work right on background threads. Now, TrackedCallback::Run will: -Run the callback immediately if it is on the right thread. -PostRun to the correct thread if it is not. This was preceded by https://chromiumcodereview.appspot.com/10909244/, which removed ClearAndRun and does some other little cleanups to TrackedCallback to make it usable on background threads. BUG=92909 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=166719

Patch Set 1 : Add ppb_message_loop_shared.cc/.h #

Total comments: 23

Patch Set 2 : review comments #

Patch Set 3 : Review comments + better documentation for PP_CompletionCallback. #

Patch Set 4 : Merged. #

Patch Set 5 : Export PPB_MessageLoop_API #

Patch Set 6 : merge #

Unified diffs Side-by-side diffs Delta from patch set Stats (+450 lines, -116 lines) Patch
M ppapi/api/pp_completion_callback.idl View 1 2 3 chunks +69 lines, -19 lines 0 comments Download
M ppapi/c/pp_completion_callback.h View 1 2 5 chunks +69 lines, -19 lines 0 comments Download
M ppapi/cpp/completion_callback.h View 1 2 2 chunks +2 lines, -1 line 0 comments Download
M ppapi/cpp/resource.h View 1 1 chunk +4 lines, -0 lines 0 comments Download
M ppapi/native_client/src/untrusted/pnacl_irt_shim/pnacl_shim.c View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ppapi/ppapi_shared.gypi View 1 chunk +2 lines, -0 lines 0 comments Download
M ppapi/proxy/plugin_globals.h View 1 chunk +1 line, -0 lines 0 comments Download
M ppapi/proxy/plugin_globals.cc View 1 chunk +4 lines, -0 lines 0 comments Download
M ppapi/proxy/ppb_message_loop_proxy.h View 4 chunks +7 lines, -7 lines 0 comments Download
M ppapi/proxy/ppb_message_loop_proxy.cc View 1 4 chunks +19 lines, -17 lines 0 comments Download
M ppapi/proxy/ppb_testing_proxy.cc View 1 chunk +4 lines, -2 lines 0 comments Download
M ppapi/shared_impl/ppapi_globals.h View 1 6 chunks +12 lines, -5 lines 0 comments Download
M ppapi/shared_impl/ppapi_globals.cc View 2 chunks +3 lines, -3 lines 0 comments Download
A ppapi/shared_impl/ppb_message_loop_shared.h View 1 1 chunk +52 lines, -0 lines 0 comments Download
A ppapi/shared_impl/ppb_message_loop_shared.cc View 1 chunk +20 lines, -0 lines 0 comments Download
M ppapi/shared_impl/test_globals.h View 1 chunk +4 lines, -0 lines 0 comments Download
M ppapi/shared_impl/test_globals.cc View 1 chunk +10 lines, -0 lines 0 comments Download
M ppapi/shared_impl/tracked_callback.h View 4 chunks +9 lines, -1 line 0 comments Download
M ppapi/shared_impl/tracked_callback.cc View 1 2 6 chunks +50 lines, -12 lines 0 comments Download
M ppapi/tests/test_case.h View 6 chunks +19 lines, -6 lines 0 comments Download
M ppapi/tests/test_utils.h View 3 chunks +4 lines, -0 lines 0 comments Download
M ppapi/tests/test_utils.cc View 1 5 chunks +34 lines, -3 lines 0 comments Download
M ppapi/thunk/enter.cc View 3 chunks +44 lines, -19 lines 0 comments Download
M ppapi/thunk/ppb_message_loop_api.h View 1 2 3 4 2 chunks +2 lines, -1 line 0 comments Download
M webkit/plugins/ppapi/host_globals.h View 1 chunk +1 line, -0 lines 0 comments Download
M webkit/plugins/ppapi/host_globals.cc View 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 18 (0 generated)
dmichael (off chromium)
8 years, 3 months ago (2012-09-19 20:40:46 UTC) #1
dmichael (off chromium)
I think this is ready for review now. https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/thunk/enter.cc File ppapi/thunk/enter.cc (right): https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/thunk/enter.cc#newcode111 ppapi/thunk/enter.cc:111: CHECK(IsMainThread()); ...
8 years, 1 month ago (2012-11-06 22:49:39 UTC) #2
brettw
https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/proxy/ppb_message_loop_proxy.cc File ppapi/proxy/ppb_message_loop_proxy.cc (right): https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/proxy/ppb_message_loop_proxy.cc#newcode154 ppapi/proxy/ppb_message_loop_proxy.cc:154: return 0; I'd use NULL instead of 0. https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/proxy/ppb_message_loop_proxy.cc#newcode215 ...
8 years, 1 month ago (2012-11-06 23:16:28 UTC) #3
dmichael (off chromium)
https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/proxy/ppb_message_loop_proxy.cc File ppapi/proxy/ppb_message_loop_proxy.cc (right): https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/proxy/ppb_message_loop_proxy.cc#newcode154 ppapi/proxy/ppb_message_loop_proxy.cc:154: return 0; On 2012/11/06 23:16:28, brettw wrote: > I'd ...
8 years, 1 month ago (2012-11-06 23:39:26 UTC) #4
brettw
https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/thunk/enter.cc File ppapi/thunk/enter.cc (right): https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/thunk/enter.cc#newcode134 ppapi/thunk/enter.cc:134: // PP_OK_COMPLETIONPENDING. So we crash to make the problem ...
8 years, 1 month ago (2012-11-07 00:02:21 UTC) #5
dmichael (off chromium)
I improved PP_CompletionCallback documentation. +teravest so we can get a fresh pair of eyes to ...
8 years, 1 month ago (2012-11-07 18:44:34 UTC) #6
brettw
lgtm https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/thunk/enter.cc File ppapi/thunk/enter.cc (right): https://chromiumcodereview.appspot.com/10910099/diff/32001/ppapi/thunk/enter.cc#newcode134 ppapi/thunk/enter.cc:134: // PP_OK_COMPLETIONPENDING. So we crash to make the ...
8 years, 1 month ago (2012-11-07 18:52:15 UTC) #7
teravest
lgtm
8 years, 1 month ago (2012-11-07 21:11:40 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/10910099/37001
8 years, 1 month ago (2012-11-07 21:40:06 UTC) #9
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years, 1 month ago (2012-11-07 22:08:40 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/10910099/37001
8 years, 1 month ago (2012-11-07 22:32:06 UTC) #11
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years, 1 month ago (2012-11-07 22:46:07 UTC) #12
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/10910099/37001
8 years, 1 month ago (2012-11-07 22:59:39 UTC) #13
commit-bot: I haz the power
Sorry for I got bad news for ya. Compile failed with a clobber build on ...
8 years, 1 month ago (2012-11-07 23:12:59 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/10910099/47001
8 years, 1 month ago (2012-11-08 04:20:44 UTC) #15
commit-bot: I haz the power
Retried try job too often for step(s) compile
8 years, 1 month ago (2012-11-08 07:32:39 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/[email protected]/10910099/21021
8 years, 1 month ago (2012-11-08 15:58:37 UTC) #17
commit-bot: I haz the power
8 years, 1 month ago (2012-11-08 18:55:18 UTC) #18
Change committed as 166719

Powered by Google App Engine
This is Rietveld 408576698