sccfilter: ignore more acceptance conditions
* src/tgbaalgos/sccfilter.cc: Compute useless variable SCC-wise, then renumber the useful variables so that they can be shared between SCCs. * src/tgbatest/sccsimpl.test, src/tgbatest/ltl2ta.test: Adjust test cases.
This commit is contained in:
parent
05e59a9e1a
commit
c46891edc7
3 changed files with 195 additions and 72 deletions
|
|
@ -1,5 +1,5 @@
|
|||
#!/bin/sh
|
||||
# Copyright (C) 2010, 2011, 2012 Laboratoire de Recherche et
|
||||
# Copyright (C) 2010, 2011, 2012, 2013 Laboratoire de Recherche et
|
||||
# Développement de l'Epita (LRDE).
|
||||
#
|
||||
# This file is part of Spot, a model checking library.
|
||||
|
|
@ -101,8 +101,8 @@ grep 'states: 21$' stdout
|
|||
# Note: after minimization with -TA -RT.
|
||||
# has 20 states and 89 transitions, after minimization.
|
||||
../ltl2tgba -ks -TA -RT -DS "$f" > stdout
|
||||
grep 'transitions: 89$' stdout
|
||||
grep 'states: 20$' stdout
|
||||
grep 'transitions: 85$' stdout
|
||||
grep 'states: 19$' stdout
|
||||
|
||||
|
||||
f='GFa & GFb & GFc & GFd & GFe & GFg'
|
||||
|
|
@ -119,12 +119,12 @@ grep 'states: 290$' stdout
|
|||
|
||||
#tests with artificial livelock state:
|
||||
run 0 ../ltl2tgba -ks -TA -lv -DS "Gq|Gr|(G(q|FGp)&G(r|FG!p))" >stdout
|
||||
grep 'transitions: 882$' stdout
|
||||
grep 'states: 78$' stdout
|
||||
grep 'transitions: 790$' stdout
|
||||
grep 'states: 66$' stdout
|
||||
|
||||
run 0 ../ltl2tgba -TA -RT -ks -lv -DS "Gq|Gr|(G(q|FGp)&G(r|FG!p))" >stdout
|
||||
grep 'transitions: 440$' stdout
|
||||
grep 'states: 28$' stdout
|
||||
grep 'transitions: 390$' stdout
|
||||
grep 'states: 26$' stdout
|
||||
|
||||
run 0 ../ltl2tgba -TGTA -RT -ks 'Gq|Gr|(G(q|FGp)&G(r|FG!p))' >stdout
|
||||
grep 'transitions: 294$' stdout
|
||||
|
|
@ -153,16 +153,16 @@ grep 'states: 32$' stdout
|
|||
|
||||
|
||||
run 0 ../ltl2tgba -TA -RT -ks -in -R3 -x -DS "$f" >stdout
|
||||
grep 'transitions: 436$' stdout
|
||||
grep 'states: 36$' stdout
|
||||
grep 'transitions: 450$' stdout
|
||||
grep 'states: 38$' stdout
|
||||
|
||||
run 0 ../ltl2tgba -TA -RT -ks -sp -lv -R3 -x -DS "$f" >stdout
|
||||
grep 'transitions: 537$' stdout
|
||||
grep 'states: 38$' stdout
|
||||
grep 'transitions: 551$' stdout
|
||||
grep 'states: 40$' stdout
|
||||
|
||||
|
||||
run 0 ../ltl2tgba -TA -ks -sp -lv -DS "$f" >stdout
|
||||
grep 'transitions: 609$' stdout
|
||||
grep 'transitions: 597$' stdout
|
||||
grep 'states: 46$' stdout
|
||||
|
||||
|
||||
|
|
@ -177,7 +177,7 @@ grep 'states: 32$' stdout
|
|||
g="G(F(GWaitLeft7 U Idle4) U (WaitLeft2 M IsEating2))"
|
||||
|
||||
run 0 ../ltl2tgba -TA -RT -ks -DS "$g" >stdout
|
||||
grep 'transitions: 2147$' stdout
|
||||
grep 'transitions: 2133$' stdout
|
||||
grep 'states: 97$' stdout
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
# Copyright (C) 2011 Laboratoire de Recherche et Developpement de
|
||||
# l'Epita
|
||||
# Copyright (C) 2011, 2013 Laboratoire de Recherche et Developpement
|
||||
# de l'Epita
|
||||
#
|
||||
# This file is part of Spot, a model checking library.
|
||||
#
|
||||
|
|
@ -54,7 +54,7 @@ S4, S4, "!p1",;
|
|||
EOF
|
||||
|
||||
run 0 ../ltl2tgba -X -R3 -b aut.txt > out.txt
|
||||
grep '^acc = "p1";$' out.txt
|
||||
grep '^acc = "[^"]*";$' out.txt
|
||||
|
||||
|
||||
# Here, acceptances A and C can both be removed.
|
||||
|
|
@ -66,7 +66,7 @@ S1, S1, "c", A B C;
|
|||
S1, S1, "d", C D;
|
||||
EOF
|
||||
run 0 ../ltl2tgba -X -R3 -b aut2.txt > out2.txt
|
||||
grep '^acc = "B" "D";$' out2.txt || grep '^acc = "D" "B";$' out2.txt || exit 1
|
||||
grep '^acc = "." ".";$' out2.txt || exit 1
|
||||
# only 4 lines output, because the "b" and "c" lines have been merged.
|
||||
test `wc -l < out2.txt` = 4
|
||||
|
||||
|
|
@ -80,7 +80,7 @@ S1, S1, "c", A B C;
|
|||
S1, S1, "d", B D;
|
||||
EOF
|
||||
run 0 ../ltl2tgba -X -R3 -b aut3.txt > out3.txt
|
||||
grep '^acc = "C" "D";$' out3.txt || grep '^acc = "D" "C";$' out3.txt || exit 1
|
||||
grep '^acc = "." ".";$' out3.txt || exit 1
|
||||
# only 4 lines output, because the "a" and "b" lines have been merged.
|
||||
test `wc -l < out3.txt` = 4
|
||||
|
||||
|
|
@ -158,6 +158,4 @@ S6, S6, "(p1 & !p2) | (p3 & !p2)", ZZ "!p2";
|
|||
S6, S6, "p1 | p2 | p3", ZZ;
|
||||
EOF
|
||||
run 0 ../ltl2tgba -X -R3 -b aut7.txt > out7.txt
|
||||
# ZZ should disappear
|
||||
grep ZZ out7.txt && exit 1
|
||||
test `grep '^acc' out7.txt | wc -w` = 4
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue