Commit Graph

362 Commits

Author SHA1 Message Date
Ben Konyi 34a6218f8e [ VM / Service ] Forward message for exceptions caught in VM service PUT requests
Fixes #36202

Change-Id: If578ec8e24a5acf10db85a7f17cc98a0b7168c57
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/105475
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2019-06-11 16:15:23 +00:00
Ben Konyi ded5c3efd5 [ VM / Service ] Fixed HTTP requests with params not working correctly when auth codes are enabled
Change-Id: Ia6dbab2c8e46cdd1fce659f55ee16f3ad98e5d6d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/101021
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2019-05-02 17:38:49 +00:00
Ben Konyi 24396182e1 [ VM / Service ] Handle case where user navigates to Observatory without a slash trailing the authentication code.
Previously, navigating to an observatory URI similar to http://127.0.0.1:8181/KUhS6KoCm24=
would result in a missing auth code error. This change explicitly checks
for this case and issues a redirect response to
http://127.0.0.1:8181/KUhS6KoCm24=/ so index.html can be sent properly
in the follow up request.

Fixes #36763

Change-Id: I8a73f2ef08f6bf1ca5aed4ddaaf97ae3489f7e23
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/100631
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2019-04-29 17:03:49 +00:00
Ben Konyi 92c9f124c3 [ VM / Service ] Fixed HTTP requests to the VM service not working correctly with authentication codes
Change-Id: Ibbf9edb58b9e1f83b31ff876d2da4ef327ea1dab
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/99081
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Ben Konyi <bkonyi@google.com>
2019-04-10 19:41:59 +00:00
Ben Konyi 15b11b0183 [ VM / Service / Observatory ] The VM service now requires an authentication code by default.
Previously, a valid web socket connection would use the following URI:

`ws://127.0.0.1/ws`

Now, by default, the VM service requires a connection to be made with a
URI similar to the following:

`ws://127.0.0.1:8181/Ug_U0QVsqFs=/ws`

where `Ug_U0QVsqFs` is an authentication code generated and shared by the
service.

This behavior can be disabled with the `--disable-service-auth-codes`
flag.

Change-Id: I288aac58e3ba9d35dca8071f3f7e7a073896c271
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98433
Commit-Queue: Ben Konyi <bkonyi@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
2019-04-09 22:57:29 +00:00
Ben Konyi ff6f61c872 [VM / Observatory ] Remove needless stacktrace print when adding to closed socket
Change-Id: Idc31b45fd880ff0233c7cbeb31a22d43fbcea01e
Reviewed-on: https://dart-review.googlesource.com/c/94840
Commit-Queue: Ben Konyi <bkonyi@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Auto-Submit: Ben Konyi <bkonyi@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2019-02-28 18:35:03 +00:00
asiva 763589472e [VM / vmservice] - Change setting of silentObservatory to a non const expression
Change-Id: I89d72c05fd897fcf1396585132d4056c4e91195d
Reviewed-on: https://dart-review.googlesource.com/c/93361
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
2019-02-15 02:46:41 +00:00
Jonas Finnemann Jensen 8146725731 Return 403 and 405 from observatory server
With this change untrusted `origin` header or method not allowed will
return 403 and 405 respectively. Before this change it returned 200 with
an empty body. Returning proper error codes helps users debug their
setup and figure out what is wrong.

Closes https://github.com/dart-lang/sdk/issues/34121

Change-Id: I60c75ee2e33882f98fd9a020d33d459e74febf29
Reviewed-on: https://dart-review.googlesource.com/c/69308
Commit-Queue: Jonas Jensen <jonasfj@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2018-11-08 17:03:11 +00:00
asiva e6d3a45b6a [VM] Fix for issue 34839 Service isolate hangs during shutdown if
the VM exits before the Observatory server has a chance to
     start listening.

