List:Commits« Previous MessageNext Message »
From:Marc Alff Date:October 15 2008 8:28pm
Subject:bzr push into mysql-6.0-perf branch (marc.alff:2704 to 2705)
View as plain text  
 2705 Marc Alff	2008-10-15
      Server instrumentation, continued
modified:
  sql/ddl_blocker.h
  sql/debug_sync.cc
  sql/event_queue.h
  sql/event_scheduler.h
  sql/events.h
  sql/hash_filo.h
  sql/hostname.cc
  sql/item_func.cc
  sql/log.h
  sql/mdl.cc
  sql/mysql_priv.h
  sql/mysqld.cc
  sql/rpl_mi.h
  sql/rpl_rli.h
  sql/scheduler.cc
  sql/sp_cache.cc
  sql/sql_audit.cc
  sql/sql_cache.h
  sql/sql_class.cc
  sql/sql_class.h
  sql/sql_insert.cc
  sql/sql_plugin.cc
  sql/sql_table.cc
  sql/table.h
  sql/tztime.cc
  storage/maria/unittest/trnman-t.c

 2704 Marc Alff	2008-10-14
      Instrumentation for maria, continued
modified:
  include/maria.h
  storage/maria/ha_maria.cc
  storage/maria/ma_bitmap.c
  storage/maria/ma_check.c
  storage/maria/ma_checkpoint.c
  storage/maria/ma_init.c
  storage/maria/ma_loghandler.c
  storage/maria/ma_open.c
  storage/maria/ma_pagecache.c
  storage/maria/ma_static.c
  storage/maria/maria_def.h
  storage/maria/tablockman.c
  storage/maria/trnman.c

=== modified file 'sql/ddl_blocker.h'
--- a/sql/ddl_blocker.h	2008-10-10 20:34:55 +0000
+++ b/sql/ddl_blocker.h	2008-10-15 20:25:34 +0000
@@ -121,12 +121,3 @@ class DDL_blocker_class
     static DDL_blocker_class *m_instance;    ///< instance var for singleton 
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_THR_LOCK_DDL_blocker;
-extern PSI_mutex_key key_THR_LOCK_DDL_is_blocked;
-extern PSI_mutex_key key_THR_LOCK_DDL_blocker_blocked;
-extern PSI_cond_key key_COND_DDL_blocker;
-extern PSI_cond_key key_COND_process_blocked;
-extern PSI_cond_key key_COND_DDL_blocker_blocked;
-#endif
-

