We use cookies to improve your experience with our site.

改进的全局分支时序逻辑CTL的限界模型检测

Improved Bounded Model Checking for the Universal Fragment of CTL

  • 摘要: 模型检测这一概念是由Clarke和Emerson在八十年代早期提出的。在模型检测的方法中,需要验证的系统被设计成一个有限状态的模型,需要验证的性质用时序逻辑来描述,通常是线性时序逻辑和分支时序逻辑。模型通过检查系统的可达状态来验证用户给出的性质。限界模型检测则是Biere等人在1999年提出的,其基本思想是通过寻找反例来证明性质是否成立。它将限界模型和待验证性质的非进行编码,并转换成SAT可求解的公式,利用SAT工具进行求解,若公式可满足,则表明找到反例,性质不成立;反之,增加界值,直到界值达到某一个上界,表明不存在反例,性质成立。虽然限界模型检测没能解决模型检测的复杂性问题,但实验显示,它能够解决很多基于BDD的模型检测技术由于状态爆炸而解决不了的问题,是基于BDD技术的一个很好的补充。因此如何提高限界模型检测的效率是一个值得考虑的问题。Penczek等人在2002年提出全局分支时序逻辑CTL的限界模型检测。该限界模型检测的一个特点是其界值相对于线性时序逻辑的要小,但可能同时用到多条路径,路径的多少、长短以及其用法对验证效率有很大影响。本文的工作对Penczek等人提出的全局分支时序逻辑CTL的限界模型检测(以下称为原方法)做了相应的改进。原方法将验证各个操作符所需的路径条数统一计算,每条路径的长度都为界值k。首先,我们知道在验证EX时,只需要考虑长度为2的路径即可。当k值较大时,每条验证EX的路径中将会出现大量的冗余状态。对这些冗余状态同样需要进行相应的编码并送入SAT求解器,这在一定程度上降低了SAT求解的效率,也就影响了整个问题求解的效率。因此,我们考虑通过改进计算验证过程中所需路径条数的函数将时序操作符EX和EG、EU区分开来,这样所得到的路径的总的状态数将会得到有效的简化,文中也给出了一个相应的例子,比较了改进前和改进后,随着k值的增加,总的路径长度增加的趋势,改进后的明显优于改进前的。其次,原方法在公式编码时,将很多路径编号不同但结构一样路径或在了一起。这些路径实际上是旋转对称的,即存在一个对它们编号的置换,使得置换后的公式的可满足性和原公式的一样。因此,在公式编码展开的每一层,我们每次只取一系列路径中可满足的那一条,并采取一个统一的编码方式来对所取的这些路径进行编码。统一编码后,消去了原方法中公式前的或操作,在不影响公式可满足性的前提下,大大减少了SAT求解中的变量数和子句数。我们将这两方面的改进在模型检测工具BMV中进行了实现,并通过进程互斥和哲学家就餐两个实例,论证了改进后的算法比原方法具有更高的效率,在同一时间界限内,求解问题的规模更大。在今后的工作中,我们将继续研究限界模型检测效率的进一步改进,并将其运用于实时系统、概率实时系统,使得模型检测这一方法能更好、更高效地应用于现实系统的验证中。

     

    Abstract: SAT-based bounded model checking (BMC) has been introduced as a complementary technique to BDD-based symbolic model checking in recent years, and a lot of successful work has been done in this direction. The approach was first introduced by A. Biere \it et al. in checking linear temporal logic (LTL) formulae and then also adapted to check formulae of the universal fragment of computation tree logic (ACTL) by W. Penczek \it et al. As the efficiency of model checking is still an important issue, we present an improved BMC approach for ACTL based on Penczek's method. We consider two aspects of the approach. One is reduction of the number of variables and transitions in the k-model by distinguishing the temporal operator \it EX from the others. The other is simplification of the transformation of formulae by using uniform path encoding instead of a disjunction of all paths needed in the k-model. With these improvements, for an ACTL formula, the length of the final encoding of the formula in the worst case is reduced. The improved approach is implemented in the tool BMV and is compared with the original one by applying both to two well known examples, mutual exclusion and dining philosophers. The comparison shows the advantages of the improved approach with respect to the efficiency of model checking.

     

/

返回文章
返回