Bug: 34839
Change-Id: I2a5dfe69a197fe054dd041af3ea4e07da736b226
Reviewed-on: https://dart-review.googlesource.com/c/81381
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
2018-10-27 00:45:59 +00:00
asiva af57d2a0eb [VM] Remove dead code associated with flag '--error-on-bad-override'
- Remove all dead code associated with flag '--error-on-bad-override' which is currently running only under !FLAG_strong which is not valid anymore
- Not removing the flag from flag_list for now as it is used in a number of tests and removing it from all these places would be a big change, it would be a NOP flag
- removed some dead code in 'loader.dart' which was invoked from the tag handler

Change-Id: I5474b51b4dee7471e80b4081e55b996f1d75612f
Reviewed-on: https://dart-review.googlesource.com/c/78382
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-10-08 04:44:24 +00:00
Jason Simmons 3463f94ed9 Delete any existing version of a DevFS file before overwriting the file
Consumers of the file may have open file mappings, and those mappings must not
see a mix of old and new content as the new file is written.

Fixes https://github.com/flutter/flutter/issues/21858

Change-Id: Ia4d6cee53cceaa04bec01a2af56c76fad05dcad8
Reviewed-on: https://dart-review.googlesource.com/75620
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2018-09-19 21:43:19 +00:00
Samir Jindel 5572df1458 [vm/precomp] Fix name of vm:entry-point.
Change-Id: I907e59a9df9407f924c0518a185d5b28ab46e381
Cq-Include-Trybots: luci.dart.try:vm-kernel-win-release-x64-try,vm-kernel-optcounter-threshold-linux-release-x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-release-simarm-try,vm-kernel-precomp-linux-release-simarm64-try,vm-kernel-precomp-linux-release-x64-try,vm-kernel-precomp-win-release-x64-try
Reviewed-on: https://dart-review.googlesource.com/69971
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-08-16 15:07:51 +00:00
Samir Jindel 9767af2550 [vm/precomp] Support @pragma for fields and remove associated entry-point entries.
Cq-Include-Trybots: luci.dart.try: vm-kernel-optcounter-threshold-linux-release-x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-release-simarm-try,vm-kernel-precomp-linux-release-simarm64-try,vm-kernel-precomp-linux-release-x64-try,vm-kernel-precomp-win-release-x64-try
Change-Id: I584aae2360771cf0599d9fb1b5ae2735b20d3413
Reviewed-on: https://dart-review.googlesource.com/65820
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-08-07 16:47:50 +00:00
Samir Jindel de408202a5 [vm/precomp] Take 4 for procedure- and class-entrypoints.
This reverts commit 08f59e5de3.

There are no changes to take 3 except fixing merge conflicts.

Change-Id: I45d5a16274c80f469827c19f4e4f4ca724e85a67
Cq-Include-Trybots: luci.dart.try:vm-kernel-win-release-x64-try,vm-kernel-optcounter-threshold-linux-release-x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-release-simarm-try,vm-kernel-precomp-linux-release-simarm64-try,vm-kernel-precomp-linux-release-x64-try,vm-kernel-precomp-win-release-x64-try
Reviewed-on: https://dart-review.googlesource.com/68363
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-08-07 13:54:27 +00:00
Ben Konyi 08f59e5de3 These changes are causing a segfault in DartEntry::InvokeFunction in dart_entry.cc in Flutter,
which was blocking the Dart SDK roll.

Revert "Take 3 for "[vm/kernel/precomp] Remove procedures from entry points files.""

This reverts commit 567109df7f.

Revert "[vm/precomp] Extend @pragma entry-points to classes."

This reverts commit 232698047c.

Change-Id: Ib63d1afb8a1c978be7ddf282af0e7d5547111cc3
Reviewed-on: https://dart-review.googlesource.com/67300
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-07-28 00:01:50 +00:00
Samir Jindel 567109df7f Take 3 for "[vm/kernel/precomp] Remove procedures from entry points files."
I've updated the transformer test. The Windows build error appears to have been spurious.

Take 2 is in patchset 1.

Cq-Include-Trybots: luci.dart.try:vm-kernel-win-release-x64-try,vm-kernel-optcounter-threshold-linux-release-x64-try,vm-kernel-precomp-linux-debug-x64-try,vm-kernel-precomp-linux-release-simarm-try,vm-kernel-precomp-linux-release-simarm64-try,vm-kernel-precomp-linux-release-x64-try,vm-kernel-precomp-win-release-x64-try
Change-Id: I6ef8f70aaf4664e0411e776463e88c2a1068dbcc
Reviewed-on: https://dart-review.googlesource.com/65902
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2018-07-26 16:24:59 +00:00
Mike Fairhurst 7911fb2683 First pass at disabling packages/ dir, packageRoot
Change-Id: Ib2d7738c84cd1258dcad46e8e2c8da8105efea60
Reviewed-on: https://dart-review.googlesource.com/59100
Reviewed-by: Kevin Moore <kevmoo@google.com>
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
2018-06-12 19:38:40 +00:00
Samir Jindel beb0432d6c Re-land "[vm/kernel/aot] Exclude vmservice_io from "product" AOT snapshots."
This reverts commit 17585c42fe.

The original revision is in Patchset 1.

Fixed Tests:

python tools/test.py -m debug -c dartkp -r dart_precompiled --strong standalone_2/no_support_service_test
python tools/test.py -m product -c precompiler -r dart_precompiled lib_2/isolate/function_send1_test

Change-Id: I6af715ee3c080b515c8312357f3d8be6e494747a
Reviewed-on: https://dart-review.googlesource.com/59760
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-06-12 15:31:19 +00:00
Alexander Markov 17585c42fe Revert "[vm/kernel/aot] Exclude vmservice_io from "product" AOT snapshots."
This reverts commit 23fff58503.

Reason: failures on vm-kernel-precomp-linux-debug-x64-4-8-be,
precomp-linux-debug-x64-1-3-be, precomp-linux-product-x64-be bots.
Change-Id: I7bd67038aac3795c4b6ec9562c6fd4afead41a36
Reviewed-on: https://dart-review.googlesource.com/59242
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Alexander Markov <alexmarkov@google.com>
2018-06-08 00:51:53 +00:00
Samir Jindel 23fff58503 [vm/kernel/aot] Exclude vmservice_io from "product" AOT snapshots.
The `@pragma` annotation on `vmservice_io.main` is modified to only mark it as a
root on non-product builds. Since the annotation is evaluated in the constant
transformation, we need to thread a flag through `gen_kernel.dart` indicating
whether the Kernel produced should target a product precompiler.

# Test Plan

Tested locally on Flutter. Unfortunately it's not possible to test the scenario where
`vmservice_io` is not included, since we don't have any "product" bots. Soon the
flag will be introduced into Flutter, and we will have some coverage from there.

Change-Id: I39f12343038fa221aafe5a55241bff4b8d14ec19
Reviewed-on: https://dart-review.googlesource.com/57501
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-06-07 20:22:21 +00:00
Samir Jindel 3d2b66074c Reland "[vm] Support definition of entry-points via @pragma('vm.extern') annotations.""
When the constant transformation is enabled on annotations, we need to fix handling
of @ExternalName annotations in the kernel_loader to ensure that we are setting
is_external = false on native methods.

The original revision is in patchset 1.

# Test Plan

The only regression was on benchmarks, Golem results are pending.

Change-Id: Ib80bb9f532299056e770a3b378cc5ad9ee451f57
Reviewed-on: https://dart-review.googlesource.com/56960
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-05-30 20:06:40 +00:00
Samir Jindel 58dc4e476d Revert "[vm] Support definition of entry-points via @pragma('vm.extern') annotations."
This reverts commit 3e50ea32b5.

Reason for revert: Severe performance regressions on many aot-v2 benchmarks.

Original change's description:
> [vm] Support definition of entry-points via @pragma('vm.extern') annotations.
> 
> The `@pragma` annotations are evaluated by the constants transformation and
> visible to TFA and the precompiler, which match on the "options" field of the
> annotation to determine whether to mark the class/procedure as a root.
> 
> This required enabling the transformation of annotation constants by default.
> 
> # Test Plan
> 
> The "vmservice_io.main" entry-point is removed from `main.cc` and annotated with
> `@pragma`. All precompiler tests will crash if "vmservice_io.main" is not
> available at runtime.
> 
> Debug/release precompiler bots are visible in "cl-linux" button.
> 
> Change-Id: I03c5d6ba7918672ed9905fcaee8dabe675a93a5d
> Reviewed-on: https://dart-review.googlesource.com/56660
> Commit-Queue: Samir Jindel <sjindel@google.com>
> Reviewed-by: Vyacheslav Egorov <vegorov@google.com>

