叫什么名字了这个bug调查技术和项目是否实现自动化吗? [英] What is the name for this bug-finding technique and do programs exist to automate it?

查看:197
本文介绍了叫什么名字了这个bug调查技术和项目是否实现自动化吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

让我们说我有一些巨型项目 P 我知道有一个bug:当我和参数运行 A 它打印丑陋的错误信息电子。在外壳的符号,出现这种情况:

Let's say I have some giant program P which I know has a bug in it: when I run it with argument A it prints the ugly error message E. In shell notation, this happens:

$ ./P A
E
$

现在我没有任何想法是什么原因造成的错误,但它似乎是确定的。我寻找错误的做法是隔离它。我的节目 P 减持为仍然产生错误的最小的版本给出的参数<$ 电子 C $ C> A 。通过减少,我的意思是我会砍掉部分程序和手动内联函数,测试在每一个阶段的 P A - &GT; Ë,而不是一个成功响应或其他一些错误信息。有一次,我不能减少它了,我有一个小程序,它可能获取到问题的核心。

Now I don't have any idea what causes the bug, but it appears to be deterministic. My approach to finding the bug is to "isolate" it. I "reduce" the program P to the "smallest" version that still generates the error E given the argument A. By "reduce", I mean I will chop out parts of the program and manually inline functions, testing at every stage that P A --> E and not a success response or some other error message. Once I can't reduce it any more, I have a small program that probably gets to the core of the issue.

这过程是相当机械:它不需要对我而言多少见解。这感觉就像它可以自动完成:可能会有一些程序 X 其中,由于 P A 电子,吐出来的是最小的节目 P',使得 P 减少了 P' P'A - &GT; Ë

This process is fairly mechanical: it doesn't require much "insight" on my part. It feels like it could be done automatically: there could be some program X which, given P, A, and E, spits out the smallest program P' such that P reduces to P' and P' A --> E.

是这样,这种策略有一个名字,并已在任何意义上实现了自动化任何编程语言?

So, does this strategy have a name, and has it been automated in any sense for any programming language?

推荐答案

最后绊了一些答案我的问题!显然,这种技术被称为减少或最小化。参见:

Finally stumbled over something that answers my question! Apparently, this technique is known as "reduction" or "minimization". See:


  • CReduce ,该对C执行我所描述的还原的一般化版本,具体节目。

  • 三角洲,一个非常类似的程序。

  • DustMite ,其他类似的程序,最大限度地减少D程序。

  • 德尔塔调试,该描述的一般过程的页面。

  • 指南测试用例的减少对海湾合作委员会维基。

  • CReduce, which performs a generalized version of the reduction that I described, specifically for C programs.
  • Delta, a very similar program.
  • DustMite, another similar program, for minimizing D programs.
  • Delta debugging, a page which describes the general process.
  • A Guide to Testcase Reduction on the GCC wiki.

这篇关于叫什么名字了这个bug调查技术和项目是否实现自动化吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