CN

What Should Be in a Book About Android Smoothness?

Word count: 1.7kReading time: 10 min
2021/10/27
loading

Recently, I read a new book: Building Smooth Android Apps (JD link: https://item.jd.com/10035215362170.html). I bought it because of the title, and after reading it, I felt it was necessary to write an article so that colleagues who haven’t bought it yet can understand what it’s about.

My personal suggestion is: if you are an experienced developer, I don’t recommend buying it. This book doesn’t go into much depth on principles and doesn’t offer a comprehensive overview of Android smoothness. If you are a beginner, it’s decent for broadening your horizons and identifying gaps in your knowledge, but it’s still a bit lacking for a deep understanding of Android smoothness.

I say this because the book doesn’t focus much on performance or smoothness. It lacks deep theoretical parts. Instead, a large portion is dedicated to static code analysis, using Android Studio Profiler, App architecture, app stay-alive techniques, network performance optimization, APK size optimization, app power consumption, etc. These topics are covered briefly and at a shallow level.

Reading note (reviewed October 2026): This is a book review and proposed outline from 2021. The personal opinions remain unchanged. Book links and WeRead availability record that period, not current stock or access. The updates below clarify performance categories and tool/version boundaries.

Book Cover

Content Overview

Here is a brief introduction to the book’s content and chapters:

  1. Overview: Briefly introduces why performance optimization is needed and how to configure Android Studio.
  2. Static Code Analysis: Covers various static analysis tools in detail, such as Android Lint, CheckStyle, SpotBugs, PMD, etc. Except for Lint, I hadn’t used the others much, so this was a good refresher.
  3. Performance Optimization with Android Profiler: Focuses on the CPU, Memory, and Network Profilers within the AS Profiler tool. The emphasis is on tool usage, with high-level introductions.
  4. High-Quality Apps Start with Architecture: Discusses architectural principles like MVC, MVP, and MVVM.
  5. Elegant App Stay-Alive Techniques: A brief introduction to techniques for keeping apps running in the background.
  6. Network Performance Optimization: Covers network interaction, multi-threading, and large-scale data transfer optimization.
  7. Optimizing APK Size: The usual topics: multi-channel packaging, resource optimization, and code obfuscation.
  8. App Power Consumption and Crash Experience Optimization: A brief overview of these areas.

As you can see from the chapter titles, there is relatively little content specifically about “smoothness.” The topics are quite diverse. If you’re interested, you can buy a copy to take a look.

What Do I Think a Book on Smoothness Should Contain?

I couldn’t write such a book myself, and I have great respect for technical authors. But that doesn’t stop me offering my “armchair” opinions. I’m good at that part. If I were to write this book, I would include the following content to ensure readers gain a deep understanding of Android smoothness principles and become proficient in using various tools to analyze issues.

In Android performance discussions, jank, responsiveness, and ANR often appear together, but they are not severity levels of the same condition. Jank concerns whether frames arrive at the expected cadence; responsiveness concerns the delay from an action to its visible result; an ANR is triggered when the system detects a timeout in a particular situation. ANR types have different triggering conditions and timeout rules. Main-thread blocking can affect all three, but many dropped frames do not automatically imply an ANR, and slow responses need not be rendering problems. Here, “smoothness” is a broad organizing term. User reports still require a specific symptom and measurement definition. See the official guides to rendering performance and ANR diagnosis.

Here is my proposed chapter structure:

  1. Chapter 1: Overview of Android Smoothness: Concepts from the perspectives of users, developers, testers, AOSP, and hardware. It’s important not to limit your thinking to just one role.
  2. Chapter 2: Overview of Android Runtime Mechanisms: Essential knowledge for analyzing smoothness. Once you understand these, you can picture what is happening: what did the user do, how did the system respond, where has the app got to, what might be wrong, and which tool would help you check?
    • App Main Thread Principles (Main Thread vs. Render Thread)
    • Message, Handler, MessageQueue, and Looper mechanisms
    • Screen Refresh Mechanism and Vsync
    • Choreographer mechanism
    • Buffer and SurfaceFlinger workflows
    • Input handling flow
    • Design philosophy of ANRs
  3. Chapter 3: Performance Analysis Tools: A craftsman is only as good as his tools. This chapter would go beyond simple introductions, explaining regular performance analysis tools in the context of system mechanisms: Perfetto and the older Systrace tool, AS Profiler, Simpleperf, MAT, Log tools (analysis and principles), Command-line tools (dumpsys for meminfo, gfxinfo, cpuinfo, SurfaceFlinger, activity, input, window, etc.), and Third-party libraries (Koom, Matrix, Profilo, BlockCanary, LeakCanary, Tailor/Raphael, etc.).
  4. Chapter 4: Deep Dive into Android Jank: Practical strategies for identifying causes, workflows for analysis, case studies, and coding best practices.
  5. Chapter 5: Deep Dive into Android Responsiveness: Similar to the above, but focused on responsiveness issues.
  6. Chapter 6: Deep Dive into Android ANR: Understanding the design, types, causes, and analysis workflows for ANRs, along with case studies and best practices. (Likely a very detailed chapter).
  7. Chapter 7: Deep Dive into Android Memory Issues: Memory is a critical performance metric. This chapter would cover app memory footprint, analysis tools, memory leaks, and continuous growth analysis.
  8. Chapter 8: Performance Testing: Smoothness from a testing perspective: retrieving metrics (intrusive vs. non-intrusive), setting standards, competitor analysis, bug reporting flows, full-device testing, third-party specifications and platform metrics (the original examples include the Green Alliance, Master Lu, Umeng, and Bugly; distinguish specifications, scores, and monitoring services rather than treating them as one authoritative standard), and monitoring and test automation (components such as Matrix and KOOM, action drivers such as Fastbot and UI Automator, and scenarios such as memory growth). Also covers soft skills: distinguishing between system and app issues and arguing it out with PMs and developers (kidding!).
  9. Chapter 9: Online Performance Monitoring: Unlike offline testing, online monitoring must reflect real user experience with minimal impact while ensuring timely data reporting.
  10. Chapter 10: Introduction to System Performance Optimization: How do Android system developers (AOSP, Qualcomm, MTK, OEMs) optimize performance?
  11. Chapter 11: High-Efficiency Work Guide:
    • Necessity and process of compiling AOSP code.
    • Tips for reading AOSP code (cs.android.com, importing into AS/VS Code, flowcharts).
    • Recommended dev environments (Windows, Linux, Mac) and command-line configurations.
    • Work habits: writing, recording, summarizing, and sharing.

That’s my “armchair” outline. Everything is ready—just waiting for an expert to fill in the content!

Tools and validation update (October 2026): The chapter outline remains, with these distinctions for present-day use.

  • System tracing: Systrace and Perfetto are distinct tools. Android’s guidance recommends Perfetto for Android 10 and later. On supported Android 12 (API 31) and later systems, FrameTimeline also lets you compare expected and actual frame timelines. Check whether the capture covers the required data, windows, and frame types; an average FPS alone is insufficient.
  • App tools: Treat the book’s Profiler UI as historical. The current Network Inspector is under Android Studio’s View > Tool Windows > App Inspection. Maintenance differs across libraries: Profilo’s official repository is archived, so treat it as a historical implementation rather than a default integration for a new project. Check other libraries individually for version compatibility.
  • Reproducible tests: Macrobenchmark can measure startup and interactions such as scrolling, with traces for investigation. Control the scenario, device, build type, compilation state, and repetitions, and record factors such as thermal state. UI Automator and Fastbot drive actions; they do not automatically establish a universal smoothness pass criterion.
  • Development hosts: App development on Windows, Linux, or macOS is distinct from building the AOSP operating system. Current AOSP requirements specify a 64-bit x86 host running 64-bit Linux. Official macOS support for Android OS development ended with Android 11.

What Other Performance Books Are Available?

Many books on the market are a bit dated. However, the Juejin community has a wealth of articles on Android performance, and many large companies open-source their internal tools. Let’s keep moving forward on the shoulders of giants.

Here are a few books I’ve read:

  1. Evaluation and Optimization of Mobile App Performance by Tencent TMQ: Published in 2016, very professional and practical. (Available on WeChat Reading). Original book link.

  2. Understanding Android: Java Virtual Machine ART by Deng Fanping (邓凡平): A massive tome on the ART VM, helpful for understanding “black tech” involving the VM. (Available on WeChat Reading). Original book link.

  3. High-Performance Android Apps by Doug Sillars: Published in 2016, an early comprehensive guide. Original book link.

  4. Best Practices for Android App Performance Optimization by Tencent developers: Published in 2017. (Available on WeChat Reading). Original book link.

  5. BPF Performance Tools by Brendan Gregg: Chinese edition published in 2020. A fundamental tool for system performance. Original book link.

  6. Systems Performance: Enterprise and the Cloud by Brendan Gregg: Chinese edition published in 2020. A must-have for anyone doing performance work. (Available on WeChat Reading). Original book link.

  7. Android Development Master Class by Zhang Shaowen (Geek Time column): Listening to it again recently, all I could think was: the man really knows his stuff.

    Original course link

    Android Development Master Class

  8. Linux Performance Optimization by Ni Pengfei.

    Linux Performance Optimization course

Final Thoughts

  1. Feel free to share your own recommendations for Android performance books, blogs, videos, or tutorials.
  2. What do you think should be included in a book about Android smoothness?
  3. This article is for sharing only, with no promotional links.
  4. Feedback is welcome on my Zhihu or WeChat accounts, or via WeChat (553000664) with “Blog” in the request.

About Me && Blog

Below is my personal introduction and related links. I look forward to exchanging ideas with fellow professionals. “When three walk together, one can always be my teacher!”

  1. Blogger Intro: Includes personal WeChat and WeChat group links.
  2. Blog Content Navigation: A guide for my blog content.
  3. Curated Excellent Blog Articles - Android Performance Optimization Must-Knows: Welcome to recommend projects/articles.
  4. Android Performance Optimization Knowledge Planet: The paid community stopped operating in 2026 and no longer accepts new members; this link preserves its history.

One walks faster alone, but a group walks further together.

Scan WeChat QR Code

CATALOG
  1. 1. Content Overview
  2. 2. What Do I Think a Book on Smoothness Should Contain?
  3. 3. What Other Performance Books Are Available?
  4. 4. Final Thoughts
  5. 5. About Me && Blog