Commit graph

1317 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
29a908cc8f Protect the state destructor.
Client code should always call the destroy() method instead.  (It
was introduced in Spot 0.7.)

* src/tgba/state.hh (state::~state): Make it protected.
2011-03-30 21:55:00 +02:00
Alexandre Duret-Lutz
94ac863cfb Speedup tgba_product when one of the argument is a Kripke structure.
The gain is not very impressive.  The runtime of the first example
in iface/dve2/README (also in dve2check.test) is 15% faster.

* src/tgba/tgbaproduct.hh (tgba_succ_iterator_product): Move ...
* src/tgba/tgbaproduct.cc (tgba_succ_iterator_product,
tgba_succ_iterator_product_common): ... in these two classes.
(tgba_succ_iterator_product_kripke): New class to speedup
successor computation on Kripke structures.  We can assume that
all the transitions leaving the same state have the same label.
(tgba_product::tgba_product, tgba_product::succ_iter): Use
tgba_succ_iterator_product_kripke when appropriate.
(tgba_product_init::tgba_product_init): Adjust for the case
where tgba_product did reverse its operands.
2011-03-30 21:53:19 +02:00
Alexandre Duret-Lutz
33732493fe * iface/dve2/dve2check.cc: Remove stray debug output. 2011-03-30 15:43:28 +02:00
Alexandre Duret-Lutz
cc0a903a6e * src/tgba/tgbaproduct.hh: Do not include statebdd.hh. 2011-03-30 10:25:58 +02:00
Alexandre Duret-Lutz
35a0193781 Include <cstddef> in python modules to workaround Swig bug.
* wrap/python/spot.i, wrap/python/buddy.i: Include <cstddef>
because Swig 2.0.2 uses ptrdiff_t and does not do the include
itself.  In g++ most libstdc++ standard headers have been changed
to no longer include <cstddef> as an implementation detail, so
the difference shows.
2011-03-29 22:52:17 +02:00
Alexandre Duret-Lutz
4ce06114d7 * THANKS: Add Michael Weber for his help on the DiVinE interface. 2011-03-21 10:49:22 +01:00
Alexandre Duret-Lutz
a5a74481d9 * src/ltltest/genltl.cc (syntax): Typos in the help text. 2011-03-21 10:49:22 +01:00
Alexandre Duret-Lutz
1878bfd0fc Improve a reduction rule for "a M b".
* src/ltlvisit/reduce.cc (reduce_visitor): Always reduce "a M b"
to "a & b" if "a" is a pure eventual formula, remove the
constraint on "b".
* src/ltltest/reduccmp.test: Add two tests.
2011-03-17 12:25:43 +01:00
Alexandre Duret-Lutz
b51b7ab8b9 * NEWS: Mention recent changes to dotty_reachable. 2011-03-11 10:20:47 +01:00
Alexandre Duret-Lutz
cb83e855a4 Add support for finite behaviors in the DVE interface.
* iface/dve2/dve2.hh (load_dve2): Take a "dead" argument.
* iface/dve2/dve2.cc (callback_context): Add a destructor
to simplify...
(dve2_succ_iterator::~dve2_succ_iterator) ... this one.
(convert_aps): Skip the dead proposition.
(dve2_kripke::dve2_kripke): Take a dead argument, and
setup alive_prop and dead_prop.
(compute_state_condition, get_succ): Use a cache for the
conditions and successor of the last state, to share
some work between these two function.  Add loops on dead
states.
(load_dve2): Pass dead to dve2_kripke and convert_aps.
* iface/dve2/dve2check.cc: Add a -dDEAD option.
* iface/dve2/finite.test, iface/dve2/finite.dve: New file.
* iface/dve2/Makefile.am: Declare them.
2011-03-10 22:37:44 +01:00
Alexandre Duret-Lutz
ef976c93d0 * iface/dve2/dve2.cc (convert_aps): Fix two typos while
parsing >= and >, mistakenly registered as <= and <.
2011-03-10 22:29:56 +01:00
Alexandre Duret-Lutz
6d213e5e4c Remove the Nips interface.
* NEWS: Mention it.
* configure.ac, README: Remove it.
* iface/Makefile.am (SUBDIRS): Remove nips.
* iface/nips/: Delete this directory.
2011-03-07 14:04:25 +01:00
Alexandre Duret-Lutz
8256ae9bfb Accept "P_0 == CS" as synonym for "P_0.CS" in the dve2 interface.
Suggested by Yann Thierry-Mieg.

