[Openmp-commits] [openmp] r269259 - Restore NULL flag check in __kmp_null_resume_wrapper
Hal Finkel via Openmp-commits
openmp-commits at lists.llvm.org
Wed May 11 17:54:09 PDT 2016
Author: hfinkel
Date: Wed May 11 19:54:08 2016
New Revision: 269259
URL: http://llvm.org/viewvc/llvm-project?rev=269259&view=rev
Log:
Restore NULL flag check in __kmp_null_resume_wrapper
This reverts a presumaby-unintentional change in:
r268640 - [STATS] Use partitioned timer scheme
and fixes segfaults in an x86_64 debug build of the runtime library.
Modified:
openmp/trunk/runtime/src/kmp_wait_release.h
Modified: openmp/trunk/runtime/src/kmp_wait_release.h
URL: http://llvm.org/viewvc/llvm-project/openmp/trunk/runtime/src/kmp_wait_release.h?rev=269259&r1=269258&r2=269259&view=diff
==============================================================================
--- openmp/trunk/runtime/src/kmp_wait_release.h (original)
+++ openmp/trunk/runtime/src/kmp_wait_release.h Wed May 11 19:54:08 2016
@@ -580,6 +580,8 @@ public:
// Used to wake up threads, volatile void* flag is usually the th_sleep_loc associated
// with int gtid.
static inline void __kmp_null_resume_wrapper(int gtid, volatile void *flag) {
+ if (!flag) return;
+
switch (((kmp_flag_64 *)flag)->get_type()) {
case flag32: __kmp_resume_32(gtid, NULL); break;
case flag64: __kmp_resume_64(gtid, NULL); break;
More information about the Openmp-commits
mailing list