Instagram App Modularization and Lazy Load

At Instagram we aim to write modularized code with features being encapsulated and decoupled. This gives us full control over when a feature is first invoked and its code loaded into memory. We try to make sure that only core features are loaded in memory during cold start. To further speed up cold start time and overall runtime we put features into separate dex files and load them lazily. This also applies for native libraries. And it opens up a potentially interesting opportunity to download features and make app fully adaptive to users' needs.

Julian KrzemiƄski, Facebook

I'm an Android engineer working on Instagram Client Performance team. My area of focus is improving cold start time and overall runtime and minimize application size. Before Instagram I was on the Messenger team implementing end-to-end encrypted messaging.