From b096a62100f870bf6a75e45228075f22f66dda83 Mon Sep 17 00:00:00 2001 From: "Alexander \"Arav\" Andreev" Date: Wed, 6 Dec 2023 03:45:36 +0400 Subject: [PATCH] Join omp pragmas in d5p2. --- day5/p2.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/day5/p2.c b/day5/p2.c index c14fa2a..0ec5f35 100644 --- a/day5/p2.c +++ b/day5/p2.c @@ -83,8 +83,7 @@ int main(int argc, char **argv) { uint64_t lowest_loc_n = UINT64_MAX; for (size_t i = 0; i < seed_ranges_len; i += 2) { - #pragma omp shared(lowest_loc_n) - #pragma omp parallel for + #pragma omp parallel for shared(lowest_loc_n) for (uint64_t r = seed_ranges[i]; r < seed_ranges[i] + seed_ranges[i+1]; ++r) { uint64_t seed = r;