* iface/dve2/dve2.cc (convert_aps): Allow string on the right
of operators, and look them up.
* iface/dve2/dve2check.test: Test this syntax.
2011-03-07 12:45:37 +01:00
Alexandre Duret-Lutz
5318c1f966 Add some tests for the DVE2 interface.
* iface/dve2/defs.in, iface/dve2/dve2check.test,
iface/dve2/beem-peterson.4.dve: New files.
* iface/dve2/Makefile.am: Add them.
* configure.ac: Generate iface/dve2/defs.
2011-03-07 12:24:32 +01:00
Alexandre Duret-Lutz
0584d278d1 Clear the timer map to help valgrind.
* src/misc/timer.hh (reset_all): New method.
* iface/dve2/dve2check.cc: Use it to help valgrind.
2011-03-07 11:09:53 +01:00
Alexandre Duret-Lutz
e75a73dfb1 Some documentation of about the dve2 interface.
* iface/dve2/README: New file.
* NEWS: Mention it.
* THANKS: Add Michael Weber.
2011-03-07 11:09:53 +01:00
Alexandre Duret-Lutz
76cfd57973 * iface/dve2/dve2.cc, iface/dve2/dve2check.cc: Cosmetic changes
to please sanity checks.
2011-03-07 11:09:53 +01:00
Alexandre Duret-Lutz
51e6989d91 Call divine to compile dve models.
* iface/dve2/dve2.cc (compile_dve2): New function.  Compile
the *.dve source if there is no newer *.dve2C already.
(load_dve2): Call compile_dve2 when given a *.dve file.
* iface/dve2/dve2.hh (load_dve2): Document it.
2011-03-07 11:09:53 +01:00
Alexandre Duret-Lutz
4a62224932 Allow atomic propositions and identifiers like `X.Y'.
* src/ltlparse/ltlscan.ll: Do not recognize `.' as an AND.  Allow
it in atomic propositions.
* src/evtgbaparse/evtgbascan.ll, src/tgbaparse/tgbascan.ll: Accept
`.' in identifiers.
* src/misc/bareword.cc (is_bareword): Accept `.' inside
barewords, so that there is no need to quote `X.Y'.
* src/ltltest/parse.test: Do not use `.' as and operator..
2011-03-07 11:09:53 +01:00
Alexandre Duret-Lutz
8ce39e09b2 Augment dve2check to perform LTL model checking.
* iface/dve2/dve2check.cc: Add many option to perform
emptiness check and other debugging tasks.
2011-03-07 11:09:53 +01:00
Alexandre Duret-Lutz
7b5879d26a Teach the DVE2 interface about enumerated types.
* iface/dve2/dve2.cc (convert_aps): Add support for
enumerated types.  E.g. an atomic proposition such
as "P_0.CS" really means "P_0 == CS".
2011-03-06 19:17:30 +01:00
Alexandre Duret-Lutz
8136bd412d Teach the DVE2 interface about atomic propositions such as "a <=
10" or "b != 3".  This only work for integer variables presently.

* iface/dve2/dve2.hh (load_dve2): Take an atomic_prop_set
argument to indicate the AP to observe.
* iface/dve2/dve2.cc (convert_aps): New function.  Parse the
atomic propositions in format them in a prop_set structure that
will allow fast generation of the state condition.
(load_dve2): Call convert_aps, and pass the resulting prop_set
structure to the kripke object.
(dve2_kripke::dve2_kripke): Store the prop_set structure.
(dve2_kripke::~dve2_kripke): Release the prop_set, and unregister
the bdd_variable associated to it.
(compute_state_condition): New method that uses the prop_set.
(succ_iter, state_condition): Call compute_state_condition().
* iface/dve2/dve2check.cc: Adjust the call to load_dve2 to
pass it atomic propositions read from the command line.
2011-03-06 19:17:30 +01:00
Alexandre Duret-Lutz
5a76a7bb05 Display states variables in the state label.
* iface/dve2/dve2.cc (dve2_kripke::dve2_kripke): Retrieve
the name of all the state variables.
(dve2_kripke::format_state): Use them to format the name
of the state.
2011-03-06 10:51:03 +01:00
Alexandre Duret-Lutz
16b4c28859 We can now explore a divine2 compiled model, but the atomic
properties are still missing.

