一句话:提出静态分析工具 ServDroid,基于四类反模式自动检测 Android 应用中服务使用低效缺陷。
Android 应用常用 Service 在后台执行耗时操作,但作者的研究表明实践中服务的使用往往并不高效,会造成不必要的资源占用和能耗。由于这类服务使用低效不会立即表现为崩溃等显式失败,基于测试的方法难以发现它们。本文识别出四类服务使用低效缺陷的反模式:过早创建(premature create)、过晚销毁(late destroy)、过早销毁(premature destroy)以及服务泄漏(service leak),并据此提出静态分析技术 ServDroid,实现自动、有效地检测这些缺陷。作者将 ServDroid 应用于大量流行的真实 Android 应用,结果显示服务使用低效现象相当普遍,且会严重影响应用性能。
Services in Android applications are frequently-used components for performing time-consuming operations in the background. While services play a crucial role in the app performance, our study shows that service uses in practice are not as efficient as expected, e.g., they tend to cause unnecessary resource occupation and/or energy consumption. Moreover, as service usage inefficiencies do not manifest with immediate failures, e.g., app crashes, existing testing-based approaches fall short in finding them. In this paper, we identify four anti-patterns of such service usage inefficiency bugs, including premature create, late destroy, premature destroy, and service leak, and present a static analysis technique, ServDroid, to automatically and effectively detect them based on the anti-patterns. We have applied ServDroid to a large collection of popular real-world Android apps. Our results show that, surprisingly, service usage inefficiencies are prevalent and can severely impact the app performance.
DOI 原文 ·
@inproceedings{paperbot5082,
title = {ServDroid: detecting service usage inefficiencies in Android applications},
author = {Wei Song and Jing Zhang and Jeff Huang},
booktitle = {FSE},
year = {2019},
doi = {10.1145/3338906.3338950}
}