Add support for W (weak until) and M (strong release) operators.

* src/ltlast/binop.cc, src/ltlast/binop.cc: Add support for
these new operators.
* src/ltlparse/ltlparse.yy, src/ltlparse/ltlscan.ll: Parse them.
* src/ltltest/reduccmp.test: Add new tests for W and M.
* src/ltlvisit/basicreduce.cc, src/ltlvisit/contain.cc,
src/ltlvisit/lunabbrev.cc, src/ltlvisit/nenoform.cc,
src/ltlvisit/randomltl.cc, src/ltlvisit/randomltl.hh,
src/ltlvisit/reduce.cc, src/ltlvisite/simpfg.cc,
src/ltlvisit/simpfg.hh, src/ltlvisit/syntimpl.cc,
src/ltlvisit/tostring.cc, src/tgba/formula2bdd.cc,
src/tgbaalgos/eltl2tgba_lacim.cc, src/tgbaalgos/ltl2taa.cc,
src/tgbaalgos/ltl2tgba_fm.cc, src/tgbaalgos/ltl2tgba_lacim.cc:
Add support for W and M.
* src/tgbatest/ltl2neverclaim.test: Test never claim output
using LBTT, this is more thorough.  Also we cannot use -N
any more in the spotlbtt.test.
* src/tgbatests/ltl2tgba.cc: Define M and W for ELTL.
* src/tgbatest/ltl2neverclaim.test: Test W and M, and use
-DS instead of -N, because lbtt-translate does not want
to translate these operators for tools that masquerade as Spin.
This commit is contained in:
Alexandre Duret-Lutz 2010-04-07 10:44:07 +02:00
parent 35a57c6dff
commit 0fc0ea3166
25 changed files with 584 additions and 123 deletions

View file

@ -1,9 +1,6 @@
#!/bin/sh
# Copyright (C) 2009 Laboratoire de Recherche et Développement
# Copyright (C) 2010 Laboratoire de Recherche et Développement
# de l'Epita (LRDE).
# Copyright (C) 2004 Laboratoire d'Informatique de Paris 6 (LIP6),
# département Systèmes Répartis Coopératifs (SRC), Université Pierre
# et Marie Curie.
#
# This file is part of Spot, a model checking library.
#
@ -22,22 +19,85 @@
# Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
# Do some quick translations to make sure the neverclaim produced by
# spot actually look correct!
# This test is separate from spotlbtt.test, because lbtt-translate
# will refuse to passe M and W to a tool (spot) that masquerades as
# Spin.
. ./defs
set -e
# We don't check the output, but just running these might be enough to
# trigger assertions.
cat > config <<EOF
Algorithm
{
Name = "Spot (Couvreur -- FM)"
Path = "${LBTT_TRANSLATE}"
Parameters = "--spot '../ltl2tgba -F -f -t'"
Enabled = yes
}
run 0 ../ltl2tgba -N -x a
run 0 ../ltl2tgba -N -x 'a U b'
run 0 ../ltl2tgba -N -x 'X a'
run 0 ../ltl2tgba -N -x 'a & b & c'
run 0 ../ltl2tgba -N -x 'a | b | (c U (d & (g U (h ^ i))))'
run 0 ../ltl2tgba -N -x 'Xa & (b U !a) & (b U !a)'
run 0 ../ltl2tgba -N -x 'Fa & Xb & GFc & Gd'
run 0 ../ltl2tgba -N -x 'Fa & Xa & GFc & Gc'
run 0 ../ltl2tgba -N -x 'Fc & X(a | Xb) & GF(a | Xb) & Gc'
run 0 ../ltl2tgba -N -x 'a R (b R c)'
run 0 ../ltl2tgba -N -x '(a U b) U (c U d)'
Algorithm
{
Name = "Spot (Couvreur -- FM), with reductions"
Path = "${LBTT_TRANSLATE}"
Parameters = "--spot '../ltl2tgba -r4 -R3f -F -f -t'"
Enabled = no
}
Algorithm
{
Name = "Spot (Couvreur -- FM), degeneralized via never claim"
Path = "${LBTT_TRANSLATE}"
Parameters = "--spin '../ltl2tgba -F -f -N'"
Enabled = yes
}
Algorithm
{
Name = "Spot (Couvreur -- FM), reductions, degeneralized via never claim"
Path = "${LBTT_TRANSLATE}"
Parameters = "--spin '../ltl2tgba -F -f -r4 -R3 -N'"
Enabled = yes
}
GlobalOptions
{
Rounds = 100
Interactive = Never
# Verbosity = 5
# ComparisonCheck = no
# ConsistencyCheck = no
# IntersectionCheck = no
}
FormulaOptions
{
Size = 1...13
Propositions = 6
AbbreviatedOperators = Yes
GenerateMode = Normal
OutputMode = Normal
PropositionPriority = 50
TruePriority = 1
FalsePriority = 1
AndPriority = 10
OrPriority = 10
XorPriority = 0
# EquivalencePriority = 0
BeforePriority = 0
StrongReleasePriority = 0
WeakUntilPriority = 0
DefaultOperatorPriority = 5
}
EOF
${LBTT}
rm config

View file

@ -71,7 +71,9 @@ U=(0 0 $0 \
accept 1) \
G=(0 0 $0) \
F=U(true, $0) \
R=!U(!$0, !$1)";
W=G($0)|U($0, $1) \
R=!U(!$0, !$1) \
M=F($0)&R($0, $1)";
return s;
}

View file

@ -208,9 +208,9 @@ Algorithm
Algorithm
{
Name = "Spot (Couvreur -- FM), degeneralized, via never claim"
Name = "Spot (Couvreur -- FM), degeneralized on states"
Path = "${LBTT_TRANSLATE}"
Parameters = "--spin '../ltl2tgba -F -f -N'"
Parameters = "--spot '../ltl2tgba -F -f -t -DS'"
Enabled = yes
}
@ -272,9 +272,9 @@ Algorithm
Algorithm
{
Name = "Spot (Couvreur -- FM), pre + post reduction, via never claim"
Name = "Spot (Couvreur -- FM), pre + post reduction, degeneralized on states"
Path = "${LBTT_TRANSLATE}"
Parameters = "--spin '../ltl2tgba -F -f -N -R3 -r7'"
Parameters = "--spot '../ltl2tgba -F -f -DS -R3 -r7 -t'"
Enabled = yes
}
@ -339,8 +339,6 @@ FormulaOptions
# EquivalencePriority = 0
BeforePriority = 0
StrongReleasePriority = 0
WeakUntilPriority = 0
DefaultOperatorPriority = 5
}