-
Notifications
You must be signed in to change notification settings - Fork 515
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
[net] iOS fat (armv7 + arm64) apps are not optimal #12607
Comments
At least for iOS using App Thinning would be better (for end-users) than doing a better deduplication of the assemblies assemblies -> #12665 |
We get significant differences for all BCL assemblies. I commented on that in dotnet/runtime#62953 and I think that needs to be investigated on the runtime side. Xamarin.Android apparently seems to be doing some deduplication based on ModuleVersionId, presumably the same could be done in the merge task for Xamarin.Mac/iOS. |
Turns out that the assembly size/content difference we hit on osx-x64/osx-arm64 is from the R2R images used by CoreCLR and Crossgen2. It should not affect the Mono runtime packs and mobile platforms but it's something interesting to keep in mind. Additionally I discussed it with the MonoVM folks and we found that the deduplication by MVID scenario is broken at the moment. There was an issue with Cecil/Linker in .NET 6 that caused some assemblies to get same MVID despite them not being identical (dotnet/linker#2203). Now that issue was supposedly fixed for .NET 7 but it appears it caused identical assemblies to get different MVIDs too (at least in two runtime assembly packs we compared) so an opposite problem. |
This will not be done in the .NET 7 time frame due to time constraints, so moving to .NET 8. |
This won't be an issue in .NET 8, because we're dropping support for 32-bit iOS (#15216). |
iOS fat (armv7 + arm64) app
Assemblies
Assemblies deduplication is not possible (e.g.
System.Runtime.dll
andMySimpleView.dll
should be shared) due to some minor changes, e.g. the path to the.pdb
file is not identical between builds. There's no diff when you compare the disassembly of both assemblies.System.Private.CoreLib.dll
is quite different (and afaik the source assembly is not identical anyway) making it hard to share.System.Private.CoreLib.dll diff
Xamarin.iOS.dll
differs due to 32/64 differences. Those could be solved by preserving additional members and moving the bit-aware types to a different (but much smaller) assembly (with type forwarders for compatibility).App Bundle Comparison
Comparison with legacy is a bit harder since the file's location is not identical.
The situation for macOS should be a little different (and simpler) since both slices would be 64 bits.
The text was updated successfully, but these errors were encountered: