Commit graph

2989 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
223d41d26b autfilt: fix destruction order for static variables
Depending on whether the global atomic proposition map was destroyed
after the global automata declared in autfilt, we could get
double-free errors.

* src/bin/autfilt.cc: Force destruction of automata in main().
2015-02-18 12:45:09 +01:00
Alexandre Lewkowicz
dcad10fc68 maskkeep: Add a tgba_digraph version
* src/bin/autfilt.cc: Add option --keep-states.
* src/tgbaalgos/mask.cc, src/tgbaalgos/mask.hh: Keep the selected states
and update the initial state.
* src/tgbatest/Makefile.am: Adjust.
* src/tgbatest/maskkeep.test: New file.
2015-02-16 11:42:41 +01:00
Alexandre Lewkowicz
727c351657 common_conv: Parse comma and space separated numbers
* src/bin/common_conv.cc, src/bin/common_conv.hh: Here.
2015-02-16 10:51:05 +01:00
Alexandre Duret-Lutz
78def4f8ca bin: add the --output to tools that output formulas
* src/bin/common_output.cc, src/bin/common_output.hh: Add option
--output.
* src/ltltest/ltlfilt.test, src/ltltest/rand.test: Add tests.
* NEWS, doc/org/ioltl.org: Document it.
2015-02-16 01:23:07 +01:00
Alexandre Duret-Lutz
e22a800fe4 ltlfilt: add a --count option, like autfilt
* src/bin/common_output.cc, src/bin/common_output.hh:
Add count_output.
* src/bin/ltlfilt.cc: Add the --count option.
* src/ltltest/ltlfilt.test: Test it.
* NEWS: Mention it.
2015-02-16 00:46:00 +01:00
Alexandre Duret-Lutz
1e7c1e5cdd bin: implement --output for automata
Fixes #56.

* src/bin/common_aoutput.cc, src/bin/common_aoutput.hh,
src/bin/dstar2tgba.cc: Implement it.
* src/bin/autfilt.cc, src/bin/ltl2tgba.cc, src/bin/ltldo.cc,
src/bin/randaut.cc: Fix main() to catch exceptions from the
constructor of the automaton printer as well.
* src/tgbatest/randaut.test: Add a test case.
* doc/org/oaut.org: Document it.
2015-02-15 12:32:12 +01:00
Alexandre Duret-Lutz
d17d7469c3 ltlcross: allow appending to files via >>FILENAME
Suggested by Joachim Klein.  Fixes #57.

* src/bin/common_file.hh, src/bin/common_file.cc: New file.
* src/bin/Makefile.am: Build them.
* src/bin/ltlcross.cc: Use the output_file class.
* src/tgbatest/ltlcross3.test: Test >>.
* NEWS: mention it.
2015-02-14 17:39:51 +01:00
Alexandre Duret-Lutz
7daea8d3cb bitvect: Fix routines for 64-width vectors
* src/misc/bitvect.hh: Here.
* src/tgbatest/det.test, src/ltltest/ltlfilt.test: Add test cases.
2015-02-13 19:15:23 +01:00
Alexandre Duret-Lutz
be40885010 * doc/org/ltlfilt.org: Update description of --stutter-invariant. 2015-02-13 17:07:48 +01:00
Alexandre Duret-Lutz
e900488e13 bench/stutter: add a "user" benchmark
* bench/stutter/user.sh: New bench.
* bench/stutter/Makefile.am: Add it.
* bench/stutter/README: Mention it.
* bench/stutter/stutter_bench.sh: Run it.
2015-02-13 16:58:42 +01:00
Alexandre Duret-Lutz
204af40b09 stutter: Improve sl2.
* src/tgbaalgos/stutter.cc (sl2): Detect selfloops, and merge
intermediate states when possible.
2015-02-11 11:39:43 +01:00
Alexandre Duret-Lutz
bd414d4d4c bench/stutter: Update
* bench/stutter/stutter_invariance_randomgraph.cc: Update to recent
changes.  If an algorithm took more that 30s on an average for a set of
parameters, avoid running it with more states.  Take the density and
ap count as parameter.  Output all the algorithms on the same line.
Add additional statistics about automata.
* bench/stutter/stutter_invariance_formulas.cc: Update to recent
changes.  Output all the algorithms on the same line.
Add additional statistics about automata.
* bench/stutter/stutter_bench.sh: Use a Makefile to manage concurrency.
* bench/stutter/README: Update.
2015-02-11 11:39:43 +01:00
Alexandre Duret-Lutz
5d31094029 dtgba_complement: take a tgba_digraph_ptr as input
* src/tgbaalgos/dtgbacomp.cc, src/tgbaalgos/dtgbacomp.hh: Here.
* src/tgbatest/ltl2tgba.cc: Adjust.
2015-02-10 16:58:08 +01:00
Alexandre Duret-Lutz
afc8773de1 ltlcross: Add --ignore-execution-failures.
Suggested by Joachim Klein.

