Technical review · 2026-10-13. This article retains the manufacturer’s optimization-team experience and industry opinions from 2019. The technical sections now distinguish Android 12 (API 31) FrameTimeline, JankStats, and Macrobenchmark. Looper logging was checked against AOSP
android-9.0.0_r1/android-16.0.0_r1; Matrix v2.1.0 is the documented feature baseline. No new device measurements were performed.
Jank issues in Android matter to both smartphone manufacturers and app developers. Internal performance or platform teams often investigate and optimize them.
Tools such as Tencent’s Matrix provide app-side performance evidence. Manufacturers can add their own instrumentation and use system source access and suitable debugging privileges to collect deeper data. Actual visibility still depends on the OS version, kernel configuration, build type, and enabled data sources.
Smoothness is not just average FPS. Two intervals averaging 55 FPS can contain very different frame spacing: one might include a noticeable pause, while another is more evenly paced. Consider the intended update cadence, actual presentation intervals, and input response together. Refresh intervals at 60/90/120 Hz are about 16.67/11.11/8.33 ms, but they are not fixed CPU budgets summed across every thread. A static screen need not submit new content on every refresh.
Causes can lie in the app, system, kernel, or display pipeline. This series has four parts:
- 0. Overview of Jank and Frame Drops in Android - Methodology
- 1. Overview of Jank and Frame Drops in Android - System Layer
- 2. Overview of Jank and Frame Drops in Android - Application Layer
- 3. Overview of Jank and Frame Drops in Android - Low Memory
Locating the scenario and following its critical path remains useful. Prefer Perfetto/System Trace for new captures. On Android 12+ with the relevant frame data captured, use FrameTimeline to compare expected/actual frames, deadlines, and presentation relationships. Legacy Systrace remains useful for historical records; changing viewers cannot add data that was never captured. The tools below answer different questions.
1. Overview of Smoothness Work
As a member of a manufacturer’s optimization group, I should briefly describe our workflow. Many factors can cause jank in Android, but testing and users experience it most directly as dropped frames in the foreground app. Since they often can’t pinpoint the root cause, they report it to us as a general bug. We are the first stop for jank reports. We investigate, then pass the bug to the responsible team: Framework, App, Multimedia, Display, BSP, etc.
We rarely solve the technical bug ourselves. Instead, we use specialized tools combined with source code to locate issues. Our primary tools include:
- Perfetto/System Trace and ftrace place frames, scheduling, Binder, and kernel events on a timeline when the device permits and captures those sources.
- strace inspects system calls and results for selected processes/threads. It is not a whole-system performance trace, and attaching has permission requirements and overhead.
- Android Studio Profiler uses callstack sampling to locate CPU hotspots and Java/Kotlin method instrumentation to inspect specific calls. Those are different measurement methods.
- MAT and memory tools answer different questions. MAT analyzes Java heap objects and references offline; native allocations, process footprint, and system pressure require their corresponding profiler, meminfo, reclaim, or LMK evidence.
- Logs and log reports can contain Main/System/Event/Kernel/Crash logs, vendor Power/Performance logs, screenshots, and videos. Preserve their clocks, time ranges, and missing fields.
- Videos and local reproduction establish the interaction and visual symptom, then align it with a trace from the same run.
This takes some understanding of app development, the Android Framework, display systems, and the Linux kernel, plus practice with the tools. Once we find the cause, we discuss the fix with the people responsible for that module.
For changes that affect the system as a whole, we work with those teams on the solution. Sometimes we also develop a feature to address the problem.
2. Analysis Tools and Workflows
Start with the visible symptom and its time range, then narrow down to the relevant frame or interaction. A trace supplies leads; callstacks, source code, or controlled comparisons help establish the cause.
- Locate the frame and critical path. Record app/OS versions, device, refresh rate, actions, and cold/warm state. Where FrameTimeline is supported and captured, connect app-surface frames to their SurfaceFlinger frames, then inspect the main thread, RenderThread, Binder peers, and available GPU/fence tracks. The app and SurfaceFlinger main threads are entry points, not sufficient evidence for every jank. Games, independent Surfaces, and missing frame tracks require attention to their actual rendering paths. Missing tracks do not mean no jank.
- Separate execution from waiting. A long slice can contain CPU execution, Runnable scheduling delay, or lock/Binder/I/O waits. Use scheduling events and dependencies to decide where to investigate: app, system_server, SurfaceFlinger, HWC/display drivers, or resource contention. App deadline missed is a useful classification, not proof that app code alone caused the delay. The Systrace series remains useful background.
- Verify hotspots against source. The current Android Studio callstack-sampling task requires API 26+. Samples reveal hotspots, not a complete record of every invocation. Java/Kotlin method recording adds instrumentation overhead; the guide recommends recordings of roughly five seconds or less. Custom trace sections cover selected business operations, not an automatic full call tree. Breakpoints can verify control flow, but pause execution and invalidate normal frame-timing comparisons. Framework debugging additionally needs suitable system builds, symbols, and privileges.
- Add log context. Screenshots identify the UI, not jank duration; EventLog does not cover every user action. Align clocks before examining errors, process state, memory, and CPU records. In AOSP Looper, Slow delivery measures delay from the message’s scheduled time, msg.when, to dispatch start. Slow dispatch measures dispatch start to finish and may include waits; it is not CPU execution time. Thresholds, enablement, and suppression affect reporting, so absent logs do not establish zero delay.
- Reproduce and compare. High-speed video helps inspect visible pacing, but camera frame rate, display refresh rate, and recording overhead affect the observation. Keep device, version, temperature/load, and actions comparable. Capture repeated normal and abnormal runs, then compare after the fix without selecting only the best result.
The original state commands remain useful supporting entry points, subject to device permissions and version. They expose snapshots or aggregation windows, not an automatic reconstruction of an earlier frame:
| Command | Evidence and limits |
|---|---|
adb shell dumpsys activity oom |
Process importance/OOM adjustment information, not proof of an OOM or LMK event |
adb shell dumpsys meminfo |
Process/system memory statistics; one value alone establishes neither a leak nor the cause of jank |
adb shell cat /proc/buddyinfo |
Free blocks by node, zone, and order; each block is 2^order × PAGE_SIZE. Useful for physical allocation/fragmentation, not total available memory or a jank score |
adb shell dumpsys cpuinfo |
CPU usage over a reporting window, not instantaneous per-thread scheduling at the jank |
adb shell dumpsys input |
Input-system state; fields vary by version |
adb shell dumpsys window |
Window/focus state to correlate with input and frames from the same interval |
See the dumpsys guide and Linux v6.6 proc documentation. Unavailable permissions, disabled sources, and lost data are missing evidence, not zero load.
3. Data-Driven Analysis
User reports do not always give us the full picture, and our tests cannot cover everything. Performance data collected by the system or app gives us another way to investigate: users need not report each incident, and we can look for patterns across many samples.
Field data helps identify recurring scenarios, but device coverage, versions, sampling rates, and metric definitions affect the result. Jank rates from different measurement methods cannot simply be merged.
The 2019 Matrix feature diagram below is historical, not a current compatibility list. Matrix v2.1.0 includes Android tools such as Trace Canary, Resource Canary, IO Canary, SQLite Lint, and APK Checker. Applications still need to select/configure plugins and handle Issue callbacks and reporting. A historical “compatible with Android P” label does not establish compatibility with every newer release.