TBR=vegorov@google.com,alexmarkov@google.com,sjindel@google.com

Change-Id: I779c17d003659129a4b3fcf284423104948f60e2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/56820
Reviewed-by: Samir Jindel <sjindel@google.com>
Commit-Queue: Samir Jindel <sjindel@google.com>
2018-05-28 19:23:16 +00:00
Samir Jindel 3e50ea32b5 [vm] Support definition of entry-points via @pragma('vm.extern') annotations.
The `@pragma` annotations are evaluated by the constants transformation and
visible to TFA and the precompiler, which match on the "options" field of the
annotation to determine whether to mark the class/procedure as a root.

This required enabling the transformation of annotation constants by default.

# Test Plan

The "vmservice_io.main" entry-point is removed from `main.cc` and annotated with
`@pragma`. All precompiler tests will crash if "vmservice_io.main" is not
available at runtime.

Debug/release precompiler bots are visible in "cl-linux" button.

Change-Id: I03c5d6ba7918672ed9905fcaee8dabe675a93a5d
Reviewed-on: https://dart-review.googlesource.com/56660
Commit-Queue: Samir Jindel <sjindel@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2018-05-28 15:13:55 +00:00
Ryan Macnak 3b7199fe63 [standalone] Only allow one outstanding load when running with --deterministic.
Bug: https://github.com/dart-lang/sdk/issues/31427
Change-Id: I3349d6cc1779ef4470262e65dff7410397cb12de
Reviewed-on: https://dart-review.googlesource.com/51161
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2018-04-16 18:31:28 +00:00
Ryan Macnak 9f4ffb64ef Partial static mode changes for vm-service and tests (part 2).
Bug: https://github.com/dart-lang/sdk/issues/31587
Change-Id: Ie2605f5043b9f5d2f9156928e3cd39f74e726853
Reviewed-on: https://dart-review.googlesource.com/30681
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Ryan Macnak <rmacnak@google.com>
2017-12-20 00:45:28 +00:00
Vyacheslav Egorov b2eab8b96e [VM/Service] Restore zero-copying handling of JSON messages in vmservice.
In 5a44162c97 in attempt to adhere to declared
method signatures we lost zero-copying JSON decoding of responses from
VM: `Message.sendToVM` was changed to always decode the response into
string before passing it to the caller and the logic to use fused
JSON decoding was removed. This increased peak memory consumption by
the VM Service.

This commit addresses the issue by restoring the zero-copying JSON decoding
logic while adding a wrapper around responses that make it clear what kind
of data is passed around and how that data is encoded and handled.

We introduce a class `Response` which can contain either a Dart string, a
binary data (represented as a Uint8List) or utf8 encoded string (represented
as a Uint8List). This class is used in all places where previously a String
or dynamic were used, e.g. MessageRouter.routeRequest is changed to return
Future<Response> rather than Future<String>. This allows callees to
decode JSON responses without copying them into Dart heap while
maintaining sufficient level of typing to make the code easy to reason about.

This commit also removes some dead code from the VM service related to old
Service API and TAR assets unpacking (which has been long done in C++).

Bug: https://github.com/flutter/flutter/issues/13626
Change-Id: Ifbba56944a552034a0f802a965a313326a1236e7
Reviewed-on: https://dart-review.googlesource.com/30280
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
2017-12-18 19:06:06 +00:00
Paul Berry eb3cf7c035 Strong mode fix for vmservice_io.dart.
The method _clearFuture needs to have return type `Server` so that it
can be used in a "then" call that's expected to return a value of type
`Future<Server>`.

