Commit graph

274 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
3e63c1a0ca * src/tgbaalgos/emptinesscheck.hh (explicit_connected_component):
New class.
(counter_example::connected_component_set): Rename as ...
(connected_component_hash_set): ... this, and inherit from
explicit_connected_component.
(counter_example::accepting_path, counter_example::complete_cycle):
2004-04-13 13:25:19 +00:00
Alexandre Duret-Lutz
1ea3c2ce5a * src/tgbaalgos/emptinesscheck.hh
(counter_example::connected_component_set::has_state): Return
a const state* and behave like h_filt.
* src/tgbaalgos/emptinesscheck.cc: Adjust.
2004-04-13 12:16:33 +00:00
Alexandre Duret-Lutz
b85e930232 * src/tgbaalgos/emptinesscheck.hh (emptiness_check::check2): Move
into ...
(emptiness_check_shy): This new subclass of emptiness_check.
* src/tgbaalgos/emptinesscheck.cc, src/tgbatest/ltl2tgba.cc,
iface/gspn/ltlgspn.cc: Adjust.
2004-04-13 11:44:42 +00:00
Alexandre Duret-Lutz
be17fc19f5 * src/tgba/bdddict.hh (bdd_dict::annon_free_list): Hide from Swig. 2004-04-13 09:56:44 +00:00
Alexandre Duret-Lutz
8a84cc6fb3 * src/tgbaalgo/semptinesscheck.hh (counter_example): New class,
extracted from ...
(emptiness_check): ... here.
* src/tgbaalgos/emptinesscheck.cc, src/tgbatest/ltl2tgba.cc,
iface/gspn/ltlgspn.cc: Adjust.
2004-04-13 09:39:30 +00:00
Alexandre Duret-Lutz
5eb2cf2cac * src/tgbaalgo/semptinesscheck.hh (emptiness_check_status): New class,
extracted from ...
(emptiness_check): ... here.
* src/tgbaalgos/emptinesscheck.cc: Adjust.
2004-04-13 08:53:10 +00:00
Alexandre Duret-Lutz
f8321633b7 * src/tgbaalgo/semptinesscheck.hh (scc_stack): New class, extracted
from ...
(emptiness_check): ... here.
(emptiness_check::root): Redefined as a scc_stack object.
* src/tgbaalgos/emptinesscheck.cc: Adjust.
2004-04-13 08:33:24 +00:00
Alexandre Duret-Lutz
7fd9459a63 * src/tgbaalgos/emptinesscheck.cc (emptiness_check::complete_cycle):
Do not visit a state more than once.  Report from Soheib Baarir.
2004-04-05 12:43:06 +00:00
Alexandre Duret-Lutz
fa6ac39cfb * src/tgbaalgos/ltl2tgba_fm.cc (translate_dict): Reuse Acc and Var
variables from a shared bdd_dict.  Register Next variables as
anonymous variables.
(translate_dict::translate_dict, translate_dict::~translate_dict,
translate_dict::register_proposition,
translate_dict::register_a_variable,
translate_dict::register_next_variable,
translate_dict::dump, translate_dict::var_to_formula,
ltl_to_tgba_fm): Adjust.
(translate_dict::dict): New attribute.
(translate_dict::a_map, translate_dict::a_formula_map,
translate_dict::var_map, translate_dict::var_formula_map): Delete.
2004-03-25 16:24:05 +00:00
Alexandre Duret-Lutz
3c3b23bfa4 * src/misc/freelist.cc (free_list::remove): Work around
invalidated iterators.
* tgba/bdddict.cc (unregister_variable): New methods,
extracted from ...
(bdd_dict::unregister_all_my_variables): ... here.
* tgba/bdddict.hh (unregister_variable): Declare them.
2004-03-25 15:02:57 +00:00
Alexandre Duret-Lutz
784ccafb1b * src/misc/freelist.hh (free_list::remove, free_list::insert): New
methods.
* src/misc/freelist.cc (free_list::register_n,
free_list::releases_n): Rewrite using free_list::remove and
free_list::insert.
(free_list::remove, free_list::insert): New methods.
* src/tgba/bdddict.hh (bdd_dict::register_anonymous_variables):
New method.
(bdd_dict::annon_free_list): New subclass.
(bdd_dict::free_annonymous_list_of_type_of): New attribute.
* src/tgba/bdddict.cc (bdd_dict::register_all_variables_of,
bdd_dict::unregister_all_my_variables): Handle anonymous variables
too.
(bdd_dict::register_anonymous_variables,
bdd_dict::annon_free_list::annon_free_list,
bdd_dict::annon_free_list::extend): New methods.
2004-03-23 09:39:38 +00:00
Alexandre Duret-Lutz
aba2dc75d7 * src/tgbaalgos/emptinesscheck.cc (emptiness_check::accepting_path)
Fix handling of PATH when backtracking.  Report from Soheib Baarir.
2004-03-23 09:33:27 +00:00
Alexandre Duret-Lutz
cf6602a3be Move the free_list management into a separate class for reuse.
* src/misc/freelist.hh, src/misc/freelist.cc: New files.
* src/misc/Makefile.am (misc_HEADERS, libmisc_la_SOURCES): Add them.
* src/misc/bddalloc.hh (bdd_allocator): Inherit from free_list and
make dump_free_list visible.
* src/misc/bddalloc.cc (bdd_allocator::allocate_variables): Move
all the code into free_list::register_n() and
bdd_allocator::extend(), and call the former.
(bdd_allocator::release_variables): Move all the code into
free_list::release_n() and call it.
(bdd_allocator::extend): New method.
* src/tgba/bdddict.cc (bdd_dict::dump): Call dump_free_list;
2004-03-18 15:43:10 +00:00
Alexandre Duret-Lutz
249a114f29 * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm) <exprop>: Do not
blindly enumerate all combinations of atomic properties; initially
set all_props to the set of all possibly satisfiable combinations.
2004-03-08 17:24:17 +00:00
Alexandre Duret-Lutz
af27439d87 * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Fix example
in comment.  Skip false transitions, and do not compute
sub-formulae reachable only via false transitions.
2004-02-20 14:18:54 +00:00
Alexandre Duret-Lutz
0f7625b17d * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Revert
yesterday's change.  This optimization is NOT covered by exprop.
In fact it could be generalized.
2004-02-20 09:29:00 +00:00
Alexandre Duret-Lutz
3350ff7176 * src/tgba/tgbatba.cc (tgba_tba_proxy_succ_iterator::current_state):
Fix reference to Oddoux's thesis.
2004-02-19 15:46:30 +00:00
Alexandre Duret-Lutz
4e793ef418 * src/tgbaalgos/ltl2tgba_fm.hh (ltl_to_tgba_fm): Add the
symb_merge argument.
* src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Likewise.
* src/tgbatest/ltl2tgba.cc (main): Rename -fx as -x, and add -y
to unset symb_merge.
* wrap/python/cgi/ltl2tgba.in: Remove the exprop version
of the FM translator, make exprop and symb_merge options.
2004-02-16 16:07:47 +00:00
Alexandre Duret-Lutz
5cb4048120 * src/tgbaalgos/ltl2tgba_fm.cc (ltl_trad_visitor::visit) <unop::G>:
suppress the GFy optimisation introduced on 2003-11-26, it is
generalized by the identification of states with same symbolic
rewriting introduced on 2004-02-02.
2004-02-16 12:25:59 +00:00
Alexandre Duret-Lutz
373be36cae * src/tgbatest/ltl2baw.pl (END): Ensure LTL2TGBA is always
closed.
2004-02-13 14:47:34 +00:00
Alexandre Duret-Lutz
2c10510e87 * src/tgbatest/ltl2tgba.cc (syntax): Recognize "-" as input
filename for the formula.  Merge the transitions of automata
read with -X.
* src/tgbatest/spotlbtt.test: Add many disabled algorithms.
It is convenient to reuse the `config' file created by this
test when making statistics.
* src/tgbatest/ltl2baw.pl: New file.
* src/tgbatest/Makefile.am (EXTRA_DIST): Add ltl2baw.pl.
2004-02-11 15:45:54 +00:00
Alexandre Duret-Lutz
07ba321e0a * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Take an exprop
argument.  Consider all possible combinations of propositions when
generating arcs.  Suggested by Jean-Michel Couvreur.
* src/tgbaalgos/ltl2tgba_fm.hh (ltl_to_tgba_fm): Adjust.
* src/tgbatest/ltl2tgba.cc: Honor -fx.
* src/tgbatest/spotlbtt.test: Exercise -fx.
* wrap/python/cgi/ltl2tgba.in: Support Couvreur/FM with exploded
properties.
2004-02-09 23:23:29 +00:00
Alexandre Duret-Lutz
f2c6db6d49 * src/ltlparse/ltlparse.yy: Typo. 2004-02-09 21:01:34 +00:00
Alexandre Duret-Lutz
7069d5406b This should help getting accurate statistics (on both the
formula automaton and the synchronized product) from LBTT.
Idea from Jean-Michel Couvreur.

* src/tgbaalgos/lbtt.cc (nonacceptant_lbtt_bfs): New class.
(nonacceptant_lbtt_reachable): New function.
* src/tgbaalgos/lbtt.hh (nonacceptant_lbtt_reachable): New
function.
* src/tgbatest/ltl2tgba.cc (main): Call nonacceptant_lbtt_reachable
if the -T option is used.
* src/tgbatest/spotlbtt.test: Setup the -T variants, disabled by
default.
2004-02-07 23:49:28 +00:00
Alexandre Duret-Lutz
0816a4505f * src/tgbaalgos/lbtt.hh: Typos. 2004-02-05 18:44:09 +00:00
Alexandre Duret-Lutz
b253881336 * src/tgbatest/spotlbtt.test: Typo. 2004-02-05 13:08:57 +00:00
Alexandre Duret-Lutz
c46204dfad * src/misc/bddalloc.hh: Make all methods public.
* wrap/python/spot.i: Include misc/bddalloc.hh and misc/minato.hh.
* wrap/python/tests/minato.py: New file.
* wrap/python/tests/Makefile.am (TESTS): Add minato.py.
2004-02-02 21:39:25 +00:00
Alexandre Duret-Lutz
e0b15c6f67 * src/tgbatest/explicit.cc, src/tgbatest/explprod.cc,
src/tgbatest/ltl2tgba.cc, src/tgbatest/ltlprod.cc,
src/tgbatest/mixprod.cc, src/tgbatest/powerset.cc,
src/tgbatest/readsave.cc, src/tgbatest/tgbaread.cc,
src/tgbatest/tripprod.cc: Add missing copyright license.
2004-02-02 20:40:32 +00:00
Alexandre Duret-Lutz
834ce05235 * src/tgbalagos/stats.hh, src/tgbalagos/stats.cc: New files.
* src/tgbalagos/Makefile.am: Add them.
* wrap/python/spot.i: Include src/tgbalagos/dupexp.hh and
src/tgbalagos/stats.hh
2004-02-02 17:32:01 +00:00
Alexandre Duret-Lutz
d13c9c179b * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Identify states
with identical successors.  This optimizes the translation
of `a R (b R c)', for instance.
* src/tgbatest/ltl2tgba.test: Add two new tests.
2004-02-02 16:26:15 +00:00
Alexandre Duret-Lutz
872f7efbeb * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Identify states
with identical successors.  This optimizes the translation
of `a R (b R c)', for instance.
* src/tgbatest/ltl2tgba.test: Add two new tests.
2004-02-02 16:12:13 +00:00
Alexandre Duret-Lutz
0dd81f7d16 * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Identify states
with identical successors.  This optimizes the translation
of `a R (b R c)', for instance.
* src/tgbatest/ltl2tgba.test: Add two new tests.
2004-02-02 16:12:13 +00:00
Alexandre Duret-Lutz
2f7d46d719 * src/ltlvisit/tostring.cc: Fix output of F0, F1, G0, G1, X0, and X1.
* src/ltltest/tostring.test: Test these.
2004-01-30 16:55:12 +00:00
Alexandre Duret-Lutz
1d72cdc86e * src/tgba/tgbaexplicit.cc (tgba_explicit::get_acceptance_condition):
Do not treat true and false specially.  Otherwise it breaks
translation of F(false).
* src/tgbatest/explprod.test, src/tgbatest/tripprod.test: Do not
use true as acceptance condition.

* src/tgbaalgos/ltl2tgba_fm.cc (ltl_trad_visitor): Use Acc[b] as
acceptance condition for Fb, not Acc[Fb].

After this change, degeneralized automata are 40% smaller
2004-01-29 17:05:19 +00:00
Alexandre Duret-Lutz
440029c1b5 After this changes, degeneralized automata are 40% smaller
in LBTT's statistics.

* src/tgba/tgbatba.cc (state_tba_proxy): Store an iterator,
pointing somewhere into the acceptance conditions list, instead of
an acceptance condition.
(state_tba_proxy::acceptance_iterator): New method.
(tgba_tba_proxy_succ_iterator): Adjust to use iterators too.
(tgba_tba_proxy_succ_iterator::current_state): If the current
transition is in several consecutive acceptance steps after the
expected one, advance many steps at once.
(tgba_tba_proxy::tgba_tba_proxy): Build the acceptance cycle
as a list, not a map.
(tgba_tba_proxy::get_init_state, tgba_tba_proxy::succ_iter):
Adjust.
* src/tgba/tgbatba.hh (tgba_tba_proxy::acc_cycle_): Declare as
a list, not a map.
2004-01-29 13:02:55 +00:00
Alexandre Duret-Lutz
bdbaa8356c * src/tgbaalgos/magic.cc (magic_search::~magic_search): Release
all iterators on the stack.
(magic_search::check): Release iterators that are popped off the
stack.
2004-01-26 12:46:39 +00:00
Alexandre Duret-Lutz
57ddf52df0 * src/tgbatest/explpro2.test: Fix reordering regex. 2004-01-26 10:16:18 +00:00
Alexandre Duret-Lutz
468a32ea6e * src/tgbatest/defs.in (run): Use libtool --mode=execute. 2004-01-26 08:37:58 +00:00
Alexandre Duret-Lutz
e434ccbec0 * src/tgbaalgos/ltl2tgba_fm.cc (ltl_to_tgba_fm): Merge transitions
with same destination and acceptance conditions directly, without
calling a->merge_transition().  If one transitions goes to "True",
subtract its conditions from all other transitions; this optimizes
a U b.
2004-01-23 17:36:04 +00:00
Alexandre Duret-Lutz
314768bf28 * src/ltlast/refformula.hh (ref_formula::ref_count_): New method.
* src/ltlast/refformula.cc (ref_formula::ref_count_): New method.
* src/ltlast/atomic_prop.hh (atomic_prop::dump_instance): New method.
* src/ltlast/atomic_prop.cc (atomic_prop::dump_instance): New method.
2004-01-23 17:08:45 +00:00
Alexandre Duret-Lutz
e73ce85cfc * src/tgbaalgos/ltl2tgba_fm.cc: Typos in comments. 2004-01-23 13:01:43 +00:00
Alexandre Duret-Lutz
90d139db24 * src/tgbaalgos/emptinesscheck.hh (emptiness_check::check,
emptiness_check::check2): Document them.
2004-01-13 16:45:55 +00:00
Alexandre Duret-Lutz
93f1cc0d47 * src/tgbaalgos/emptinesscheck.cc (emptiness_check::check2):
New function, variant of emptiness_check::check().
* src/tgbaalgos/emptinesscheck.hh (emptiness_check::check2):
Likewise.
* src/tgbatest/emptchk.test, src/tgbatest/emptchke.test: Exercize -e2.
* src/tgbatest/ltl2tgba.cc: Support -e2, for emptiness_check::check2().
* iface/gspn/Makefile.am [WITH_GSPN_EESRG] (check_PROGRAMS):
Compile ltlgspn-eesrg instead of ltleesrg.
(ltleesrg_SOURCES, ltleesrg_LDADD): Replace by...
(ltlgspn_eesrg_SOURCES, ltlgspn_eesrg_LDADD, LIBGSPNESRG_LDFLAGS):
... these.
* iface/gspn/ltleesrg.cc: Delete.
* iface/gspn/ltlgspn.cc [EESRG]: Support EESRG conditionally.
Support -e2.
2004-01-09 17:22:09 +00:00
Alexandre Duret-Lutz
a1f990b125 * src/tgbaalgos/ltl2tgba_lacim.cc: Typo in comment. 2004-01-09 16:19:12 +00:00
Alexandre Duret-Lutz
036cfd30f8 * src/tgbaalgos/emptinesscheck.cc (emptiness_check::check): Typos
in comment.
2004-01-09 13:34:14 +00:00
Alexandre Duret-Lutz
f01267f36f * src/tgbaalgos/emptinesscheck.cc (emptiness_check::check): Typos
in comment.
2004-01-09 13:34:14 +00:00
Alexandre Duret-Lutz
7a54e04800 * src/tgbaalgos/emptinesscheck.cc (emptiness_check::print_stats):
New function.
* src/tgbaalgos/emptinesscheck.hh (emptiness_check::print_stats):
Likewise.
* iface/gspn/ltlgspn.cc (main) <Couvreur>: Call print_stats().
* iface/gspn/ltleesrg.cc (main): Likewise.
2004-01-09 10:56:56 +00:00
Alexandre Duret-Lutz
92cc5f9b9f Run valgrind in test cases.
* src/tgbatest/defs.in (VALGRIND, run): Define.
* src/tgbatest/bddprod.test, src/tgbatest/dupexp.test,
src/tgbatest/emptchk.test, src/tgbatest/emptchke.test,
src/tgbatest/explicit.test, src/tgbatest/explpro2.test,
src/tgbatest/explpro3.test, src/tgbatest/explprod.test,
src/tgbatest/ltl2tgba.test, src/tgbatest/ltlprod.test,
src/tgbatest/mixprod.test, src/tgbatest/readsave.test,
src/tgbatest/tgbaread.test, src/tgbatest/tripprod.test: Use run().
2004-01-08 15:44:27 +00:00
Alexandre Duret-Lutz
9297d6dd9f * iface/gspn/eesrg.cc (format_state): Do not rewrite n's,
just strip the last one.  Escaping must be done at output.
* iface/gspn/gspm.cc (format_state): Likewise.
* src/misc/escape.hh, src/misc/escape.cc: New files.
* src/misc/Makefile.am: Add them.
* src/tgba/bddprint.cc (bdd_format_accset): New function.
* src/tgba/bddprint.hh (bdd_format_accset): New function.
* src/tgbaalgos/dotty.cc (dotty_bfs::process_state):
Escape the state name using escape_str().
(dotty_bfs::process_link): Escape conditions and acceptance
conditions using escape_str().
* src/tgbaalgos/save.cc (save_bfs::start): Call print_acc().
(save_bfs::print_acc): New function extracted from save_bfs::start().
Escape each acceptance condition.
(save_bfs::process_state): Use escape_str() and print_acc()
2004-01-06 16:56:07 +00:00
Alexandre Duret-Lutz
8008deeddd * src/ltlvisit/tostring.cc
(to_string_visitor::visit(const atomic_prop*)): Quote propositions
that start with F, G, or X.
* src/ltltest/tostring.test: Test quoted propositions.
* src/tgbaalgos/save.cc (save_bfs::process_state): Escape " and +	characters in formulae.
* src/tgbatest/readsave.test: Test for this.
2004-01-06 15:45:00 +00:00