Manufacturers, with their source code access, collect even deeper data: CPU load, I/O load, Memory pressure, FSync times, Exception monitoring, Thermal monitoring, and Storage health. Each category might have dozens of sub-metrics. Someone with experience still has to decide which measurements are useful, what to collect, and how to interpret the results.
This was my view of manufacturers’ work in 2019, not a ranking of their current capabilities. The subsequent optimization work tests a company’s R&D strength. High-tier manufacturers optimize at the hardware-software boundary (resource allocation), while others focus on scenario-based resource policies.
Keep field trends and local regressions distinct. Android Vitals, JankStats, and custom APM differ in coverage and measurement. JankStats uses FrameMetrics on API 24+ and other mechanisms on earlier versions; its configurable jank heuristic is not SurfaceFlinger’s FrameTimeline presentation classification. Record scenario and version distributions so sample changes are not mistaken for improvements.
Turn a suspect interaction into a repeatable Macrobenchmark FrameTimingMetric journey and compare distributions and frame counts under matching conditions. Available since library version 1.1.0, frameOverrunMs requires API 31 and measures time relative to the frame deadline. frameDurationCpuMs covers the UI-thread/RenderThread CPU-side frame-production interval, not complete GPU/display latency. On older devices, keep unavailable frameOverrunMs data missing rather than reporting zero. A benchmark does not automatically replay a field user’s complete state, and one P99 result does not establish an improvement for the entire user population.
4. Summary
Those are the tools and approaches I wanted to outline. My work is mainly in Framework and apps, so much of this comes from that side. Kernel optimization teams will probably have useful angles I have not covered here.
The original article cited a 2019 discussion of Android system optimization. Its hardware/ecosystem grouping is retained as historical opinion, not a current product-performance ranking:
- Apple: Inhouse chips, OS, and ecosystem. They have the tightest control from hardware to app layers.
- Samsung & Huawei: Inhouse chips/core components but sharing the Android OS/ecosystem. They can perform Chip-to-OS integration.
- Other Top Android OEMs: Rely on different SoCs (Qualcomm, MediaTek). Their optimizations are often software-policy-based since they don’t always control the deepest chip layers.
The other articles in this series are listed below.
- 0. Overview of Jank and Frame Drops in Android - Methodology
- 1. Overview of Jank and Frame Drops in Android - System Layer
- 2. Overview of Jank and Frame Drops in Android - Application Layer
- 3. Overview of Jank and Frame Drops in Android - Low Memory
Zhihu Article
Original Chinese article and discussion
About Me && Blog
For my introduction and related articles:
- About me
- Blog navigation
- Android performance optimization: skills and tools
- Android performance community: The paid community stopped operating in 2026 and no longer accepts new members; this link preserves its history.
