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

Unified Diff: third_party/mojo/src/mojo/edk/system/message_pipe.h

Issue 929433005: WIP: A couple of more ChannelMojo speedup ideas (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Build and test fix Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/mojo/src/mojo/edk/system/message_pipe.h
diff --git a/third_party/mojo/src/mojo/edk/system/message_pipe.h b/third_party/mojo/src/mojo/edk/system/message_pipe.h
index df0501484e5715eb743733b2b739cc77803b49b6..3deee2986a92f9b0b07f06a42603117ad6e2ecb2 100644
--- a/third_party/mojo/src/mojo/edk/system/message_pipe.h
+++ b/third_party/mojo/src/mojo/edk/system/message_pipe.h
@@ -105,6 +105,9 @@ class MOJO_SYSTEM_IMPL_EXPORT MessagePipe : public ChannelEndpointClient {
void RemoveAwakable(unsigned port,
Awakable* awakable,
HandleSignalsState* signals_state);
+ MojoResult SetAsyncMessageCallback(unsigned port,
+ const AsyncMessageCallback& callback);
+
void StartSerialize(unsigned port,
Channel* channel,
size_t* max_size,
@@ -116,7 +119,8 @@ class MOJO_SYSTEM_IMPL_EXPORT MessagePipe : public ChannelEndpointClient {
embedder::PlatformHandleVector* platform_handles);
// |ChannelEndpointClient| methods:
- bool OnReadMessage(unsigned port, MessageInTransit* message) override;
+ bool OnReadMessage(unsigned port,
+ MessageInTransit::ReadContext& reading_message) override;
void OnDetachFromChannel(unsigned port) override;
private:
@@ -130,6 +134,10 @@ class MOJO_SYSTEM_IMPL_EXPORT MessagePipe : public ChannelEndpointClient {
scoped_ptr<MessageInTransit> message,
std::vector<DispatcherTransport>* transports);
+ MojoResult DispatchOnReadMessageNoLock(
+ unsigned port,
+ MessageInTransit::ReadContext& reading_message);
+
// Helper for |EnqueueMessageNoLock()|. Must be called with |lock_| held.
MojoResult AttachTransportsNoLock(
unsigned port,
« no previous file with comments | « third_party/mojo/src/mojo/edk/system/message_in_transit.h ('k') | third_party/mojo/src/mojo/edk/system/message_pipe.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698