|
@@ -101,9 +101,15 @@ typedef pthread_mutexattr_t starpu_pthread_mutexattr_t;
|
|
|
#define starpu_pthread_mutexattr_destroy pthread_mutexattr_destroy
|
|
|
#define starpu_pthread_mutexattr_init pthread_mutexattr_init
|
|
|
|
|
|
+#ifdef STARPU_FXT_LOCK_TRACES
|
|
|
int starpu_pthread_mutex_lock(starpu_pthread_mutex_t *mutex);
|
|
|
int starpu_pthread_mutex_unlock(starpu_pthread_mutex_t *mutex);
|
|
|
int starpu_pthread_mutex_trylock(starpu_pthread_mutex_t *mutex);
|
|
|
+#else
|
|
|
+#define starpu_pthread_mutex_lock pthread_mutex_lock
|
|
|
+#define starpu_pthread_mutex_unlock pthread_mutex_unlock
|
|
|
+#define starpu_pthread_mutex_trylock pthread_mutex_trylock
|
|
|
+#endif
|
|
|
|
|
|
#define STARPU_PTHREAD_MUTEX_INITIALIZER PTHREAD_MUTEX_INITIALIZER
|
|
|
|
|
@@ -163,7 +169,11 @@ typedef pthread_condattr_t starpu_pthread_condattr_t;
|
|
|
#define starpu_pthread_cond_signal pthread_cond_signal
|
|
|
#define starpu_pthread_cond_broadcast pthread_cond_broadcast
|
|
|
|
|
|
+#ifdef STARPU_FXT_LOCK_TRACES
|
|
|
int starpu_pthread_cond_wait(starpu_pthread_cond_t *cond, starpu_pthread_mutex_t *mutex);
|
|
|
+#else
|
|
|
+#define starpu_pthread_cond_wait pthread_cond_wait
|
|
|
+#endif
|
|
|
|
|
|
#define starpu_pthread_cond_timedwait pthread_cond_timedwait
|
|
|
#define starpu_pthread_cond_destroy pthread_cond_destroy
|
|
@@ -195,11 +205,19 @@ typedef pthread_rwlockattr_t starpu_pthread_rwlockattr_t;
|
|
|
#define starpu_pthread_rwlock_init pthread_rwlock_init
|
|
|
#define starpu_pthread_rwlock_destroy pthread_rwlock_destroy
|
|
|
|
|
|
+#ifdef STARPU_FXT_LOCK_TRACES
|
|
|
int starpu_pthread_rwlock_rdlock(starpu_pthread_rwlock_t *rwlock);
|
|
|
int starpu_pthread_rwlock_tryrdlock(starpu_pthread_rwlock_t *rwlock);
|
|
|
int starpu_pthread_rwlock_wrlock(starpu_pthread_rwlock_t *rwlock);
|
|
|
int starpu_pthread_rwlock_trywrlock(starpu_pthread_rwlock_t *rwlock);
|
|
|
int starpu_pthread_rwlock_unlock(starpu_pthread_rwlock_t *rwlock);
|
|
|
+#else
|
|
|
+#define starpu_pthread_rwlock_rdlock pthread_rwlock_rdlock
|
|
|
+#define starpu_pthread_rwlock_tryrdlock pthread_rwlock_tryrdlock
|
|
|
+#define starpu_pthread_rwlock_wrlock pthread_rwlock_wrlock
|
|
|
+#define starpu_pthread_rwlock_trywrlock pthread_rwlock_trywrlock
|
|
|
+#define starpu_pthread_rwlock_unlock pthread_rwlock_unlock
|
|
|
+#endif
|
|
|
|
|
|
#endif /* STARPU_SIMGRID, _MSC_VER */
|
|
|
|
|
@@ -238,7 +256,11 @@ typedef pthread_barrierattr_t starpu_pthread_barrierattr_t;
|
|
|
#define starpu_pthread_barrier_init pthread_barrier_init
|
|
|
#define starpu_pthread_barrier_destroy pthread_barrier_destroy
|
|
|
|
|
|
+#ifdef STARPU_FXT_LOCK_TRACES
|
|
|
int starpu_pthread_barrier_wait(starpu_pthread_barrier_t *barrier);
|
|
|
+#else
|
|
|
+#define starpu_pthread_barrier_wait pthread_barrier_wait
|
|
|
+#endif
|
|
|
#define STARPU_PTHREAD_BARRIER_SERIAL_THREAD PTHREAD_BARRIER_SERIAL_THREAD
|
|
|
|
|
|
#endif /* STARPU_SIMGRID, !STARPU_HAVE_PTHREAD_BARRIER, _MSC_VER */
|