mirror of
https://github.com/NGSolve/netgen.git
synced 2024-11-11 16:49:16 +05:00
Fix mesh generation from GUI when building with MPI
This commit is contained in:
parent
12aaaf1e6c
commit
5e6f2ee045
@ -27,17 +27,7 @@ namespace netgen
|
|||||||
static std::thread meshingthread;
|
static std::thread meshingthread;
|
||||||
void RunParallel ( void * (*fun)(void *), void * in)
|
void RunParallel ( void * (*fun)(void *), void * in)
|
||||||
{
|
{
|
||||||
bool parthread = netgen::mparam.parthread;
|
if (netgen::mparam.parthread)
|
||||||
|
|
||||||
#ifdef PARALLEL
|
|
||||||
int provided;
|
|
||||||
netgen::NG_MPI_Query_thread(&provided);
|
|
||||||
if (provided < 3)
|
|
||||||
if (netgen::ntasks > 1) parthread = false;
|
|
||||||
// cout << "runparallel = " << parthread << endl;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (parthread)
|
|
||||||
{
|
{
|
||||||
meshingthread = std::thread(fun, in);
|
meshingthread = std::thread(fun, in);
|
||||||
meshingthread.detach();
|
meshingthread.detach();
|
||||||
|
Loading…
Reference in New Issue
Block a user