Google Ben Weiss Nov 20, 2025

How Reddit used the R8 optimizer for high impact performance

M7 Related OWASP risk: Insufficient Binary Protections Learn more →

Article Summary

Ben Weiss from Google shares how Reddit achieved 40% faster cold startup and boosted Play Store ratings in under 2 weeks. The secret? Finally enabling R8 optimizer's full potential.

Reddit partnered with Android Developer Relations to evaluate their app using the App Performance Score. They identified major optimization opportunities and enabled R8's complete feature set, leading to dramatic improvements across startup time, stability, and user satisfaction metrics visible in both Android Vitals and Play Store ratings.

Key Takeaways

Critical Insight

Reddit achieved massive performance gains and higher Play Store ratings by enabling R8's full optimization mode in a focused two-week effort.

The article reveals the specific build.gradle configuration and macrobenchmark setup Reddit used to measure JIT compilation improvements.

About This Article

Problem

Reddit's app was slow to start up because JIT compilation happened on user devices during runtime, and dex files loaded inefficiently. This meant people had to wait longer before they could actually use the app.

Solution

Reddit used Baseline Profiles to shift JIT compilation from user devices to developer machines ahead of time. They also added Startup Profiles to optimize how dex files were packaged, letting the d8 dexer focus on the classes and methods that matter most.

Impact

Testing showed JIT compilation happened two-thirds less often and took one-third less time to complete. Users could start browsing 18% faster after launching the app.