dstarparse: get rid of the deticated data structures and conversions

* src/dstarparse/dstarparse.yy: Use the twa_graph_ptr to store the
acceptance condition.
* src/dstarparse/dra2ba.cc, src/dstarparse/dstar2tgba.cc,
src/dstarparse/nra2nba.cc, src/dstarparse/nsa2tgba.cc: Delete
all these conversion routines.
* src/dstarparse/public.hh, src/dstarparse/Makefile.am: Adjust.
* src/bin/dstar2tgba.cc: Adjust to call to_generalized_buchi()
instead.
* src/bin/ltlcross.cc: Adjust to call remove_fin() instead.
* src/bin/ltldo.cc: Use the parsed automaton as-is.
* src/tests/degenid.test, src/tests/dstar.test, src/tests/ikwiad.cc:
Adjust test cases.
This commit is contained in:
Alexandre Duret-Lutz 2015-08-20 19:50:03 +02:00
parent 5f0b6dc36c
commit 9b5340b90a
13 changed files with 75 additions and 874 deletions

View file

@ -37,6 +37,7 @@
#include "twaalgos/hoa.hh"
#include "twaalgos/neverclaim.hh"
#include "twaalgos/stats.hh"
#include "twaalgos/totgba.hh"
#include "twa/bddprint.hh"
#include "misc/optionmap.hh"
#include "misc/timer.hh"
@ -290,7 +291,7 @@ namespace
}
if (has('A'))
daut_acc_ = daut->accpair_count;
daut_acc_ = daut->aut->num_sets() / 2;
if (has('C'))
daut_scc_ = spot::scc_info(daut->aut).scc_count();
@ -355,7 +356,7 @@ namespace
spot::stopwatch sw;
sw.start();
auto nba = spot::dstar_to_tgba(daut);
auto nba = spot::to_generalized_buchi(daut->aut);
auto aut = post.run(nba, 0);
const double conversion_time = sw.stop();

View file

@ -620,14 +620,14 @@ namespace
st->in_states= s.states;
st->in_edges = s.transitions;
st->in_transitions = s.sub_transitions;
st->in_acc = aut->accpair_count;
st->in_acc = aut->aut->num_sets() / 2;
st->in_scc = spot::scc_info(aut->aut).scc_count();
}
// convert it into TGBA for further processing
if (verbose)
std::cerr << "info: converting " << type << " to TGBA\n";
res = dstar_to_tgba(aut);
res = remove_fin(aut->aut);
}
break;
}

View file

@ -40,6 +40,7 @@
#include "misc/timer.hh"
#include "twaalgos/lbtt.hh"
#include "twaalgos/relabel.hh"
#include "twaalgos/totgba.hh"
#include "parseaut/public.hh"
#include "dstarparse/public.hh"
@ -185,7 +186,7 @@ namespace
}
else
{
res = dstar_to_tgba(aut);
res = aut->aut;
}
break;
}