基于值依赖分析的空指针解引用检测  被引量:4

Null Pointer Dereference Detection Based on Value Dependences Analysis

在线阅读下载全文

作  者:马森[1,2] 赵文[2,3] 习翔宇 王栋伟[2,3] 

机构地区:[1]北京大学信息科学技术学院,北京100871 [2]北京大学软件工程国家工程研究中心,北京100871 [3]北京大学信息科学技术学院软件研究所高可信软件技术教育部重点实验室,北京100871

出  处:《电子学报》2015年第4期647-651,共5页Acta Electronica Sinica

摘  要:本文提出了一种基于程序值依赖分析的、路径敏感的空指针解引用检测方法.该方法通过结合数据流分析中的到达定值分析、区间分析及指向分析创建了值依赖分析图,该图刻画了可能产生空指针语句到其解引用语句的值依赖关系.该图中的边采用守卫标注,即描述了相邻点之间的到达条件.为了降低误报率,本文同时提出了一种需求驱动的必然别名算法.由本文所述方法实现的工具展示了良好的实验效果,在10个SPEC2000项目中发现了70余个空指针解引用缺陷,误报率仅为6%左右.This paper presents a context-sensitive and path-sensitive algorithm for detecting null pointer dereferences (NPD). Our algorithm tracks the flow of values from the points where a null pointer might be produced to dereference points via value dependence graph that captures def-use relations and combines interval analysis results. Edges in the graph are annotated with guards that describe branch conditions in the program. In the meantime, for reducing the false warnings we propose an innovative demand-driven must-alias algorithm using this graph. Our implemented tool detects more than 70 points which might produce null pointer dereferences in ten SPEC 2000 benchmarks while keeping the false positive rate around 6 %, which is excellent experimental results.

关 键 词:程序分析 静态缺陷检测 空指针解引用检测 需求驱动别名分析 

分 类 号:TP311[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象