* iface/dve2/dve2.cc, iface/dve2/dve2.hh: Add
classes for presenting the DiVinE2 model as a kripke object.
(load_dve2): Load the *.dve2C file using libltdl.
* iface/dve2/Makefile.am: Add a dve2check program.
* iface/dve2/dve2check.cc: New file.  Currently it just
outputs the reachability graph using dotty.
2011-03-06 10:51:03 +01:00
Alexandre Duret-Lutz
155d76f4fb Setup libltdl in ltdl/, so we can use it in the dve2 interface.
Don't keep it under version control since it is installed by
autoreconf.

* configure.ac: Call LT_CONFIG_LTDL_DIR and LTDL_INIT.
* README: Mention ltdl/.
* Makefile.am: Recurse into ldtl.
* iface/dve2/Makefile.am: Link with it.
2011-03-05 12:29:04 +01:00
Alexandre Duret-Lutz
3427f3bf0e Setup build system for a new dve2 interface.
* iface/dve2/dve2.cc, iface/dve2/dve2.hh: New dummy files.
* iface/dve2/Makefile.am: New file.
* iface/Makefile.am (SUBDIRS): Add dve2.
* configure.ac: Build iface/dve2/Makefile.
* README: Mention the new directory.
2011-03-05 11:13:37 +01:00
Alexandre Duret-Lutz
e1ef47d975 Using double borders for acceptance states in SBAs.
* src/tgbaalgos/dotty.hh (dotty_reachable): Take a new
assume_sba argument.
* src/tgbaalgos/dotty.cc (dotty_bfs): Take a new
mark_accepting_states arguments.
(dotty_bfs::process_state): Check if a state is accepting using
the state_is_accepting() method for tgba_sba_proxies, or by
looking at the first outgoing transition of the state.  Pass
the result to the dectorator.
(dotty_reachable): Adjust function.
* src/tgbaalgos/dottydec.hh, src/tgbaalgos/dottydec.cc,
src/tgbaalgos/rundotdec.hh, src/tgbaalgos/rundotdec.cc
(state_decl): Add an "accepting" argument, and use it to
decorate accepting states with a double border.
* src/tgbatest/ltl2tgba.cc: Keep track of whether the output
is an SBA or not, so that we can tell it to dotty().
* wrap/python/ajax/spot.in: Likewise.
* wrap/python/cgi-bin/ltl2tgba.in: Likewise.
2011-03-05 10:26:20 +01:00
Alexandre Duret-Lutz
2c5bae3d37 * src/ltltest/genltl.cc (GF_n): Really use "op". 2011-03-05 08:58:40 +01:00
Alexandre Duret-Lutz
0792fb741d * wrap/python/ajax/spot.in: Use the degeneralized automaton if
available while computing the emptiness check.
2011-03-04 21:04:38 +01:00
Alexandre Duret-Lutz
de4166f4c9 Speedup build_result() called by minimize_dfa().
* src/tgbaalgos/minimize.cc (build_result): Speed it up by
removing one useless loop, creating many duplicate transitions
that had to be merged.
2011-03-04 11:50:52 +01:00
Alexandre Duret-Lutz
4b75c9b8e6 * src/ltltest/genltl.cc: Add 10 more LTL formula classes. 2011-03-01 18:15:13 +01:00
Alexandre Duret-Lutz
774e20d8ee * src/tgba/bdddict.hh: Add more documentation. 2011-02-21 22:11:57 +01:00
Alexandre Duret-Lutz
428b21552f * src/misc/escape.hh: Correct documentation. 2011-02-21 21:49:19 +01:00
Alexandre Duret-Lutz
94d1c57ed4 Correct tgba_explicit::compute_support_conditions.
* src/tgba/tgbaexplicit.cc (tgba_explicit::compute_support_conditions):
Fix logic.  This function has always been returning bddtrue instead
of the actual computed value...
2011-02-14 21:09:04 +01:00
Alexandre Duret-Lutz
40e7350c80 Enable VERBOSE logs for nips, greatspn, and python tests.
* wrap/python/tests/run.in, iface/nips/nipstest/defs.in,
iface/gspn/defs.in: Do not disable VERBOSE when running from "make
check".  Since we have started using parallel-check on 2009-08-31,
we should always send verbose output to the log.
2011-02-10 12:58:16 +01:00
Alexandre Duret-Lutz
0385f5b6c7 This should finally fix kv.test and dotty.test on the LIP6 buildfarm.
* src/tgbatest/kv.test, iface/nips/nipstest/dotty.test: Don't rely
on the ${DOT-...} syntax, because DOT is always set and might be
set to the empty value.
2011-02-10 12:34:39 +01:00
Alexandre Duret-Lutz
e6be19cdf7 * HACKING (Running coverage tests): New section. 2011-02-10 08:23:11 +01:00
Alexandre Duret-Lutz
ba564af08f Previous patch did not work on MacOS X, and I don't have shell
access to that host.

