-
Notifications
You must be signed in to change notification settings - Fork 30.1k
Description
+[NSBundle bundleWithIdentifier] is slow, and scales to the size of the app. On iOS flutter/engine#39975 searches within the privateFrameworksURL where the default bundle is expected to be located first, then falls back to +bundleWithIdentifier. When tested internally, this improves startup of customer: chalk by 30% on iOS - see http://shortn/_WcifhO48X6.
I suspect macOS could benefit from the same optimization:
@jiahaog said:
I don't have a setup for profiling macOS apps now so I can't say for sure now, but I would expect this to also happen there – we should perhaps follow up separately. It seems like Chrome also encountered this problem on macOS - see
GetFrameworkBundlePath(L156) of https://chromium.googlesource.com/chromium/src/+/master/chrome/common/chrome_paths_mac.mm.
flutter/engine#39975 (comment)
cc @cbracken