MySQL 5.6.14 Source Code Document
|
#include "mysql/psi/psi.h"
Go to the source code of this file.
Classes | |
struct | st_mysql_mutex |
struct | st_mysql_rwlock |
struct | st_mysql_prlock |
struct | st_mysql_cond |
Macros | |
#define | mysql_mutex_assert_owner(M) safe_mutex_assert_owner(&(M)->m_mutex) |
#define | mysql_mutex_assert_not_owner(M) safe_mutex_assert_not_owner(&(M)->m_mutex) |
#define | mysql_prlock_assert_write_owner(M) rw_pr_lock_assert_write_owner(&(M)->m_prlock) |
#define | mysql_prlock_assert_not_write_owner(M) rw_pr_lock_assert_not_write_owner(&(M)->m_prlock) |
#define | mysql_mutex_register(P1, P2, P3) inline_mysql_mutex_register(P1, P2, P3) |
#define | mysql_mutex_init(K, M, A) inline_mysql_mutex_init(M, A) |
#define | mysql_mutex_destroy(M) inline_mysql_mutex_destroy(M) |
#define | mysql_mutex_lock(M) inline_mysql_mutex_lock(M) |
#define | mysql_mutex_trylock(M) inline_mysql_mutex_trylock(M) |
#define | mysql_mutex_unlock(M) inline_mysql_mutex_unlock(M) |
#define | mysql_rwlock_register(P1, P2, P3) inline_mysql_rwlock_register(P1, P2, P3) |
#define | mysql_rwlock_init(K, RW) inline_mysql_rwlock_init(RW) |
#define | mysql_prlock_init(K, RW) inline_mysql_prlock_init(RW) |
#define | mysql_rwlock_destroy(RW) inline_mysql_rwlock_destroy(RW) |
#define | mysql_prlock_destroy(RW) inline_mysql_prlock_destroy(RW) |
#define | mysql_rwlock_rdlock(RW) inline_mysql_rwlock_rdlock(RW) |
#define | mysql_prlock_rdlock(RW) inline_mysql_prlock_rdlock(RW) |
#define | mysql_rwlock_wrlock(RW) inline_mysql_rwlock_wrlock(RW) |
#define | mysql_prlock_wrlock(RW) inline_mysql_prlock_wrlock(RW) |
#define | mysql_rwlock_tryrdlock(RW) inline_mysql_rwlock_tryrdlock(RW) |
#define | mysql_rwlock_trywrlock(RW) inline_mysql_rwlock_trywrlock(RW) |
#define | mysql_rwlock_unlock(RW) inline_mysql_rwlock_unlock(RW) |
#define | mysql_prlock_unlock(RW) inline_mysql_prlock_unlock(RW) |
#define | mysql_cond_register(P1, P2, P3) inline_mysql_cond_register(P1, P2, P3) |
#define | mysql_cond_init(K, C, A) inline_mysql_cond_init(C, A) |
#define | mysql_cond_destroy(C) inline_mysql_cond_destroy(C) |
#define | mysql_cond_wait(C, M) inline_mysql_cond_wait(C, M) |
#define | mysql_cond_timedwait(C, M, W) inline_mysql_cond_timedwait(C, M, W) |
#define | mysql_cond_signal(C) inline_mysql_cond_signal(C) |
#define | mysql_cond_broadcast(C) inline_mysql_cond_broadcast(C) |
#define | mysql_thread_register(P1, P2, P3) inline_mysql_thread_register(P1, P2, P3) |
#define | mysql_thread_create(K, P1, P2, P3, P4) pthread_create(P1, P2, P3, P4) |
#define | mysql_thread_set_psi_id(I) do {} while (0) |
Typedefs | |
typedef struct st_mysql_mutex | mysql_mutex_t |
typedef struct st_mysql_rwlock | mysql_rwlock_t |
typedef struct st_mysql_prlock | mysql_prlock_t |
typedef struct st_mysql_cond | mysql_cond_t |
Instrumentation helpers for mysys threads, mutexes, read write locks and conditions. This header file provides the necessary declarations to use the mysys thread API with the performance schema instrumentation. In some compilers (SunStudio), 'static inline' functions, when declared but not used, are not optimized away (because they are unused) by default, so that including a static inline function from a header file does create unwanted dependencies, causing unresolved symbols at link time. Other compilers, like gcc, optimize these dependencies by default.
Since the instrumented APIs declared here are wrapper on top of my_pthread / safemutex / etc APIs, including mysql/psi/mysql_thread.h assumes that the dependency on my_pthread and safemutex already exists.
Definition in file mysql_thread.h.