Commit graph

5937 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
9ed2682f67 [buddy] introduce bdd_stable_cmp
* src/bddx.h, misc/bddlt.hh (bdd_stable_cmp): Define this
new function, based on some code that was implemented in Spot, but was
unnecessarily doing reference counting.
2021-06-11 11:47:29 +02:00
Alexandre Duret-Lutz
edfcd5b0d8 merge_states: fix segfault reported by Philipp
* spot/twa/twagraph.cc: Here.
* tests/python/mergedge.py: Add test case.
2021-05-31 20:46:41 +02:00
Alexandre Duret-Lutz
634dd28379 merge_states: include sorting and detection of identical self-loops
* spot/twa/twagraph.cc: Implement it.
* spot/twa/twagraph.hh, NEWS: Document it.
* tests/python/mergedge.py: Test it.
* tests/core/ltlsynt.test, tests/python/games.ipynb: Adjust expectations.
2021-05-18 10:50:12 +02:00
Alexandre Duret-Lutz
e12f22f82a * spot/graph/graph.hh (chain_edges_): Typo in doc. 2021-05-17 18:14:32 +02:00
Alexandre Duret-Lutz
e53265dd44 Merge branch 'master' into next 2021-05-12 16:42:06 +02:00
Alexandre Duret-Lutz
30e82e7b1f Bump version to 2.9.7.dev
* NEWS, configure.ac: Here.
2021-05-12 15:56:02 +02:00
Alexandre Duret-Lutz
bc768a7157 Release Spot 2.9.7
* NEWS, configure.ac, doc/org/setup.org: Update for 2.9.7.
2021-05-12 15:54:55 +02:00
Alexandre Duret-Lutz
d3df766e56 org: add missing :exports results :results silent
* doc/org/ltlfilt.org, doc/org/tut30.org, doc/org/tut31.org: Hide rm
invocations used for cleanup.
2021-05-12 10:27:46 +02:00
Alexandre Duret-Lutz
6253885af7 improve documentation for -x sat-minimize
* bin/man/spot-x.x, bin/spot-x.cc: Improve documentation of SAT-based
minimization.  It was still referring to TGBA although it works for
TwA.
* spot/twaalgos/postproc.cc: Typo.
2021-05-12 10:26:54 +02:00
Alexandre Duret-Lutz
caca8728fe * spot/twa/twagraph.cc (remove_unused_ap): Remove unused variable. 2021-05-12 10:24:50 +02:00
Alexandre Duret-Lutz
7ef69fa15b * doc/tl/tl.tex: Typo reported by Florian. 2021-05-12 10:24:29 +02:00
Alexandre Duret-Lutz
084964a9ff autfilt: fix incorrect diagnostic
* bin/autfilt.cc (OPT_KEEP_STATES): Mention the correct option.
* tests/core/maskkeep.test: Test for it.
* NEWS: Mention the bug.
2021-05-12 10:24:12 +02:00
Alexandre Duret-Lutz
cad3d7706c twagraph: improve doc
Based on report by Michaël Cadilhac.

* spot/graph/graph.hh, spot/twa/twagraph.hh (defrag_state): Clarify
that only unreachable states are meant to be removed.
* spot/twa/twagraph.hh (merge_edges): Typo in comment.  Fixes #457.
* THANKS: Add Michaël.
2021-05-12 10:22:42 +02:00
Alexandre Duret-Lutz
4d23b7b770 work around a GraphViz 2.60.0 bug
* spot/twa/twagraph.cc (dump_storage_as_dot): Prefer \n over a plain
new line to work around GraphViz issue 1931, which was causing
twagraph-internals.ipynb to fail in our test suite.
2021-05-12 10:13:56 +02:00
Alexandre Duret-Lutz
244e3a9731 fix eventual/universal properties for ->/<->/xor
* spot/tl/formula.cc: Correctly set eventual and universal properties
for ->, <->, and xor.  This wasn't really relevant before, but there
are now situation where those are not rewritten.
* tests/core/kind.test: Adjust expected output.
* tests/core/ltl2tgba2.test: New test case, reported by Florian
Renkin.
* NEWS: Mention the bug.
2021-05-12 10:13:38 +02:00
Alexandre Duret-Lutz
b6c4145599 merge_edge: clarify documentation
Reported by Florian Renkin.

* spot/graph/graph.hh, spot/twa/twagraph.hh (merge_edge): Document
that it is expected that state i can only be renamed as j if j≤i.
2021-05-12 10:11:35 +02:00
Alexandre Duret-Lutz
fe007b9de3 * doc/org/setup.org: Fix last release date. 2021-05-12 10:09:40 +02:00
Alexandre Duret-Lutz
9a5a2836a9 org: add missing :exports results :results silent
* doc/org/ltlfilt.org, doc/org/tut30.org, doc/org/tut31.org: Hide rm
invocations used for cleanup.
2021-05-11 18:25:55 +02:00
Alexandre Duret-Lutz
23323b743f postproc: introduce dba-simul, and have simul=0 disable all *-simul
* spot/twaalgos/postproc.cc, spot/twaalgos/postproc.hh: Implement the
dba-simul option, and disable ba-simul, dba-simul, dpa-simul,
det-simul when simul=0.
* bin/ltlsynt.cc: Adjust.
* bin/spot-x.cc: Document dba-simul and adjust other variables.
* tests/core/minusx.test: Add some test.
2021-05-03 13:30:03 +02:00
Alexandre Duret-Lutz
0744052bc0 remove a useless test
We have enough outputs checked verbatim everywhere so that testing
that three execution of a single command return the same output is now
a waste of time.

* tests/core/simdet.test: Remove.
* tests/Makefile.am: Adjust.
2021-04-30 22:22:02 +02:00
Alexandre Duret-Lutz
d32f19f5d0 postproc: add support for -x dpa-simul and simul-trans-pruning
Also have simul-max default to 4096 instead of 512, because it's
really simul-trans-pruning that is very slow and need to be limited.

* spot/twaalgos/postproc.cc, spot/twaalgos/postproc.hh,
spot/twaalgos/simulation.cc, spot/twaalgos/simulation.hh,
spot/twaalgos/determinize.cc, spot/twaalgos/determinize.hh:
Implement the above options.
* bin/spot-x.cc, NEWS: Document them.
* tests/core/ltlsynt.test, tests/core/minusx.test,
tests/core/sim3.test: Add some test cases.
2021-04-30 22:22:02 +02:00
Alexandre Duret-Lutz
fca6513604 simulation: fix merging transiant SCCs
This fixes #452, and also fix a bug related to transiant SCCs
incorrectly merged in cosimulation: the source of the edges was
updated without fixing the chaining of the edges.

* spot/twaalgos/simulation.cc: Fix all the above.
* tests/python/simstate.py: Add test case from issue #452.
* tests/core/det.test, tests/core/ltlsynt.test,
tests/core/satmin.test: Lower expected sizes.
* tests/python/decompose.ipynb: Adjust for changed order.
2021-04-19 23:38:50 +02:00
Alexandre Duret-Lutz
cfa3417449 improve documentation for -x sat-minimize
* bin/man/spot-x.x, bin/spot-x.cc: Improve documentation of SAT-based
minimization.  It was still referring to TGBA although it works for
TwA.
* spot/twaalgos/postproc.cc: Typo.
2021-04-19 16:46:30 +02:00
Alexandre Duret-Lutz
803a61a03d parse_aut: add support for #line
Fixes issue #232.

* spot/parseaut/parseaut.yy, spot/parseaut/public.hh,
spot/parseaut/scanaut.ll: Add support for #line.
* tests/core/parseaut.test: Test it.
* NEWS: Mention it.
2021-04-17 10:39:02 +02:00
Alexandre Duret-Lutz
093de290c1 python: add binding for spot::twa::prop_set
Fix #453.

* python/spot/impl.i: Here.
* NEWS: Mention them.
* tests/python/twagraph.py: Test them.
2021-04-17 10:38:58 +02:00
Alexandre Duret-Lutz
b4b4730ecb * .gitlab-ci.yml (before_script): Ignore a missing */cpuset.cpus. 2021-04-15 16:08:00 +02:00
Alexandre Duret-Lutz
85581d7c3a * spot/twa/twagraph.cc (remove_unused_ap): Remove unused variable. 2021-04-15 16:03:16 +02:00
Alexandre Duret-Lutz
2a38328a5c replace bdd_satoneset(x,y,bddtrue) loops by minterms_of(x,y)
Because the loops iterate in the opposite order, multiple
test cases need to be adjusted.