* src/tgbatest/kv.test: Use ${DOT-true} instead of ${DOT-:}.  I
don't know, the MacOS shell must be mixing the syntaxes for
${DOT:-} and ${DOT-:}.
* iface/nips/nipstest/dotty.test: Likewise
2011-02-09 22:44:05 +01:00
Alexandre Duret-Lutz
cb7b7d16f3 Avoid running "dot" when it is not installed...
* src/tgbatest/kv.test: Do not run dot if it is not installed.
* iface/nips/nipstest/dotty.test: Likewise
2011-02-09 21:09:54 +01:00
Alexandre Duret-Lutz
dd13bfa07b Add some tricks into HACKING.
* README: Typo.
* HACKING: s/CVS/GIT/ and add some tricks about libtool and doxygen.
2011-02-08 12:23:34 +01:00
Alexandre Duret-Lutz
964c2bed43 Adjust the WDBA test to count for sub-transitions.
* bench/wdba/run: Use -kt to count sub-transitions.
* bench/wdba/README: Adjust comments.
2011-02-08 12:21:36 +01:00
Alexandre Duret-Lutz
baf1288dc6 Fix a spurious g++ warning observed on Darwin builds.
* src/tgba/taatgba.cc (taa_succ_iterator::taa_succ_iterator):
Initialize iterator i to silence a spurious g++ warning on Darwin.
2011-02-08 10:53:06 +01:00
Alexandre Duret-Lutz
9119ffe9bc * configure.ac: s/gnit/gnu so that we can use 0.7.1a as a version. 2011-02-07 18:47:08 +01:00
Alexandre Duret-Lutz
e72f85a327 * NEWS: Typos. 2011-02-07 18:30:21 +01:00
Alexandre Duret-Lutz
6f43b997de * NEWS, configure.ac: Bump version to 0.7.1a 2011-02-07 17:53:56 +01:00
Alexandre Duret-Lutz
51bf0b18e3 Release Spot 0.7.1.
* NEWS: Update for 0.7.1.
* configure.ac: Bump version to 0.7.1.
2011-02-07 17:52:20 +01:00
Alexandre Duret-Lutz
8b06edbc3b Generalize patch from 2011-02-03 by allowing guards like "! (...)".
* src/neverparse/neverclaimscan.ll: Allow space between ! and (.
* src/tgbatest/neverclaimread.test: Add space for testing.
2011-02-07 00:06:18 +01:00
Alexandre Duret-Lutz
0568eaf0ee Speedup scc_filter on tgba_explicit_number automata.
* src/tgbaalgos/sccfilter.cc (scc_filter): If the input automaton
is an instance of tgba_explicit_number, create a similar automaton
for output, instead of a tgba_explicit_string.
2011-02-06 18:57:52 +01:00
Alexandre Duret-Lutz
caaf0a80c2 Document the new operators in the on-line tools.
* wrap/python/ajax/ltl2tgba.html: Mention Goal's ~, -->, and <-->
operators.
* wrap/python/cgi-bin/ltl2tgba.in: Likewise.
2011-02-06 17:36:26 +01:00
Alexandre Duret-Lutz
c019a44c49 Fix a segfault in WDBA minimization.
* src/tgbaalgos/minimize.cc (build_result, minimize_dfa,
minimize_wdba): Correctly handle (i.e. ignore) useless states.
* src/tgbatest/ltl2tgba.test: Add two more tests.
2011-02-06 16:48:52 +01:00