do not use a global variable to define the number of available threads

* python/spot/impl.i: Make parallel_policy implicitly contractible.
* spot/graph/graph.hh (sort_edges_srcfirst_): Pass a parallel_policy
explicitly.
* spot/twa/twagraph.hh, spot/twa/twagraph.cc (merge_states): Likewise.
* spot/misc/common.cc: Remove file.
* spot/misc/common.hh (set_nthreads, get_nthreads): Remove, and
replace with...
(parallel_policy): ... this.
* spot/misc/Makefile.am, tests/python/mergedge.py, NEWS: Adjust.
This commit is contained in:
Alexandre Duret-Lutz 2022-08-12 14:56:45 +02:00
parent 2848951965
commit d1b8495510
9 changed files with 137 additions and 154 deletions

View file

@ -486,6 +486,7 @@ static void handle_any_exception()
}
}
%implicitconv spot::parallel_policy;
%include <spot/misc/common.hh>
%include <spot/misc/version.hh>
%include <spot/misc/minato.hh>