-
Notifications
You must be signed in to change notification settings - Fork 30.1k
Description
Since https://dart-review.googlesource.com/c/sdk/+/151635, this flag helps limit how much memory the VM will allocate in old space, and should help trigger collections more aggressively as we approach device limits.
On Android, this could be defaulted to dalvik.vm.heapsize, which is the size of a "largeHeap" app on Android. My only concern with this is that this value is likely much lower than what we currently allow - i.e. I haven't seen it larger than 512mb, whereas I've definitely run apps without OOMing that use multiple gigabytes of RAM.
On iOS, we should probably be safe with [NSProcessInfo processInfo].physicalMemory / 2. Some devices seem to let you use more (e.g. use up to 75% of memory before killing you), but some are as low as half.
- Android
- iOS
- Fuchsia (TBD)
/cc @iskakaushik @gw280 for input on Fuchsia
/cc @rmacnak-google FYI