* src/bin/ltlcross.cc: Add --ignore-execution-failures.
* src/tgbatest/ltlcross3.test: Test it.
* NEWS: Mention it.
2015-02-10 13:17:55 +01:00
Etienne Renault
2786d0c652 hoaparse: Fix non-posix warnings.
*  src/hoaparse/Makefile.am: here.
2015-02-09 10:10:06 +01:00
Alexandre Duret-Lutz
87f51e28e0 ltldo: cleanup temporary files
* src/bin/ltldo.cc: Here.
2015-02-06 22:31:39 +01:00
Alexandre Duret-Lutz
db34207084 graph: Make perfect forwarding imperfect.
Make sure the constructors with perfect forwarding for states and
transitions do not take the place of copy constructors.  Thanks to Akim
Demaille for its help.  This should fix a bug observed by Joachim Klein
and David Muller.

* src/graph/graph.hh: Disable forwarding constructors for states and
transitions if the first argument is a subclass of the current class.
2015-02-06 14:40:08 +01:00
Alexandre Duret-Lutz
f2ba94f4d4 Add (void) casts for variables used only in assert()s.
Report from Akim Demaille.

* src/ltlvisit/snf.cc, src/ta/taexplicit.cc, src/taalgos/tgba2ta.cc,
src/tgbaalgos/dupexp.cc, src/tgbaalgos/stutter.cc: Here.
2015-02-06 11:57:27 +01:00
Alexandre Duret-Lutz
78e63d0324 nra2nba: Fix initial state construction.
This bug caused tgbatest/ltl2dstar.test to fail but because I had
no ltl2dstar on my computer for a while, I only discovered it after
David Müller and Joachim Klein reported a bug against ltlcross.
It might be the case that their bug is different (I can't reproduce it
using their format), but I hope it was caused by this as well.

* src/dstarparse/nra2nba.cc: Revert 57cda2d9, with a comment.
* THANKS: Add David.
2015-02-05 18:55:52 +01:00
Alexandre Duret-Lutz
856adef9a8 acc: do not store a bdd_dict
Fixes #55.

* src/tgba/acc.hh: Do not store a bdd_dict_ptr, it is not used.
* src/tgba/tgba.hh, src/tgba/tgba.cc, src/ta/ta.hh,
src/tgba/tgbagraph.hh, src/tgbaalgos/dtgbasat.cc,
src/tgbatest/acc.cc: Adjust.
2015-02-04 21:40:46 +01:00
Alexandre Duret-Lutz
2a3c126c15 Make the compiler requirement clearer.
* configure.ac: Check for g++ 4.6 bugs, so we catch
the error at compile time, not make time.
* README: Mention the minimal g++ and clang++ versions.
2015-02-04 15:57:58 +01:00
Alexandre Duret-Lutz
ee0b8e4ea8 autfilt: add a --strip-acceptance option
* src/bin/autfilt.cc: New option.
* src/tgbatest/sbacc.test: Test it.
2015-02-03 23:02:37 +01:00
Alexandre Duret-Lutz
acb67c1bf6 autfilt: add a --sbacc option
... to force automata into state-based acceptance.

* src/tgbaalgos/sbacc.cc, src/tgbaalgos/sbacc.hh,
src/tgbatest/sbacc.test: New files.
* src/tgbaalgos/Makefile.am, src/tgbatest/Makefile.am: Add
them.
* src/tgba/tgbagraph.hh (copy_acceptance_conditions_of):
Call set_acceptance_conditions().
* src/bin/autfilt.cc: Add option --sbacc.
2015-02-03 21:40:56 +01:00
Alexandre Duret-Lutz
cbee5c1a3f hoaparse: detect duplicate atomic propositions
Reported by Joachim Klein.

