• 中国计算机学会会刊
  • 中国科技核心期刊
  • 中文核心期刊

J4 ›› 2014, Vol. 36 ›› Issue (01): 19-27.

• 论文 • 上一篇    下一篇

基于QEMU实现的处理器类故障模拟与注入方法研究

李毅1,徐萍1,万寒2   

  1. (1.北京航空航天大学可靠性与环境工程技术重点实验室,北京 100191;
    2.北京航空航天大学虚拟现实技术与系统国家重点实验室,北京 100191)
  • 收稿日期:2012-08-31 修回日期:2012-10-22 出版日期:2014-01-25 发布日期:2014-01-25
  • 基金资助:

    国防科工局技术基础科研项目(Z132012A004)

Research on a QEMU based processor fault simulation and injection method      

LI Yi1,XU Ping1,WAN Han2   

  1. (1.Key Laboratory of Science and Technology on Reliability and Environment Engineering,Beihang University,Beijing 100191;
    2.State Key Laboratory of Virtual Reality Technology and Systems,Beihang University,Beijing 100191,China)
  • Received:2012-08-31 Revised:2012-10-22 Online:2014-01-25 Published:2014-01-25

摘要:

故障注入技术在BIT软件测试中是一种有效的手段。针对电路板级BIT软件测试中遇到的问题,介绍了一种基于开源模拟器QEMU实现的处理器类故障模拟方法。采用该方法对多种处理器故障进行仿真建模,通过对QEMU的扩展开发,加入故障行为模拟模块和故障注入模块,以实现一个具有处理器类故障注入功能的系统级模拟器BitVaSim。首先分析处理器功能故障模式,提取故障的关键字值对,用XML Schema定义故障并用于故障建模;其次对QEMU代码进行二次开发以实现对处理器故障行为的模拟;然后通过配置故障注入接口实现模拟器运行时的故障模式匹配、故障按条件触发等功能;最后通过实验案例来观察模拟器的故障表现,评价这种基于模拟器的故障注入技术。实验过程和结果显示这种方法是有效可行的。

关键词: 模拟器, 故障注入, 故障建模, BIT软件测试

Abstract:

Fault injection technique is an effective means for BIT software testing. Addressing to the problems encountered in the boardlevel BIT software testing, this paper proposes a fault simulation and injection method based on the open source simulator QEMU. This method models and simulates a variety of processor class fault mode after the expansion and development of QEMU, which joins faulty behavior simulation and fault injection modules to achieve a system level simulator BitVaSim. Firstly, processor function failure mode analysis is given, keyvalue pair of faults are extracted, and XML Schema is used to define and model faults. Secondly, a second development is conducted on QEMU codes so as to simulate the fault behavior of processors. Thirdly, fault injection interfaces are configured to implement failure mode matching and fault conditions triggering to inject faults on demand in simulator runtime. Experimental results demonstrate the accuracy and potential of BitVaSim in the evaluation of the dependability properties of the complex computer systems and the BIT system.

Key words: Simulator;fault injection;fault modeling;BIT software testing