Clean the as_bdd() cache after LTL simplification.

Syntactic implication checks may use as_bdd() to compare Boolean
formulae.  By doing so, they register Boolean variables in an order
that is usially detrimental to the LTL translator.  The new,
clear_as_bdd_cache() function offers a mean to unregister these
variables, so that the LTL translator will register them again in the
a more natural way.

* src/ltlvisit/simplify.hh, src/ltlvisit/simplify.cc
(clear_as_bdd_cache): New function.
* src/tgbatest/ltl2tgba.cc, wrap/python/ajax/spot.in: Call it.
This commit is contained in:
Alexandre Duret-Lutz 2012-05-19 22:51:18 +02:00
parent 9633dd6e88
commit e5a86290cf
4 changed files with 32 additions and 0 deletions

View file

@ -131,6 +131,15 @@ namespace spot
/// to the constructor.
bdd as_bdd(const formula* f);
/// \brief Clear the as_bdd() cache.
///
/// Calling this function is recommended before running other
/// algorithms that create BDD variables in a more natural
/// order. For instance ltl_to_tgba_fm() will usually be more
/// efficient if the BDD variables for atomic propositions have
/// not been ordered before hand.
void clear_as_bdd_cache();
/// Return the bdd_dict used.
bdd_dict* get_dict() const;