* src/hoaparse/hoaparse.yy: Add a std::set to keep track of duplicate
propositions.
* src/tgbatest/hoaparse.test: Test it.
2015-02-03 09:57:53 +01:00
Alexandre Duret-Lutz
d7dc584992 hoaparse: fix parsing of LBTT with non 0-based states
* src/hoaparse/hoaparse.yy: Here.
* src/tgbatest/lbttparse.test: Add test cases.
* src/tgbatest/hoaparse.test: Adjust.
2015-02-02 20:09:33 +01:00
Alexandre Duret-Lutz
08fbe27136 bin: diagnose empty automata in ltlcross and ltldo
* src/bin/ltlcross.cc, src/bin/ltldo.cc: Make sure
the result of hoa_parse() is non-empty.
* src/tgbatest/ltlcross3.test, src/tgbatest/ltldo.test:
Add test cases.
2015-02-02 18:53:14 +01:00
Alexandre Duret-Lutz
de935d40ca autfilt: improve documentation
* src/bin/autfilt.cc: Tweak --help.
* doc/org/autfilt.org: More documentation.
2015-02-01 20:31:21 +01:00
Alexandre Duret-Lutz
57cda2d9c3 * src/dstarparse/nra2nba.cc: Simplify construction of initial state. 2015-02-01 17:18:49 +01:00
Alexandre Duret-Lutz
847270b480 ltlcross: replace %H,%T,%N by %O
Also get rid of the lbt_parser, and fix the LBT support of the HOA
parser.

* doc/org/ltlcross.org, doc/org/ltldo.org: Update.
* src/bin/common_trans.cc, src/bin/common_trans.hh: Add support for
%O, and keep %T,%N,%H as hidden aliases without disabling them.
* src/bin/ltlcross.cc, src/bin/ltldo.cc, src/tgbatest/ltl2tgba.cc:
Call hoa_parse instead of lbt_parse.
* src/hoaparse/hoaparse.yy: Improve error reporting from LBT.
* src/hoaparse/hoascan.ll: Fix typos preventing parsing of
LBT files with more than 10 states.
* src/tgbaalgos/lbtt.cc, src/tgbaalgos/lbtt.hh: Delete the lbt
parser.
* src/tgbatest/lbttparse.test: Adjust the expected error message.
* NEWS: Update.
2015-02-01 02:09:48 +01:00
Alexandre Duret-Lutz
dbd824c539 save: remove
Get rid of the output in Spot's format.

This finally fixes #1.

* src/tgbaalgos/save.cc, src/tgbaalgos/save.hh: Delete.
* src/tgbaalgos/Makefile.am: Adjust.
* src/ltlvisit/contain.cc: Remove useless includes.
* src/bin/dstar2tgba.cc, src/bin/common_aoutput.cc,
src/bin/common_aoutput.hh: Remove the "Spot" output.
* doc/org/dstar2tgba.org, doc/org/ioltl.org,
doc/org/ltl2tgba.org, doc/org/oaut.org: Update doc.
* NEWS: Mention that Spot i/o is gone.
* src/tgbatest/randtgba.cc: Output in HOA.
* src/tgbatest/randtgba.test: Use randaut instead of
randtgba.
* wrap/python/spot.i: Do not provide binding for save.hh
2015-01-31 21:22:15 +01:00
Alexandre Duret-Lutz
a246c3b8ba tgbaparse: remove this parser
For issue #1 (nearly done).

