summaryrefslogtreecommitdiff
path: root/include/mysql/psi/mysql_table.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/mysql/psi/mysql_table.h')
-rw-r--r--include/mysql/psi/mysql_table.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/mysql/psi/mysql_table.h b/include/mysql/psi/mysql_table.h
index 5b4b64a8e48..e420f9a099e 100644
--- a/include/mysql/psi/mysql_table.h
+++ b/include/mysql/psi/mysql_table.h
@@ -87,7 +87,7 @@
#ifdef HAVE_PSI_TABLE_INTERFACE
#define MYSQL_TABLE_IO_WAIT(PSI, OP, INDEX, FLAGS, PAYLOAD) \
{ \
- if (PSI != NULL) \
+ if (psi_likely(PSI != NULL)) \
{ \
PSI_table_locker *locker; \
PSI_table_locker_state state; \
@@ -120,7 +120,7 @@
#ifdef HAVE_PSI_TABLE_INTERFACE
#define MYSQL_TABLE_LOCK_WAIT(PSI, OP, FLAGS, PAYLOAD) \
{ \
- if (PSI != NULL) \
+ if (psi_likely(PSI != NULL)) \
{ \
PSI_table_locker *locker; \
PSI_table_locker_state state; \
@@ -186,7 +186,7 @@ inline_mysql_start_table_lock_wait(PSI_table_locker_state *state,
enum PSI_table_lock_operation op,
ulong flags, const char *src_file, uint src_line)
{
- if (psi != NULL)
+ if (psi_likely(psi != NULL))
{
struct PSI_table_locker *locker;
locker= PSI_TABLE_CALL(start_table_lock_wait)
@@ -203,7 +203,7 @@ inline_mysql_start_table_lock_wait(PSI_table_locker_state *state,
static inline void
inline_mysql_end_table_lock_wait(struct PSI_table_locker *locker)
{
- if (locker != NULL)
+ if (psi_likely(locker != NULL))
PSI_TABLE_CALL(end_table_lock_wait)(locker);
}
#endif