Commit graph

3873 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
736003057c * NEWS: Minor typos and reorganization. 2016-08-03 12:23:46 +02:00
Alexandre Duret-Lutz
51afd4adfe ltlcross: prefer execl("/bin/sh", ...) to execlp("sh", ...)
Fixes #98.

* bin/common_trans.cc: Here.
2016-08-02 14:24:08 +02:00
Alexandre Duret-Lutz
7524e05128 ltlcross: bypass the shell for simple command
For #98.

* bin/common_trans.cc: Here.
* NEWS: Mention it.
2016-08-02 14:24:05 +02:00
Alexandre Duret-Lutz
d2068bb1a0 sbacc: improve using SCCs and common marks
* spot/twaalgos/sbacc.cc: Here.
* tests/core/parseaut.test, tests/python/automata.ipynb: Adjust.
* tests/core/sbacc.test: Likewise + more tests.
* NEWS: Mention it.
2016-07-31 22:57:50 +02:00
Alexandre Duret-Lutz
d271dfd592 python: make it possible to modify edges during iteration
Reported by Laurent Xu.

* python/spot/impl.i: Fix the iterator to return pointers instead of
references.  Because references are ultimately copied.
* tests/python/automata.ipynb: Add test cases.
* NEWS: Mention it.
2016-07-29 16:09:54 +02:00
Alexandre Duret-Lutz
09c6393942 * NEWS: Typo. 2016-07-29 11:59:31 +02:00
Alexandre Duret-Lutz
59efe470ca ltlcross: show cross-comparison checks counterexamples
Part of #38.

* bin/ltlcross.cc: Implement it.
* NEWS: Mention it.
* doc/org/ltlcross.org: Adjust example.
* tests/core/ltlcrossce2.test: New test case.
2016-07-29 11:58:12 +02:00
Alexandre Duret-Lutz
f6c7ed54c7 update gnulib
This comes from gnulib 348402f2aac342bc925b7aaea9ee3cc353f427a9 plus
a custom patch to support compilation of arpg in C++11.

