Xcode 14 accidentally increased the weight of many apps

Xcode 14, the development environment provided by Apple, promised to lighten the apps compiled by him, in particular those running on iOS 16 and later versions. The reality, however, is quite different, since this update has, on the contrary, contributed to increasing the size of iOS apps. And not just a little: for some apps, the weight increased by 68% by compiling in Xcode 14 instead of Xcode 13.

Guess the Xcode 14 release date only with this graph… (Emerge Tools image).

The creators of Emerge Tools, a series of tools for mobile app developers, detailed what happened in an article published on their blog. Since one of the tools they offer is designed to analyze the weight of an app in search of optimizations, they are particularly well placed to analyze the effect of Xcode 14 on many apps and to understand what is has passed.

The increase in the weight of apps compiled with Xcode 14 is the unfortunate consequence of the end of Bitcode, an idea launched by Apple in 2015 that could be roughly summarized as follows. Instead of sending a compiled app ready to install to App Store servers, developers send Bitcode, a file that basically contains instructions for compiling the final version. It is not the source code of the app, but an intermediary which would have enabled the Cupertino company to simplify the 64-bit transition on the Apple Watch, without calling on the developers.

Series 4: the transition to 64 bits facilitated by Bitcode?

Series 4: the transition to 64 bits facilitated by Bitcode?

The advantage of Bitcode is that the app you download has been optimized by Apple for your hardware. Among the optimizations carried out on its servers, the company notably removed the ” binary symbol », metadata files that are essential during development and compilation, but useless in the final file. Apparently, these documents can weigh heavily and this is what caused the increase in the weight of the apps with Xcode 14. Bitcode being disabled, the developers submitted final binaries to Apple and these were no longer optimized.

In the case of the Nike app chosen as an example, no less than an additional 127 MB are linked to these binary symbols which were not removed in the final version. They are particularly visible in the underlying frameworks, since each element has its own symbols and this ends up weighing particularly heavily on the final weight of the app.

Analysis of the frameworks of the Nike app with the latest version compiled under Xcode 13.
And the same analysis with the first version compiled under Xcode 14: the “String Tables” that have been added everywhere correspond to the binary symbols.

The site analyzed many apps on the App Store and found similar increases in many cases. Nike’s was the most spectacular in terms of volume gained due to binary symbols, but they can have a much lighter impact… even at Apple! The Shazam app, for example, grew by around 2MB following the upgrade to Xcode 14.

For developers, the article details how to configure compilation in Xcode 14 to remove binary symbols of the final app. The recommended method is a shell script to add to the process, just before signing the app. Maybe Apple will add a simpler option to do this automatically, but that’s not the case in the current version.

Apple did not justify the abandonment of Bitcode, so we do not know its exact motivations. We know, however, that this idea, with its many theoretical advantages, also had practical drawbacks. There are several situations where using Bitcode was not possible or not recommended and storing apps on App Store servers in this intermediate format does not guarantee their durability as much as with a compiled binary.

These disadvantages were not counterbalanced by advantages as obvious as expected and the format was finally used very little by the apple. All these elements taken together probably justified the termination of this initiative, seven years after its arrival.


Leave a Comment

Your email address will not be published. Required fields are marked *