diff --git a/OpenMP/linear-algebra/kernels/atax/atax.c b/OpenMP/linear-algebra/kernels/atax/atax.c index 8894087..885bc9f 100644 --- a/OpenMP/linear-algebra/kernels/atax/atax.c +++ b/OpenMP/linear-algebra/kernels/atax/atax.c @@ -31,7 +31,7 @@ static void init_array(int nx, int ny, } /// Initialize the `A` matrix with [something?] - // Using 4 threads here slows everything down: why? + #pragma omp parallel for num_threads(THREAD_COUNT) schedule(static) for (i = 0; i < nx; i++) for (j = 0; j < ny; j++) A[i][j] = ((DATA_TYPE)i * (j + 1)) / nx;