* lib/hard-locale.c, lib/hard-locale.h, m4/hard-locale.m4, m4/ltargz.m4:
New files.
* lib/Makefile.am, lib/alloca.in.h, lib/argmatch.c, lib/argmatch.h,
lib/argp-ba.c, lib/argp-eexst.c, lib/argp-fmtstream.c,
lib/argp-fmtstream.h, lib/argp-fs-xinl.c, lib/argp-help.c,
lib/argp-namefrob.h, lib/argp-parse.c, lib/argp-pin.c, lib/argp-pv.c,
lib/argp-pvh.c, lib/argp-xinl.c, lib/argp.h, lib/asnprintf.c,
lib/basename-lgpl.c, lib/c-ctype.h, lib/c-strcase.h, lib/c-strcasecmp.c,
lib/c-strcaseeq.h, lib/c-strncasecmp.c, lib/config.charset,
lib/dirname-lgpl.c, lib/dirname.h, lib/dosname.h, lib/errno.in.h,
lib/error.c, lib/error.h, lib/exitfail.c, lib/exitfail.h,
lib/fcntl.in.h, lib/float+.h, lib/float.c, lib/float.in.h, lib/getopt.c,
lib/getopt.in.h, lib/getopt1.c, lib/getopt_int.h, lib/gettext.h,
lib/gettimeofday.c, lib/hard-locale.h, lib/intprops.h, lib/isatty.c,
lib/itold.c, lib/localcharset.c, lib/localcharset.h, lib/lstat.c,
lib/malloc.c, lib/mbrtowc.c, lib/mbsinit.c, lib/memchr.c, lib/mempcpy.c,
lib/mkstemp.c, lib/mkstemps.c, lib/msvc-inval.c, lib/msvc-inval.h,
lib/msvc-nothrow.c, lib/msvc-nothrow.h, lib/pathmax.h,
lib/printf-args.c, lib/printf-args.h, lib/printf-parse.c,
lib/printf-parse.h, lib/progname.c, lib/progname.h, lib/quote.h,
lib/quotearg.c, lib/quotearg.h, lib/rawmemchr.c, lib/ref-add.sin,
lib/ref-del.sin, lib/secure_getenv.c, lib/size_max.h, lib/sleep.c,
lib/stat.c, lib/stdalign.in.h, lib/stdbool.in.h, lib/stddef.in.h,
lib/stdint.in.h, lib/stdio.in.h, lib/stdlib.in.h, lib/stpcpy.c,
lib/strcasecmp.c, lib/strchrnul.c, lib/streq.h, lib/strerror-override.c,
lib/strerror-override.h, lib/strerror.c, lib/string.in.h,
lib/strings.in.h, lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c,
lib/strnlen.c, lib/strverscmp.c, lib/sys_stat.in.h, lib/sys_time.in.h,
lib/sys_types.in.h, lib/sys_wait.in.h, lib/sysexits.in.h,
lib/tempname.c, lib/tempname.h, lib/time.in.h, lib/unistd.in.h,
lib/vasnprintf.c, lib/vasnprintf.h, lib/verify.h, lib/vsnprintf.c,
lib/wchar.in.h, lib/wctype.in.h, lib/xalloc-die.c,
lib/xalloc-oversized.h, lib/xalloc.h, lib/xmalloc.c, lib/xsize.h,
m4/00gnulib.m4, m4/absolute-header.m4, m4/alloca.m4, m4/argp.m4,
m4/codeset.m4, m4/configmake.m4, m4/dirname.m4, m4/double-slash-root.m4,
m4/errno_h.m4, m4/error.m4, m4/exponentd.m4, m4/extensions.m4,
m4/extern-inline.m4, m4/fcntl-o.m4, m4/fcntl_h.m4, m4/float_h.m4,
m4/getopt.m4, m4/gettimeofday.m4, m4/glibc21.m4, m4/gnulib-cache.m4,
m4/gnulib-common.m4, m4/gnulib-comp.m4, m4/gnulib-tool.m4,
m4/include_next.m4, m4/intmax_t.m4, m4/inttypes_h.m4, m4/isatty.m4,
m4/largefile.m4, m4/localcharset.m4, m4/locale-fr.m4, m4/locale-ja.m4,
m4/locale-zh.m4, m4/longlong.m4, m4/lstat.m4, m4/malloc.m4,
m4/math_h.m4, m4/mbrtowc.m4, m4/mbsinit.m4, m4/mbstate_t.m4,
m4/memchr.m4, m4/mempcpy.m4, m4/mkstemp.m4, m4/mkstemps.m4,
m4/mmap-anon.m4, m4/msvc-inval.m4, m4/msvc-nothrow.m4, m4/multiarch.m4,
m4/nocrash.m4, m4/off_t.m4, m4/pathmax.m4, m4/printf.m4, m4/quote.m4,
m4/quotearg.m4, m4/rawmemchr.m4, m4/secure_getenv.m4, m4/size_max.m4,
m4/sleep.m4, m4/ssize_t.m4, m4/stat.m4, m4/stdalign.m4, m4/stdbool.m4,
m4/stddef_h.m4, m4/stdint.m4, m4/stdint_h.m4, m4/stdio_h.m4,
m4/stdlib_h.m4, m4/stpcpy.m4, m4/strcase.m4, m4/strchrnul.m4,
m4/strerror.m4, m4/string_h.m4, m4/strings_h.m4, m4/strndup.m4,
m4/strnlen.m4, m4/strverscmp.m4, m4/sys_socket_h.m4, m4/sys_stat_h.m4,
m4/sys_time_h.m4, m4/sys_types_h.m4, m4/sys_wait_h.m4, m4/sysexits.m4,
m4/tempname.m4, m4/time_h.m4, m4/unistd_h.m4, m4/vasnprintf.m4,
m4/vsnprintf.m4, m4/warn-on-use.m4, m4/wchar_h.m4, m4/wchar_t.m4,
m4/wctype_h.m4, m4/wint_t.m4, m4/xalloc.m4, m4/xsize.m4,
tests/core/randtgba.cc, tools/snippet/arg-nonnull.h,
tools/snippet/c++defs.h, tools/snippet/warn-on-use.h: Update.
2016-07-29 10:59:21 +02:00
Alexandre Duret-Lutz
561672d3d7 lbtt: fix a memory leak detected by asan.
* spot/twaalgos/lbtt.cc: Here.
* NEWS: Mention it.
2016-07-27 20:10:51 +02:00
Alexandre Duret-Lutz
a9fc5d49d8 misc: fix some signed shifts
* spot/misc/intvcmp2.cc, spot/misc/intvcomp.cc: Here.
2016-07-27 19:47:34 +02:00
Alexandre Duret-Lutz
a7842ac47f tests: disable ltsmin tests if --disable-shared
* configure.ac (USE_LTSMIN): New.
* tests/Makefile.am: Use it.
2016-07-27 19:47:34 +02:00
Alexandre Duret-Lutz
8e69530023 [buddy] fix an undefined behavior
* src/prime.c (BitIsSet): Do not shift signed
int by 31 places; shift unsigned int instead.
2016-07-27 19:47:30 +02:00
Alexandre Duret-Lutz
fcd6783157 * doc/org/tut50.org: Simplify UML diagrams. 2016-07-27 16:21:37 +02:00
Alexandre Duret-Lutz
15ea2e66e8 org: show how to implement Kripke structures
* doc/org/tut51.org: New file.
* doc/org/tut.org, doc/Makefile.am, NEWS: Add it.
* elisp/ob-dot.el: New file, to work around old org-mode versions.
* elisp/README, elisp/Makefile.am: Add it.
2016-07-27 16:21:03 +02:00
Alexandre Duret-Lutz
6617538156 kripke: rename state_acceptance_conditions
* spot/kripke/kripke.cc, spot/kripke/kripke.hh,
spot/kripke/fairkripke.hh (state_acceptance_conditions): Rename as...
(state_acceptance_mark): ... this.
* NEWS: Mention it.
2016-07-27 11:13:06 +02:00
Alexandre Duret-Lutz
096edf227d * NEWS: Reword some entries. 2016-07-27 10:35:59 +02:00
Alexandre Duret-Lutz
64c7036660 active -Wsuggest-override where supported
* m4/gccwarn.m4: Add the option.
* bin/autfilt.cc, bin/common_output.hh, bin/dstar2tgba.cc,
bin/ltl2tgba.cc, bin/ltl2tgta.cc, bin/ltlcross.cc, bin/ltldo.cc,
bin/ltlfilt.cc, bin/ltlgrind.cc, spot/kripke/kripke.hh,
spot/ltsmin/ltsmin.cc, spot/ta/ta.hh, spot/ta/tgtaproduct.hh,
spot/taalgos/dot.cc, spot/taalgos/reachiter.hh,
spot/taalgos/statessetbuilder.cc, spot/taalgos/stats.cc,
spot/twa/twaproduct.cc, spot/twaalgos/emptiness.cc,
spot/twaalgos/gtec/ce.cc, spot/twaalgos/lbtt.cc,
spot/twaalgos/ndfs_result.hxx, spot/twaalgos/stats.hh,
spot/twaalgos/tau03opt.cc, tests/core/ngraph.cc: Add suggested override
qualifiers.
2016-07-27 10:30:10 +02:00
Alexandre Duret-Lutz
da464d8199 org: document explicit vs. on-the-fly
* doc/org/tut50.org: New file.
* doc/org/tut.org: Add it.
* NEWS: Mention it.
* doc/Makefile.am: Add tut50.org, and download plantuml.jar when needed.
* doc/org/.dir-locals.el.in, doc/org/init.el.in: Activate plantum.
* HACKING: Mention the Java dependency.
2016-07-26 11:26:16 +02:00
Alexandre Duret-Lutz
d7d6b40926 minimize_wdba: fix nondeterministic execution
Fixes core/readsave.test and python/automata.ipython
with gcc-snapshot (future gcc 7).

