arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1505.01878cs.SE
收藏

使用范围值监视的C程序故障检测:初步结果

Fault Detection in C Programs using Monitoring of Range Values: Preliminary Results

Pedro Pinto, Rui Abreu, João M. P. Cardoso

摘要:

本技术报告介绍了作为AutoSeer项目一部分所做的工作。我们在这个项目中的工作是开发一个源代码到源代码的编译器,MANET,为C语言,可用于仪器的关键部分的应用程序进行测试。其目的是使用LARA提供的面向汇编的方法来指导汇编流程并定义插装策略。这允许分离原始目标应用程序和检测次要关注点。这项工作的目标之一是开发一个源代码到源代码的C编译器,根据输入策略修改代码。这些修改可以提供针对性能和调试工具的代码转换,但在本工作中,它们用于注入代码,收集有关某些变量在运行时所取值的信息。这个编译器由AOP方法支持,该方法支持插装策略的定义。我们决定扩展现有的源到源编译器Cetus,并将其与LARA耦合,LARA是一种从目标程序设计语言中部分抽象出来的AOP语言。我们提出并评估了一种方法来检测故障的C程序通过监视变量的范围值。我们考虑各种监控策略,并使用两个实际应用程序,GZIP文件压缩器和ABS,由工业合作伙伴提供的程序。LARA中规定了不同的策略,并使用MANET自动应用。实验结果表明,我们的方法有潜力,但阻碍了不占数组和控制变量中的值。当将我们的方法与更传统的方法(将输出与预期结果进行比较)进行比较时,我们对ABS的预测准确率约为54%,对GZIP的预测准确率约为83%。

英文摘要:

This technical report presents the work done as part of the AutoSeer project. Our work in this project was to develop a source-to-source compiler, MANET, for the C language that could be used for instrumentation of critical parts of applications under testing. The intention was to guide the compilation flow and define instrumentation strategies using the Aspect-Oriented Approach provided by LARA. This allows a separation of the original target application and the instrumentation secondary concerns. One of the goals of this work was the development of a source-to-source C compiler that modifies code according to an input strategy. These modifications could provide code transformations that target performance and instrumentation for debugging, but in this work they are used to inject code that collects information about the values that certain variables take during runtime. This compiler is supported by an AOP approach that enables the definition of instrumentation strategies. We decided to extend an existing source-to-source compiler, Cetus, and couple it with LARA, an AOP language that is partially abstracted from the target programming language. We propose and evaluate an approach to detect faults in C programs by monitoring the range values of variables. We consider various monitoring strategies and use two real-life applications, the GZIP file compressor and ABS, a program provided by an industrial partner. The different strategies were specified in LARA and automatically applied using MANET. The experimental results show that our approach has potential but is hindered by not accounting for values in arrays and control variables. We achieve prediction accuracies of around 54% for ABS and 83% for GZIP, when comparing our approach to a more traditional one, where the outputs are compared to an expected result.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