Keep track of the number of inclusions detected in ssp_semi
This commit is contained in:
parent
35bf9b5345
commit
40c4476ce4
2 changed files with 39 additions and 7 deletions
|
|
@ -1,3 +1,8 @@
|
||||||
|
2008-08-18 Alexandre Duret-Lutz <adl@lrde.epita.fr>
|
||||||
|
|
||||||
|
* iface/gspn/ssp.cc (numbered_state_heap_ssp_semi): Keep track
|
||||||
|
of the number of inclusions detected.
|
||||||
|
|
||||||
2008-08-07 Alexandre Duret-Lutz <adl@lrde.epita.fr>
|
2008-08-07 Alexandre Duret-Lutz <adl@lrde.epita.fr>
|
||||||
|
|
||||||
* bench/gspn-ssp/Makefile.am, bench/gspn-ssp/trans2prop.pl: New files.
|
* bench/gspn-ssp/Makefile.am, bench/gspn-ssp/trans2prop.pl: New files.
|
||||||
|
|
|
||||||
|
|
@ -657,6 +657,11 @@ namespace spot
|
||||||
class numbered_state_heap_ssp_semi : public numbered_state_heap
|
class numbered_state_heap_ssp_semi : public numbered_state_heap
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
numbered_state_heap_ssp_semi()
|
||||||
|
: numbered_state_heap(), inclusions(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
virtual
|
virtual
|
||||||
~numbered_state_heap_ssp_semi()
|
~numbered_state_heap_ssp_semi()
|
||||||
{
|
{
|
||||||
|
|
@ -700,8 +705,11 @@ namespace spot
|
||||||
if (old_state->left()
|
if (old_state->left()
|
||||||
&& new_state->left()
|
&& new_state->left()
|
||||||
&& spot_inclusion(new_state->left(), old_state->left()))
|
&& spot_inclusion(new_state->left(), old_state->left()))
|
||||||
|
{
|
||||||
|
++inclusions;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (j != l.end())
|
if (j != l.end())
|
||||||
{
|
{
|
||||||
if (s != *j)
|
if (s != *j)
|
||||||
|
|
@ -772,8 +780,11 @@ namespace spot
|
||||||
if (old_state->left()
|
if (old_state->left()
|
||||||
&& new_state->left()
|
&& new_state->left()
|
||||||
&& spot_inclusion(new_state->left(), old_state->left()))
|
&& spot_inclusion(new_state->left(), old_state->left()))
|
||||||
|
{
|
||||||
|
++inclusions;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (j != l.end())
|
if (j != l.end())
|
||||||
{
|
{
|
||||||
if (s != *j)
|
if (s != *j)
|
||||||
|
|
@ -897,6 +908,8 @@ namespace spot
|
||||||
friend class numbered_state_heap_ssp_const_iterator;
|
friend class numbered_state_heap_ssp_const_iterator;
|
||||||
friend class couvreur99_check_shy_ssp;
|
friend class couvreur99_check_shy_ssp;
|
||||||
friend class couvreur99_check_shy_semi_ssp;
|
friend class couvreur99_check_shy_semi_ssp;
|
||||||
|
|
||||||
|
mutable unsigned inclusions;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -1250,27 +1263,41 @@ namespace spot
|
||||||
: couvreur99_check_shy(a,
|
: couvreur99_check_shy(a,
|
||||||
option_map(),
|
option_map(),
|
||||||
numbered_state_heap_ssp_factory_semi::instance()),
|
numbered_state_heap_ssp_factory_semi::instance()),
|
||||||
inclusion_count(0)
|
find_count(0)
|
||||||
{
|
{
|
||||||
onepass_ = true;
|
onepass_ = true;
|
||||||
|
|
||||||
stats["find_state count"] =
|
stats["find_state count"] =
|
||||||
static_cast<spot::unsigned_statistics::unsigned_fun>
|
static_cast<spot::unsigned_statistics::unsigned_fun>
|
||||||
(&couvreur99_check_shy_semi_ssp::get_inclusion_count);
|
(&couvreur99_check_shy_semi_ssp::get_find_count);
|
||||||
stats["contained map size"] =
|
stats["contained map size"] =
|
||||||
static_cast<spot::unsigned_statistics::unsigned_fun>
|
static_cast<spot::unsigned_statistics::unsigned_fun>
|
||||||
(&couvreur99_check_shy_semi_ssp::get_contained_map_size);
|
(&couvreur99_check_shy_semi_ssp::get_contained_map_size);
|
||||||
|
stats["inclusion count"] =
|
||||||
|
static_cast<spot::unsigned_statistics::unsigned_fun>
|
||||||
|
(&couvreur99_check_shy_semi_ssp::get_inclusion_count);
|
||||||
|
|
||||||
|
//dynamic_cast<numbered_state_heap_ssp_semi*>(ecs_->h)->stats = this;
|
||||||
}
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
unsigned inclusion_count;
|
unsigned find_count;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
unsigned
|
||||||
|
get_find_count() const
|
||||||
|
{
|
||||||
|
return find_count;
|
||||||
|
};
|
||||||
|
|
||||||
unsigned
|
unsigned
|
||||||
get_inclusion_count() const
|
get_inclusion_count() const
|
||||||
{
|
{
|
||||||
return inclusion_count;
|
return
|
||||||
|
dynamic_cast<numbered_state_heap_ssp_semi*>(ecs_->h)->inclusions;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
unsigned
|
unsigned
|
||||||
get_contained_map_size() const
|
get_contained_map_size() const
|
||||||
{
|
{
|
||||||
|
|
@ -1281,7 +1308,7 @@ namespace spot
|
||||||
virtual numbered_state_heap::state_index_p
|
virtual numbered_state_heap::state_index_p
|
||||||
find_state(const state* s)
|
find_state(const state* s)
|
||||||
{
|
{
|
||||||
++inclusion_count;
|
++find_count;
|
||||||
return couvreur99_check_shy::find_state(s);
|
return couvreur99_check_shy::find_state(s);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue