[Openmp-commits] [openmp] bc8bb3d - Revert "[omp] Fix build without ITT after D103121 changes"
Johannes Doerfert via Openmp-commits
openmp-commits at lists.llvm.org
Tue Jun 29 07:39:09 PDT 2021
Author: Johannes Doerfert
Date: 2021-06-29T09:38:27-05:00
New Revision: bc8bb3df35223afeea62170b32f8ce9bd04255d4
URL: https://github.com/llvm/llvm-project/commit/bc8bb3df35223afeea62170b32f8ce9bd04255d4
DIFF: https://github.com/llvm/llvm-project/commit/bc8bb3df35223afeea62170b32f8ce9bd04255d4.diff
LOG: Revert "[omp] Fix build without ITT after D103121 changes"
This reverts commit eab1fd389b61d236bf8df4d09f62dd18253a10bc.
This commit fixed a problem with 25073a4ecfc9 (D103121) which is the one
we actually need to revert to unblock non-X86 builds of OpenMP. Can be
reapplied, or merged into, D103121 as it goes in again.
Added:
Modified:
openmp/runtime/src/kmp_barrier.cpp
openmp/runtime/src/kmp_wait_release.h
Removed:
################################################################################
diff --git a/openmp/runtime/src/kmp_barrier.cpp b/openmp/runtime/src/kmp_barrier.cpp
index a0a020bf9474..134163e23fa7 100644
--- a/openmp/runtime/src/kmp_barrier.cpp
+++ b/openmp/runtime/src/kmp_barrier.cpp
@@ -225,9 +225,10 @@ void __kmp_dist_barrier_wakeup(enum barrier_type bt, kmp_team_t *team,
}
}
-static void __kmp_dist_barrier_gather(
- enum barrier_type bt, kmp_info_t *this_thr, int gtid, int tid,
- void (*reduce)(void *, void *) USE_ITT_BUILD_ARG(void *itt_sync_obj)) {
+static void
+__kmp_dist_barrier_gather(enum barrier_type bt, kmp_info_t *this_thr, int gtid,
+ int tid, void (*reduce)(void *, void *)
+ USE_ITT_BUILD_ARG(void *itt_sync_obj)) {
KMP_TIME_DEVELOPER_PARTITIONED_BLOCK(KMP_dist_gather);
kmp_team_t *team;
distributedBarrier *b;
@@ -403,7 +404,7 @@ static void __kmp_dist_barrier_release(
if (KMP_COMPARE_AND_STORE_ACQ32(&(this_thr->th.th_used_in_team), 2,
0) ||
this_thr->th.th_used_in_team.load() == 0) {
- my_flag.wait(this_thr, true USE_ITT_BUILD_ARG(itt_sync_obj));
+ my_flag.wait(this_thr, true, itt_sync_obj);
}
#if USE_ITT_BUILD && USE_ITT_NOTIFY
if ((__itt_sync_create_ptr && itt_sync_obj == NULL) || KMP_ITT_DEBUG) {
@@ -453,7 +454,7 @@ static void __kmp_dist_barrier_release(
// Wait on go flag on team
kmp_atomic_flag_64<false, true> my_flag(
&(b->go[my_go_index].go), next_go, &(b->sleep[tid].sleep));
- my_flag.wait(this_thr, true USE_ITT_BUILD_ARG(itt_sync_obj));
+ my_flag.wait(this_thr, true, itt_sync_obj);
KMP_DEBUG_ASSERT(my_current_iter == b->iter[tid].iter ||
b->iter[tid].iter == 0);
KMP_DEBUG_ASSERT(b->sleep[tid].sleep == false);
diff --git a/openmp/runtime/src/kmp_wait_release.h b/openmp/runtime/src/kmp_wait_release.h
index e63a93ce880f..5c250d94886f 100644
--- a/openmp/runtime/src/kmp_wait_release.h
+++ b/openmp/runtime/src/kmp_wait_release.h
@@ -943,8 +943,7 @@ class kmp_flag_oncore : public kmp_flag_native<kmp_uint64, flag_oncore, false> {
}
kmp_flag_oncore(volatile kmp_uint64 *p, kmp_uint32 idx)
: kmp_flag_native<kmp_uint64, flag_oncore, false>(p), offset(idx),
- flag_switch(false),
- bt(bs_last_barrier) USE_ITT_BUILD_ARG(itt_sync_obj(nullptr)) {}
+ flag_switch(false), bt(bs_last_barrier), itt_sync_obj(nullptr) {}
kmp_flag_oncore(volatile kmp_uint64 *p, kmp_uint64 c, kmp_uint32 idx,
enum barrier_type bar_t,
kmp_info_t *thr USE_ITT_BUILD_ARG(void *itt))
More information about the Openmp-commits
mailing list