Commit graph

270 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
5b3034b605 dot: add an option to display the acceptance
* src/tgbaalgos/dotty.cc: Display the acceptance if "a" is used.
* src/bin/common_aoutput.cc, src/bin/dstar2tgba.cc,
src/tgbaalgos/dotty.hh: Document it.
* src/tgbatest/readsave.test: Test it.
2015-02-26 17:30:01 +01:00
Alexandre Duret-Lutz
717c857794 ltlcross: adjust to work with generic acceptance
* src/bin/ltlcross.cc: Remove Fin-acceptance before
doing checks.  More --verbose output.
* src/tgba/acc.cc, src/tgba/acc.hh: Add an eval_sets() function
to find the set of acceptance sets needed to satisfy the condition
in an accepting SCC.
* src/tgbaalgos/gtec/ce.cc: Use eval_sets() when computing
a counter example.
* src/tgbaalgos/gtec/gtec.cc: Raise an exception when called
on an acceptance that contains Fin.
* src/tgbatest/ltl2dstar3.test, src/tgbatest/ltlcrossce2.test:
New files.
* src/tgbatest/Makefile.am: Add them.
* src/tgba/tgba.cc (is_empty): Call remove_fin if needed.
* src/tgbaalgos/product.cc, src/tgbaalgos/dtgbacomp.cc: Adjust
to work with generic acceptance.
2015-02-26 17:30:01 +01:00
Alexandre Duret-Lutz
d597050f6d Make it easy to complement an acceptance condition
* src/tgba/acc.cc, src/tgba/acc.hh (complement): New method.
* src/bin/autfilt.cc: Add a --complement-acceptance option.
* src/tgbatest/acc2.test: Test it.
2015-02-26 17:30:01 +01:00
Alexandre Duret-Lutz
659107a000 Add a cleanup_acceptance() algorithm
* src/tgbaalgos/cleanacc.cc, src/tgbaalgos/cleanacc.hh: New file.
* src/tgbaalgos/Makefile.am: Add them.
* src/tgba/acc.hh, src/tgba/tgba.hh (get_acceptance): Return a
reference.
* src/bin/autfilt.cc: Add a --cleanup-acceptance option.
* src/tgbatest/hoaparse.test: Test it.
2015-02-26 17:30:01 +01:00
Alexandre Duret-Lutz
85508a0ea6 Add a remove_fin() algorithm
* src/bin/autfilt.cc: Add remove_fin().
* src/tgba/acc.cc, src/tgba/acc.hh: Add is_dnf() and simplify eval().
* src/tgbaalgos/remfin.cc, src/tgbaalgos/remfin.hh: New files.
* src/tgbaalgos/Makefile.am: Add them.
* src/tgbatest/remfin.test: New file.
* src/tgbatest/Makefile.am: Add it.
2015-02-26 17:30:01 +01:00
Alexandre Duret-Lutz
1441c4fe34 acc: add a to_dnf() method
* src/tgba/acc.cc, src/tgba/acc.hh: Implement a to_dnf()
method.
* src/bin/autfilt.cc: Add option --dnf-acceptance.
* src/tgbatest/acc2.test: Test it.
2015-02-24 15:32:15 +01:00
Alexandre Duret-Lutz
de586dd2f0 stats: use %g to print the (generic) acceptance condition
* src/tgbaalgos/stats.cc, src/tgbaalgos/stats.hh: Implement %g.
* src/bin/common_aoutput.cc, src/bin/common_aoutput.hh:
Document it, and also implement %G.
* src/tgbatest/acc2.test: New file.
* src/tgbatest/Makefile.am: Add it.
2015-02-23 17:12:12 +01:00
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
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
Alexandre Duret-Lutz
87f51e28e0 ltldo: cleanup temporary files
* src/bin/ltldo.cc: Here.
2015-02-06 22:31:39 +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
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
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
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
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
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
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
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
Alexandre Duret-Lutz
0159027395 simulation: get rid of the "don't care" simulation reductions
Those where never really publicized because they were slow and we failed
to fix what we hopped to fix with them.  They where never used by
default.  Getting rid of them will make it easier to cleanup the
simulation code.

* src/tgbaalgos/simulation.cc, src/tgbaalgos/simulation.hh: Remove
the simulation code.
* src/tgbaalgos/postproc.cc, src/tgbaalgos/postproc.hh,
src/tgbatest/ltl2tgba.cc: Do not call it.
* src/bin/spot-x.cc: Update doc.
* src/tgbatest/sim.test: Delete this file.
* src/tgbatest/Makefile.am: Adjust.
* src/tgbatest/spotlbtt.test, bench/ltl2tgba/tools.sim:
Remove uses to don't care simulation.
2015-01-19 18:17:44 +01:00
Alexandre Duret-Lutz
34f1601b9b ltl: rename is_X_free() into is_syntactic_stutter_invariant()
and adjust it to detect siPSL formulas, as in the paper of Dax et
al. (ATVA'09).  For issue #51.

* src/ltlast/atomic_prop.cc, src/ltlast/binop.cc,
src/ltlast/bunop.cc, src/ltlast/constant.cc, src/ltlast/formula.cc,
src/ltlast/formula.hh, src/ltlast/multop.cc, src/ltlast/unop.cc: Rename
the property, and adjust its computation on siSERE.
* src/ltlvisit/remove_x.cc, src/ltlvisit/simplify.cc,
src/tgbaalgos/stutter.cc: Adjust to new names.
* src/bin/ltlfilt.cc: Add option --syntactic-sutter-invariant.
* src/ltltest/kind.test: Update tests and add some new.
2015-01-19 14:39:41 +01:00
Alexandre Duret-Lutz
8fd594f5d0 ltlfilt: add a --max-count/-n option
This fixes #44.

* src/bin/ltlfilt.cc: Implement -n/--max-count.
* doc/org/ltlfilt.org, src/tgbatest/randpsl.test: Use it
* NEWS: Document it.
2015-01-14 19:59:23 +01:00
Alexandre Duret-Lutz
ae234d2e12 ltlfilt: remove -n.
* src/bin/ltlfilt.cc: Remove short option -n for --negate.
2015-01-14 18:24:31 +01:00
Alexandre Duret-Lutz
6a2aad6259 never: add an option to output in Spin's 6.2.4 style
Fixes #46.

* src/tgbaalgos/neverclaim.cc: Add option '6'.
* src/bin/common_aoutput.cc, src/bin/dstar2tgba.cc: Make it
possible to use the option.
* NEWS, doc/org/oaut.org: Document it.
* src/tgbatest/ltlcross2.test: Test it.
2015-01-09 22:52:46 +01:00
Alexandre Duret-Lutz
e01ab2b236 sccinfo: make it easier to iterate over all SCCs
* src/tgbaalgos/sccinfo.cc, src/tgbaalgos/sccinfo.hh: add
scc_info::begin() and scc_info::end() methods to iterate over the
node_ vector.   Tidy the scc_node structure that that its member
are accessed via methods.
* src/tgbaalgos/safety.cc, src/bin/ltlcross.cc: Simplify using
this interface.
2015-01-09 13:46:13 +01:00
Alexandre Duret-Lutz
94577d6519 product: rename the one-the-fly version as otf_product
This avoid compiler errors about ambiguous calls and make sure we are
calling the intended algorithms everywhere (this wasn't the case).

* src/tgba/tgbaproduct.hh (product, product_at): Rename as...
(otf_product, otf_product_at): ... this.
* iface/ltsmin/modelcheck.cc, src/bin/autfilt.cc, src/bin/ltlfilt.cc,
src/tgbaalgos/minimize.cc, src/tgbaalgos/powerset.cc,
src/tgbatest/ltl2tgba.cc, src/tgbatest/checkpsl.cc,
src/tgbatest/complementation.cc, src/tgbatest/ltlprod.cc: Adjust
callers.
2015-01-09 08:23:49 +01:00
Alexandre Duret-Lutz
7c34c1ae79 stutterize: fix sl2() to keep the correct properties
Combined with 87c2b29, this fixes #7.

* src/tgbaalgos/stutterize.cc: Call keep_props().
* src/tgbaalgos/closure.cc: Just specify the encoding.
* src/bin/autfilt.cc: Add a --instut=2 option.
* src/tgbatest/stutter.test: More test.
2015-01-05 21:52:12 +01:00
Alexandre Duret-Lutz
a5d52633bd bin: fix help text for --dot
* src/bin/common_aoutput.cc, src/bin/dstar2tgba.cc: Here.
2015-01-04 15:59:45 +01:00
Alexandre Duret-Lutz
c6a5de3e23 dstar2tgba: add support for --name and --stats=%m
* src/bin/dstar2tgba.cc: Here.
* src/tgbatest/dstar.test: Test them.
2015-01-04 12:55:26 +01:00
Alexandre Duret-Lutz
4d4c5d807b ltl2tgba, randaut: better error reporting
* src/bin/ltl2tgba.cc, src/bin/randaut.cc: Catch exceptions
in main loop.
* src/tgbatest/ltl2tgba.test, src/tgbatest/randaut.test: Test
errors with unknown --dot argument.
2015-01-04 11:24:31 +01:00
Alexandre Duret-Lutz
3b7b52027c More files to ignore. 2015-01-03 19:01:44 +01:00
Alexandre Duret-Lutz
b048f65dd8 bin: --dot=s display SCCs
* src/tgbaalgos/dotty.cc: Add option 's' to display SCCs.
* src/bin/dstar2tgba.cc, src/bin/common_aoutput.cc: Document it.
* src/tgbatest/neverclaimread.test: Test it.
2015-01-03 17:08:14 +01:00
Alexandre Duret-Lutz
40fb80ea2c bin: use common_aoutput in ltl2tgba
* src/bin/common_aoutput.hh, src/bin/common_aoutput.cc: Adjust to
support three kind of statistics printer, depending on whether the
tool input formulas, automata, or nothing.
* src/bin/randaut.cc, src/bin/autfilt.cc: Adjust.
* src/bin/ltl2tgba.cc: Use the common_aoutput printers.  The
--csv-escape option disappeared along the way, but it was not honored
anyway...
2015-01-03 17:08:14 +01:00
Alexandre Duret-Lutz
72737dfefc bin: factor output options of autfilt and randaut
* src/bin/autfilt.cc: Move output options handling...
* src/bin/common_aoutput.cc, src/bin/common_aoutput.hh:... here.
* src/bin/randaut.cc: Use them.
* src/tgbatest/randaut.test: Test --name and --stats for randaut.
2015-01-03 17:08:14 +01:00
Alexandre Duret-Lutz
3f4b19142d * src/bin/common_setup.cc: bump copyright year to 2015. 2015-01-03 17:08:14 +01:00
Alexandre Duret-Lutz
cf65f606b4 ltlgrind: cosmetics
* src/bin/ltlgrind.cc: Adjust help text to match other tools.
2015-01-03 17:08:14 +01:00
Alexandre Duret-Lutz
06b8118dec ltl2tgba: rename --hoa to --hoaf
for consistency with autfilt, randaut, and dstar2tgba

* src/bin/ltl2tgba.cc: Here.
2015-01-03 17:08:14 +01:00
Alexandre Duret-Lutz
a7c1d4c479 autfilt, randaut: rename --uniq to --unique
for consistency with ltlfilt

* src/bin/autfilt.cc, src/bin/randaut.cc: Here.
2015-01-03 17:08:14 +01:00