New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 819046 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
please use my google.com address
Closed: May 2018
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

Clean up Mojo C API

Project Member Reported by roc...@chromium.org, Mar 6 2018

Issue description

In the interest of committing to a stable C ABI ASAP, there's a small amount of polish I want to apply to Mojo system library. This does not include the (probable) eventual rename of functions from MojoFoo to CrFoo, but when that rename is ready to happen, the Mojo API surface should correspond 1:1 with the SDK API surface I think we want.

Namely:

- Data pipe API surface will be removed [see bug 812642]
- MojoGetTimeTicksNow will be removed
- Most API functions will take a versioned "options" structure with
  at least a field for flags. Destruction operations (MojoClose,
  MojoDestroyMessage, MojoUnmapBuffer), MojoQueryHandleSignalsState, and
  MojoGetProperty will remain excluded from this set, but all others will be
  updated.
- The shared buffer API will be updated to reflect the upcoming base
  SharedMemory API changes. This means removing access control flags from
  MojoDuplicateBufferHandle and introducing a new MojoProtectBuffer API.
- Message manipulation is consolidated and made more ergonomical.
    - MojoAttachSerializedMessageBuffer,
      MojoExtendSerializedMessagePayload, and
      MojoCommitSerializedMessageContents are all merged into a unified
      MojoAppendMessageData call which accepts a COMMIT flag.
    - MojoGetSerializedMessageContents -> MojoGetMessageData
    - MojoGetMessageData gets an IGNORE_HANDLES flag to leave handles intact
    - MojoAttachMessageContext -> MojoSetMessageContext
- Watchers are renamed to traps, and you add and remove "triggers"
  from them rather than "contexts". Trap handler invocations are
  "events" rather than "notifications". Arming a trap is a more
  intuitive analogy than arming a "watcher".
 
A few more things I want to do:

- Kill MojoFuseMessagePipes. This is a neat API but it severely constrains
  how we can implement Mojo if we ever want to replace it with something
  else. It has seen very little practical use and I think I can refactor
  all existing consumers 

- Reorder API function arguments to all match this basic template:

     F(primary-input-arguments, options-where-applicable, output-arguments)

Project Member

Comment 2 by bugdroid1@chromium.org, Mar 7 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8e49dd7b1153274611c5c72f9e6de5895f1d5e08

commit 8e49dd7b1153274611c5c72f9e6de5895f1d5e08
Author: Ken Rockot <rockot@chromium.org>
Date: Wed Mar 07 18:06:40 2018

Mojo: Consolidate and stabilize core message APIs

Combines MojoAttachSerializedMessageBuffer,
MojoExtendSerializedMessagePayload, and
MojoCommitSerializedMessageContents (phew!) into a single
MojoAppendMessageData.

Renames MojoGetSerializedMessageContents to MojoGetMessageData.

Adds extensible options parameters to both calls.

Restores a flag for MojoGetMessageData to ignore attached handles,
allowing callers to e.g. peek at message contents non-destructively.

This is in preparation for actual commitment to a stable API. Modulo a
likely rename of the "Mojo" prefix, these message functions should
henceforth be considered stable and must maintain forward-compatibility
indefinitely.

TBR=dcheng@chromium.org

Bug:  819046 
Change-Id: Ie6a572c84146a5ab3b40c8415eb179a809570bfe
Reviewed-on: https://chromium-review.googlesource.com/951870
Commit-Queue: Ken Rockot <rockot@chromium.org>
Reviewed-by: Jay Civelli <jcivelli@chromium.org>
Cr-Commit-Position: refs/heads/master@{#541499}
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/android/system/core_impl.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/embedder/entrypoints.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/system/core.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/system/core.h
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/system/message_pipe_unittest.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/system/message_unittest.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/system/user_message_impl.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/edk/system/user_message_impl.h
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/c/system/README.md
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/c/system/message_pipe.h
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/c/system/thunks.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/c/system/thunks.h
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/cpp/bindings/lib/buffer.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/cpp/bindings/lib/buffer.h
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/cpp/bindings/lib/message.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/cpp/bindings/tests/validation_unittest.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/cpp/system/message.h
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/mojo/public/cpp/system/message_pipe.cc
[modify] https://crrev.com/8e49dd7b1153274611c5c72f9e6de5895f1d5e08/third_party/WebKit/Source/core/mojo/MojoHandle.cpp

Project Member

Comment 3 by bugdroid1@chromium.org, Mar 7 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40

commit f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40
Author: Ken Rockot <rockot@chromium.org>
Date: Wed Mar 07 20:35:08 2018

Mojo: Stabilize remaining message APIs.

Updates MojoCreateMessage, MojoSerializeMessage, MojoSetMessageContext
(nee MojoAttachMessageContext), and MojoGetMessageContext to support a
versioned options structure.

Reworks MojoSetMessageContext to support a zero value as context
removal, and gets rid of the RELEASE flag on MojoGetMessageContext,
because this seems like a better API.

TBR=dcheng@chromium.org

Bug:  819046 
Change-Id: I090554f484c1d6427a53496463e5de6bcd386bbd
Reviewed-on: https://chromium-review.googlesource.com/952284
Commit-Queue: Ken Rockot <rockot@chromium.org>
Reviewed-by: Jay Civelli <jcivelli@chromium.org>
Cr-Commit-Position: refs/heads/master@{#541560}
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/android/system/core_impl.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/embedder/entrypoints.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/core.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/core.h
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/core_unittest.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/message_unittest.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/user_message_impl.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/user_message_impl.h
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/edk/system/watcher_unittest.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/c/system/README.md
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/c/system/message_pipe.h
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/c/system/tests/core_api_unittest.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/c/system/tests/core_unittest_pure_c.c
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/c/system/thunks.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/c/system/thunks.h
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/cpp/bindings/lib/message.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/cpp/system/message.h
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/mojo/public/cpp/system/message_pipe.cc
[modify] https://crrev.com/f3208fc9c7c4edfce6a4ad8ab3d8ea5f5f436b40/third_party/WebKit/Source/core/mojo/MojoHandle.cpp

I had ExtendMessagePayloadLarge timeout in https://ci.chromium.org/buildbot/tryserver.chromium.win/win_chromium_dbg_ng/4079. Could the CL in #3 be responsible?
Actually in https://ci.chromium.org/buildbot/tryserver.chromium.win/win_chromium_dbg_ng/4080, and I guess not, since that was revision 541530 and the CL in #3 landed in 541560.
Thanks for the report though, the test is probably just doing too much work for a debug bot. I'll see about reducing the cost a bit.
Project Member

Comment 7 by bugdroid1@chromium.org, Mar 8 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/cf150a3d82e40aedf2190b1e550f8935a8305cdf

commit cf150a3d82e40aedf2190b1e550f8935a8305cdf
Author: Ken Rockot <rockot@chromium.org>
Date: Thu Mar 08 03:08:00 2018

mojo_unittests: Decrease cost of MessageTest.ExtendMessagePayloadLarge

This test is timing out on Windows debug, where even on very fast
devices it can take 35+ seconds to run.

The runtime grows linearly with the size of the test message used, so
this cuts that size to one tenth (512 kB instead of 5 MB).

TBR=jcivelli@chromium.org

Bug:  819046 
Change-Id: Ib4598981856566dc8ae54de1060840b52e30b959
Reviewed-on: https://chromium-review.googlesource.com/954045
Reviewed-by: Ken Rockot <rockot@chromium.org>
Commit-Queue: Ken Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#541704}
[modify] https://crrev.com/cf150a3d82e40aedf2190b1e550f8935a8305cdf/mojo/edk/system/message_unittest.cc

Project Member

Comment 8 by bugdroid1@chromium.org, Mar 9 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/13e55a33207c004ade4a43d3e177ed026d7a64bb

commit 13e55a33207c004ade4a43d3e177ed026d7a64bb
Author: Ken Rockot <rockot@chromium.org>
Date: Fri Mar 09 00:11:19 2018

Mojo: Watchers -> Traps

Refactors the watcher APIs a bit to support some exensibility. Also
renames them in the process because "trap" seems like a better analogy.

Some remnants of the watcher concept are left intact to keep the CL size
small.

TBR=dcheng@chromium.org

Bug:  819046 
Change-Id: Ie469f715c32080824d99b3a4f85834c030cbd181
Reviewed-on: https://chromium-review.googlesource.com/952081
Reviewed-by: Ken Rockot <rockot@chromium.org>
Reviewed-by: Daniel Cheng <dcheng@chromium.org>
Reviewed-by: Jay Civelli <jcivelli@chromium.org>
Commit-Queue: Ken Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#541949}
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/embedder/entrypoints.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/BUILD.gn
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/core.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/core.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/dispatcher.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/dispatcher.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/request_context.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/signals_unittest.cc
[rename] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/trap_unittest.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/watch.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/watch.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/watcher_dispatcher.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/system/watcher_dispatcher.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/test/mojo_test_base.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/edk/test/mojo_test_base.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/BUILD.gn
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/core.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/functions.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/thunks.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/thunks.h
[add] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/trap.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/c/system/types.h
[delete] https://crrev.com/745839d917dae569a46fb237696e016342fe67d3/mojo/public/c/system/watcher.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/BUILD.gn
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/handle_signal_tracker.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/simple_watcher.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/simple_watcher.h
[add] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/trap.cc
[add] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/trap.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/wait.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/wait.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/wait_set.cc
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/mojo/public/cpp/system/wait_set.h
[delete] https://crrev.com/745839d917dae569a46fb237696e016342fe67d3/mojo/public/cpp/system/watcher.cc
[delete] https://crrev.com/745839d917dae569a46fb237696e016342fe67d3/mojo/public/cpp/system/watcher.h
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/third_party/WebKit/Source/core/mojo/MojoWatcher.cpp
[modify] https://crrev.com/13e55a33207c004ade4a43d3e177ed026d7a64bb/third_party/WebKit/Source/core/mojo/MojoWatcher.h

Project Member

Comment 9 by bugdroid1@chromium.org, May 2 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/21402593c9def11ac030db05e546cb42528e906e

commit 21402593c9def11ac030db05e546cb42528e906e
Author: Ken Rockot <rockot@chromium.org>
Date: Wed May 02 00:22:32 2018

Remove MojoGetProperty and EDK SetProperty APIs

These have only ever been used to support bindings-level state. There's
no need for the EDK to support this, and no need for the stable ABI to
expose a GetProperty call.

Bug:  819046 
Change-Id: I94bdca21045590350f83914fa0429f8a96d7851d
Reviewed-on: https://chromium-review.googlesource.com/1036936
Reviewed-by: John Abd-El-Malek <jam@chromium.org>
Reviewed-by: Jay Civelli <jcivelli@chromium.org>
Commit-Queue: Ken Rockot <rockot@chromium.org>
Cr-Commit-Position: refs/heads/master@{#555245}
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/content/browser/browser_main_loop.cc
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/edk/embedder/README.md
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/edk/embedder/embedder.cc
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/edk/embedder/embedder.h
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/edk/embedder/entrypoints.cc
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/edk/system/core.cc
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/edk/system/core.h
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/public/c/system/functions.h
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/public/c/system/thunks.cc
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/public/c/system/thunks.h
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/public/c/system/types.h
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/public/cpp/bindings/lib/sync_call_restrictions.cc
[modify] https://crrev.com/21402593c9def11ac030db05e546cb42528e906e/mojo/public/cpp/bindings/sync_call_restrictions.h

Project Member

Comment 10 by bugdroid1@chromium.org, May 3 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c12080cd8b6e8c53746d63bf74e72614664df5dd

commit c12080cd8b6e8c53746d63bf74e72614664df5dd
Author: Ken Rockot <rockot@chromium.org>
Date: Thu May 03 18:10:21 2018

Clean up most Mojo core APIs

TL;DR for non-mojo reviews: No functional changes in your code. All
mechanical aesthetic changes.

This cleans up all message pipe, data pipe, and shared buffer APIs to
reflect the intended stable ABI of the initial mojo_core release, adding
extensible options structs where appropriate and homogenizing argument
ordering conventions. Also renames some badly named types and begins
eliminating the split C/C++ flag constant definitions in favor of using
C macros everywhere.

Documentation formatting is also made more consistent, and the thunk
table ordering is mostly finalized here.

The only functional change is a small drive-by bugfix in
MojoGetBufferInfo where the implementation was not filling in the actual
size of the MojoSharedBufferInfo struct. This has no effect on any
current production uses of the API.

TBR=miu@chromium.org
TBR=jam@chromium.org
TBR=kinuko@chromium.org

Bug:  819046 
Cq-Include-Trybots: master.tryserver.chromium.linux:linux_mojo
Change-Id: I5c1019bf1fe95a9295a0d053544e867fdebadde8
Reviewed-on: https://chromium-review.googlesource.com/1041149
Commit-Queue: Ken Rockot <rockot@chromium.org>
Reviewed-by: Jay Civelli <jcivelli@chromium.org>
Cr-Commit-Position: refs/heads/master@{#555808}
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/components/mirroring/browser/cast_remoting_sender_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/content/browser/loader/data_pipe_to_source_stream_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/content/browser/loader/mojo_async_resource_handler.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/content/browser/loader/source_stream_to_data_pipe_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/content/renderer/loader/url_loader_client_impl_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/content/renderer/loader/url_response_body_consumer_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/content/renderer/loader/web_data_consumer_handle_impl_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/media/remoting/demuxer_stream_adapter_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/android/system/core_impl.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/embedder/embedder_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/embedder/entrypoints.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/mojo_core_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/core.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/core.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/core_test_base.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/core_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/data_pipe_consumer_dispatcher.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/data_pipe_consumer_dispatcher.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/data_pipe_producer_dispatcher.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/data_pipe_producer_dispatcher.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/data_pipe_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/dispatcher.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/dispatcher.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/message_pipe_dispatcher.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/message_pipe_dispatcher.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/message_pipe_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/message_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/multiprocess_message_pipe_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/shared_buffer_dispatcher.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/shared_buffer_dispatcher.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/shared_buffer_dispatcher_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/signals_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/system/trap_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/edk/test/mojo_test_base.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/README.md
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/buffer.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/data_pipe.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/functions.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/message_pipe.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/tests/core_api_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/tests/core_perftest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/tests/core_unittest_pure_c.c
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/thunks.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/c/system/thunks.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/bindings/tests/handle_passing_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/bindings/tests/sample_service_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/system/buffer.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/system/data_pipe.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/system/message.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/system/message_pipe.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/system/message_pipe.h
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/mojo/public/cpp/test_support/lib/test_utils.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/services/network/url_loader_unittest.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/storage/browser/blob/blob_transport_strategy.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/third_party/blink/renderer/core/mojo/mojo.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/third_party/blink/renderer/core/mojo/mojo_handle.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/third_party/blink/renderer/platform/loader/fetch/buffering_data_pipe_writer_test.cc
[modify] https://crrev.com/c12080cd8b6e8c53746d63bf74e72614664df5dd/third_party/blink/renderer/platform/loader/fetch/raw_resource.cc

Status: Fixed (was: Assigned)
All done.
Project Member

Comment 13 by bugdroid1@chromium.org, Jul 12

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7831a95dc47fbf2e72acba0de69703380076e333

commit 7831a95dc47fbf2e72acba0de69703380076e333
Author: Ken Rockot <rockot@chromium.org>
Date: Thu Jul 12 01:11:30 2018

Mojo: Clean up MojoArmTrap API

Modifies MojoArmTrap() to place its outputs in a single buffer of
MojoTrapEvent structures, rather than inlining all the event fields as
output parameters. This means that traps which fail to arm can
provide the caller with information in the same form that an actual
event handler would receive it.

Also finally cleans up trap unittests, taking advantage of capturing
lambdas, removing the hacked in adaptations to old watcher APIs,

TBR=kinuko@chromium.org

Bug:  819046 
Change-Id: Ib2917df06611cbbe8406a65bcdcac71011f52e88
Reviewed-on: https://chromium-review.googlesource.com/1133962
Commit-Queue: Ken Rockot <rockot@chromium.org>
Reviewed-by: Reilly Grant <reillyg@chromium.org>
Cr-Commit-Position: refs/heads/master@{#574439}
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/core.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/core.h
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/dispatcher.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/dispatcher.h
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/entrypoints.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/trap_unittest.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/watcher_dispatcher.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/core/watcher_dispatcher.h
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/c/system/README.md
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/c/system/thunks.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/c/system/thunks.h
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/c/system/trap.h
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/cpp/system/simple_watcher.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/cpp/system/wait.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/mojo/public/cpp/system/wait_set.cc
[modify] https://crrev.com/7831a95dc47fbf2e72acba0de69703380076e333/third_party/blink/renderer/core/mojo/mojo_watcher.cc

Sign in to add a comment