Change-Id: Ia63309c16a2f28457e06a52419219c93a38ef389
Reviewed-on: https://dart-review.googlesource.com/26161
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2017-12-05 18:19:21 +00:00
Paul Berry 7a778cf47c Strong mode fix for vmservice_io.dart.
Change-Id: I3cb1b44969779018cccff91e45eba11d60afcd58
Reviewed-on: https://dart-review.googlesource.com/21568
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
2017-11-17 08:31:56 +00:00
Lasse R.H. Nielsen 0b58c4bd10 Change some constant declarations to lowerCase.
Retain the old values.

Reapply of https://dart-review.googlesource.com/c/sdk/+/20680 with fixes
for VM method fingerprints.

Change-Id: Ie14e7ccc3194d5561983348e6b6752728913ff4d
Reviewed-on: https://dart-review.googlesource.com/20664
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
2017-11-14 12:59:14 +00:00
Lasse R.H. Nielsen e61fc07b58 Revert "Change some constant declarations to lowerCase."
This reverts commit c048cfb178.

Reason for revert: VM code fingerprints needs update.

Original change's description:
> Change some constant declarations to lowerCase.
> 
> Retain the old values.
> 
> Change-Id: I03bd326f379fe5f96d8f6081a7133de956d745c0
> Reviewed-on: https://dart-review.googlesource.com/11520
> Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
> Reviewed-by: Florian Loitsch <floitsch@google.com>

TBR=lrn@google.com,floitsch@google.com

Change-Id: I095e8198304ca4e59b39d30b0fdf0af4945e5231
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/20680
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
2017-11-14 11:23:08 +00:00
Lasse R.H. Nielsen c048cfb178 Change some constant declarations to lowerCase.
Retain the old values.

Change-Id: I03bd326f379fe5f96d8f6081a7133de956d745c0
Reviewed-on: https://dart-review.googlesource.com/11520
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Florian Loitsch <floitsch@google.com>
2017-11-14 11:13:04 +00:00
Paul Berry 8f57cf8e45 Strong mode fix for runtime/bin/vmservice/loader.dart
The values in isolateEmbedderData have IsolateLoaderState in practice,
but the static type system only guarantees they have type
IsolateEmbedderData (a supertype).  So we need an implicit downcast.

Change-Id: I9da0c9a34deae233e3bb25d264e4307fd186c3c7
Reviewed-on: https://dart-review.googlesource.com/20160
Reviewed-by: Ryan Macnak <rmacnak@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2017-11-11 15:38:51 +00:00
Zachary Anderson 08f2633022 [Fuchsia] Remove vm service hacks
Change-Id: Ia012ed493dc15f847db2b8798435944dff637c8e
Reviewed-on: https://dart-review.googlesource.com/7441
Reviewed-by: Ryan Macnak <rmacnak@google.com>
2017-09-21 15:00:39 +00:00
Zachary Anderson 734beef062 [infra] Translate _sources.gypi files to _sources.gni files
Also deletes code that becomes dead as a result.

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2996903002 .
2017-08-14 21:54:36 -07:00
Carlo Bernaschina df8bf384eb Introduce external services registration
A new RPC is introduced `_registerService` which allow clients to
register new services that are accessible from all the other clients.

Each registered endpoint is identified by 3 strings:

 - `service`
   a non empty string which identifies the provided service
   (e.g. `HotReload`, `OpenFile`)
 - `alias`
   an alias for that particular endpoint used by clients to identify it
   (e.g. `Flutter`, `IntelliJ`)
 - `method` __generated__
   the RPC method that should be invoked from a client to request it

A new _stream_ `_Service` is introduce, and two related events:

 - `ServiceRegistered`
   which is triggered when a new client is registered.
   All the related information (`service`, `alias`, `method`) are sent.

 - `ServiceUnregistered`
   which is triggered when a client, which previously registered a
   service, disconnects.
   Just `service` and `method` are sent.

Related https://github.com/dart-lang/sdk/issues/30023

R=asiva@google.com, bkonyi@google.com

Review-Url: https://codereview.chromium.org/2980733003 .
2017-07-13 18:18:51 -07:00
Erik Corry 029b1cb948 Spelling fixes e to i.
R=kevmoo@google.com
BUG=

