Repository navigation
Implement iOS app install deltas - #77756
Merged
Merged
Conversation
Member
Author
|
@anirudhb I would love to know if this feature is working for you, if you have any bandwidth. Please file any issues you see! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Incremental iOS installs (app-deltas) are an Xcode feature exposed by ios-deploy in ios-control/ios-deploy#434 that saves a representation of the app to a place on disk, then only copies the deltas over when installing. Only implemented for
BuildableIOSAppatbuild/ios/app-deltas, notPrebuiltIOSAppsince I wasn't sure where the app deltas directory should live.The app delta calculations are based on time stamp changes, not on file content hashes, so instead of deleting
build/ios/iphoneosand copying the app bundle on every build, insteadrsyncthe bundle so it only updates changed files, thus preserving the timestamps of unchanged files.I ran some numbers (on my machine an an iPhone 6s) building and installing the new non-trivial gallery app after a
flutter cleanThe first number is the amount of time
flutter runtakes where I force an exit as soon as the app is launched. The second number is the same, run a second time with noclean.So the improvements with thinning (#76834 and #77007), bitcode stripping (#77329), and codesigning (#77664) improved matters by ~3 seconds. App deltas gave us another ~14 seconds. It also cost us ~3 seconds on a first run, presumably to build the initial app-delta disk representation.
Note as long as
flutter cleanisn't run this will also be an improvement if any dart code changes and theApp.frameworkneeds to be recompiled, since the largeFlutter.frameworkand plugin frameworks won't be copied over on subsequent installs.BuildableIOSApppart of #67580.