From: Christopher Powers Date: September 22 2011 5:41pm Subject: bzr push into mysql-trunk-wl5908 branch (chris.powers:3423 to 3424) List-Archive: http://lists.mysql.com/commits/141094 Message-Id: <201109221741.p8MHfsm9024850@acsmt356.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit 3424 Christopher Powers 2011-09-22 [merge] downmerge with mysql-trunk removed: support-files/config.huge.ini.sh support-files/config.medium.ini.sh support-files/config.small.ini.sh support-files/ndb-config-2-node.ini.sh modified: client/mysqltest.cc extra/perror.c mysql-test/r/ctype_utf16.result mysql-test/r/func_str.result mysql-test/t/func_str.test plugin/auth/qa_auth_interface.c sql/item_create.cc sql/item_strfunc.cc sql/item_strfunc.h sql/sql_base.cc storage/innobase/include/srv0mon.h storage/innobase/os/os0file.c storage/innobase/read/read0read.c storage/innobase/trx/trx0purge.c storage/perfschema/pfs.cc storage/perfschema/pfs_instr.cc storage/perfschema/pfs_instr.h support-files/CMakeLists.txt tests/mysql_client_test.c 3423 Christopher Powers 2011-09-21 [merge] downmerge with mysql-trunk removed: scripts/make_binary_distribution.sh scripts/make_win_bin_dist added: mysql-test/r/auth_rpl.result mysql-test/suite/opt_trace/include/filesort_pq.inc mysql-test/suite/opt_trace/r/filesort_pq.result mysql-test/suite/opt_trace/t/filesort_pq.test mysql-test/t/auth_rpl-master.opt mysql-test/t/auth_rpl-slave.opt mysql-test/t/auth_rpl.test modified: cmake/mysql_version.cmake include/mysql/psi/mysql_socket.h libmysql/client_settings.h mysql-test/include/mtr_check.sql mysql-test/r/derived.result mysql-test/r/func_str.result mysql-test/r/myisampack.result mysql-test/r/query_cache.result mysql-test/r/range_all.result mysql-test/r/subquery_all.result mysql-test/r/subquery_all_bka.result mysql-test/r/subquery_sj_dupsweed.result mysql-test/r/subquery_sj_dupsweed_bka.result mysql-test/r/subquery_sj_dupsweed_bkaunique.result mysql-test/r/subquery_sj_loosescan.result mysql-test/r/subquery_sj_loosescan_bka.result mysql-test/r/subquery_sj_loosescan_bkaunique.result mysql-test/r/subquery_sj_mat.result mysql-test/r/subquery_sj_mat_bka.result mysql-test/r/subquery_sj_mat_bkaunique.result mysql-test/r/view_grant.result mysql-test/suite/innodb/r/innodb-index.result mysql-test/suite/innodb/t/innodb-index.test mysql-test/suite/opt_trace/r/general2_no_prot.result mysql-test/suite/opt_trace/r/general2_ps_prot.result mysql-test/suite/opt_trace/r/general_no_prot_none.result mysql-test/suite/opt_trace/r/general_ps_prot_none.result mysql-test/suite/opt_trace/r/range_no_prot.result mysql-test/suite/opt_trace/r/range_ps_prot.result mysql-test/suite/perfschema/r/pfs_upgrade.result mysql-test/suite/perfschema/t/socket_instances_func.test mysql-test/suite/perfschema/t/socket_instances_func_win.test mysql-test/suite/perfschema/t/socket_summary_by_instance_func.test mysql-test/suite/perfschema/t/socket_summary_by_instance_func_win.test mysql-test/suite/rpl/r/rpl_row_ignorable_event.result mysql-test/suite/rpl/t/disabled.def mysql-test/suite/rpl/t/rpl_row_ignorable_event.test mysql-test/t/derived.test mysql-test/t/func_str.test mysql-test/t/myisampack.test mysql-test/t/query_cache.test mysql-test/t/view_grant.test mysql-test/valgrind.supp scripts/CMakeLists.txt scripts/mysql_system_tables.sql sql/client_settings.h sql/filesort.cc sql/opt_range.cc sql/opt_trace.h sql/rpl_slave.cc sql/share/errmsg-utf8.txt sql/sql_base.cc sql/sql_cache.cc sql/sql_select.cc sql/sql_test.cc sql/sql_test.h sql/sql_update.cc sql/table.h storage/innobase/ibuf/ibuf0ibuf.c storage/innobase/row/row0purge.c storage/innobase/row/row0sel.c storage/innobase/sync/sync0sync.c storage/myisam/ft_boolean_search.c storage/myisam/ft_nlq_search.c storage/myisam/mi_check.c storage/myisam/mi_write.c storage/perfschema/pfs_instr.h strings/dtoa.c support-files/mysql.spec.sh === modified file 'client/mysqltest.cc' --- a/client/mysqltest.cc 2011-08-22 13:24:38 +0000 +++ b/client/mysqltest.cc 2011-09-22 08:26:08 +0000 @@ -8076,6 +8076,7 @@ void free_re(void) my_regfree(&sp_re); my_regfree(&view_re); my_regfree(&opt_trace_re); + my_regfree(&explain_re); my_regex_end(); } === modified file 'extra/perror.c' --- a/extra/perror.c 2011-07-04 00:25:46 +0000 +++ b/extra/perror.c 2011-09-20 14:24:18 +0000 @@ -34,7 +34,6 @@ static my_bool verbose; #include "../include/my_base.h" #include "../mysys/my_handler_errors.h" -// #include "../include/my_compare.h" #ifdef WITH_NDBCLUSTER_STORAGE_ENGINE static my_bool ndb_code; === modified file 'mysql-test/r/ctype_utf16.result' --- a/mysql-test/r/ctype_utf16.result 2011-05-02 11:31:27 +0000 +++ b/mysql-test/r/ctype_utf16.result 2011-09-22 10:42:10 +0000 @@ -1131,7 +1131,7 @@ SELECT space(date_add(101, INTERVAL CHAR space(date_add(101, INTERVAL CHAR('1' USING utf16) hour_second)) NULL Warnings: -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated # # End of 5.5 tests # === modified file 'mysql-test/r/func_str.result' --- a/mysql-test/r/func_str.result 2011-09-20 09:17:02 +0000 +++ b/mysql-test/r/func_str.result 2011-09-22 10:42:10 +0000 @@ -845,7 +845,7 @@ explain extended select concat('*',space id select_type table type possible_keys key key_len ref rows filtered Extra 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used Warnings: -Note 1003 /* select#1 */ select concat('*',repeat(' ',5),'*') AS `concat('*',space(5),'*')` +Note 1003 /* select#1 */ select concat('*',space(5),'*') AS `concat('*',space(5),'*')` explain extended select reverse('abc'); id select_type table type possible_keys key key_len ref rows filtered Extra 1 SIMPLE NULL NULL NULL NULL NULL NULL NULL NULL No tables used @@ -2084,7 +2084,7 @@ select space(4294967295); space(4294967295) NULL Warnings: -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated select space(-4294967296); space(-4294967296) @@ -2092,7 +2092,7 @@ select space(4294967296); space(4294967296) NULL Warnings: -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated select space(-4294967297); space(-4294967297) @@ -2100,7 +2100,7 @@ select space(4294967297); space(4294967297) NULL Warnings: -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated select space(-18446744073709551615); space(-18446744073709551615) @@ -2111,7 +2111,7 @@ select space(18446744073709551615); space(18446744073709551615) NULL Warnings: -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated select space(-18446744073709551616); space(-18446744073709551616) @@ -2124,7 +2124,7 @@ NULL Warnings: Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: '' -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated select space(-18446744073709551617); space(-18446744073709551617) @@ -2137,7 +2137,7 @@ NULL Warnings: Warning 1292 Truncated incorrect DECIMAL value: '' Warning 1292 Truncated incorrect DECIMAL value: '' -Warning 1301 Result of repeat() was larger than max_allowed_packet (1048576) - truncated +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated select rpad('hello', -1, '1'); rpad('hello', -1, '1') NULL @@ -4407,6 +4407,20 @@ NULL Warnings: Warning 1301 Result of export_set() was larger than max_allowed_packet (1073741824) - truncated SET @@global.max_allowed_packet:= @tmp_max; +SELECT SPACE(@@global.max_allowed_packet*2); +SPACE(@@global.max_allowed_packet*2) +NULL +Warnings: +Warning 1301 Result of space() was larger than max_allowed_packet (1048576) - truncated +SET NAMES latin1; +PREPARE stmt FROM "SELECT COLLATION(space(2))"; +EXECUTE stmt; +COLLATION(space(2)) +latin1_swedish_ci +SET NAMES latin2; +EXECUTE stmt; +COLLATION(space(2)) +latin2_general_ci # # End of 5.6 tests # === modified file 'mysql-test/t/func_str.test' --- a/mysql-test/t/func_str.test 2011-09-20 09:17:02 +0000 +++ b/mysql-test/t/func_str.test 2011-09-22 10:42:10 +0000 @@ -1626,6 +1626,23 @@ SET @@global.max_allowed_packet:= @tmp_m --disconnect newconn +# +# BUG #12735829: SPACE() FUNCTION WARNING REFERS TO REPEAT() IN ER_WARN_ALLOWED_PACKET_OVERFLOWED +# + +SELECT SPACE(@@global.max_allowed_packet*2); + + +# +# BUG #11746123-23637: CHARSET AND COLLATION OF THE FUNCTION SPACE() +# + +SET NAMES latin1; +PREPARE stmt FROM "SELECT COLLATION(space(2))"; +EXECUTE stmt; +SET NAMES latin2; +EXECUTE stmt; + --echo # --echo # End of 5.6 tests --echo # === modified file 'plugin/auth/qa_auth_interface.c' --- a/plugin/auth/qa_auth_interface.c 2010-10-20 14:56:09 +0000 +++ b/plugin/auth/qa_auth_interface.c 2011-09-20 14:24:18 +0000 @@ -61,12 +61,13 @@ static int qa_auth_interface (MYSQL_PLUG err= CR_ERROR; if (info->auth_string_length != 14) err= CR_ERROR; -/* To be set by the plugin */ -// if (strcmp(info->authenticated_as, "qa_test_1_user")) -// err= CR_ERROR; -/* To be set by the plugin */ -// if (strcmp(info->external_user, "")) -// err= CR_ERROR; +/* + To be set by the plugin + if (strcmp(info->authenticated_as, "qa_test_1_user")) + err= CR_ERROR; + if (strcmp(info->external_user, "")) + err= CR_ERROR; +*/ if (info->password_used != PASSWORD_USED_YES) err= CR_ERROR; if (strcmp(info->host_or_ip, "localhost")) @@ -87,9 +88,11 @@ static int qa_auth_interface (MYSQL_PLUG strcpy(info->authenticated_as, "authenticated_as"); /* Assign with an external account, effect on @@local.EXTERNAL_USER */ strcpy(info->external_user, "externaluser"); - /* Overwriting will cause a core dump */ -// strcpy(info->host_or_ip, "host_or_ip"); -// info->host_or_ip_length= 10; + /* + Overwriting will cause a core dump + strcpy(info->host_or_ip, "host_or_ip"); + info->host_or_ip_length= 10; + */ } /* Invalid, means too high values for length */ else if (strcmp(info->user_name, "qa_test_3_user")== 0) @@ -126,9 +129,11 @@ static int qa_auth_interface (MYSQL_PLUG strcpy(info->authenticated_as, ""); /* This assignment has no effect.*/ strcpy(info->external_user, ""); - /* Overwriting will cause a core dump */ -// strcpy(info->host_or_ip, ""); -// info->host_or_ip_length= 0; + /* + Overwriting will cause a core dump + strcpy(info->host_or_ip, ""); + info->host_or_ip_length= 0; + */ } /* Set to 'root' */ else if (strcmp(info->user_name, "qa_test_6_user")== 0) === modified file 'sql/item_create.cc' --- a/sql/item_create.cc 2011-07-04 00:25:46 +0000 +++ b/sql/item_create.cc 2011-09-22 10:42:10 +0000 @@ -4909,26 +4909,7 @@ Create_func_space Create_func_space::s_s Item* Create_func_space::create(THD *thd, Item *arg1) { - /** - TODO: Fix Bug#23637 - The parsed item tree should not depend on - thd->variables.collation_connection. - */ - const CHARSET_INFO *cs= thd->variables.collation_connection; - Item *sp; - - if (cs->mbminlen > 1) - { - uint dummy_errors; - sp= new (thd->mem_root) Item_string("", 0, cs, DERIVATION_COERCIBLE, MY_REPERTOIRE_ASCII); - sp->str_value.copy(" ", 1, &my_charset_latin1, cs, &dummy_errors); - } - else - { - sp= new (thd->mem_root) Item_string(" ", 1, cs, DERIVATION_COERCIBLE, MY_REPERTOIRE_ASCII); - } - - return new (thd->mem_root) Item_func_repeat(sp, arg1); + return new (thd->mem_root) Item_func_space(arg1); } === modified file 'sql/item_strfunc.cc' --- a/sql/item_strfunc.cc 2011-07-28 10:54:44 +0000 +++ b/sql/item_strfunc.cc 2011-09-22 10:42:10 +0000 @@ -2816,6 +2816,76 @@ err: } + +void Item_func_space::fix_length_and_dec() +{ + collation.set(default_charset(), DERIVATION_COERCIBLE, MY_REPERTOIRE_ASCII); + if (args[0]->const_item()) + { + /* must be longlong to avoid truncation */ + longlong count= args[0]->val_int(); + if (args[0]->null_value) + goto end; + /* + Assumes that the maximum length of a String is < INT_MAX32. + Set here so that rest of code sees out-of-bound value as such. + */ + if (count > INT_MAX32) + count= INT_MAX32; + fix_char_length_ulonglong(count); + return; + } + +end: + max_length= MAX_BLOB_WIDTH; + maybe_null= 1; +} + + +String *Item_func_space::val_str(String *str) +{ + uint tot_length; + longlong count= args[0]->val_int(); + const CHARSET_INFO *cs= collation.collation; + + if (args[0]->null_value) + goto err; // string and/or delim are null + null_value= 0; + + if (count <= 0 && (count == 0 || !args[0]->unsigned_flag)) + return make_empty_result(); + /* + Assumes that the maximum length of a String is < INT_MAX32. + Bounds check on count: If this is triggered, we will error. + */ + if ((ulonglong) count > INT_MAX32) + count= INT_MAX32; + + // Safe length check + tot_length= (uint) count * cs->mbminlen; + if (tot_length > current_thd->variables.max_allowed_packet) + { + push_warning_printf(current_thd, Sql_condition::WARN_LEVEL_WARN, + ER_WARN_ALLOWED_PACKET_OVERFLOWED, + ER(ER_WARN_ALLOWED_PACKET_OVERFLOWED), + func_name(), + current_thd->variables.max_allowed_packet); + goto err; + } + + if (str->alloc(tot_length)) + goto err; + str->length(tot_length); + str->set_charset(cs); + cs->cset->fill(cs, (char*) str->ptr(), tot_length, ' '); + return str; + +err: + null_value= 1; + return 0; +} + + void Item_func_rpad::fix_length_and_dec() { // Handle character set for args[0] and args[2]. === modified file 'sql/item_strfunc.h' --- a/sql/item_strfunc.h 2011-07-04 00:25:46 +0000 +++ b/sql/item_strfunc.h 2011-09-22 10:42:10 +0000 @@ -617,6 +617,16 @@ public: }; +class Item_func_space :public Item_str_func +{ +public: + Item_func_space(Item *arg1):Item_str_func(arg1) {} + String *val_str(String *); + void fix_length_and_dec(); + const char *func_name() const { return "space"; } +}; + + class Item_func_rpad :public Item_str_func { String tmp_value, rpad_str; === modified file 'sql/sql_base.cc' --- a/sql/sql_base.cc 2011-09-14 15:03:55 +0000 +++ b/sql/sql_base.cc 2011-09-21 15:41:50 +0000 @@ -542,8 +542,6 @@ static void table_def_use_table(THD *thd DBUG_ASSERT(table->db_stat && table->file); /* The children must be detached from the table. */ DBUG_ASSERT(! table->file->extra(HA_EXTRA_IS_ATTACHED_CHILDREN)); - - table->file->rebind_psi(); } @@ -560,7 +558,6 @@ static void table_def_unuse_table(TABLE DBUG_ASSERT(! table->s->has_old_version()); table->in_use= 0; - table->file->unbind_psi(); /* Remove table from the list of tables used in this share. */ table->s->used_tables.remove(table); @@ -1655,6 +1652,10 @@ bool close_thread_table(THD *thd, TABLE table->file->ha_reset(); } + /* Do this *before* entering the LOCK_open critical section. */ + if (table->file != NULL) + table->file->unbind_psi(); + mysql_mutex_lock(&LOCK_open); if (table->s->has_old_version() || table->needs_reopen() || @@ -2731,6 +2732,8 @@ bool open_table(THD *thd, TABLE_LIST *ta int error; TABLE_SHARE *share; my_hash_value_type hash_value; + bool recycled_free_table; + DBUG_ENTER("open_table"); /* @@ -3088,6 +3091,7 @@ retry_share: { table= share->free_tables.front(); table_def_use_table(thd, table); + recycled_free_table= true; /* We need to release share as we have EXTRA reference to it in our hands. */ release_table_share(share); } @@ -3099,6 +3103,7 @@ retry_share: mysql_mutex_unlock(&LOCK_open); + recycled_free_table= false; /* make a new table */ if (!(table=(TABLE*) my_malloc(sizeof(*table),MYF(MY_WME)))) goto err_lock; @@ -3140,6 +3145,13 @@ retry_share: mysql_mutex_unlock(&LOCK_open); + /* Call rebind_psi outside of the LOCK_open critical section. */ + if (recycled_free_table) + { + DBUG_ASSERT(table->file != NULL); + table->file->rebind_psi(); + } + table->mdl_ticket= mdl_ticket; table->next= thd->open_tables; /* Link into simple list */ === modified file 'storage/innobase/include/srv0mon.h' --- a/storage/innobase/include/srv0mon.h 2011-08-10 06:26:39 +0000 +++ b/storage/innobase/include/srv0mon.h 2011-09-22 07:44:19 +0000 @@ -528,6 +528,33 @@ on the counters */ } \ } +#ifdef HAVE_ATOMIC_BUILTINS + +# define MONITOR_ATOMIC_INC(monitor) \ + if (MONITOR_IS_ON(monitor)) { \ + ib_int64_t value; \ + value = (ib_int64_t) os_atomic_increment_ulint( \ + &MONITOR_VALUE(monitor), 1); \ + /* Note: This is not 100% accurate because of the \ + inherent race, we ignore it due to performance. */ \ + if (value > MONITOR_MAX_VALUE(monitor)) { \ + MONITOR_MAX_VALUE(monitor) = value; \ + } \ + } + +# define MONITOR_ATOMIC_DEC(monitor) \ + if (MONITOR_IS_ON(monitor)) { \ + ib_int64_t value; \ + value = (ib_int64_t) os_atomic_decrement_ulint( \ + &MONITOR_VALUE(monitor), 1); \ + /* Note: This is not 100% accurate because of the \ + inherent race, we ignore it due to performance. */ \ + if (value < MONITOR_MIN_VALUE(monitor)) { \ + MONITOR_MIN_VALUE(monitor) = value; \ + } \ + } +#endif /* HAVE_ATOMIC_BUILTINS */ + #define MONITOR_DEC(monitor) \ if (MONITOR_IS_ON(monitor)) { \ MONITOR_VALUE(monitor)--; \ === modified file 'storage/innobase/os/os0file.c' --- a/storage/innobase/os/os0file.c 2011-07-19 00:25:20 +0000 +++ b/storage/innobase/os/os0file.c 2011-09-22 07:44:19 +0000 @@ -288,10 +288,12 @@ UNIV_INTERN time_t os_last_printout; UNIV_INTERN ibool os_has_said_disk_full = FALSE; -#ifndef UNIV_HOTBACKUP +#if !defined(UNIV_HOTBACKUP) \ + && (!defined(HAVE_ATOMIC_BUILTINS) || UNIV_WORD_SIZE < 8) /** The mutex protecting the following counts of pending I/O operations */ static os_mutex_t os_file_count_mutex; -#endif /* !UNIV_HOTBACKUP */ +#endif /* !UNIV_HOTBACKUP && (!HAVE_ATOMIC_BUILTINS || UNIV_WORD_SIZE < 8) */ + /** Number of pending os_file_pread() operations */ UNIV_INTERN ulint os_file_n_pending_preads = 0; /** Number of pending os_file_pwrite() operations */ @@ -747,7 +749,9 @@ os_io_init_simple(void) { ulint i; +#if !defined(HAVE_ATOMIC_BUILTINS) || UNIV_WORD_SIZE < 8 os_file_count_mutex = os_mutex_create(); +#endif /* !HAVE_ATOMIC_BUILTINS || UNIV_WORD_SIZE < 8 */ for (i = 0; i < OS_FILE_N_SEEK_MUTEXES; i++) { os_file_seek_mutexes[i] = os_mutex_create(); @@ -2212,19 +2216,31 @@ os_file_pread( os_n_file_reads++; #if defined(HAVE_PREAD) && !defined(HAVE_BROKEN_PREAD) +#if defined(HAVE_ATOMIC_BUILTINS) && UNIV_WORD_SIZE == 8 + (void) os_atomic_increment_ulint(&os_n_pending_reads, 1); + (void) os_atomic_increment_ulint(&os_file_n_pending_preads, 1); + MONITOR_ATOMIC_INC(MONITOR_OS_PENDING_READS); +#else os_mutex_enter(os_file_count_mutex); os_file_n_pending_preads++; os_n_pending_reads++; MONITOR_INC(MONITOR_OS_PENDING_READS); os_mutex_exit(os_file_count_mutex); +#endif /* HAVE_ATOMIC_BUILTINS && UNIV_WORD == 8 */ - n_bytes = pread(file, buf, (ssize_t)n, offs); + n_bytes = pread(file, buf, n, offs); +#if defined(HAVE_ATOMIC_BUILTINS) && UNIV_WORD_SIZE == 8 + (void) os_atomic_decrement_ulint(&os_n_pending_reads, 1); + (void) os_atomic_decrement_ulint(&os_file_n_pending_preads, 1); + MONITOR_ATOMIC_DEC(MONITOR_OS_PENDING_READS); +#else os_mutex_enter(os_file_count_mutex); os_file_n_pending_preads--; os_n_pending_reads--; MONITOR_DEC(MONITOR_OS_PENDING_READS); os_mutex_exit(os_file_count_mutex); +#endif /* !HAVE_ATOMIC_BUILTINS || UNIV_WORD == 8 */ return(n_bytes); #else @@ -2235,11 +2251,15 @@ os_file_pread( ulint i; #endif /* !UNIV_HOTBACKUP */ +#if defined(HAVE_ATOMIC_BUILTINS) && UNIV_WORD_SIZE == 8 + (void) os_atomic_increment_ulint(&os_n_pending_reads, 1); + MONITOR_ATOMIC_INC(MONITOR_OS_PENDING_READS); +#else os_mutex_enter(os_file_count_mutex); os_n_pending_reads++; MONITOR_INC(MONITOR_OS_PENDING_READS); os_mutex_exit(os_file_count_mutex); - +#endif /* HAVE_ATOMIC_BUILTINS && UNIV_WORD == 8 */ #ifndef UNIV_HOTBACKUP /* Protect the seek / read operation with a mutex */ i = ((ulint) file) % OS_FILE_N_SEEK_MUTEXES; @@ -2259,10 +2279,15 @@ os_file_pread( os_mutex_exit(os_file_seek_mutexes[i]); #endif /* !UNIV_HOTBACKUP */ +#if defined(HAVE_ATOMIC_BUILTINS) && UNIV_WORD_SIZE == 8 + (void) os_atomic_decrement_ulint(&os_n_pending_reads, 1); + MONITOR_ATOIC_DEC(MONITOR_OS_PENDING_READS); +#else os_mutex_enter(os_file_count_mutex); os_n_pending_reads--; MONITOR_DEC(MONITOR_OS_PENDING_READS); os_mutex_exit(os_file_count_mutex); +#endif /* HAVE_ATOMIC_BUILTINS && UNIV_WORD_SIZE == 8 */ return(ret); } @@ -2301,19 +2326,31 @@ os_file_pwrite( os_n_file_writes++; #if defined(HAVE_PWRITE) && !defined(HAVE_BROKEN_PREAD) +#if !defined(HAVE_ATOMIC_BUILTINS) || UNIV_WORD_SIZE < 8 os_mutex_enter(os_file_count_mutex); os_file_n_pending_pwrites++; os_n_pending_writes++; MONITOR_INC(MONITOR_OS_PENDING_WRITES); os_mutex_exit(os_file_count_mutex); +#else + (void) os_atomic_increment_ulint(&os_n_pending_writes, 1); + (void) os_atomic_increment_ulint(&os_file_n_pending_pwrites, 1); + MONITOR_ATOMIC_INC(MONITOR_OS_PENDING_WRITES); +#endif /* !HAVE_ATOMIC_BUILTINS || UNIV_WORD < 8 */ ret = pwrite(file, buf, (ssize_t)n, offs); +#if !defined(HAVE_ATOMIC_BUILTINS) || UNIV_WORD_SIZE < 8 os_mutex_enter(os_file_count_mutex); os_file_n_pending_pwrites--; os_n_pending_writes--; MONITOR_DEC(MONITOR_OS_PENDING_WRITES); os_mutex_exit(os_file_count_mutex); +#else + (void) os_atomic_decrement_ulint(&os_n_pending_writes, 1); + (void) os_atomic_decrement_ulint(&os_file_n_pending_pwrites, 1); + MONITOR_ATOMIC_DEC(MONITOR_OS_PENDING_WRITES); +#endif /* !HAVE_ATOMIC_BUILTINS || UNIV_WORD < 8 */ # ifdef UNIV_DO_FLUSH if (srv_unix_file_flush_method != SRV_UNIX_LITTLESYNC === modified file 'storage/innobase/read/read0read.c' --- a/storage/innobase/read/read0read.c 2011-08-11 20:23:10 +0000 +++ b/storage/innobase/read/read0read.c 2011-09-22 06:35:38 +0000 @@ -394,7 +394,10 @@ read_view_open_now_low( view->up_limit_id = view->low_limit_id; } - read_view_add(view); + /* Purge views are not added to the view list. */ + if (cr_trx_id > 0) { + read_view_add(view); + } return(view); } @@ -461,6 +464,8 @@ read_view_purge_open( ut_ad(read_view_validate(oldest_view)); + mutex_exit(&trx_sys->mutex); + ut_a(oldest_view->creator_trx_id > 0); creator_trx_id = oldest_view->creator_trx_id; @@ -489,8 +494,6 @@ read_view_purge_open( view->trx_ids[i] = oldest_view->trx_ids[i - 1]; } - ut_ad(read_view_validate(view)); - view->creator_trx_id = 0; view->low_limit_no = oldest_view->low_limit_no; @@ -504,10 +507,6 @@ read_view_purge_open( view->up_limit_id = oldest_view->up_limit_id; } - read_view_add(view); - - mutex_exit(&trx_sys->mutex); - return(view); } === modified file 'storage/innobase/trx/trx0purge.c' --- a/storage/innobase/trx/trx0purge.c 2011-07-26 03:21:33 +0000 +++ b/storage/innobase/trx/trx0purge.c 2011-09-22 06:35:38 +0000 @@ -180,11 +180,7 @@ trx_purge_sys_close(void) purge_sys->sess = NULL; - if (purge_sys->view != NULL) { - read_view_remove(purge_sys->view); - - purge_sys->view = NULL; - } + purge_sys->view = NULL; rw_lock_free(&purge_sys->latch); mutex_free(&purge_sys->bh_mutex); @@ -1204,8 +1200,6 @@ trx_purge( rw_lock_x_lock(&purge_sys->latch); - read_view_remove(purge_sys->view); - purge_sys->view = NULL; mem_heap_empty(purge_sys->heap); === modified file 'storage/perfschema/pfs.cc' --- a/storage/perfschema/pfs.cc 2011-09-21 12:47:15 +0000 +++ b/storage/perfschema/pfs.cc 2011-09-22 17:40:57 +0000 @@ -3710,6 +3710,8 @@ static void end_table_io_wait_v1(PSI_tab insert_events_waits_history_long(wait); thread->m_events_waits_count--; } + + table->m_has_io_stats= true; } /** @@ -3787,6 +3789,8 @@ static void end_table_lock_wait_v1(PSI_t insert_events_waits_history_long(wait); thread->m_events_waits_count--; } + + table->m_has_lock_stats= true; } static void start_file_wait_v1(PSI_file_locker *locker, === modified file 'storage/perfschema/pfs_instr.cc' --- a/storage/perfschema/pfs_instr.cc 2011-09-02 20:03:36 +0000 +++ b/storage/perfschema/pfs_instr.cc 2011-09-22 17:40:57 +0000 @@ -1303,6 +1303,8 @@ PFS_table* create_table(PFS_table_share pfs->m_lock_enabled= share->m_enabled && flag_global_instrumentation && global_table_lock_class.m_enabled; pfs->m_lock_timed= share->m_timed && global_table_lock_class.m_timed; + pfs->m_has_io_stats= false; + pfs->m_has_lock_stats= false; share->inc_refcount(); pfs->m_table_stat.reset(); pfs->m_thread_owner= opening_thread; @@ -1324,24 +1326,35 @@ void PFS_table::sanitized_aggregate(void */ PFS_table_share *safe_share= sanitize_table_share(m_share); PFS_thread *safe_thread= sanitize_thread(m_thread_owner); - if (safe_share != NULL && safe_thread != NULL) + if ((safe_share != NULL && safe_thread != NULL) && + (m_has_io_stats || m_has_lock_stats)) + { safe_aggregate(& m_table_stat, safe_share, safe_thread); + m_has_io_stats= false; + m_has_lock_stats= false; + } } void PFS_table::sanitized_aggregate_io(void) { PFS_table_share *safe_share= sanitize_table_share(m_share); PFS_thread *safe_thread= sanitize_thread(m_thread_owner); - if (safe_share != NULL && safe_thread != NULL) + if (safe_share != NULL && safe_thread != NULL && m_has_io_stats) + { safe_aggregate_io(& m_table_stat, safe_share, safe_thread); + m_has_io_stats= false; + } } void PFS_table::sanitized_aggregate_lock(void) { PFS_table_share *safe_share= sanitize_table_share(m_share); PFS_thread *safe_thread= sanitize_thread(m_thread_owner); - if (safe_share != NULL && safe_thread != NULL) + if (safe_share != NULL && safe_thread != NULL && m_has_lock_stats) + { safe_aggregate_lock(& m_table_stat, safe_share, safe_thread); + m_has_lock_stats= false; + } } void PFS_table::safe_aggregate(PFS_table_stat *table_stat, @@ -1358,11 +1371,17 @@ void PFS_table::safe_aggregate(PFS_table uint index; event_name_array= thread->m_instr_class_waits_stats; - /* Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME (for wait/io/table/sql/handler) */ + /* + Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME + (for wait/io/table/sql/handler) + */ index= global_table_io_class.m_event_name_index; table_stat->sum_io(& event_name_array[index]); - /* Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME (for wait/lock/table/sql/handler) */ + /* + Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME + (for wait/lock/table/sql/handler) + */ index= global_table_lock_class.m_event_name_index; table_stat->sum_lock(& event_name_array[index]); } @@ -1386,7 +1405,10 @@ void PFS_table::safe_aggregate_io(PFS_ta uint index; event_name_array= thread->m_instr_class_waits_stats; - /* Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME (for wait/io/table/sql/handler) */ + /* + Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME + (for wait/io/table/sql/handler) + */ index= global_table_io_class.m_event_name_index; table_stat->sum_io(& event_name_array[index]); } @@ -1410,7 +1432,10 @@ void PFS_table::safe_aggregate_lock(PFS_ uint index; event_name_array= thread->m_instr_class_waits_stats; - /* Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME (for wait/lock/table/sql/handler) */ + /* + Aggregate to EVENTS_WAITS_SUMMARY_BY_THREAD_BY_EVENT_NAME + (for wait/lock/table/sql/handler) + */ index= global_table_lock_class.m_event_name_index; table_stat->sum_lock(& event_name_array[index]); } === modified file 'storage/perfschema/pfs_instr.h' --- a/storage/perfschema/pfs_instr.h 2011-09-21 12:47:15 +0000 +++ b/storage/perfschema/pfs_instr.h 2011-09-22 17:40:57 +0000 @@ -182,6 +182,12 @@ struct PFS_table */ bool m_lock_timed; + /** True if table io statistics have been collected. */ + bool m_has_io_stats; + + /** True if table lock statistics have been collected. */ + bool m_has_lock_stats; + public: /** Aggregate this table handle statistics to the parents. @@ -190,8 +196,12 @@ public: */ void aggregate(void) { - if (likely(m_thread_owner != NULL)) + if (likely((m_thread_owner != NULL) && (m_has_io_stats || m_has_lock_stats))) + { safe_aggregate(& m_table_stat, m_share, m_thread_owner); + m_has_io_stats= false; + m_has_lock_stats= false; + } } /** === modified file 'support-files/CMakeLists.txt' --- a/support-files/CMakeLists.txt 2010-12-17 23:03:23 +0000 +++ b/support-files/CMakeLists.txt 2011-09-20 12:35:54 +0000 @@ -49,8 +49,7 @@ ENDFOREACH() IF(UNIX) SET(prefix ${CMAKE_INSTALL_PREFIX}) - FOREACH(script mysqld_multi.server mysql-log-rotate binary-configure - config.medium.ini config.small.ini config.huge.ini ndb-config-2-node.ini) + FOREACH(script mysqld_multi.server mysql-log-rotate binary-configure) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/${script}.sh ${CMAKE_CURRENT_BINARY_DIR}/${script} @ONLY ) === removed file 'support-files/config.huge.ini.sh' --- a/support-files/config.huge.ini.sh 2011-06-30 15:37:13 +0000 +++ b/support-files/config.huge.ini.sh 1970-01-01 00:00:00 +0000 @@ -1,228 +0,0 @@ -# Copyright (c) 2008 MySQL AB -# Use is subject to license terms. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -# -###################################################### -# MySQL NDB Cluster Huge Sample Configuration File # -###################################################### -# This files assumes that you are using at least 9 # -# hosts for running the cluster. Hostnames and paths # -# listed below should be changed to match your setup # -###################################################### - -[NDBD DEFAULT] -NoOfReplicas: 2 -DataDir: /add/path/here -FileSystemPath: /add/path/here - -# Data Memory, Index Memory, and String Memory # -DataMemory: 6000M -IndexMemory: 1500M -StringMemory: 5 - -# Transaction Parameters # -MaxNoOfConcurrentTransactions: 4096 -MaxNoOfConcurrentOperations: 100000 -MaxNoOfLocalOperations: 100000 - -# Transaction Temporary Storage # -MaxNoOfConcurrentIndexOperations: 8192 -MaxNoOfFiredTriggers: 4000 -TransactionBufferMemory: 1M - -# Scans and buffering # -MaxNoOfConcurrentScans: 300 -MaxNoOfLocalScans: 32 -BatchSizePerLocalScan: 64 -LongMessageBuffer: 1M - -# Logging and Checkpointing # -NoOfFragmentLogFiles: 300 -FragmentLogFileSize: 16M -MaxNoOfOpenFiles: 40 -InitialNoOfOpenFiles: 27 -MaxNoOfSavedMessages: 25 - -# Metadata Objects # -MaxNoOfAttributes: 1500 -MaxNoOfTables: 400 -MaxNoOfOrderedIndexes: 200 -MaxNoOfUniqueHashIndexes: 200 -MaxNoOfTriggers: 770 - -# Boolean Parameters # -LockPagesInMainMemory: 0 -StopOnError: 1 -Diskless: 0 -ODirect: 0 - -# Controlling Timeouts, Intervals, and Disk Paging # -TimeBetweenWatchDogCheck: 6000 -TimeBetweenWatchDogCheckInitial: 6000 -StartPartialTimeout: 30000 -StartPartitionedTimeout: 60000 -StartFailureTimeout: 1000000 -HeartbeatIntervalDbDb: 2000 -HeartbeatIntervalDbApi: 3000 -TimeBetweenLocalCheckpoints: 20 -TimeBetweenGlobalCheckpoints: 2000 -TransactionInactiveTimeout: 0 -TransactionDeadlockDetectionTimeout: 1200 -DiskSyncSize: 4M -DiskCheckpointSpeed: 10M -DiskCheckpointSpeedInRestart: 100M -ArbitrationTimeout: 10 - -# Buffering and Logging # -UndoIndexBuffer: 2M -UndoDataBuffer: 1M -RedoBuffer: 32M -LogLevelStartup: 15 -LogLevelShutdown: 3 -LogLevelStatistic: 0 -LogLevelCheckpoint: 0 -LogLevelNodeRestart: 0 -LogLevelConnection: 0 -LogLevelError: 15 -LogLevelCongestion: 0 -LogLevelInfo: 3 -MemReportFrequency: 0 - -# Backup Parameters # -BackupDataBufferSize: 2M -BackupLogBufferSize: 2M -BackupMemory: 64M -BackupWriteSize: 32K -BackupMaxWriteSize: 256K - -[MGM DEFAULT] -PortNumber: 1186 -DataDir: /add/path/here - -[TCP DEFAULT] -SendBufferMemory: 2M - -####################################### -# Change HOST1 to the name of the NDB_MGMD host -# Change HOST2 to the name of the NDB_MGMD host -# Change HOST3 to the name of the NDB_MGMD host -# Change HOST4 to the name of the NDBD host -# Change HOST5 to the name of the NDBD host -# Change HOST6 to the name of the NDBD host -# Change HOST7 to the name of the NDBD host -# Change HOST8 to the name of the NDBD host -# Change HOST9 to the name of the NDBD host -####################################### - -[NDB_MGMD] -Id: 1 -HostName: HOST1 -ArbitrationRank: 1 - -[NDB_MGMD] -Id: 2 -HostName: HOST2 -ArbitrationRank: 1 - -[NDB_MGMD] -Id: 3 -HostName: HOST3 -ArbitrationRank: 1 - -[NDBD] -Id: 4 -HostName: HOST4 - -[NDBD] -Id: 5 -HostName: HOST5 - -[NDBD] -Id: 6 -HostName: HOST6 - -[NDBD] -Id: 7 -HostName: HOST7 - -[NDBD] -Id: 8 -HostName: HOST8 - -[NDBD] -Id: 9 -HostName: HOST9 - -###################################################### -# Note: The following can be MySQLD connections or # -# NDB API application connecting to the cluster # -###################################################### - -[API] -Id: 10 -HostName: HOST1 -ArbitrationRank: 2 - -[API] -Id: 11 -HostName: HOST2 -ArbitrationRank: 2 - -[API] -Id: 12 -HostName: HOST3 - -[API] -Id: 13 -HostName: HOST4 - -[API] -Id: 14 -HostName: HOST5 - -[API] -Id: 15 -HostName: HOST6 - -[API] -Id: 16 -HostName: HOST7 - -[API] -Id: 17 -HostName: HOST8 - -[API] -Id: 19 -HostName: HOST9 - -[API] -Id: 20 - -[API] -Id: 21 - -[API] -Id: 22 - -[API] -Id: 23 - -[API] -Id: 24 - -[API] -Id: 25 - === removed file 'support-files/config.medium.ini.sh' --- a/support-files/config.medium.ini.sh 2011-06-30 15:37:13 +0000 +++ b/support-files/config.medium.ini.sh 1970-01-01 00:00:00 +0000 @@ -1,139 +0,0 @@ -# Copyright (c) 2008 MySQL AB -# Use is subject to license terms. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -# -# MySQL NDB Cluster Medium Sample Configuration File -# -# This files assumes that you are using at least 6 -# hosts for running the cluster. Hostnames and paths -# listed below should be changed to match your setup -# - -[NDBD DEFAULT] -NoOfReplicas: 2 -DataDir: /add/path/here -FileSystemPath: /add/path/here - - -# Data Memory, Index Memory, and String Memory - -DataMemory: 3000M -IndexMemory: 800M -BackupMemory: 64M - -# Transaction Parameters - -MaxNoOfConcurrentOperations: 100000 -MaxNoOfLocalOperations: 100000 - -# Buffering and Logging - -RedoBuffer: 16M - -# Logging and Checkpointing - -NoOfFragmentLogFiles: 200 - -# Metadata Objects - -MaxNoOfAttributes: 500 -MaxNoOfTables: 100 - -# Scans and Buffering - -MaxNoOfConcurrentScans: 100 - - -[MGM DEFAULT] -PortNumber: 1186 -DataDir: /add/path/here - -# -# Change HOST1 to the name of the NDB_MGMD host -# Change HOST2 to the name of the NDB_MGMD host -# Change HOST3 to the name of the NDBD host -# Change HOST4 to the name of the NDBD host -# Change HOST5 to the name of the NDBD host -# Change HOST6 to the name of the NDBD host -# - -[NDB_MGMD] -Id: 1 -HostName: HOST1 -ArbitrationRank: 1 - -[NDB_MGMD] -Id: 2 -HostName: HOST2 -ArbitrationRank: 1 - -[NDBD] -Id: 3 -HostName: HOST3 - -[NDBD] -Id: 4 -HostName: HOST4 - -[NDBD] -Id: 5 -HostName: HOST5 - -[NDBD] -Id: 6 -HostName: HOST6 - -# -# Note: The following can be MySQLD connections or -# NDB API application connecting to the cluster -# - -[API] -Id: 7 -HostName: HOST1 -ArbitrationRank: 2 - -[API] -Id: 8 -HostName: HOST2 -ArbitrationRank: 2 - -[API] -Id: 9 -HostName: HOST3 -ArbitrationRank: 2 - -[API] -Id: 10 -HostName: HOST4 - -[API] -Id: 11 -HostName: HOST5 - -[API] -Id: 12 -HostName: HOST6 - -[API] -Id: 13 - -[API] -Id: 14 - -[API] -Id: 15 - - === removed file 'support-files/config.small.ini.sh' --- a/support-files/config.small.ini.sh 2011-06-30 15:37:13 +0000 +++ b/support-files/config.small.ini.sh 1970-01-01 00:00:00 +0000 @@ -1,80 +0,0 @@ -# Copyright (c) 2008 MySQL AB -# Use is subject to license terms. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -# -# MySQL NDB Cluster Small Sample Configuration File -# -# This files assumes that you are using 1 to 3 hosts -# for running the cluster. Hostnames and paths listed -# below should be changed to match your setup. -# -# Note: You can change localhost for a different host -# - -[NDBD DEFAULT] -NoOfReplicas: 2 -DataDir: /add/path/here -FileSystemPath: /add/path/here - -# Data Memory, Index Memory, and String Memory - -DataMemory: 600M -IndexMemory: 100M -BackupMemory: 64M - -[MGM DEFAULT] -PortNumber: 1186 -DataDir: /add/path/here - -[NDB_MGMD] -Id: 1 -HostName: localhost -ArbitrationRank: 1 - -[NDBD] -Id: 2 -HostName: localhost - -[NDBD] -Id: 3 -HostName: localhost - -# -# Note: The following can be MySQLD connections or -# NDB API application connecting to the cluster -# - -[API] -Id: 4 -HostName: localhost -ArbitrationRank: 2 - -[API] -Id: 5 -HostName: localhost - -[API] -Id: 6 -HostName: localhost - -[API] -Id: 7 - -[API] -Id: 8 - -[API] -Id: 9 - === removed file 'support-files/ndb-config-2-node.ini.sh' --- a/support-files/ndb-config-2-node.ini.sh 2011-06-30 15:46:53 +0000 +++ b/support-files/ndb-config-2-node.ini.sh 1970-01-01 00:00:00 +0000 @@ -1,58 +0,0 @@ -# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved. -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; version 2 of the License. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA -# -# Example Ndbcluster storage engine config file. -# -[ndbd default] -NoOfReplicas= 2 -MaxNoOfConcurrentOperations= 10000 -DataMemory= 80M -IndexMemory= 24M -TimeBetweenWatchDogCheck= 30000 -DataDir= /var/lib/mysql-cluster -MaxNoOfOrderedIndexes= 512 - -[ndb_mgmd default] -DataDir= /var/lib/mysql-cluster - -[ndb_mgmd] -Id=1 -HostName= localhost - -[ndbd] -Id= 2 -HostName= localhost - -[ndbd] -Id= 3 -HostName= localhost - -[mysqld] -Id= 4 - -[mysqld] -Id= 5 - -[mysqld] -Id= 6 - -[mysqld] -Id= 7 - -# choose an unused port number -# in this configuration 63132, 63133, and 63134 -# will be used -[tcp default] -PortNumber= 63132 === modified file 'tests/mysql_client_test.c' --- a/tests/mysql_client_test.c 2011-08-03 14:02:33 +0000 +++ b/tests/mysql_client_test.c 2011-09-20 14:24:18 +0000 @@ -2190,22 +2190,24 @@ static void test_wl4435_3() puts(""); - // The following types are not supported: - // - ENUM - // - SET - // - // The following types are supported but can not be used for - // OUT-parameters: - // - MEDIUMINT; - // - BIT(..); - // - // The problem is that those types are not supported for IN-parameters, - // and OUT-parameters should be bound as IN-parameters before execution. - // - // The following types should not be used: - // - MYSQL_TYPE_YEAR (use MYSQL_TYPE_SHORT instead); - // - MYSQL_TYPE_TINY_BLOB, MYSQL_TYPE_MEDIUM_BLOB, MYSQL_TYPE_LONG_BLOB - // (use MYSQL_TYPE_BLOB instead); + /* + The following types are not supported: + - ENUM + - SET + + The following types are supported but can not be used for + OUT-parameters: + - MEDIUMINT; + - BIT(..); + + The problem is that those types are not supported for IN-parameters, + and OUT-parameters should be bound as IN-parameters before execution + + The following types should not be used: + - MYSQL_TYPE_YEAR (use MYSQL_TYPE_SHORT instead); + - MYSQL_TYPE_TINY_BLOB, MYSQL_TYPE_MEDIUM_BLOB, MYSQL_TYPE_LONG_BLOB + (use MYSQL_TYPE_BLOB instead); + */ WL4435_TEST("TINYINT", "127", MYSQL_TYPE_TINY, MYSQL_TYPE_TINY, No bundle (reason: useless for push emails).