计算机应用 ›› 2017, Vol. 37 ›› Issue (4): 1129-1134.DOI: 10.11772/j.issn.1001-9081.2017.04.1129

• 计算机软件技术 • 上一篇    下一篇

针对Android资源泄漏的基准测试集的构造与评测

刘洁瑞1,2, 巫雪青3, 严俊1,2,4, 杨红丽3   

  1. 1. 计算机科学国家重点实验室(中国科学院软件研究所), 北京 100190;
    2. 中国科学院大学 计算机与控制学院, 北京 100049;
    3. 北京工业大学 计算机学院, 北京 100124;
    4. 中国科学院软件研究所 软件工程技术研究开发中心, 北京 100190
  • 收稿日期:2016-09-09 修回日期:2016-12-23 出版日期:2017-04-10 发布日期:2017-04-19
  • 通讯作者: 严俊
  • 作者简介:刘洁瑞(1990-),男,四川成都人,硕士研究生,主要研究方向:程序分析与测试;严俊(1980-),男,湖北石首人,副研究员,博士,CCF会员,主要研究方向:程序分析与测试;杨红丽(1970-),女,陕西宝鸡人,副教授,博士,CCF会员,主要研究方向:程序分析与验证。
  • 基金资助:
    国家自然科学基金资助项目(91418206)。

Benchmarks construction and evaluation for resource leak in Android apps

LIU Jierui1,2, WU Xueqing3, YAN Jun1,2,4, YANG Hongli3   

  1. 1. State Key Laboratory of Computer Science(Institute of Software, Chinese Academy of Sciences), Beijing 100190, China;
    2. School of Computer and Control Engineering, University of Chinese Academy of Sciences, Beijing 100049, China;
    3. College of Computer Science, Beijing University of Technology, Beijing 100124, China;
    4. Technology Center of Software Engineering, Institute of Software, Chinese Academy of Sciences, Beijing 100190, China
  • Received:2016-09-09 Revised:2016-12-23 Online:2017-04-10 Published:2017-04-19
  • Supported by:
    This work is partially supported by National Natural Science Foundation of China (91418206).

摘要: Android系统是目前最受欢迎的开放手机操作系统,然而高度的开放性也引来了许多问题,资源泄漏就是其中普遍存在的一个。对于Android系统出现的资源泄漏以及没有基于该漏洞的基准测试集被提出的问题,构造出了一套针对Android资源泄漏的基准测试集ResLeakBench。首先,参考Android官方文档以及观察大量的真实Android应用,整理出了Android程序中使用的资源操作以及它们常用的使用场景。然后,根据整理的信息自主构造了35个基准测试程序;另外,收集了35个资源使用相关的真实开源程序作为基准测试程序来保证测试集的实用性。最后,利用ResLeakBench对资源泄漏检测工具Relda2以及资源泄漏修复工具RelFix进行了有效性评测,发现了Relda2以及RelFix工具存在的问题。实验结果表明ResLeakBench针对资源泄漏问题是一套实用的基准测试集。

关键词: 基准测试程序, Android应用, 资源泄漏, 工具评测, 程序分析

Abstract: Android system is becoming the most popular mobile operating system for its opening property. However, the opening also brings some problems, the resource leak is one of the common ones. For the problems that resource leak is existed in Android system and no benchmarks has been provided for this specific issue, a benchmark named ResLeakBench for resource leak problem was proposed. First, official Android reference and a lot of real apps were studied, then the operation of resources and their common application scenarios were generalized. Second, 35 self-designed test apps were put into the benchmark according to the collected information; besides, to ensure the practicality of the benchmarks, 35 real apps related to resources were added into the benchmark. Finally, to evaluate the ResLeakBench, the resource leak analysis tool Relda2 and resource leak fixing tool RelFix were tested on the benchmark, and some shortages of Relda2 and RelFix were found. The experimental results show that ResLeakBench is a practical benchmark.

Key words: benchmarking procedure, Android app, resource leak, tool evaluation, program analysis

中图分类号: