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:
parent
35a57c6dff
commit
0fc0ea3166
25 changed files with 584 additions and 123 deletions
|
|
@ -393,6 +393,13 @@ namespace spot
|
|||
res_ = f2 | (bdd_ithvar(a) & f1 & bdd_ithvar(x));
|
||||
return;
|
||||
}
|
||||
case binop::W:
|
||||
{
|
||||
// r(f1 W f2) = r(f2) + r(f1)r(X(f1 U f2))
|
||||
int x = dict_.register_next_variable(node);
|
||||
res_ = f2 | (f1 & bdd_ithvar(x));
|
||||
return;
|
||||
}
|
||||
case binop::R:
|
||||
{
|
||||
// r(f1 R f2) = r(f1)r(f2) + r(f2)r(X(f1 U f2))
|
||||
|
|
@ -400,6 +407,14 @@ namespace spot
|
|||
res_ = (f1 & f2) | (f2 & bdd_ithvar(x));
|
||||
return;
|
||||
}
|
||||
case binop::M:
|
||||
{
|
||||
// r(f1 M f2) = r(f1)r(f2) + a(f1)r(f2)r(X(f1 M f2))
|
||||
int a = dict_.register_a_variable(node->first());
|
||||
int x = dict_.register_next_variable(node);
|
||||
res_ = (f1 & f2) | (bdd_ithvar(a) & f2 & bdd_ithvar(x));
|
||||
return;
|
||||
}
|
||||
}
|
||||
/* Unreachable code. */
|
||||
assert(0);
|
||||
|
|
@ -449,8 +464,8 @@ namespace spot
|
|||
};
|
||||
|
||||
|
||||
// Check whether a formula has a R or G operator at its top-level
|
||||
// (preceding logical operators do not count).
|
||||
// Check whether a formula has a R, W, or G operator at its
|
||||
// top-level (preceding logical operators do not count).
|
||||
class ltl_possible_fair_loop_visitor: public const_visitor
|
||||
{
|
||||
public:
|
||||
|
|
@ -501,8 +516,10 @@ namespace spot
|
|||
node->second()->accept(*this);
|
||||
return;
|
||||
case binop::U:
|
||||
case binop::M:
|
||||
return;
|
||||
case binop::R:
|
||||
case binop::W:
|
||||
res_ = true;
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue