-
Notifications
You must be signed in to change notification settings - Fork 1.7k
need to support deferred libraries in VM / incremental compiler at least as noops #32245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
A related bug #31938 (there is no deserialization in cpp for deferred instructions) |
I've fixed the explosion in the compiler (currently in commit queue). |
This CL adds a test that bootstraps from a dill with a deferred library in it. Before this CL it crashed, see bug #32245. This CL "double fixes" the problem: a) When lazy loading a dill file the _currentLibrary variable wasn't set properly. This has been fixed. b) When bootstrapping from a dill file, (almost) everything in the dill will be included in the output so lazy loading it doesn't make sense. Bug: 32245. Change-Id: I94980608e19633fd31b522651a4a05b9cf7beabd Reviewed-on: https://dart-review.googlesource.com/42600 Commit-Queue: Jens Johansen <[email protected]> Reviewed-by: Kevin Millikin <[email protected]>
Introduce no-op LoadLibrary, CheckLibraryIsLoaded into kernel_binary_flowgraph.cc Bug: #32245 Change-Id: If93a4d717844dcb8a5d45d0237660ec764a6f738 Reviewed-on: https://dart-review.googlesource.com/42461 Reviewed-by: Vyacheslav Egorov <[email protected]> Reviewed-by: Kevin Millikin <[email protected]> Commit-Queue: Alexander Aprelev <[email protected]>
ec7029d patched VM side of things(deserialization, generation of no-op for deferred operations). |
Is there any work remaining here? |
@dgrove , ideally we add better support for deferred operations which means generating runtime calls(load, isLoaded) to corresponding LibraryPrefix objects. |
Created #32298 to track remaining(non-P0) work. Closing this. |
If you change
flutter_gallery
lib/main.dart
into this:and try to run it in
--preview-dart-2
mode then it explodes in both compiler and VMNote:
intl
package generates code that containsdeferred
so there are Flutter apps in a wild that usedeferred
. If we don't have time to supportdeferred
we should at least fix it to be a no-op whenFlutterTarget
is used.This issue was revealed when I tried to run this Flutter application: https://github.com/brianegan/flutter_architecture_samples/tree/master/example/built_redux
The text was updated successfully, but these errors were encountered: