powerset: rewrite the determinization construction using bitvectors

This helps issue #26 considerably, but I'm not closing it because there
are a few places here and there that can be cleaned up.  For instance
build_state_set in minimize.cc should be rewritten.

* src/misc/bitvect.hh (bitvector_array::clear_all): New method.
* src/tgbaalgos/powerset.cc (tgba_powerset): Rewrite it.
* src/tgbaalgos/powerset.hh (power_map): Simplify.
This commit is contained in:
Alexandre Duret-Lutz 2015-01-13 08:54:36 +01:00
parent 0d1c08e6e1
commit f958c51991
3 changed files with 162 additions and 46 deletions

View file

@ -23,8 +23,8 @@
#ifndef SPOT_TGBAALGOS_POWERSET_HH
# define SPOT_TGBAALGOS_POWERSET_HH
# include <list>
# include <map>
# include <set>
# include <vector>
# include "tgba/tgbagraph.hh"
namespace spot
@ -33,15 +33,13 @@ namespace spot
struct SPOT_API power_map
{
typedef std::set<unsigned> power_state;
typedef std::map<unsigned, power_state> power_map_data;
std::vector<power_state> map_;
const power_state&
states_of(unsigned s) const
{
return map_.at(s);
}
power_map_data map_;
};