Skip to content

Commit b1d93bd

Browse files
committed
Buechi: mark unconverted properties as unsupported
The Buechi flow now marks properties that cannot be converted into a Buechi acceptance condition as unsupported.
1 parent 0d4c976 commit b1d93bd

File tree

4 files changed

+32
-1
lines changed

4 files changed

+32
-1
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
CORE
2+
../../verilog/SVA/sequence2.sv
3+
--buechi --bound 10
4+
^\[main\.p0] weak\(##\[0:\$\] main\.x == 10\): PROVED up to bound 10$
5+
^\[main\.p1] strong\(##\[0:\$\] main\.x == 10\): UNSUPPORTED: not convertible to Buechi$
6+
^EXIT=10$
7+
^SIGNAL=0$
8+
--
9+
^warning: ignoring
10+
--
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
CORE
2+
../../verilog/SVA/strong1.sv
3+
--buechi --bound 4
4+
^\[main\.p0\] strong\(##\[0:9\] main\.x == 5\): UNSUPPORTED: not convertible to Buechi$
5+
^EXIT=10$
6+
^SIGNAL=0$
7+
--
8+
^warning: ignoring
9+
--

src/ebmc/instrument_buechi.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ void instrument_buechi(
2727
!is_LTL(property.normalized_expr) &&
2828
!is_Buechi_SVA(property.normalized_expr))
2929
{
30+
property.unsupported("not convertible to Buechi");
3031
continue;
3132
}
3233

src/temporal-logic/temporal_logic.cpp

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,18 @@ std::optional<exprt> LTL_to_CTL(exprt expr)
217217
bool is_Buechi_SVA(const exprt &expr)
218218
{
219219
auto unsupported_operator = [](const exprt &expr)
220-
{ return is_temporal_operator(expr) && !is_SVA_operator(expr); };
220+
{
221+
// ltl2tgba produces the wrong anser for [->n] and [=n]
222+
if(
223+
expr.id() == ID_sva_implicit_strong || expr.id() == ID_sva_strong ||
224+
expr.id() == ID_sva_sequence_goto_repetition ||
225+
expr.id() == ID_sva_sequence_non_consecutive_repetition)
226+
{
227+
return true;
228+
}
229+
else
230+
return is_temporal_operator(expr) && !is_SVA_operator(expr);
231+
};
221232

222233
return !has_subexpr(expr, unsupported_operator);
223234
}

0 commit comments

Comments
 (0)