* spot/twaalgos/minimize.cc: Here.
* NEWS: Mention the change.
* tests/core/acc_word.test: Adjust test case.
2016-07-25 14:02:40 +02:00
Alexandre Duret-Lutz
20cf43b3ea use SPOT_ASSERT instead of assert
For #184.

* spot/graph/graph.hh, spot/kripke/kripkegraph.hh,
spot/misc/bitvect.hh, spot/misc/common.hh, spot/misc/fixpool.hh,
spot/misc/mspool.hh, spot/misc/timer.hh, spot/tl/formula.hh,
spot/twa/acc.hh, spot/twa/taatgba.hh, spot/twa/twa.hh,
spot/twa/twagraph.hh, spot/twaalgos/emptiness_stats.hh,
spot/twaalgos/mask.hh, spot/twaalgos/ndfs_result.hxx,
spot/twaalgos/sccinfo.hh, spot/twaalgos/translate.hh: Replace
assert() by SPOT_ASSERT(), or an exception, or nothing, depending
on the case.
* tests/sanity/style.test: Flag all asserts in headers.
* HACKING: Discuss assertions.
2016-07-24 23:26:59 +02:00
Alexandre Duret-Lutz
9f7bf5ab2d configure: support --enable-glibgxx-debug
Part of #184.

* m4/devel.m4 (adl_ENABLE_GLIBCXX_DEBUG): New macro.
* configure.ac: Use it.
* README: Mention it.
* spot/twa/acc.cc: Fix a small issue found with this
option.
2016-07-24 00:07:04 +02:00
Alexandre Duret-Lutz
1a5de86c1e * spot/tl/formula.hh: Fix some comments. 2016-07-24 00:02:34 +02:00
Alexandre Duret-Lutz
71e2490643 twa: rename twa::succ_iterable into internal::twa_succ_iterable
* spot/twa/twa.hh: Here.
* NEWS: Mention the change.
2016-07-22 14:14:23 +02:00
Alexandre Duret-Lutz
7534f62dba org: add autfilt decoration examples
* doc/org/autfilt.org: Here.
* doc/org/hoa.org: Add a link to it.
* bin/autfilt.cc: Typo.
2016-07-20 11:22:20 +02:00
Alexandre Duret-Lutz
dd6875d5fe bin: overhaul default input selection
If no input have been specified, and the standard input is not a tty all
tools now default to reading it.  If standard input is a tty, all tools
display an error message.  Additionally, - is now a shorthand for -F- in
all tools.

* NEWS: Summarize this.
* bin/common_finput.cc, bin/common_finput.hh (check_no_formulas,
check_no_automaton): New functions that implement the above istty()
logic.
* bin/autfilt.cc, bin/dstar2tgba.cc, bin/ltl2tgba.cc, bin/ltl2tgta.cc,
bin/ltlcross.cc, bin/ltldo.cc, bin/ltlgrind.cc: Use these function,
and recognize '-' if it was not the case.
* tests/core/acc_word.test, tests/core/ltldo.test,
tests/core/minusx.test, tests/core/readsave.test,
tests/core/unambig.test: Adjust some tests to exercise this.
* doc/org/autfilt.org, doc/org/csv.org, doc/org/dstar2tgba.org,
doc/org/ltl2tgba.org, doc/org/ltlcross.org, doc/org/ltlfilt.org,
doc/org/oaut.org: Adjust the documentation and simplify some
examples.
2016-07-19 21:55:12 +02:00
Alexandre Duret-Lutz
abff7eba8e simplifier: new PSL simplifications
{e[*0..j]}<>->f = {e[*1..j]}<>->f
{e[*0..j]}[]->f = {e[*1..j]}[]->f

Fixes #81.

This required a small change to the bounded-star-normal-form to prevent
infinite recursion.

* spot/tl/simplify.cc: Implement these rules.
* doc/tl/tl.tex, NEWS: Document them.
* tests/core/reduccmp.test: Add tests, and adjust others.
* tests/core/unambig.test: Replace formula that used to generated an
ambiguous automaton, but now generates a deterministic one.
2016-07-19 17:57:16 +02:00
Alexandre Duret-Lutz
d5b2de7fa8 simplifier: new LTL simplifications
if e is pure eventuality and g => e, then e U g = Fg
if u is purely universal and u => g, then u R g = Gg

Fixes #93.

* doc/tl/tl.tex, NEWS: Document the rules.
* spot/tl/simplify.cc: Implement them.
* tests/core/reduccmp.test: Test them.
* tests/core/det.test: Adjust.
2016-07-19 16:02:19 +02:00
Alexandre Duret-Lutz
e37f62dc75 python: have %%dve and %%pml honor SPOT_TMPDIR and TMPDIR
* python/spot/aux.py (tmpdir): New context manager.
* python/spot/ltsmin.i: Use it for the two magics.
* NEWS: Mention this.
2016-07-19 14:23:27 +02:00
Alexandre Duret-Lutz
b136b81c6d new test case to improve coverage stats
The streett_to_generalized_buchi() function was not tested unless
ltl2dstar is installed.

* tests/core/streett.test: New file.
* tests/Makefile.am: Add it.
2016-07-19 13:35:47 +02:00
Alexandre Duret-Lutz
4c0500a8a9 autfilt: add --stutter-invariant
* bin/autfilt.cc: Implement the option.
* NEWS: Mention it.
* tests/core/readsave.test, tests/core/stutter-tgba.test: Add some
tests.
2016-07-19 13:20:08 +02:00
Alexandre Duret-Lutz
5a2bc9f915 stutter: complement non-det automata via determinization
Fixes #164.

* spot/twaalgos/stutter.hh, spot/twaalgos/stutter.cc: Implement
the determinization, while keeping it optional.
* NEWS: Mention the change.
* tests/core/ltl2dstar.test, tests/core/stutter-tgba.test: Add
test cases.
* tests/core/readsave.test: Adjust.
2016-07-19 13:03:37 +02:00
Alexandre Duret-Lutz
29a1e3a299 python: add missing bindings for randomize()
* python/spot/impl.i: Here.
* NEWS: Mention it.
* tests/python/highlighting.ipynb: Add test case.
2016-07-19 02:55:07 +02:00
Alexandre Duret-Lutz
69b687ab66 dot: preserve highlights for <N output
* spot/twa/twagraph.hh (twa_graph::edge_number): New method.
* spot/twaalgos/copy.cc: Copy the highlights if requested.
* tests/python/highlighting.ipynb: More tests.
2016-07-19 02:41:34 +02:00
Alexandre Duret-Lutz
014a9dbd6b twa: add accepting_run() and accepting_word() methods
Fixes #153.

* spot/twa/twa.cc, spot/twa/twa.hh: Add the methods.
* bin/autfilt.cc, bin/common_aoutput.hh, bin/ltlcross.cc,
tests/python/highlighting.ipynb, tests/python/word.ipynb: Use
them to simplify the code.
* NEWS: Mention them.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
3836ea8d18 python: more examples of highlighting
* tests/python/highlighting.ipynb: Augment.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
d1aca565b5 remove the incorrect project_twa_run()
It was bogus, and is better replaced by twa_run::project().

* NEWS, doc/org/upgrade2.org: Mention the removal.
* spot/twaalgos/projrun.cc, spot/twaalgos/projrun.hh: Remove the files.
* spot/twaalgos/Makefile.am: Adjust.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
b13caea3d8 autfilt: --highlight-word
* bin/autfilt.cc: Add the option.
* NEWS: Mention it.
* tests/core/acc_word.test: Test it.
* spot/twaalgos/emptiness.cc,
spot/twaalgos/emptiness.hh (twa_run::project): New method.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
6793d6de7d highlight: do not reset existing highlights
* spot/twa/twa.hh (twa::get_or_set_named_prop): New method.
* spot/twaalgos/emptiness.cc, spot/twaalgos/isdet.cc: Use it to not
overwrite existing highlights.
* tests/core/det.test: Add test case.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
57f47c16e7 genltl: support --positive and --negative
* bin/genltl.cc: Implement these options.
* NEWS: Mention them.
* tests/core/genltl.test: New file with test cases.
* tests/Makefile.am: Add it.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
31a1dfbc6a autfilt: add --nondet-states=RANGE
* bin/autfilt.cc: Here.
* tests/core/det.test: Test it.
* NEWS: Mention it.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
9af7001329 autfilt: swap transformation and filtering --help
It makes more sense to keep the transformationn options near the
simplification options.

* bin/autfilt.cc: Reorder --help.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
b6cd54ab16 autfilt: add highlighting options for nondeterminism
Fixes #123.

* bin/autfilt.cc: Add options --highlight-nondet-states=NUM,
 --highlight-nondet-edges=NUM, and  --highlight-nondet=NUM.
* spot/twaalgos/isdet.cc,
spot/twaalgos/isdet.hh (highlight_nondet_states,
highlight_nondet_edges): New functions.
* tests/core/det.test: Add test cases.
* NEWS: Mention them.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
39332fb118 highlight: improve support for highlighted edges
* spot/twa/twa.cc, spot/twa/twa.hh: Add a way to
remove named properties.
* spot/twa/twagraph.cc: Clear highlight-edges on operations
that reorder the edge vector.
* spot/twaalgos/randomize.cc, spot/twaalgos/randomize.hh:
Preserve highlighted state, but not highlighted edges.
* spot/twaalgos/hoa.cc: Adjust output of highlight-edge
when the edges are not stored in order.
* tests/core/readsave.test, tests/core/tgbagraph.test,
tests/core/twagraph.cc: More test cases.
2016-07-18 23:23:01 +02:00
Alexandre Duret-Lutz
e17a617bc2 hoa: output highlighted states and edges in v1.1
* spot/twaalgos/hoa.cc: Here.
* doc/org/hoa.org, NEWS: Document that.
* tests/core/readsave.test: Test it.
2016-07-18 14:19:08 +02:00
Alexandre Duret-Lutz
bbc3afe1cf org: document named properties
* doc/org/concepts.org: Add a new section.
* doc/org/hoa.org, spot/twa/twa.hh: Link to it.
* NEWS: Mention it.
2016-07-15 18:52:06 +02:00
Alexandre Duret-Lutz
486d9edad7 ltlcross: list collected automata on --verbose
* bin/ltlcross.cc: Here.
2016-07-13 17:33:39 +02:00
Alexandre Duret-Lutz
fafb135c87 isdet: update prop_deterministic in count_nondet_states()
* spot/twaalgos/isdet.cc: Here.
* bin/ltlcross.cc: Simplify.
* NEWS: Update.
2016-07-13 17:33:39 +02:00
Alexandre Duret-Lutz
a2f0b22810 ltlcross: fix swapped automata in error diagnostic
Failures could be reported against "Comp(Ni)*Comp(Pj)" when
it was really "Comp(Nj)*Comp(Pi)" that failed.

* bin/ltlcross.cc: Here.
* NEWS: Mention the bug.
2016-07-13 14:40:04 +02:00
Alexandre Duret-Lutz
556db2a203 Merge branch 'master' into next 2016-07-11 11:06:05 +02:00
Alexandre Duret-Lutz
2abfd73a30 Release Spot 2.0.3
* NEWS, configure.ac, doc/org/setup.org: Update.
2016-07-11 10:59:23 +02:00