=== modified file 'sql/debug_sync.cc'
--- a/sql/debug_sync.cc	2008-10-10 20:34:55 +0000
+++ b/sql/debug_sync.cc	2008-10-15 20:25:34 +0000
@@ -240,11 +240,6 @@ struct st_debug_sync_control
   ulonglong             dsp_max_active;         /* statistics */
 };
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_cond_key key_ds_cond;
-PSI_mutex_key key_ds_mutex;
-#endif
-
 /**
   Definitions for the debug sync facility.
   1. Global string variable to hold a "signal" ("signal post", "flag mast").

=== modified file 'sql/event_queue.h'
--- a/sql/event_queue.h	2008-10-10 20:34:55 +0000
+++ b/sql/event_queue.h	2008-10-15 20:25:34 +0000
@@ -35,11 +35,6 @@ class THD;
   Queue of active events awaiting execution.
 */
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOCK_event_queue;
-extern PSI_cond_key key_COND_queue_state;
-#endif
-
 class Event_queue
 {
 public:

=== modified file 'sql/event_scheduler.h'
--- a/sql/event_scheduler.h	2008-10-10 20:34:55 +0000
+++ b/sql/event_scheduler.h	2008-10-15 20:25:34 +0000
@@ -65,10 +65,6 @@ private:
   static Event_db_repository *db_repository;
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOCK_scheduler_state;
-extern PSI_cond_key key_Event_scheduler_COND_state;
-#endif
 
 class Event_scheduler
 {

=== modified file 'sql/events.h'
--- a/sql/events.h	2008-10-10 20:34:55 +0000
+++ b/sql/events.h	2008-10-15 20:25:34 +0000
@@ -67,10 +67,6 @@ sortcmp_lex_string(LEX_STRING s, LEX_STR
   subsystems (ACL, time zone tables, etc).
 */
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOCK_event_metadata;
-#endif
-
 class Events
 {
 public:

=== modified file 'sql/hash_filo.h'
--- a/sql/hash_filo.h	2008-10-10 20:34:55 +0000
+++ b/sql/hash_filo.h	2008-10-15 20:25:34 +0000
@@ -34,9 +34,6 @@ class hash_filo_element
   friend class hash_filo;
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_hash_filo_lock;
-#endif
 
 class hash_filo
 {

=== modified file 'sql/hostname.cc'
--- a/sql/hostname.cc	2008-10-10 20:34:55 +0000
+++ b/sql/hostname.cc	2008-10-15 20:25:34 +0000
@@ -50,10 +50,6 @@ public:
 
 static hash_filo *hostname_cache;
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_hostname;
-#endif
-
 static mysql_mutex_t LOCK_hostname;
 
 void hostname_cache_refresh()

=== modified file 'sql/item_func.cc'
--- a/sql/item_func.cc	2008-10-10 20:34:55 +0000
+++ b/sql/item_func.cc	2008-10-15 20:25:34 +0000
@@ -3261,11 +3261,6 @@ bool udf_handler::get_arguments() { retu
 ** User level locks
 */
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_user_locks;
-PSI_cond_key key_ULL_cond;
-#endif
-
 mysql_mutex_t LOCK_user_locks;
 static HASH hash_user_locks;
 
@@ -3790,10 +3785,6 @@ void Item_func_benchmark::print(String *
   str->append(')');
 }
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_cond_key key_Item_func_sleep_cond;
-#endif
-
 /** This function is just used to create tests with time gaps. */
 
 longlong Item_func_sleep::val_int()

=== modified file 'sql/log.h'
--- a/sql/log.h	2008-10-10 20:34:55 +0000
+++ b/sql/log.h	2008-10-15 20:25:34 +0000
@@ -92,17 +92,6 @@ public:
 };
 
 #ifdef HAVE_MMAP
-
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_PAGE_lock;
-extern PSI_cond_key key_PAGE_cond;
-extern PSI_mutex_key key_LOCK_sync;
-extern PSI_mutex_key key_LOCK_active;
-extern PSI_mutex_key key_LOCK_pool;
-extern PSI_cond_key key_COND_active;
-extern PSI_cond_key key_COND_pool;
-#endif
-
 class TC_LOG_MMAP: public TC_LOG
 {
   public:                // only to keep Sun Forte on sol9x86 happy
@@ -176,12 +165,12 @@ extern TC_LOG_DUMMY tc_log_dummy;
 #define LOG_CLOSE_TO_BE_OPENED	2
 #define LOG_CLOSE_STOP_EVENT	4
 
+class Relay_log_info;
+
 #ifdef HAVE_PSI_INTERFACE
 extern PSI_mutex_key key_LOG_INFO_lock;
 #endif
 
-class Relay_log_info;
-
 typedef struct st_log_info
 {
   char log_file_name[FN_REFLEN];
@@ -221,10 +210,6 @@ enum enum_log_state { LOG_OPENED, LOG_CL
   (mmap+fsync is two times faster than write+fsync)
 */
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOG_LOCK_log;
-#endif
-
 class MYSQL_LOG
 {
 public:
@@ -340,12 +325,6 @@ private:
   mysql_mutex_t LOCK_backupid; ///< mutex for backupid generation
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_BINLOG_LOCK_index;
-extern PSI_mutex_key key_BINLOG_LOCK_prep_xids;
-extern PSI_cond_key key_BINLOG_COND_prep_xids;
-extern PSI_cond_key key_BINLOG_update_cond;
-#endif
 
 class MYSQL_BIN_LOG: public TC_LOG, private MYSQL_LOG
 {
@@ -653,10 +632,6 @@ public:
   { return &mysql_backup_progress_log; }
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOCK_logger;
-#endif
-
 /*
    Class which manages slow, general, error log, backup history, and
    backup progress event handlers.

=== modified file 'sql/mdl.cc'
--- a/sql/mdl.cc	2008-10-10 20:34:55 +0000
+++ b/sql/mdl.cc	2008-10-15 20:25:34 +0000
@@ -15,6 +15,7 @@
 
 
 #include "mdl.h"
+#include "mysql_priv.h"
 
 #include <hash.h>
 #include <mysqld_error.h>
@@ -66,11 +67,6 @@ struct MDL_LOCK
   }
 };
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_mdl;
-PSI_cond_key key_COND_mdl;
-#endif
-
 mysql_mutex_t LOCK_mdl;
 mysql_cond_t  COND_mdl;
 HASH mdl_locks;

=== modified file 'sql/mysql_priv.h'
--- a/sql/mysql_priv.h	2008-10-10 20:34:55 +0000
+++ b/sql/mysql_priv.h	2008-10-15 20:25:34 +0000
@@ -2099,9 +2099,6 @@ extern PSI_mutex_key key_LOCK_prepared_s
 extern PSI_mutex_key key_LOCK_bytes_sent;
 extern PSI_mutex_key key_LOCK_bytes_received;
 extern PSI_mutex_key key_LOCK_connection_count;
-#ifdef HAVE_OPENSSL
-extern PSI_mutex_key key_LOCK_des_key_file;
-#endif
 extern PSI_mutex_key key_LOCK_server_started;
 extern PSI_cond_key key_COND_server_started;
 extern PSI_rwlock_key key_LOCK_grant;
@@ -2116,6 +2113,74 @@ extern PSI_cond_key key_COND_thread_cach
 extern PSI_cond_key key_COND_flush_thread_cache;
 extern PSI_mutex_key key_LOCK_rpl_status;
 extern PSI_cond_key key_COND_rpl_status;
+extern PSI_mutex_key key_LOG_LOCK_log;
+extern PSI_mutex_key key_BINLOG_LOCK_index;
+extern PSI_mutex_key key_BINLOG_LOCK_prep_xids;
+extern PSI_cond_key key_BINLOG_COND_prep_xids;
+extern PSI_cond_key key_BINLOG_update_cond;
+extern PSI_mutex_key key_LOCK_logger;
+extern PSI_mutex_key key_THR_LOCK_DDL_blocker;
+extern PSI_mutex_key key_THR_LOCK_DDL_is_blocked;
+extern PSI_mutex_key key_THR_LOCK_DDL_blocker_blocked;
+extern PSI_cond_key key_COND_DDL_blocker;
+extern PSI_cond_key key_COND_process_blocked;
+extern PSI_cond_key key_COND_DDL_blocker_blocked;
+extern PSI_mutex_key key_LOCK_event_queue;
+extern PSI_cond_key key_COND_queue_state;
+extern PSI_mutex_key key_LOCK_scheduler_state;
+extern PSI_cond_key key_Event_scheduler_COND_state;
+extern PSI_mutex_key key_LOCK_event_metadata;
+extern PSI_mutex_key key_hash_filo_lock;
+extern PSI_mutex_key key_MI_run_lock;
+extern PSI_mutex_key key_MI_data_lock;
+extern PSI_cond_key key_MI_data_cond;
+extern PSI_cond_key key_MI_start_cond;
+extern PSI_cond_key key_MI_stop_cond;
+extern PSI_mutex_key key_RLI_run_lock;
+extern PSI_mutex_key key_RLI_data_lock;
+extern PSI_mutex_key key_RLI_log_space_lock;
+extern PSI_cond_key key_RLI_data_cond;
+extern PSI_cond_key key_RLI_start_cond;
+extern PSI_cond_key key_RLI_stop_cond;
+extern PSI_cond_key key_RLI_log_space_cond;
+extern PSI_rwlock_key key_QCQ_lock;
+extern PSI_mutex_key key_structure_guard_mutex;
+extern PSI_cond_key key_COND_cache_status_changed;
+extern PSI_mutex_key key_LOCK_ha_data;
+extern PSI_mutex_key key_LOCK_delete;
+extern PSI_cond_key key_ds_cond;
+extern PSI_mutex_key key_ds_mutex;
+extern PSI_mutex_key key_LOCK_hostname;
+extern PSI_mutex_key key_LOCK_user_locks;
+extern PSI_cond_key key_ULL_cond;
+extern PSI_cond_key key_Item_func_sleep_cond;
+extern PSI_mutex_key key_LOCK_mdl;
+extern PSI_cond_key key_COND_mdl;
+extern PSI_mutex_key key_LOCK_thd_add;
+extern PSI_mutex_key key_LOCK_event_loop;
+extern PSI_mutex_key key_Cversion_lock;
+extern PSI_mutex_key key_LOCK_audit_mask;
+extern PSI_mutex_key key_LOCK_xid_cache;
+extern PSI_mutex_key key_Delayed_insert_mutex;
+extern PSI_cond_key key_Delayed_insert_cond;
+extern PSI_cond_key key_Delayed_insert_cond_client;
+extern PSI_mutex_key key_LOCK_plugin;
+extern PSI_mutex_key key_LOCK_gdl;
+extern PSI_mutex_key key_tz_LOCK;
+
+#ifdef HAVE_OPENSSL
+extern PSI_mutex_key key_LOCK_des_key_file;
+#endif
+#ifdef HAVE_MMAP
+extern PSI_mutex_key key_PAGE_lock;
+extern PSI_cond_key key_PAGE_cond;
+extern PSI_mutex_key key_LOCK_sync;
+extern PSI_mutex_key key_LOCK_active;
+extern PSI_mutex_key key_LOCK_pool;
+extern PSI_cond_key key_COND_active;
+extern PSI_cond_key key_COND_pool;
+#endif
+void init_psi_server_keys();
 #endif
 
 extern mysql_mutex_t LOCK_mysql_create_db,LOCK_Acl,LOCK_open, LOCK_lock_db,

=== modified file 'sql/mysqld.cc'
--- a/sql/mysqld.cc	2008-10-14 01:55:03 +0000
+++ b/sql/mysqld.cc	2008-10-15 20:25:34 +0000
@@ -4434,10 +4434,6 @@ void decrement_handler_count()
 #define decrement_handler_count()
 #endif /* defined(__NT__) || defined(HAVE_SMEM) */
 
-#ifdef HAVE_PSI_INTERFACE
-static void init_psi_server_keys();
-#endif
-
 #ifndef EMBEDDED_LIBRARY
 #ifdef __WIN__
 int win_main(int argc, char **argv)
@@ -9141,6 +9137,26 @@ PSI_cond_key key_COND_caller_wait;
 PSI_mutex_key key_BRC_run_lock;
 PSI_mutex_key key_NDB_SHARE_mutex;
 
+PSI_cond_key key_ds_cond;
+PSI_mutex_key key_ds_mutex;
+PSI_mutex_key key_LOCK_hostname;
+PSI_mutex_key key_LOCK_user_locks;
+PSI_cond_key key_ULL_cond;
+PSI_cond_key key_Item_func_sleep_cond;
+PSI_mutex_key key_LOCK_mdl;
+PSI_cond_key key_COND_mdl;
+PSI_mutex_key key_LOCK_thd_add;
+PSI_mutex_key key_LOCK_event_loop;
+PSI_mutex_key key_Cversion_lock;
+PSI_mutex_key key_LOCK_audit_mask;
+PSI_mutex_key key_LOCK_xid_cache;
+PSI_mutex_key key_Delayed_insert_mutex;
+PSI_cond_key key_Delayed_insert_cond;
+PSI_cond_key key_Delayed_insert_cond_client;
+PSI_mutex_key key_LOCK_plugin;
+PSI_mutex_key key_LOCK_gdl;
+PSI_mutex_key key_tz_LOCK;
+
 #ifdef HAVE_OPENSSL
 PSI_mutex_key key_LOCK_des_key_file;
 #endif

=== modified file 'sql/rpl_mi.h'
--- a/sql/rpl_mi.h	2008-10-10 20:34:55 +0000
+++ b/sql/rpl_mi.h	2008-10-15 20:25:34 +0000
@@ -55,14 +55,6 @@
 
 *****************************************************************************/
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_MI_run_lock;
-extern PSI_mutex_key key_MI_data_lock;
-extern PSI_cond_key key_MI_data_cond;
-extern PSI_cond_key key_MI_start_cond;
-extern PSI_cond_key key_MI_stop_cond;
-#endif
-
 class Master_info : public Slave_reporting_capability
 {
  public:

=== modified file 'sql/rpl_rli.h'
--- a/sql/rpl_rli.h	2008-10-10 20:34:55 +0000
+++ b/sql/rpl_rli.h	2008-10-15 20:25:34 +0000
@@ -49,16 +49,6 @@ class Master_info;
 
 *****************************************************************************/
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_RLI_run_lock;
-extern PSI_mutex_key key_RLI_data_lock;
-extern PSI_mutex_key key_RLI_log_space_lock;
-extern PSI_cond_key key_RLI_data_cond;
-extern PSI_cond_key key_RLI_start_cond;
-extern PSI_cond_key key_RLI_stop_cond;
-extern PSI_cond_key key_RLI_log_space_cond;
-#endif
-
 class Relay_log_info : public Slave_reporting_capability
 {
 public:

=== modified file 'sql/scheduler.cc'
--- a/sql/scheduler.cc	2008-10-10 20:34:55 +0000
+++ b/sql/scheduler.cc	2008-10-15 20:25:34 +0000
@@ -102,10 +102,6 @@ static bool kill_pool_threads;
 static struct event thd_add_event;
 static struct event thd_kill_event;
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_thd_add;
-#endif
-
 static mysql_mutex_t LOCK_thd_add;    /* protects thds_need_adding */
 static LIST *thds_need_adding;    /* list of thds to add to libevent queue */
 
@@ -116,9 +112,6 @@ static int thd_kill_pipe[2]; /* pipe to 
   LOCK_event_loop protects the non-thread safe libevent calls (event_add and 
   event_del) and thds_need_processing and thds_waiting_for_io.
 */
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_event_loop;
-#endif
 static mysql_mutex_t LOCK_event_loop;
 static LIST *thds_need_processing; /* list of thds that needs some processing */
 static LIST *thds_waiting_for_io; /* list of thds with added events */

=== modified file 'sql/sp_cache.cc'
--- a/sql/sp_cache.cc	2008-10-10 20:34:55 +0000
+++ b/sql/sp_cache.cc	2008-10-15 20:25:34 +0000
@@ -20,9 +20,6 @@
 #include "sp_cache.h"
 #include "sp_head.h"
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_Cversion_lock;
-#endif
 static mysql_mutex_t Cversion_lock;
 static ulong volatile Cversion= 0;
 

=== modified file 'sql/sql_audit.cc'
--- a/sql/sql_audit.cc	2008-10-10 20:34:55 +0000
+++ b/sql/sql_audit.cc	2008-10-15 20:25:34 +0000
@@ -23,9 +23,6 @@ extern int finalize_audit_plugin(st_plug
 
 unsigned long mysql_global_audit_mask[MYSQL_AUDIT_CLASS_MASK_SIZE];
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_audit_mask;
-#endif
 static mysql_mutex_t LOCK_audit_mask;
 
 static void event_class_dispatch(THD *thd, const struct mysql_event *event);

=== modified file 'sql/sql_cache.h'
--- a/sql/sql_cache.h	2008-10-10 20:34:55 +0000
+++ b/sql/sql_cache.h	2008-10-15 20:25:34 +0000
@@ -134,9 +134,6 @@ struct Query_cache_block
   inline Query_cache_block_table *table(TABLE_COUNTER_TYPE n);
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_rwlock_key key_QCQ_lock;
-#endif
 
 struct Query_cache_query
 {
@@ -267,10 +264,6 @@ struct Query_cache_memory_bin_step
   }
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_structure_guard_mutex;
-extern PSI_cond_key key_COND_cache_status_changed;
-#endif
 
 class Query_cache
 {

=== modified file 'sql/sql_class.cc'
--- a/sql/sql_class.cc	2008-10-13 20:42:40 +0000
+++ b/sql/sql_class.cc	2008-10-15 20:25:34 +0000
@@ -3095,9 +3095,6 @@ void mark_transaction_to_rollback(THD *t
   Handling of XA id cacheing
 ***************************************************************************/
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_xid_cache;
-#endif
 mysql_mutex_t LOCK_xid_cache;
 HASH xid_cache;
 

=== modified file 'sql/sql_class.h'
--- a/sql/sql_class.h	2008-10-13 20:42:40 +0000
+++ b/sql/sql_class.h	2008-10-15 20:25:34 +0000
@@ -1310,10 +1310,6 @@ struct Ha_data
   Ha_data() :ha_ptr(NULL) {}
 };
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOCK_delete;
-#endif
-
 /**
   @class THD
   For each client connection we create a separate thread with THD serving as

=== modified file 'sql/sql_insert.cc'
--- a/sql/sql_insert.cc	2008-10-10 20:34:55 +0000
+++ b/sql/sql_insert.cc	2008-10-15 20:25:34 +0000
@@ -1707,12 +1707,6 @@ public:
   }
 };
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_Delayed_insert_mutex;
-PSI_cond_key key_Delayed_insert_cond;
-PSI_cond_key key_Delayed_insert_cond_client;
-#endif
-
 /**
   Delayed_insert - context of a thread responsible for delayed insert
   into one table. When processing delayed inserts, we create an own

=== modified file 'sql/sql_plugin.cc'
--- a/sql/sql_plugin.cc	2008-10-10 20:34:55 +0000
+++ b/sql/sql_plugin.cc	2008-10-15 20:25:34 +0000
@@ -108,9 +108,6 @@ static bool initialized= 0;
   following variables/structures.
   We are always manipulating ref count, so a rwlock here is unneccessary.
 */
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_plugin;
-#endif
 
 mysql_mutex_t LOCK_plugin;
 static DYNAMIC_ARRAY plugin_dl_array;

=== modified file 'sql/sql_table.cc'
--- a/sql/sql_table.cc	2008-10-10 20:34:55 +0000
+++ b/sql/sql_table.cc	2008-10-15 20:25:34 +0000
@@ -310,10 +310,6 @@ struct st_global_ddl_log
 
 st_global_ddl_log global_ddl_log;
 
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_LOCK_gdl;
-#endif
-
 mysql_mutex_t LOCK_gdl;
 
 #define DDL_LOG_ENTRY_TYPE_POS 0

=== modified file 'sql/table.h'
--- a/sql/table.h	2008-10-10 20:34:55 +0000
+++ b/sql/table.h	2008-10-15 20:25:34 +0000
@@ -240,10 +240,6 @@ TABLE_CATEGORY get_table_category(const 
 
 struct TABLE_share;
 
-#ifdef HAVE_PSI_INTERFACE
-extern PSI_mutex_key key_LOCK_ha_data;
-#endif
-
 /*
   This structure is shared between different table objects. There is one
   instance of table share per one table in the database.

=== modified file 'sql/tztime.cc'
--- a/sql/tztime.cc	2008-10-10 20:34:55 +0000
+++ b/sql/tztime.cc	2008-10-15 20:25:34 +0000
@@ -1429,9 +1429,6 @@ static MEM_ROOT tz_storage;
   time zone in offset_tzs or creating if it didn't existed before in
   tz_storage. So contention is low.
 */
-#ifdef HAVE_PSI_INTERFACE
-PSI_mutex_key key_tz_LOCK;
-#endif
 static mysql_mutex_t tz_LOCK;
 static bool tz_inited= 0;
 

=== modified file 'storage/maria/unittest/trnman-t.c'
--- a/storage/maria/unittest/trnman-t.c	2008-06-05 17:16:32 +0000
+++ b/storage/maria/unittest/trnman-t.c	2008-10-15 20:25:34 +0000
@@ -38,14 +38,14 @@ pthread_handler_t test_trnman(void *arg)
 {
   uint   x, y, i, n;
   TRN    *trn[MAX_ITER];
-  pthread_mutex_t mutexes[MAX_ITER];
-  pthread_cond_t conds[MAX_ITER];
+  mysql_mutex_t mutexes[MAX_ITER];
+  mysql_cond_t conds[MAX_ITER];
   int    m= (*(int *)arg);
 
   for (i= 0; i < MAX_ITER; i++)
   {
-    pthread_mutex_init(&mutexes[i], MY_MUTEX_INIT_FAST);
-    pthread_cond_init(&conds[i], 0);
+    MYSQL_MUTEX_INIT(&mutexes[i], 0, MY_MUTEX_INIT_FAST);
+    MYSQL_COND_INIT(&conds[i], 0, 0);
   }
 
   for (x= ((int)(intptr)(&m)); m > 0; )
@@ -69,8 +69,8 @@ pthread_handler_t test_trnman(void *arg)
   }
   for (i= 0; i < MAX_ITER; i++)
   {
-    pthread_mutex_destroy(&mutexes[i]);
-    pthread_cond_destroy(&conds[i]);
+    MYSQL_MUTEX_DESTROY(&mutexes[i]);
+    MYSQL_COND_DESTROY(&conds[i]);
   }
   pthread_mutex_lock(&rt_mutex);
   rt_num_threads--;
@@ -124,14 +124,14 @@ void test_trnman_read_from()
 {
   TRN *trn[Ntrns];
   TrID trid[Ntrns];
-  pthread_mutex_t mutexes[Ntrns];
-  pthread_cond_t conds[Ntrns];
+  mysql_mutex_t mutexes[Ntrns];
+  mysql_cond_t conds[Ntrns];
   int i;
 
   for (i= 0; i < Ntrns; i++)
   {
-    pthread_mutex_init(&mutexes[i], MY_MUTEX_INIT_FAST);
-    pthread_cond_init(&conds[i], 0);
+    MYSQL_MUTEX_INIT(&mutexes[i], 0, MY_MUTEX_INIT_FAST);
+    MYSQL_COND_INIT(&conds[i], 0, 0);
   }
 
   start_transaction(0);                    /* start trn1 */
@@ -151,8 +151,8 @@ void test_trnman_read_from()
 
   for (i= 0; i < Ntrns; i++)
   {
-    pthread_mutex_destroy(&mutexes[i]);
-    pthread_cond_destroy(&conds[i]);
+    MYSQL_MUTEX_DESTROY(&mutexes[i]);
+    MYSQL_COND_DESTROY(&conds[i]);
   }
 }
 

Thread
bzr push into mysql-6.0-perf branch (marc.alff:2704 to 2705) Marc Alff15 Oct