added omp_set_num_threads() and --no-threads option
git-svn-id: svn://anubis/gvsu@334 45c1a28c-8058-47b2-ae61-ca45b979098e
This commit is contained in:
parent
ae61805902
commit
4aa10bec95
@ -8,6 +8,7 @@
|
|||||||
#include <mpi.h>
|
#include <mpi.h>
|
||||||
#include <sys/time.h> /* struct timeval, gettimeofday() */
|
#include <sys/time.h> /* struct timeval, gettimeofday() */
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
#include <omp.h>
|
||||||
#include "Computation.h"
|
#include "Computation.h"
|
||||||
#include "NewtonComputation.h"
|
#include "NewtonComputation.h"
|
||||||
#include "FatouComputation.h"
|
#include "FatouComputation.h"
|
||||||
@ -63,6 +64,10 @@ int main(int argc, char * argv[])
|
|||||||
{
|
{
|
||||||
display_times = true;
|
display_times = true;
|
||||||
}
|
}
|
||||||
|
else if (!strcmp(argv[i], "--no-threads"))
|
||||||
|
{
|
||||||
|
omp_set_num_threads(1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
getSizes(&my_rank, &world_size, &nprocs);
|
getSizes(&my_rank, &world_size, &nprocs);
|
||||||
if (my_rank == 0)
|
if (my_rank == 0)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user