69 Commits

Author SHA1 Message Date
Jason Simmons
07e64fd60a
Do not free the buffer owned by the kernel_data vector (#4753)
Fixes https://github.com/flutter/flutter/issues/14947
2018-03-07 14:21:15 -08:00
Ryan Macnak
0d4e72e86f
[fuchsia] Place Observatory in the runner's package instead of linking it in. (#4719)
This allows blobfs to deduplicate it across {dart,flutter}_{jit,aot}_runner.
2018-02-27 16:45:52 -08:00
Vyacheslav Egorov
bacb388fda
Switch on --sync-async in Dart 2 mode (#4686) 2018-02-27 09:44:27 +01:00
Siva
19e8d9b2bf
Fix strong flag setting (#4683)
* Turn on strong mode by default when a platform file is present in the
bundle instead of using a flag passed into the engine which might not be
true when we invoke an installed app.

* - Roll dart to version fe96de2858f078e4ad04f8f30640184bf3d8102d

* Update license file.
2018-02-15 11:02:31 -08:00
Jason Simmons
c8bf22552e
Fix an improper deletion of DirectoryAssetBundle when creating isolates (#4637) 2018-02-05 17:33:59 -08:00
Siva Chandra
2b398ee227 Roll Dart to 93d8c9fe2a2c22dc95ec85866af108cfab71ad06. (#4558)
* Roll Dart to 93d8c9fe2a2c22dc95ec85866af108cfab71ad06.

* Fix analyzer nits

* Try to pin dependency for tools/licenses to convert 2.0.1. Add verbose flag to pub get

* Pin dart to dev.16 to overcome pub issue

* Revert "Try to pin dependency for tools/licenses to convert 2.0.1. Add verbose flag to pub get"

This reverts commit d525a83f4494a511996226d328a5208d4651d46e as it is no
longer needed, was added to diagnose the problem, which turned out to be
a problem with pub in latest dart dev release.

* Fix license hash

* Reintroduce api methods and tests
2018-01-18 12:35:09 -08:00
Siva
0f0b144b03
Add support for --strong option in the engine, create a strong mode version of the platform file (#4504)
* Add a --strong option to the front end server so we can use strong mode with preview-dart-2.

* Plumb the --strong option through the dart controller into the VM.

* - Build a strong version of platform.dill for use with the engine.
- Fix a strong mode static error in the assert statement

* Enable asserts when running debug version even in strong mode.

* Use the correct platform dill file for linking when doing the aot builds.

* Fix formatting issue.
2018-01-03 16:52:24 -08:00
Alexander Markov
37789650cb
Enable Dart 2.0 fixed-size integers in Flutter (#4501) 2018-01-02 14:34:15 -08:00
Brian Osman
d65b521b41
Fix formatting (#4473) 2017-12-18 13:21:32 -05:00
Sarah Zakarias
1c46319677
Read platform kernel blob from asset directory instead of FLX (#4471) 2017-12-18 13:15:01 +01:00
Sarah Zakarias
f04c5715ce
Add missing include (#4454) 2017-12-13 14:29:14 +01:00
Sarah Zakarias
8cfab93439
Add #define's in dart_init.cc (#4453) 2017-12-13 14:13:02 +01:00
Sarah Zakarias
4cbe26dd37
Handle Flutter assets outside FLX (#4343) 2017-12-13 10:55:24 +01:00
Ben Konyi
74a2d90530
Changes to assets/ build/ flow/ runtime/ and shell/ to allow for compilation on Windows (#4407)
Made changes to assets/ build/ flow/ runtime/ and shell/ to allow for
compilation on Windows.
2017-11-30 19:47:20 -05:00
Ian McKellar
d917c35e72
Allow Flutter apps on Fuchsia to shut down cleanly (#4366)
The UIDartState is now always owned by the isolate and always freed in
the isolate cleanup callback.

In the isolate shutdown callback, if the isolate being shut down is the
main isolate, the RuntimeController is informed which in turn notifies
the RuntimeHolder and thus the ApplicationControllerImpl. The
ApplicationControllerImpl tears down the whole Flutter application.

This fixes Fuchsia bug: MI4-328
2017-11-15 13:28:21 -08:00
Alexander Markov
11d68f63da
Revert "Enable Dart 2.0 fixed-size integers in Flutter (#4337)" (#4344)
This reverts commit 0b7582e6a130fc99270dafec5113a7ec46ed522a.
2017-11-10 11:08:42 -08:00
Alexander Markov
0b7582e6a1
Enable Dart 2.0 fixed-size integers in Flutter (#4337) 2017-11-09 09:42:40 -08:00
Alexander Aprelev
ec19da1c80 Initialize service isolate from kernel file, rather than from embedded sources. (#4263)
* Read core platform kernel file during Dart initialization.

Currently service isolate is initialized from the source code parsed by VM.
This CL changes it so service isolate created during Dart initialization
is created from the kernel platform.dill file if it is present in the application
bundle. Then this platform kernel file is kept in dart_init module and reused
for application sciprt isolates.

* Reformat and merge

* Use accessor method

* Avoid passing running_from_kernel param. Add TODO for cleanup. Rename param.
2017-10-24 19:37:24 -07:00
P.Y. Laligand
6fcb45991d Move //dart to //third_party/dart. (#4245) 2017-10-19 01:20:38 -07:00
Siva
5003703330 Fix for issue 12526 (#4218)
* Fix for issue 12526

Ensure that child isolates do not clear the dart_ui_state_ field present in the dart controller.

The commit dd1e0b59ec implemented code to reset the dart_ui_state_ back to null when an isolate was being shutdown to ensure there was no use after free issues when the main isolate exeutes Isolate.current.kill() it however it was also clearning the field when a child isolate was shutdown causing SEGVs later.

* Address code format issues.
2017-10-17 14:47:09 -07:00
Zachary Anderson
be547d66c2 Remove daed --assert_initializer flag (#4181) 2017-10-06 14:54:08 -07:00
Siva
79cb2eaf65 - Remove call to DartDebugger::InitDebugger in InitDartVM (#4167)
- Remove linking of dart_debugger.cc as this is not used
(all debugging is done using the service API, this debugger implementation uses the deprecated dart debugger API)
2017-10-03 16:49:43 -07:00
Jason Simmons
e1aa86739b Provide an entropy source to the Dart engine (#4161)
This is required by the _CryptoUtils class used by the recently repackaged
Dart HTTP libraries
2017-10-02 12:40:29 -07:00
Ian McKellar
dd1e0b59ec Support cleaner Dart isolate shutdown handling. (#4121)
If an isolate shuts down (for example if an app calls
Isolate.current.kill()), the UIDartState* on DartController will refer
to a freed object. This wires through notification that the is shutting
down through to the DartController so it can clean up appropriately.

This also makes gives the vm-service isolate an UIDartState* so that
the shutdown callback can behave correctly.
2017-09-19 12:11:05 -07:00
Alexander Aprelev
0e8ffa24e0 Reverting to unblock engine roll (#4109)
* Revert "Make Travis happy again (#4101)"

This reverts commit c99b2559df05f4b5f547d26bb0a61d88809f5564.

* Revert "Support cleaner Dart isolate shutdown handling. (#4096)"

This reverts commit 05751f7be993316057d772e8334a783537e10e26.
2017-09-14 12:10:11 -07:00
Alexander Aprelev
1b367b06f1 Provide callback to free fetched bytes when reading kernel binary. (#4095) 2017-09-14 08:01:25 -07:00
Michael Goderbauer
c99b2559df Make Travis happy again (#4101) 2017-09-13 12:42:37 -07:00
Ian McKellar
05751f7be9 Support cleaner Dart isolate shutdown handling. (#4096)
If an isolate shuts down (for example if an app calls
Isolate.current.kill()), the UIDartState* on DartController will refer
to a freed object. This wires through notification that the is shutting
down through to the DartController so it can clean up appropriately.
2017-09-13 10:29:21 -07:00
Michael Goderbauer
08961f8ec5 Format all c-like sources with clang-format (#4088)
* format

* license script adaptions

* updated licenses

* review comments
2017-09-12 15:36:20 -07:00
George Kulakowski
3aa7522c11 Rename ftl to fxl in Fuchsia specific code (#4090) 2017-09-11 15:58:48 -07:00
Carlo Bernaschina
a246501917 Roll Dart to 491390eeaa7974f44a8931d10a899c39c0df8dda (#3984)
- Roll Dart to 491390eeaa7974f44a8931d10a899c39c0df8dda
- Register the EmbedderInformationCallback
2017-08-16 13:17:11 -07:00
Yegor
ff50334587 enable async stack traces in all modes (#3948) 2017-08-04 12:22:20 -07:00
Alexander Aprelev
ba9a525bdc Update Flutter engine kernel-loading logic. (#3886)
* Fix Flutter loading from dill files.

* Remove disable of causal async stacks.

* Include mirrors patch files as they are needed for release/profile gen_snapshot

* Free the bytes

* Add FTL_DCHECK
2017-07-24 09:47:23 -07:00
Zachary Anderson
e385c1b454 [Fuchsia] Pass command line arguments for tracing (#3868) 2017-07-12 15:17:24 -07:00
Ryan Macnak
dd634d349d Revert "Allow SIGQUIT to toggle the vm-service server a la command line Dart. (#3857)" (#3859)
This reverts commit d67b614a29fe9dc112ddc0b60b6eb685c1f55eb1.

Fuchsia TO-370
2017-07-10 15:57:26 -07:00
Ryan Macnak
d67b614a29 Allow SIGQUIT to toggle the vm-service server a la command line Dart. (#3857)
Fixes flutter/flutter#9128
2017-07-10 13:08:00 -07:00
Zachary Anderson
11131b2678 [Fuchsia] For profiling, export symbols, profile the VM (#3756) 2017-06-08 13:57:31 -07:00
Todd Volkert
f5d92bee15 Add ipv6 flag to shell. (#3646)
It controls whether the observatory and diagnostic server will
bind to the IPv6 loopback address rather than the IPv4.

Fixes https://github.com/flutter/flutter/issues/9813
2017-05-04 19:35:59 -07:00
Ryan Macnak
1084a83f11 AOT for Fuchsia. (#3570) 2017-04-11 14:53:14 -07:00
Jason Simmons
29f289acbb Remove dart:jni (#3546)
Fixes https://github.com/flutter/flutter/issues/9129
2017-03-31 13:07:52 -07:00
Jason Simmons
e5442c96ae Return an error to Dart when spawning an isolate with an unsupported URI (#3443)
Fixes https://github.com/flutter/flutter/issues/8084
2017-02-24 09:44:36 -08:00
Dan Rubel
481049f9cd add kernel support (#3369) 2017-02-16 10:11:38 -05:00
Jason Simmons
e70d3ea1df Enable some new Dart VM features (#3408)
Fixes https://github.com/flutter/flutter/issues/7579
2017-02-10 12:28:41 -08:00
Zachary Anderson
f2866146a7 Properly return VM service assets on Fuchsia. (#3406)
In a previous change I re-included the observatory assets in the Fuchsia build, but didn't notice this bit here.

After this, if Settings::enable_observatory can be set to true somehow, the Observatory will come up in Flutter apps on Fuchsia. Unfortunately, I'm not sure how to do that.
2017-02-09 15:18:35 -08:00
Chinmay Garde
9053b6c0ab Allow running in debug product mode with checked mode off. (#3398) 2017-02-07 17:01:27 -08:00
Ryan Macnak
adef37080f Adapt to refactoring of snapshot APIs in the Dart VM. (#3354)
Adapt to refactoring of snapshot APIs in the Dart VM.
2017-01-23 12:09:59 -08:00
Chinmay Garde
2fc99153b7 Decorate kDartWriteProtectCodeArgs with FTL_ALLOW_UNUSED_TYPE since it may not be used in all configurations. (#3302) 2016-12-08 16:26:39 -08:00
John McCutchan
5afca375e3 Disable code page write protection in debug mode (#3299) 2016-12-08 15:06:13 -08:00
Todd Volkert
dd17a112c1 Make dylib filename configurable in Info.plist for iOS (#3277) 2016-11-28 19:44:08 -08:00
Chinmay Garde
327d122de9 Disable profiling by default. Allow enabling via --enable-dart-profiling. (#3238) 2016-11-21 11:50:42 -08:00