Review-Url: https://codereview.chromium.org/2957593002 .
2017-06-24 13:41:39 +02:00
Ryan Macnak 9ab39ae099 Reapply "[fuchsia] Prepare for setting the Dart target architecture appropriately in the host binaries."
Add missing config to run_vm_tests.

R=zra@google.com

Review-Url: https://codereview.chromium.org/2937503003 .
2017-06-13 08:49:00 -07:00
Ryan Macnak 3383c4ac25 Revert "[fuchsia] Prepare for setting the Dart target architecture appropriately in the host binaries."
This reverts commit 54e80a8c32.

Review-Url: https://codereview.chromium.org/2940513002 .
2017-06-12 15:19:23 -07:00
Ryan Macnak 54e80a8c32 [fuchsia] Prepare for setting the Dart target architecture appropriately in the host binaries.
Build another varient of dart_bootstrap targeting the host architecture to ensure reasonable Observatory build times.

Remove assert assuming a root script, which does not exist when gen_snapshot builds core snapshots.

R=zra@google.com

Review-Url: https://codereview.chromium.org/2924173005 .
2017-06-12 14:33:10 -07:00
Vyacheslav Egorov 13f5616ef6 VM: Fix snapshoting slow-down caused by 99c6a18a1b.
Only reload packages map when we are actually doing the isolate reload.

Snapshotting creates and destroys and loader object every time it loads a dart
file - which means kInitLoader is on the hot path and we should avoid rereading
packages map.

R=asiva@google.com, rmacnak@google.com

Review-Url: https://codereview.chromium.org/2901093002 .
2017-05-23 22:01:45 +02:00
Zachary Anderson d6cc48b8e1 [Fuchsia] Switch service protocol to bind to ipv6
This should work now.

R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2842783002 .
2017-04-25 09:53:49 -07:00
Jacob Richman b67e83eea3 Format all remaining unformatted runtime files other than multitests.
BUG=
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2829463003 .
2017-04-18 15:34:03 -07:00
Ryan Macnak b810cb2fe5 Ensure resolved packages before _Dart_kResolveAsFilePath.
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2820853002 .
2017-04-14 15:55:03 -07:00
John McCutchan 9af072399e Fix reload bots
BUG=

Review-Url: https://codereview.chromium.org/2812373003 .
2017-04-12 14:36:38 -07:00
John McCutchan 99c6a18a1b Attempt 2 -- Fix updating packages map on reload and add a regression test
- [x] Update the isolate's .packages path when requested.
- [x] Always refresh package map when loader is initialized.
- [x] Add regression test.

Review-Url: https://codereview.chromium.org/2810223003 .
2017-04-12 14:02:19 -07:00
John McCutchan 94df115e4b Revert "Fix updating packages map on reload and add a regression test"
This reverts commit 7a2d67f3ba.

BUG=

Review-Url: https://codereview.chromium.org/2808953003 .
2017-04-10 12:30:38 -07:00
John McCutchan 80c27841a3 Fix logic bug in loader code
BUG=

Review-Url: https://codereview.chromium.org/2815433002 .
2017-04-10 11:13:46 -07:00
John McCutchan d75edfb408 Attempt to fix loader hangs
I cannot reproduce locally so I'm going off scraps from the buildbot logs

BUG=

Review-Url: https://codereview.chromium.org/2814543002 .
2017-04-10 10:12:04 -07:00
John McCutchan 7a2d67f3ba Fix updating packages map on reload and add a regression test
- [x] Update the isolate's .packages path when requested.
- [x] Always refresh package map when loader is initialized.
- [x] Add regression test.

BUG=
R=rmacnak@google.com

Review-Url: https://codereview.chromium.org/2797923008 .
2017-04-10 08:59:10 -07:00
Ryan Macnak d0529c8638 Nicer message when attempting to use Observatory from dart_bootstrap, dart_precompiled_runtime or an unnamed badly configured build.
R=johnmccutchan@google.com

Review-Url: https://codereview.chromium.org/2793603002 .
2017-03-31 13:29:52 -07:00