Enable shutting down all root isolates in a VM.#8457
Enable shutting down all root isolates in a VM.#8457chinmaygarde merged 1 commit intoflutter:masterfrom
Conversation
This reverts commit 800ea0a.
| static std::mutex gVMMutex; | ||
| static std::weak_ptr<DartVM> gVM FML_GUARDED_BY(gVMMutex); | ||
| static std::shared_ptr<DartVM> gVMLeak FML_GUARDED_BY(gVMMutex); | ||
| static std::shared_ptr<DartVM>* gVMLeak FML_GUARDED_BY(gVMMutex); |
There was a problem hiding this comment.
This is the only difference between the previous patch and this reland. It used to be a shared pointer and now it is a pointer to one.
liyuqian
left a comment
There was a problem hiding this comment.
LGTM with a nit on more explanation on leak_vm.
| @@ -88,7 +88,7 @@ DartVMRef DartVMRef::Create(Settings settings, | |||
| gVM = vm; | |||
|
|
|||
| if (settings.leak_vm) { | |||
There was a problem hiding this comment.
Nit: can we have a comment in settings.h that explains why leak_vm is default to true (I guess that it's to preserve our old behavior)? The name leak_vm sounds scary to me, especially considering that its default value is true...
There was a problem hiding this comment.
Missed this. Sure will update the comment in an incoming patch. You're right, it is to preserve old behavior. Applications tend to "warm-up" the VM and depend on the VM running when launching subsequent apps. Not leaking by default breaks these workarounds.
flutter/engine@6bc33b5...fea42a2 git log 6bc33b5..fea42a2 --no-merges --oneline fea42a2 Roll src/third_party/dart 9e1adc54a7..389ccc9000 (10 commits) d6cf2bd Roll src/third_party/dart da4ccd0855..9e1adc54a7 (3 commits) 0c2a2c1 Initialize OpacityLayer&flutter#39;s matrix to identity (flutter/engine#8467) 7fd4caf Roll src/third_party/dart 1ad11facec..da4ccd0855 (6 commits) d3fbaea Android Embedding PR25: Prevent black rectangle when launching FlutterActivity (flutter/engine#8460) 99da038 Document the leak_vm flag. (flutter/engine#8462) ce7c21c Log the correct function on error in the embedder. (flutter/engine#8461) e10d464 Improve path metrics tests and docs (flutter/engine#7851) 424045c Enable shutting down all root isolates in a VM. (flutter/engine#8457) 816e3dc Roll src/third_party/dart 907c514c89..1ad11facec (7 commits) 45dc353 Roll src/third_party/skia 0e35ce27e0e9..053b2939938c (10 commits) (flutter/engine#8458) This roll also includes manual fix for @mustCallSuper update: call the super method whenever possible, and suppress warnings in tests.
flutter/engine@6bc33b5...0c393d6 git log 6bc33b5..0c393d6 --no-merges --oneline 0c393d6 Roll dart back to 907c514c8937cf76e (flutter/engine#8473) fea42a2 Roll src/third_party/dart 9e1adc54a7..389ccc9000 (10 commits) d6cf2bd Roll src/third_party/dart da4ccd0855..9e1adc54a7 (3 commits) 0c2a2c1 Initialize OpacityLayer's matrix to identity (flutter/engine#8467) 7fd4caf Roll src/third_party/dart 1ad11facec..da4ccd0855 (6 commits) d3fbaea Android Embedding PR25: Prevent black rectangle when launching FlutterActivity (flutter/engine#8460) 99da038 Document the leak_vm flag. (flutter/engine#8462) ce7c21c Log the correct function on error in the embedder. (flutter/engine#8461) e10d464 Improve path metrics tests and docs (flutter/engine#7851) 424045c Enable shutting down all root isolates in a VM. (flutter/engine#8457) 816e3dc Roll src/third_party/dart 907c514c89..1ad11facec (7 commits) 45dc353 Roll src/third_party/skia 0e35ce27e0e9..053b2939938c (10 commits) (flutter/engine#8458) The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+/master/autoroll/README.md If the roll is causing failures, please contact the current sheriff ([email protected]), and stop the roller if necessary.
This reverts commit 800ea0a.
This reverts commit d80409c.
This reverts commit d80409c.

This reverts commit 800ea0a.