summaryrefslogtreecommitdiffstats
path: root/openmp/runtime/src/z_Linux_util.c
diff options
context:
space:
mode:
authorJonathan Peyton <jonathan.l.peyton@intel.com>2015-10-08 19:44:16 +0000
committerJonathan Peyton <jonathan.l.peyton@intel.com>2015-10-08 19:44:16 +0000
commit1bd61b423e0c6edc7f36c11a99b828a55be3f5ff (patch)
tree0644fb54bea28ce1f6dea51460572a98c7fba6ba /openmp/runtime/src/z_Linux_util.c
parentaae1ed8e08236a8f99b8fca690db7f954f15c031 (diff)
downloadbcm5719-llvm-1bd61b423e0c6edc7f36c11a99b828a55be3f5ff.tar.gz
bcm5719-llvm-1bd61b423e0c6edc7f36c11a99b828a55be3f5ff.zip
Formatting/Whitespace/Comment changes associated with wait/release improvements.
llvm-svn: 249725
Diffstat (limited to 'openmp/runtime/src/z_Linux_util.c')
-rw-r--r--openmp/runtime/src/z_Linux_util.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/openmp/runtime/src/z_Linux_util.c b/openmp/runtime/src/z_Linux_util.c
index 9815232201f..78cada4c3c0 100644
--- a/openmp/runtime/src/z_Linux_util.c
+++ b/openmp/runtime/src/z_Linux_util.c
@@ -1757,8 +1757,7 @@ static inline void __kmp_suspend_template( int th_gtid, C *flag )
status = pthread_cond_timedwait( &th->th.th_suspend_cv.c_cond, &th->th.th_suspend_mx.m_mutex, & now );
#else
KF_TRACE( 15, ( "__kmp_suspend_template: T#%d about to perform pthread_cond_wait\n",
- th_gtid ) );
-
+ th_gtid ) );
status = pthread_cond_wait( &th->th.th_suspend_cv.c_cond, &th->th.th_suspend_mx.m_mutex );
#endif
@@ -1849,7 +1848,7 @@ static inline void __kmp_resume_template( int target_gtid, C *flag )
KMP_CHECK_SYSFAIL( "pthread_mutex_unlock", status );
return;
}
- else {
+ else { // if multiple threads are sleeping, flag should be internally referring to a specific thread here
typename C::flag_t old_spin = flag->unset_sleeping();
if ( ! flag->is_sleeping_val(old_spin) ) {
KF_TRACE( 5, ( "__kmp_resume_template: T#%d exiting, thread T#%d already awake: flag(%p): "
OpenPOWER on IntegriCloud