节点文献
引用未初始化变量故障静态测试方法研究
Research on the Static Testing Method of Referencing Uninitialized Variables
【摘要】 引用未初始化变量故障往往存在于C/C++程序中,该类故障常常会导致系统崩溃.鉴于传统测试方法、编译器和现有静态测试工具检测这类故障的局限性,本文提出了基于引用未初始化变量故障模型的静态测试方法.首先给出了引用未初始化变量的形式化定义,作为研究引用未初始化变量的基础;分析了变量状态及其变化,建立了变量状态集产生模型,作为静态识别引用未初始化变量的前提基础;建立了引用未初始化变量故障模型,作为静态识别引用未初始化变量的依据;提出了引用未初始化变量自动测试算法.实验结果表明,基于引用未初始化变量故障模型的静态测试方法具有较高的故障检测准确率和测试效率,这说明建立的故障模型和自动测试方法是有效的.
【Abstract】 Referencing uninitialized variables usually exist in C/C++ programs, and often lead to system crash. Since the limitation of traditional testing methods, compilers and existing static testing tools in detecting referencing uninitialized variables, a static testing method based on the fault model of referencing uninitialized variables is proposed in this paper. Formal definition of referencing uninitialized variables is given firstly, as the basis of investigating referencing uninitialized variables. Variable’s state and its transformations are analyzed, and the generation model of variables’ states set is established, as the preconditions of identifying referencing uninitialized variables statically. Fault model of referencing uninitialized variables is established, as the basis of identifying referencing uninitialized variables statically. The automatic testing algorithm of referencing uninitialized variables is proposed. The experimental result shows that the static testing method could detect referencing uninitialized variables with higher accuracy and efficiency, which means that the fault model and the automatic testing method are valid.
【Key words】 software testing; referencing uninitialized variables; fault model; static testing method;
- 【文献出处】 小型微型计算机系统 ,Journal of Chinese Computer Systems , 编辑部邮箱 ,2007年05期
- 【分类号】TP311.52
- 【被引频次】4
- 【下载频次】127