[关键词]
[摘要]
现有的计算软件可靠性的方法采用测试的输入/输出结果,但这些数据并不能真实地反映软件内部的真实行为,如测试中会出现假性正确的情况以及测试不能显示一个输入有多个错误的输出情况.试图通过程序不变量来计算软件的可靠性,程序不变量可以描述程序的性质.首先选取测试用例集,动态地获取程序不变量,再从这些不变量中提取失效数据,最后,基于Nelson模型计算软件的可靠性.作为实验,对西门子程序包计算软件的可靠性.采用随机、分支覆盖和分块覆盖这3种不同的测试方法得到程序不变量,据此计算程序的可靠性.为了检查结果的可行性,采用传统方法计算这些软件的可靠性.两种可靠性比较后显示:它们的差别很小,而且不依赖于对测试方法的选择.通过进一步的方差分析得知,用所提出的方法计算的可靠性比用现有的方法计算的可靠性具有更小的波动,即更平稳.因此,前者更接近系统的真实可靠性.结论说明,可用程序不变量来计算软件的可靠性.
[Key word]
[Abstract]
Existing methods to compute software reliability use the testing data of input and output. However, the data cannot truly reflect the behaviors of the software. For examples, it is possible that testing has false positive outputs, and one input with multiple faults cannot be revealed in the testing. This paper attempts to use program invariants to compute software reliability. First, test cases are selected to dynamically obtain program invariants. Then, the failure data from these invariants are extracted. Finally, the software reliabilities is computed based on Nelson model. In experiments, the reliabilities of the software in the Siemens set are computed. Program invariants are obtained by applying three different testing methods:random, branch coverage and block coverage. The reliabilities are computed next based on these invariants. To check the correctness of the results, software reliabilities are also computed with traditional methods. A comparison shows that the differences between two types of reliabilities are small no matter which testing method is selected. Further variance analysis shows that reliabilities by the proposed method have lower fluctuation, i.e., more stable, than those with existing methods, thus is closer to the real reliability of the system. This suggests that software reliability can be computed based on program invariants.
[中图分类号]
[基金项目]
国家自然科学基金(61210004,61170015)