* src/tgbaparse/: Delete.
* configure.ac, src/Makefile.am, README: Adjust.
* src/tgbatest/randtgba.cc: Remove useless #include.
2015-01-31 21:22:10 +01:00
Alexandre Duret-Lutz
d0f0be234d maskacc: Add a tgba_digraph version
* src/tgbaalgos/mask.cc, src/tgbaalgos/mask.hh: New files.
* src/tgbaalgos/Makefile.am: Adjust.
* src/tgba/acc.hh (mark_t::set): New method.
* src/bin/autfilt.cc: Add option --mask-acc.
* src/tgbatest/maskacc.test: Rewrite.
* src/tgbatest/maskacc.cc: Delete.
* src/tgbatest/Makefile.am: Adjust.
2015-01-31 21:21:46 +01:00
Alexandre Duret-Lutz
a0a035e0e1 tgbatest: remove the unused powerset source
* src/tgbatest/powerset.cc: Delete.
* src/tgbatest/Makefile.am: Adjust.
2015-01-31 17:55:38 +01:00
Alexandre Duret-Lutz
7b5f80d46d tgbatest: get rid of tgbaread
since it's only purpose is to test a parser we
want to get rid of (#1)

* src/tgbatest/tgbaread.cc, src/tgbatest/tgbaread.test: Delete.
* src/tgbatest/Makefile.am: Adjust.
2015-01-31 17:49:02 +01:00
Alexandre Duret-Lutz
33a944705c tgbatest: drop support of Spot's legacy format from ltl2tgba
This is progress for #1.

* src/tgbatest/ltl2tgba.cc: Remove options -b and -X.  Change
-P to read HOA files instead.
* src/tgbatest/complementation.cc: Replace option -b by -H for
HOA output, and read files in HOA.
* src/tgbatest/complementation.test, src/tgbatest/cycles.test,
src/tgbatest/dbacomp.test, src/tgbatest/degenid.test,
src/tgbatest/dfs.test, src/tgbatest/emptchke.test,
src/tgbatest/ltl2tgba.test, src/tgbatest/renault.test,
src/tgbatest/satmin2.test, src/tgbatest/sccsimpl.test,
src/tgbatest/sim2.test: Adjust.
2015-01-31 17:46:32 +01:00
Alexandre Duret-Lutz
5852292c9f hoa: correctly deal with "Acceptance: 1 t"
Report from Tomáš Babiak and František Blahoudek

See also https://github.com/adl/hoaf/issues/36

Also fix a typo in the handling of Fin(1)&Fin(!1) while we are at it.

* src/hoaparse/hoaparse.yy: Here.
* src/tgbatest/hoaparse.test: Add tests.
2015-01-28 22:35:11 +01:00
Alexandre Duret-Lutz
44f98219d3 python: use hoa_parse instead of tgba_parse
* src/hoaparse/public.hh: Cope with SWIG.
* wrap/python/spot.i: Bind hoa_parse instead of tgba_parse.
Remove the binding for tgba_parse because it will be removed
soon from Spot (cf. #1).
* wrap/python/ajax/spot.in: Use the HOA output of ltl3ba.
* wrap/python/tests/parsetgba.py: Adjust test case.
2015-01-27 22:44:01 +01:00
Alexandre Duret-Lutz
6819cee682 bin: fix compilation on mingw
* src/bin/common_trans.cc: Fix conditional compilation.
* src/bin/ltldo.cc, src/bin/ltlcross.cc: Include sys/wait.h.
2015-01-27 22:03:26 +01:00
Alexandre Duret-Lutz
48d508420b ltldo: rounds start at 1
* src/bin/ltldo.cc: Start at 1.
* src/tgbatest/ltldo.test: Adjust.
2015-01-27 16:02:13 +01:00
Alexandre Duret-Lutz
a24a021964 bin: add shorthands for ltlcross and ltldo
* src/bin/common_trans.cc: Implement shorthands.
* doc/org/ltlcross.org, doc/org/ltldo.org: Document them.
* src/tgbatest/ltldo2.test: Quick test.
* NEWS: Mention it.
2015-01-27 15:16:50 +01:00
Alexandre Duret-Lutz
259c9faaae ltldo: automatic renaming of AP
* src/bin/ltldo.cc: Relabel formula and output automata as needed.
* src/tgbaalgos/relabel.cc, src/tgbaalgos/relabel.hh: New files.
* src/tgbaalgos/Makefile.am: Add them.
* src/tgbatest/ltldo.test: Add some tests.
* doc/org/ltldo.org: Document this.
2015-01-27 15:16:50 +01:00
Alexandre Duret-Lutz
a4a0cf3bb2 ltl: keep track of spin-compatible AP
* src/misc/bareword.cc, src/misc/bareword.hh (is_spin_ap): New function.
* src/ltlast/formula.cc, src/ltlast/formula.hh (is_spin_atomic_props):
New method and boolean.
* src/ltlast/atomic_prop.cc, src/ltlast/constant.cc: Update it.
* src/ltltest/kind.test: Test it.
2015-01-27 10:21:17 +01:00
Alexandre Duret-Lutz
16a8c03143 ltldo: new binary
* src/bin/common_trans.cc, src/bin/common_trans.hh: New files,
extracted from...
* src/bin/ltlcross.cc: ... here, so that ltldo can use them.
* src/bin/ltldo.cc: New file.
* src/bin/Makefile.am: Adjust.
* src/bin/common_aoutput.cc, src/bin/common_aoutput.hh: Make
it possible to add new statistics.
* doc/org/ltldo.org: New file.
* doc/Makefile.am, doc/org/tools.org: Adjust.
* src/bin/man/ltldo.x: New file.
* src/bin/man/Makefile.am: Adjust.
* src/bin/man/ltlcross.x, src/bin/man/ltlfilt.x: Mention ltldo(1).
* src/tgbatest/ltldo.test, src/tgbatest/ltldo2.test: New files.
* src/tgbatest/Makefile.am: Add them.
* NEWS: Mention ltldo.
2015-01-27 08:18:15 +01:00
Alexandre Duret-Lutz
e5294aac21 never: use state-names as comments
* src/tgbaalgos/neverclaim.cc: Here.
* src/hoaparse/hoaparse.yy: Use set_acceptance_conditions() to set
the number of acceptance sets.  Otherwise, the single_acc_set property
is not set.
* src/tgbaalgos/postproc.cc: When expecting a BA or a monitor, do not do
anything if the input is already a BA or a monitor.
* src/tgbatest/hoaparse.test: Add a test case.
* src/tgbatest/readsave.test: Adjust.
2015-01-25 13:07:04 +01:00
Alexandre Duret-Lutz
c44b158716 org: declare utf8 everwhere and fix some typos
* doc/org/autfilt.org, doc/org/csv.org, doc/org/dstar2tgba.org,
doc/org/genltl.org, doc/org/ioltl.org, doc/org/ltl2tgba.org,
doc/org/ltlfilt.org, doc/org/ltlgrind.org, doc/org/oaut.org,
doc/org/randaut.org, doc/org/tools.org: Update.
2015-01-25 12:03:15 +01:00
Alexandre Duret-Lutz
25af8e7eff update to ltl3ba 1.1.1
Compared to 1.1.0, -L/-M have been renamed to -M0,-M1.

* bench/ltl2tgba/tools, bench/spin13/README,
bench/spin13/run.sh, doc/org/ltlcross.org,
wrap/python/ajax/spot.in: Adjust all references.
2015-01-25 11:44:00 +01:00
Alexandre Duret-Lutz
d9045d131c bin: factor common conversion functions
* src/bin/common_conv.cc, src/bin/common_conv.hh: New files.
* src/bin/Makefile.am: Add them.
* src/bin/autfilt.cc, src/bin/ltlcross.cc, src/bin/ltlfilt.cc,
src/bin/ltlgrind.cc, src/bin/randaut.cc, src/bin/randltl.cc: Use them.
2015-01-24 22:55:57 +01:00
Alexandre Duret-Lutz
06d1c1ea96 * wrap/python/ajax/spot.in: Replace call to dupex by ensure_digraph. 2015-01-24 16:52:08 +01:00
Alexandre Duret-Lutz
49701ca3bc dotty: get rid of the decorated version
* src/tgbaalgos/dottydec.cc, src/tgbaalgos/dottydec.hh,
src/tgbaalgos/rundotdec.cc, src/tgbaalgos/rundotdec.hh: Delete.
* src/tgbaalgos/Makefile.am, wrap/python/spot.i: Adjust.
* src/tgbaalgos/dotty.cc, src/tgbaalgos/dotty.hh: Remove the
decorated version, and the related arguments.
* src/bin/common_aoutput.cc, src/bin/dstar2tgba.cc,
src/tgbatest/ltl2tgba.cc, src/tgbatest/complementation.cc,
src/tgbatest/emptchk.cc: Adjust calls.
* wrap/python/ajax/spot.in: Draw the accepting run as an
automaton instead of painting it.
* wrap/python/ajax/ltl2tgba.html: Update help text.
2015-01-24 12:22:31 +01:00
Alexandre Duret-Lutz
947ab17b12 autfilt: add an --intersect filter
* src/bin/autfilt.cc: Add option --intersect.  Factor the code to read
automata.
* src/tgbatest/neverclaimread.test: Rewrite the tests, replacing 3 calls
to ltl2tgba by a single call to autfilt.
2015-01-23 22:48:15 +01:00