* spot/taalgos/tgba2ta.cc, spot/twaalgos/alternation.cc,
spot/twaalgos/dualize.cc, spot/twaalgos/ltl2tgba_fm.cc,
spot/twaalgos/simulation.cc, spot/twaalgos/stutter.cc,
spot/twaalgos/toweak.cc: Replace loops based on
bdd_satonest(x,y,bddtrue) by loops based on minterms_of(x,y).
* tests/core/degenscc.test, tests/core/dualize.test,
tests/core/genltl.test, tests/core/readsave.test,
tests/python/alternation.ipynb, tests/python/automata.ipynb,
tests/python/decompose.ipynb, tests/python/decompose_scc.py,
tests/python/dualize.py, tests/python/sccinfo.py,
tests/python/simstate.py, tests/python/testingaut.ipynb,
tests/python/word.ipynb: Adjust expected test cases.  The
only regression is in genltl.test, but the worsened case
should eventually be fixed as discussed in issue #425 anyway.
2021-04-14 17:31:45 +02:00
Alexandre Duret-Lutz
d54dca610e replace bdd_satoneset(x,y,bddfalse) loops by minterms_of(x,y)
This replaces loops of the form

   while (all != bddfalse) {
      bdd one = bdd_satoneset(all, sup, bddfalse);
      all -= one;
      // ... use one ...
   }

by the more efficient

   for (bdd one: minterms_of(all, sub))
      // ... use one ...

This patch only focues on loops where the third
argument of bdd_satoneset is bddfalse.

* spot/twaalgos/cobuchi.cc, spot/twaalgos/complement.cc,
spot/twaalgos/determinize.cc, spot/twaalgos/dtbasat.cc,
spot/twaalgos/dtwasat.cc, spot/twaalgos/hoa.cc,
spot/twaalgos/powerset.cc: Improve bdd_satoneset()-based loops.
*
2021-04-12 19:07:25 +02:00
Alexandre Duret-Lutz
f3c42596aa split_edges: actually use the cache, and minterms_of()
* spot/twaalgos/split.cc (split_edges): Fix some typos, reported by
Philipp, that were causing the cache not to be used.  Speed up using
minterms_of().
2021-04-12 18:53:24 +02:00
Alexandre Duret-Lutz
c58aa678ec test minterms_of enumerator
* tests/core/minterm.cc, tests/core/minterm.test: New files.
* tests/core/.gitignore, tests/Makefile.am: Add them.
2021-04-12 17:54:12 +02:00
Alexandre Duret-Lutz
d2fe46136a [buddy] introduce minterm enumeration support
* src/bddop.c, src/bddx.h (bdd_ibuildcube2, bdd_first_minterm,
bdd_next_minterm): New functions.
* src/bddx.h (minterms_of): New class.
2021-04-12 17:52:47 +02:00
Jerome Dubois
ec4deb3219 split: Improve performance of split_edges()
* spot/twaalgos/split.cc: Add cache to avoid
  computing multiple split on the same condition.
2021-03-29 11:30:05 +02:00
Jerome Dubois
b082df201f postproc: Add the new simulation in do_simul()
* spot/twaalgos/postproc.hh, spot/twaalgos/postproc.cc: Add the new simulation
  in do_simul().
* bin/man/spot-x.x, bin/spot-x.cc: Add documentation for
  SPOT_SIMULATION_REDUCTION environnement variable and the simul-method
  fine tunning option.
* NEWS: Mention the changes.
2021-03-29 11:29:50 +02:00
Jerome Dubois
fb066ada0a simulation: Add simulation based reduction
* spot/twaalgos/simulation.hh, spot/twaalgos/simulation.cc: Add
  reduce_direct_sim(), reduce_direct_cosim() and
  reduce_direct_iterated() wich reduce an automaton using simulation.
  This functions wrap the class direct_sim wich compute simulation
  with a new method.
* doc/spot.bib: Add ref.
* tests/python/simstate.py: Add tests for the new simulation.
2021-03-29 11:25:56 +02:00
Alexandre Duret-Lutz
535d4555e5 bricks: fix the test-suite
Fixes #446 using a fix from Étienne Renault.

* tests/core/bricks.cc: Pass the hash table by reference while
instantiating the threads.
2021-03-24 10:04:38 +01:00
Alexandre Duret-Lutz
64be4dc814 * doc/tl/tl.tex: Typo reported by Florian. 2021-03-03 14:13:55 +01:00
Alexandre Duret-Lutz
caa960d857 twagraph: new kill_state method
This proceeds from a discussion with Michaël Cadilhac.
http://lists.lrde.epita.fr/pipermail/spot/2021q1/000356.html

* bin/autfilt.cc (--kill-states): New option.
* NEWS: Mention those.
* spot/twa/twagraph.hh, spot/twa/twagraph.cc: Add a kill_state()
method.
* tests/core/maskkeep.test: Test it.
2021-02-19 16:42:55 +01:00
Alexandre Duret-Lutz
da0dd4c534 autfilt: fix incorrect diagnostic
* bin/autfilt.cc (OPT_KEEP_STATES): Mention the correct option.
* tests/core/maskkeep.test: Test for it.
* NEWS: Mention the bug.
2021-02-19 16:01:07 +01:00
Alexandre Duret-Lutz
7a56ae958e defrag_states: do not take the argument by rvalue ref
Reported by Michaël Cadilhac.

