This test is launcing a subprocess with N parallel tracks.
Each track is effectively a child isolate that will make a
tail call to another child isolate. This process will continue
until a reload is requested.
=> So it tests performing hot-reload of an application that has
a lot of isolate creation, initialization, destructions in it.
Right now it uses N=20 for normal architectures (and N=2 for
simulators).
It turns out that part of the slowness of this test is due to the
subprocess's "vm-service" sending massive amounts of data via the
websocket to the parent process that performs reloading:
Each isolate will produce 4 events:
* IsolateStart
* IsolateRunnable
* ServiceExtensionAdded
* IsolateExit
and send those to the `vm-service` isolate. The service isolate will
then send those further via the WebSocket API to the parent process.
=> For 400k isolates this may send 3 GB of data via websocket.
=> The individual events most likely result in individual syscalls.
=> Networking stack on windows/mac may not be soo good, which
would explain why it's more likely to time out there vs linux
We ensure the helper reload utilites unsubscribe to the "isolate"
stream once there's no longer a need for it.
=> This will avoid the 3 GB of network traffic.
=> It will avoid a subset (but not all) of the isolate -> vm-service events
Issue https://github.com/dart-lang/sdk/issues/51347
TEST=vm/dart{,_2}/isolates/reload_many_isolates_live_and_die_test
Change-Id: I971b983a08ea8febd38e8b40a53ed6b114c4daca
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/306421
Reviewed-by: Slava Egorov <vegorov@google.com>
Commit-Queue: Martin Kustermann <kustermann@google.com>
This CL enables the avoid_void_async lint in the CFE, makes the needed
changes and adds the missing `await` (because the lint
`unawaited_futures` doesn't react to void async methods).
Change-Id: Iffc1f173badd3c2d48356ee02e81a9aed492ce5d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/213481
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
* Update named configs for unit tests to Dart 2.
* Bump json_rpc_2 in front_end package.
* Use named configurations in unit tests.
* Fix typing issues.
Change-Id: Id3b393a0d2abe92c8eaec10fa8057fb35d18a4c6
Reviewed-on: https://dart-review.googlesource.com/67341
Reviewed-by: Jens Johansen <jensj@google.com>