[Openmp-commits] [PATCH] D83171: [OpenMP][OMPT] Fix ifdefs for OMPT code

Joachim Protze via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Sun Jul 5 13:52:23 PDT 2020


This revision was automatically updated to reflect the committed changes.
Closed by commit rG30205865d96a: [OpenMP][OMPT] Fix ifdefs for OMPT code (authored by protze.joachim).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D83171/new/

https://reviews.llvm.org/D83171

Files:
  openmp/runtime/src/kmp_taskdeps.cpp


Index: openmp/runtime/src/kmp_taskdeps.cpp
===================================================================
--- openmp/runtime/src/kmp_taskdeps.cpp
+++ openmp/runtime/src/kmp_taskdeps.cpp
@@ -638,9 +638,9 @@
   return ret;
 }
 
+#if OMPT_SUPPORT
 void __ompt_taskwait_dep_finish(kmp_taskdata_t *current_task,
                                 ompt_data_t *taskwait_task_data) {
-#if OMPT_SUPPORT
   if (ompt_enabled.ompt_callback_task_schedule) {
     ompt_data_t task_data = ompt_data_none;
     ompt_callbacks.ompt_callback(ompt_callback_task_schedule)(
@@ -652,8 +652,8 @@
   }
   current_task->ompt_task_info.frame.enter_frame.ptr = NULL;
   *taskwait_task_data = ompt_data_none;
-#endif /* OMPT_SUPPORT */
 }
+#endif /* OMPT_SUPPORT */
 
 /*!
 @ingroup TASKING
@@ -763,7 +763,9 @@
     KA_TRACE(10, ("__kmpc_omp_wait_deps(exit): T#%d has no blocking "
                   "dependencies : loc=%p\n",
                   gtid, loc_ref));
+#if OMPT_SUPPORT
     __ompt_taskwait_dep_finish(current_task, taskwait_task_data);
+#endif /* OMPT_SUPPORT */
     return;
   }
 
@@ -776,7 +778,9 @@
     KA_TRACE(10, ("__kmpc_omp_wait_deps(exit): T#%d has no blocking "
                   "dependencies : loc=%p\n",
                   gtid, loc_ref));
+#if OMPT_SUPPORT
     __ompt_taskwait_dep_finish(current_task, taskwait_task_data);
+#endif /* OMPT_SUPPORT */
     return;
   }
 
@@ -788,7 +792,9 @@
                        __kmp_task_stealing_constraint);
   }
 
+#if OMPT_SUPPORT
   __ompt_taskwait_dep_finish(current_task, taskwait_task_data);
+#endif /* OMPT_SUPPORT */
   KA_TRACE(10, ("__kmpc_omp_wait_deps(exit): T#%d finished waiting : loc=%p\n",
                 gtid, loc_ref));
 }


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D83171.275570.patch
Type: text/x-patch
Size: 1690 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20200705/831ec95a/attachment-0001.bin>


More information about the Openmp-commits mailing list