* spot/graph/graph.hh, spot/twa/twagraph.hh: Take the renaming vector
by reference, not rvalue reference.  Document that
twa_graph::defrag_states may modify the vector.  Keep a deprecated
version of the old prototype just in case.  While there, also hide
this method from Swig.
* spot/twa/twagraph.cc: Simplify all calls to defrag_states().
* NEWS: Mention the change.
2021-02-19 16:01:07 +01:00
Alexandre Duret-Lutz
0b048e1c05 twagraph: improve doc
Based on report by Michaël Cadilhac.

* spot/graph/graph.hh, spot/twa/twagraph.hh (defrag_state): Clarify
that only unreachable states are meant to be removed.
* spot/twa/twagraph.hh (merge_edges): Typo in comment.  Fixes #454.
* THANKS: Add Michaël.
2021-02-18 22:19:03 +01:00
Alexandre Duret-Lutz
57b508c767 work around a GraphViz 2.60.0 bug
* spot/twa/twagraph.cc (dump_storage_as_dot): Prefer \n over a plain
new line to work around GraphViz issue 1931, which was causing
twagraph-internals.ipynb to fail in our test suite.
2021-02-03 17:10:41 +01:00
Alexandre Duret-Lutz
c06e15e085 fix eventual/universal properties for ->/<->/xor
* spot/tl/formula.cc: Correctly set eventual and universal properties
for ->, <->, and xor.  This wasn't really relevant before, but there
are now situation where those are not rewritten.
* tests/core/kind.test: Adjust expected output.
* tests/core/ltl2tgba2.test: New test case, reported by Florian
Renkin.
* NEWS: Mention the bug.
2021-02-03 12:23:34 +01:00
Alexandre Duret-Lutz
93d8f43285 translate: speed up some -G -D cases
When gf-guarentee works and produce a deterministic automaton, use it
right away without comparing it with the automaton produced by the
regular translation.  This used to be the case for all -D scenarios
except -G -D.

Reported by Florian Renkin.

* spot/twaalgos/translate.cc: Use the result of
gf_guarantee_to_ba_maybe() or fg_safety_to_dca_maybe() whenever -D is
used.
* spot/twaalgos/postproc.cc: Call remove_unused_ap() in finalize(), to
iron out some slight output differences.
* tests/core/ltl2tgba2.test, tests/python/toparity.py: Lower expected
results in the test cases.
* tests/python/automata.ipynb, tests/core/prodor.test: Adjust to new
order.
2021-01-27 13:26:49 +01:00
Alexandre Duret-Lutz
238a9ffc1d merge_edge: clarify documentation
Reported by Florian Renkin.

* spot/graph/graph.hh, spot/twa/twagraph.hh (merge_edge): Document
that it is expected that state i can only be renamed as j if j≤i.
2021-01-27 13:26:49 +01:00
Alexandre Duret-Lutz
2072151499 twa_graph: swap the two passes of merge_edges()
This improves the determinism in a few cases.

* spot/twa/twagraph.cc (merge_edges): Encapsulate the two
passes into lambdas so that they are very easy to swap.
* spot/twa/twagraph.hh (merge_edges): Adjust documentation.
* tests/python/mergedge.py: Add test case.
* tests/core/alternating.test, tests/python/alternation.ipynb:
Determinism was improved.
* tests/core/parity2.test, tests/core/readsave.test,
tests/core/sbacc.test, tests/python/_product_susp.ipynb,
tests/python/atva16-fig2a.ipynb, tests/python/decompose.ipynb,
tests/python/highlighting.ipynb, tests/python/satmin.ipynb,
tests/python/simstate.py: Adjust expected order of edges.
* NEWS: Mention the change.
2021-01-20 00:16:12 +01:00
Alexandre Duret-Lutz
e8e31c2723 * doc/org/setup.org: Fix last release date. 2021-01-18 18:19:23 +01:00
Alexandre Duret-Lutz
2b51861953 Merge branch 'master' into next 2021-01-18 11:15:25 +01:00
Alexandre Duret-Lutz
e5b90a8e00 * NEWS, configure.ac: Bump version to 2.9.6.dev. 2021-01-18 11:09:49 +01:00
Alexandre Duret-Lutz
93ea0e34b0 Release Spot 2.9.6
* NEWS, configure.ac, doc/org/setup.org: Bump version to 2.9.6.
2021-01-18 11:07:12 +01:00