diff --git a/algo/detectors/tof/Hitfind.cxx b/algo/detectors/tof/Hitfind.cxx index be317d82f942a551dcd930f3d19f6642da8a5e3e..824630044e607f9fa4ecbe68737c6f2b61749b17 100644 --- a/algo/detectors/tof/Hitfind.cxx +++ b/algo/detectors/tof/Hitfind.cxx @@ -109,12 +109,13 @@ namespace cbm::algo::tof xpu::push_timer("TofHitfind"); xpu::t_add_bytes(digiIn.size_bytes()); -#pragma omp parallel + + CBM_PARALLEL() { const int ithread = openmp::GetThreadNum(); const int nthreads = openmp::GetNumThreads(); -#pragma omp single + CBM_OMP(single) { cluPrefix.resize(nthreads + 1); sizePrefix.resize(nthreads + 1); @@ -124,7 +125,7 @@ namespace cbm::algo::tof auto [clusters, sizes, addresses, indices] = Clusterizer::resultType(); -#pragma omp for schedule(dynamic) nowait + CBM_OMP(for schedule(dynamic) nowait) for (uint32_t iRpc = 0; iRpc < fAlgo.size(); iRpc++) { // Get digis @@ -154,9 +155,9 @@ namespace cbm::algo::tof sizePrefix[ithread + 1] = sizes.size(); addrPrefix[ithread + 1] = addresses.size(); indPrefix[ithread + 1] = indices.size(); -#pragma omp barrier + CBM_OMP(barrier) -#pragma omp single + CBM_OMP(single) { for (int i = 1; i < (nthreads + 1); i++) { cluPrefix[i] += cluPrefix[i - 1];