Skip to content

Commit

Permalink
add a macro to disable thread_multiple check
Browse files Browse the repository at this point in the history
  • Loading branch information
Exa-Graph committed Mar 25, 2021
1 parent f0c140c commit 9364fdc
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,9 @@ static void parseCommandLine(const int argc, char * const argv[]);
int main(int argc, char *argv[])
{
double t0, t1, t2, t3, ti = 0.0;
#ifdef DISABLE_THREAD_MULTIPLE_CHECK
MPI_Init(&argc, &argv);
#else
int max_threads;

max_threads = omp_get_max_threads();
Expand All @@ -89,7 +92,8 @@ int main(int argc, char *argv[])
} else {
MPI_Init(&argc, &argv);
}

#endif

MPI_Comm_size(MPI_COMM_WORLD, &nprocs);
MPI_Comm_rank(MPI_COMM_WORLD, &me);

Expand Down

0 comments on commit 9364fdc

Please sign in to comment.