Commit cd180bc2 authored by Vadim Tkachenko's avatar Vadim Tkachenko

sync to extension rev 58

parent e76737c2
...@@ -713,8 +713,7 @@ check_have_atomic_pthread_t: ...@@ -713,8 +713,7 @@ check_have_atomic_pthread_t:
echo '#define HAVE_ATOMIC_PTHREAD_T' > include/ut0auxconf.h ; \ echo '#define HAVE_ATOMIC_PTHREAD_T' > include/ut0auxconf.h ; \
fi fi
# This is temprary fix for http://bugs.mysql.com/43740 all: check_have_atomic_pthread_t all-am
all: all-am
.SUFFIXES: .SUFFIXES:
.SUFFIXES: .c .cc .lo .o .obj .SUFFIXES: .c .cc .lo .o .obj
......
...@@ -26,7 +26,6 @@ struct innodb_enhancement { ...@@ -26,7 +26,6 @@ struct innodb_enhancement {
{"xtradb_show_enhancements","I_S.XTRADB_ENHANCEMENTS","","http://www.percona.com/docs/wiki/percona-xtradb"}, {"xtradb_show_enhancements","I_S.XTRADB_ENHANCEMENTS","","http://www.percona.com/docs/wiki/percona-xtradb"},
{"innodb_show_status","Improvements to SHOW INNODB STATUS","Memory information and lock info fixes","http://www.percona.com/docs/wiki/percona-xtradb"}, {"innodb_show_status","Improvements to SHOW INNODB STATUS","Memory information and lock info fixes","http://www.percona.com/docs/wiki/percona-xtradb"},
{"innodb_io","Improvements to InnoDB IO","","http://www.percona.com/docs/wiki/percona-xtradb"}, {"innodb_io","Improvements to InnoDB IO","","http://www.percona.com/docs/wiki/percona-xtradb"},
{"innodb_rw_lock","InnoDB RW-lock fixes","Useful for 8+ cores SMP systems","http://www.percona.com/docs/wiki/percona-xtradb"},
{"innodb_opt_lru_count","Fix of buffer_pool mutex","Decreases contention on buffer_pool mutex on LRU operations","http://www.percona.com/docs/wiki/percona-xtradb"}, {"innodb_opt_lru_count","Fix of buffer_pool mutex","Decreases contention on buffer_pool mutex on LRU operations","http://www.percona.com/docs/wiki/percona-xtradb"},
{"innodb_buffer_pool_pages","Information of buffer pool content","","http://www.percona.com/docs/wiki/percona-xtradb"}, {"innodb_buffer_pool_pages","Information of buffer pool content","","http://www.percona.com/docs/wiki/percona-xtradb"},
{"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"}, {"innodb_split_buf_pool_mutex","More fix of buffer_pool mutex","Spliting buf_pool_mutex and optimizing based on innodb_opt_lru_count","http://www.percona.com/docs/wiki/percona-xtradb"},
......
...@@ -359,17 +359,7 @@ rw_lock_get_x_lock_count( ...@@ -359,17 +359,7 @@ rw_lock_get_x_lock_count(
Accessor functions for rw lock. */ Accessor functions for rw lock. */
UNIV_INLINE UNIV_INLINE
ulint ulint
rw_lock_get_s_waiters( rw_lock_get_waiters(
/*==================*/
rw_lock_t* lock);
UNIV_INLINE
ulint
rw_lock_get_x_waiters(
/*==================*/
rw_lock_t* lock);
UNIV_INLINE
ulint
rw_lock_get_wx_waiters(
/*================*/ /*================*/
rw_lock_t* lock); rw_lock_t* lock);
UNIV_INLINE UNIV_INLINE
...@@ -488,14 +478,6 @@ rw_lock_debug_print( ...@@ -488,14 +478,6 @@ rw_lock_debug_print(
rw_lock_debug_t* info); /* in: debug struct */ rw_lock_debug_t* info); /* in: debug struct */
#endif /* UNIV_SYNC_DEBUG */ #endif /* UNIV_SYNC_DEBUG */
#ifndef INNODB_RW_LOCKS_USE_ATOMICS
#error INNODB_RW_LOCKS_USE_ATOMICS is not defined. Do you use enough new GCC or compatibles?
#error Or do you use exact options for CFLAGS?
#error e.g. (for x86_32): "-m32 -march=i586 -mtune=i686"
#error e.g. (for Sparc_64): "-m64 -mcpu=v9"
#error Otherwise, this build may be slower than normal version.
#endif
/* NOTE! The structure appears here only for the compiler to know its size. /* NOTE! The structure appears here only for the compiler to know its size.
Do not use its fields directly! The structure used in the spin lock Do not use its fields directly! The structure used in the spin lock
implementation of a read-write lock. Several threads may have a shared lock implementation of a read-write lock. Several threads may have a shared lock
...@@ -507,16 +489,7 @@ no new readers will be let in while the thread waits for readers to exit. */ ...@@ -507,16 +489,7 @@ no new readers will be let in while the thread waits for readers to exit. */
struct rw_lock_struct { struct rw_lock_struct {
volatile lint lock_word; volatile lint lock_word;
/* Holds the state of the lock. */ /* Holds the state of the lock. */
#ifdef INNODB_RW_LOCKS_USE_ATOMICS
volatile ulint s_waiters; /* 1: there are waiters (s_lock) */
volatile ulint x_waiters; /* 1: there are waiters (x_lock) */
volatile ulint wait_ex_waiters; /* 1: there are waiters (wait_ex) */
volatile ulint reader_count; /* Number of readers who have locked this
lock in the shared mode */
volatile ulint writer;
#else
volatile ulint waiters;/* 1: there are waiters */ volatile ulint waiters;/* 1: there are waiters */
#endif
volatile ibool recursive;/* Default value FALSE which means the lock volatile ibool recursive;/* Default value FALSE which means the lock
is non-recursive. The value is typically set is non-recursive. The value is typically set
to TRUE making normal rw_locks recursive. In to TRUE making normal rw_locks recursive. In
...@@ -533,16 +506,7 @@ struct rw_lock_struct { ...@@ -533,16 +506,7 @@ struct rw_lock_struct {
/* Thread id of writer thread. Is only /* Thread id of writer thread. Is only
guaranteed to have sane and non-stale guaranteed to have sane and non-stale
value iff recursive flag is set. */ value iff recursive flag is set. */
#ifdef INNODB_RW_LOCKS_USE_ATOMICS
volatile ulint writer_count; /* Number of times the same thread has
recursively locked the lock in the exclusive
mode */
/* Used by sync0arr.c for thread queueing */
os_event_t s_event; /* Used for s_lock */
os_event_t x_event; /* Used for x_lock */
#else
os_event_t event; /* Used by sync0arr.c for thread queueing */ os_event_t event; /* Used by sync0arr.c for thread queueing */
#endif
os_event_t wait_ex_event; os_event_t wait_ex_event;
/* Event for next-writer to wait on. A thread /* Event for next-writer to wait on. A thread
must decrement lock_word before waiting. */ must decrement lock_word before waiting. */
...@@ -564,7 +528,7 @@ struct rw_lock_struct { ...@@ -564,7 +528,7 @@ struct rw_lock_struct {
/* last s-lock file/line is not guaranteed to be correct */ /* last s-lock file/line is not guaranteed to be correct */
const char* last_s_file_name;/* File name where last s-locked */ const char* last_s_file_name;/* File name where last s-locked */
const char* last_x_file_name;/* File name where last x-locked */ const char* last_x_file_name;/* File name where last x-locked */
volatile ibool writer_is_wait_ex; ibool writer_is_wait_ex;
/* This is TRUE if the writer field is /* This is TRUE if the writer field is
RW_LOCK_WAIT_EX; this field is located far RW_LOCK_WAIT_EX; this field is located far
from the memory update hotspot fields which from the memory update hotspot fields which
......
This diff is collapsed.
...@@ -35,7 +35,7 @@ Created 1/20/1994 Heikki Tuuri ...@@ -35,7 +35,7 @@ Created 1/20/1994 Heikki Tuuri
#define INNODB_VERSION_MAJOR 1 #define INNODB_VERSION_MAJOR 1
#define INNODB_VERSION_MINOR 0 #define INNODB_VERSION_MINOR 0
#define INNODB_VERSION_BUGFIX 3 #define INNODB_VERSION_BUGFIX 3
#define PERCONA_INNODB_VERSION 3 #define PERCONA_INNODB_VERSION 5
/* The following is the InnoDB version as shown in /* The following is the InnoDB version as shown in
SELECT plugin_version FROM information_schema.plugins; SELECT plugin_version FROM information_schema.plugins;
......
...@@ -12,8 +12,3 @@ If by any chance Makefile.in and ./configure are regenerated and thus ...@@ -12,8 +12,3 @@ If by any chance Makefile.in and ./configure are regenerated and thus
the hack from Makefile.in wiped away then the "real" check from plug.in the hack from Makefile.in wiped away then the "real" check from plug.in
will take over. will take over.
*/ */
/* This is temprary fix for http://bugs.mysql.com/43740 */
/* force to enable */
#ifdef HAVE_GCC_ATOMIC_BUILTINS
#define HAVE_ATOMIC_PTHREAD_T
#endif
...@@ -46,6 +46,13 @@ t1 CREATE TABLE `t1` ( ...@@ -46,6 +46,13 @@ t1 CREATE TABLE `t1` (
KEY `d2` (`d`), KEY `d2` (`d`),
KEY `b` (`b`) KEY `b` (`b`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
CREATE TABLE `t1#1`(a INT PRIMARY KEY) ENGINE=InnoDB;
alter table t1 add unique index (c), add index (d);
ERROR HY000: Table 'test.t1#1' already exists
rename table `t1#1` to `t1#2`;
alter table t1 add unique index (c), add index (d);
ERROR HY000: Table 'test.t1#2' already exists
drop table `t1#2`;
alter table t1 add unique index (c), add index (d); alter table t1 add unique index (c), add index (d);
show create table t1; show create table t1;
Table Create Table Table Create Table
......
...@@ -17,6 +17,16 @@ show create table t1; ...@@ -17,6 +17,16 @@ show create table t1;
alter table t1 add index (b); alter table t1 add index (b);
show create table t1; show create table t1;
# Check how existing tables interfere with temporary tables.
CREATE TABLE `t1#1`(a INT PRIMARY KEY) ENGINE=InnoDB;
--error 156
alter table t1 add unique index (c), add index (d);
rename table `t1#1` to `t1#2`;
--error 156
alter table t1 add unique index (c), add index (d);
drop table `t1#2`;
alter table t1 add unique index (c), add index (d); alter table t1 add unique index (c), add index (d);
show create table t1; show create table t1;
explain select * from t1 force index(c) order by c; explain select * from t1 force index(c) order by c;
......
...@@ -30,4 +30,3 @@ ALTER TABLE bug34300 ADD COLUMN (f10 INT); ...@@ -30,4 +30,3 @@ ALTER TABLE bug34300 ADD COLUMN (f10 INT);
SELECT f4, f8 FROM bug34300; SELECT f4, f8 FROM bug34300;
DROP TABLE bug34300; DROP TABLE bug34300;
SET @@global.max_allowed_packet=1048576;
set @old_innodb_file_per_table=@@innodb_file_per_table;
set @old_innodb_file_format=@@innodb_file_format;
set @old_innodb_file_format_check=@@innodb_file_format_check;
SET GLOBAL innodb_file_format='Barracuda'; SET GLOBAL innodb_file_format='Barracuda';
SET GLOBAL innodb_file_per_table=ON; SET GLOBAL innodb_file_per_table=ON;
...@@ -4,9 +4,6 @@ ...@@ -4,9 +4,6 @@
# #
-- source include/have_innodb.inc -- source include/have_innodb.inc
set @old_innodb_file_per_table=@@innodb_file_per_table;
set @old_innodb_file_format=@@innodb_file_format;
set @old_innodb_file_format_check=@@innodb_file_format_check;
SET GLOBAL innodb_file_format='Barracuda'; SET GLOBAL innodb_file_format='Barracuda';
SET GLOBAL innodb_file_per_table=ON; SET GLOBAL innodb_file_per_table=ON;
...@@ -1156,7 +1153,3 @@ DROP TABLE IF EXISTS table4; ...@@ -1156,7 +1153,3 @@ DROP TABLE IF EXISTS table4;
DROP TABLE IF EXISTS table5; DROP TABLE IF EXISTS table5;
DROP TABLE IF EXISTS table6; DROP TABLE IF EXISTS table6;
set global innodb_file_per_table=@old_innodb_file_per_table;
set global innodb_file_format=@old_innodb_file_format;
set global innodb_file_format_check=@old_innodb_file_format_check;
...@@ -13,9 +13,6 @@ SET storage_engine=InnoDB; ...@@ -13,9 +13,6 @@ SET storage_engine=InnoDB;
-- disable_query_log -- disable_query_log
-- disable_result_log -- disable_result_log
set @old_innodb_file_per_table=@@innodb_file_per_table;
set @old_innodb_file_format=@@innodb_file_format;
set @old_innodb_file_format_check=@@innodb_file_format_check;
SET GLOBAL innodb_file_format='Barracuda'; SET GLOBAL innodb_file_format='Barracuda';
SET GLOBAL innodb_file_per_table=on; SET GLOBAL innodb_file_per_table=on;
...@@ -27,7 +24,3 @@ CHECK TABLE table0 EXTENDED; ...@@ -27,7 +24,3 @@ CHECK TABLE table0 EXTENDED;
INSERT IGNORE INTO `table0` SET `col19` = '19940127002709', `col20` = 2383927.9055146948, `col21` = 4293243420.5621204000, `col22` = '20511211123705', `col23` = 4289899778.6573381000, `col24` = 4293449279.0540481000, `col25` = 'emphysemic', `col26` = 'dentally', `col27` = '2347406', `col28` = 'eruct', `col30` = 1222, `col31` = 4294372994.9941406000, `col32` = 4291385574.1173744000, `col33` = 'borrowing\'s', `col34` = 'septics', `col35` = 'ratter\'s', `col36` = 'Kaye', `col37` = 'Florentia', `col38` = 'allium', `col39` = 'barkeep', `col40` = '19510407003441', `col41` = 4293559200.4215522000, `col42` = 22482, `col43` = 'decussate', `col44` = 'Brom\'s', `col45` = 'violated', `col46` = 4925506.4635456400, `col47` = 930549, `col48` = '51296066', `col49` = 'voluminously', `col50` = '29306676', `col51` = -88, `col52` = -2153690, `col53` = 4290250202.1464887000, `col54` = 'expropriation', `col55` = 'Aberdeen\'s', `col56` = 20343, `col58` = '19640415171532', `col59` = 'extern', `col60` = 'Ubana', `col61` = 4290487961.8539081000, `col62` = '2147', `col63` = -24271, `col64` = '20750801194548', `col65` = 'Cunaxa\'s', `col66` = 'pasticcio', `col67` = 2795817, `col68` = 'Indore\'s', `col70` = 6864127, `col71` = '1817832', `col72` = '20540506114211', `col73` = '20040101012300', `col74` = 'rationalized', `col75` = '45522', `col76` = 'indene', `col77` = -6964559, `col78` = 4247535.5266884370, `col79` = '20720416124357', `col80` = '2143', `col81` = 4292060102.4466386000, `col82` = 'striving', `col83` = 'boneblack\'s', `col84` = 'redolent', `col85` = 6489697.9009369183, `col86` = 4287473465.9731131000, `col87` = 7726015, `col88` = 'perplexed', `col89` = '17153791', `col90` = 5478587.1108127078, `col91` = 4287091404.7004304000, `col92` = 'Boulez\'s', `col93` = '2931278'; INSERT IGNORE INTO `table0` SET `col19` = '19940127002709', `col20` = 2383927.9055146948, `col21` = 4293243420.5621204000, `col22` = '20511211123705', `col23` = 4289899778.6573381000, `col24` = 4293449279.0540481000, `col25` = 'emphysemic', `col26` = 'dentally', `col27` = '2347406', `col28` = 'eruct', `col30` = 1222, `col31` = 4294372994.9941406000, `col32` = 4291385574.1173744000, `col33` = 'borrowing\'s', `col34` = 'septics', `col35` = 'ratter\'s', `col36` = 'Kaye', `col37` = 'Florentia', `col38` = 'allium', `col39` = 'barkeep', `col40` = '19510407003441', `col41` = 4293559200.4215522000, `col42` = 22482, `col43` = 'decussate', `col44` = 'Brom\'s', `col45` = 'violated', `col46` = 4925506.4635456400, `col47` = 930549, `col48` = '51296066', `col49` = 'voluminously', `col50` = '29306676', `col51` = -88, `col52` = -2153690, `col53` = 4290250202.1464887000, `col54` = 'expropriation', `col55` = 'Aberdeen\'s', `col56` = 20343, `col58` = '19640415171532', `col59` = 'extern', `col60` = 'Ubana', `col61` = 4290487961.8539081000, `col62` = '2147', `col63` = -24271, `col64` = '20750801194548', `col65` = 'Cunaxa\'s', `col66` = 'pasticcio', `col67` = 2795817, `col68` = 'Indore\'s', `col70` = 6864127, `col71` = '1817832', `col72` = '20540506114211', `col73` = '20040101012300', `col74` = 'rationalized', `col75` = '45522', `col76` = 'indene', `col77` = -6964559, `col78` = 4247535.5266884370, `col79` = '20720416124357', `col80` = '2143', `col81` = 4292060102.4466386000, `col82` = 'striving', `col83` = 'boneblack\'s', `col84` = 'redolent', `col85` = 6489697.9009369183, `col86` = 4287473465.9731131000, `col87` = 7726015, `col88` = 'perplexed', `col89` = '17153791', `col90` = 5478587.1108127078, `col91` = 4287091404.7004304000, `col92` = 'Boulez\'s', `col93` = '2931278';
CHECK TABLE table0 EXTENDED; CHECK TABLE table0 EXTENDED;
DROP TABLE table0; DROP TABLE table0;
set global innodb_file_per_table=@old_innodb_file_per_table;
set global innodb_file_format=@old_innodb_file_format;
set global innodb_file_format_check=@old_innodb_file_format_check;
set @old_innodb_file_per_table=@@innodb_file_per_table;
set @old_innodb_file_format=@@innodb_file_format;
set @old_innodb_file_format_check=@@innodb_file_format_check;
SET GLOBAL innodb_file_format='Barracuda'; SET GLOBAL innodb_file_format='Barracuda';
SET GLOBAL innodb_file_per_table=ON; SET GLOBAL innodb_file_per_table=ON;
-- source include/have_innodb.inc -- source include/have_innodb.inc
set @old_innodb_file_per_table=@@innodb_file_per_table;
set @old_innodb_file_format=@@innodb_file_format;
set @old_innodb_file_format_check=@@innodb_file_format_check;
SET GLOBAL innodb_file_format='Barracuda'; SET GLOBAL innodb_file_format='Barracuda';
SET GLOBAL innodb_file_per_table=ON; SET GLOBAL innodb_file_per_table=ON;
...@@ -39,7 +36,3 @@ DROP PROCEDURE insert_many; ...@@ -39,7 +36,3 @@ DROP PROCEDURE insert_many;
ALTER TABLE test1 ENGINE=MyISAM; ALTER TABLE test1 ENGINE=MyISAM;
DROP TABLE test1; DROP TABLE test1;
set global innodb_file_per_table=@old_innodb_file_per_table;
set global innodb_file_format=@old_innodb_file_format;
set global innodb_file_format_check=@old_innodb_file_format_check;
--- mysql-test/r/information_schema.result.orig 2009-04-16 19:59:13.000000000 +0000 --- mysql-test/r/information_schema.result.orig 2009-01-31 03:38:50.000000000 +0200
+++ mysql-test/r/information_schema.result 2009-04-16 20:00:16.000000000 +0000 +++ mysql-test/r/information_schema.result 2009-01-31 07:51:58.000000000 +0200
@@ -71,6 +71,18 @@ @@ -71,6 +71,13 @@
TRIGGERS TRIGGERS
USER_PRIVILEGES USER_PRIVILEGES
VIEWS VIEWS
+INNODB_BUFFER_POOL_PAGES_INDEX
+INNODB_RSEG
+INNODB_LOCKS
+INNODB_BUFFER_POOL_PAGES
+XTRADB_ENHANCEMENTS
+INNODB_TRX
+INNODB_BUFFER_POOL_PAGES_BLOB
+INNODB_LOCK_WAITS
+INNODB_CMP_RESET +INNODB_CMP_RESET
+INNODB_CMP +INNODB_TRX
+INNODB_CMPMEM_RESET +INNODB_CMPMEM_RESET
+INNODB_LOCK_WAITS
+INNODB_CMPMEM +INNODB_CMPMEM
+INNODB_CMP
+INNODB_LOCKS
columns_priv columns_priv
db db
event event
@@ -799,6 +811,8 @@ @@ -799,6 +806,8 @@
TABLES UPDATE_TIME datetime TABLES UPDATE_TIME datetime
TABLES CHECK_TIME datetime TABLES CHECK_TIME datetime
TRIGGERS CREATED datetime TRIGGERS CREATED datetime
...@@ -28,92 +23,102 @@ ...@@ -28,92 +23,102 @@
event execute_at datetime event execute_at datetime
event last_executed datetime event last_executed datetime
event starts datetime event starts datetime
@@ -847,12 +861,13 @@ @@ -852,7 +861,7 @@
TABLE_CONSTRAINTS TABLE_NAME select
TABLE_PRIVILEGES TABLE_NAME select
VIEWS TABLE_NAME select
+INNODB_BUFFER_POOL_PAGES_INDEX table_name select
delete from mysql.user where user='mysqltest_4';
delete from mysql.db where user='mysqltest_4';
flush privileges; flush privileges;
SELECT table_schema, count(*) FROM information_schema.TABLES WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test', 'mysqltest') AND table_name<>'ndb_binlog_index' AND table_name<>'ndb_apply_status' GROUP BY TABLE_SCHEMA; SELECT table_schema, count(*) FROM information_schema.TABLES WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test', 'mysqltest') AND table_name<>'ndb_binlog_index' AND table_name<>'ndb_apply_status' GROUP BY TABLE_SCHEMA;
table_schema count(*) table_schema count(*)
-information_schema 28 -information_schema 28
+information_schema 40 +information_schema 35
mysql 22 mysql 22
create table t1 (i int, j int); create table t1 (i int, j int);
create trigger trg1 before insert on t1 for each row create trigger trg1 before insert on t1 for each row
@@ -1267,6 +1282,18 @@ @@ -1267,6 +1276,13 @@
TRIGGERS TRIGGER_SCHEMA TRIGGERS TRIGGER_SCHEMA
USER_PRIVILEGES GRANTEE USER_PRIVILEGES GRANTEE
VIEWS TABLE_SCHEMA VIEWS TABLE_SCHEMA
+INNODB_BUFFER_POOL_PAGES_INDEX schema_name
+INNODB_RSEG rseg_id
+INNODB_LOCKS lock_id
+INNODB_BUFFER_POOL_PAGES page_type
+XTRADB_ENHANCEMENTS name
+INNODB_TRX trx_id
+INNODB_BUFFER_POOL_PAGES_BLOB space_id
+INNODB_LOCK_WAITS requesting_trx_id
+INNODB_CMP_RESET page_size +INNODB_CMP_RESET page_size
+INNODB_CMP page_size +INNODB_TRX trx_id
+INNODB_CMPMEM_RESET page_size +INNODB_CMPMEM_RESET page_size
+INNODB_LOCK_WAITS requesting_trx_id
+INNODB_CMPMEM page_size +INNODB_CMPMEM page_size
+INNODB_CMP page_size
+INNODB_LOCKS lock_id
SELECT t.table_name, c1.column_name SELECT t.table_name, c1.column_name
FROM information_schema.tables t FROM information_schema.tables t
INNER JOIN INNER JOIN
@@ -1310,14 +1337,26 @@ @@ -1310,6 +1326,13 @@
TRIGGERS TRIGGER_SCHEMA TRIGGERS TRIGGER_SCHEMA
USER_PRIVILEGES GRANTEE USER_PRIVILEGES GRANTEE
VIEWS TABLE_SCHEMA VIEWS TABLE_SCHEMA
+INNODB_BUFFER_POOL_PAGES_INDEX schema_name
+INNODB_RSEG rseg_id
+INNODB_LOCKS lock_id
+INNODB_BUFFER_POOL_PAGES page_type
+XTRADB_ENHANCEMENTS name
+INNODB_TRX trx_id
+INNODB_BUFFER_POOL_PAGES_BLOB space_id
+INNODB_LOCK_WAITS requesting_trx_id
+INNODB_CMP_RESET page_size +INNODB_CMP_RESET page_size
+INNODB_CMP page_size +INNODB_TRX trx_id
+INNODB_CMPMEM_RESET page_size +INNODB_CMPMEM_RESET page_size
+INNODB_LOCK_WAITS requesting_trx_id
+INNODB_CMPMEM page_size +INNODB_CMPMEM page_size
+INNODB_CMP page_size
+INNODB_LOCKS lock_id
SELECT MAX(table_name) FROM information_schema.tables WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test'); SELECT MAX(table_name) FROM information_schema.tables WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test');
MAX(table_name) MAX(table_name)
-VIEWS VIEWS
+XTRADB_ENHANCEMENTS @@ -1386,6 +1409,13 @@
SELECT table_name from information_schema.tables
WHERE table_name=(SELECT MAX(table_name)
FROM information_schema.tables WHERE table_schema IN ('mysql', 'INFORMATION_SCHEMA', 'test'));
table_name
-VIEWS
+XTRADB_ENHANCEMENTS
DROP TABLE IF EXISTS bug23037;
DROP FUNCTION IF EXISTS get_value;
SELECT COLUMN_NAME, MD5(COLUMN_DEFAULT), LENGTH(COLUMN_DEFAULT) FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME='bug23037';
@@ -1386,6 +1425,17 @@
FILES information_schema.FILES 1 FILES information_schema.FILES 1
GLOBAL_STATUS information_schema.GLOBAL_STATUS 1 GLOBAL_STATUS information_schema.GLOBAL_STATUS 1
GLOBAL_VARIABLES information_schema.GLOBAL_VARIABLES 1 GLOBAL_VARIABLES information_schema.GLOBAL_VARIABLES 1
+INNODB_BUFFER_POOL_PAGES information_schema.INNODB_BUFFER_POOL_PAGES 1
+INNODB_BUFFER_POOL_PAGES_BLOB information_schema.INNODB_BUFFER_POOL_PAGES_BLOB 1
+INNODB_BUFFER_POOL_PAGES_INDEX information_schema.INNODB_BUFFER_POOL_PAGES_INDEX 1
+INNODB_CMP information_schema.INNODB_CMP 1 +INNODB_CMP information_schema.INNODB_CMP 1
+INNODB_CMPMEM information_schema.INNODB_CMPMEM 1 +INNODB_CMPMEM information_schema.INNODB_CMPMEM 1
+INNODB_CMPMEM_RESET information_schema.INNODB_CMPMEM_RESET 1 +INNODB_CMPMEM_RESET information_schema.INNODB_CMPMEM_RESET 1
+INNODB_CMP_RESET information_schema.INNODB_CMP_RESET 1 +INNODB_CMP_RESET information_schema.INNODB_CMP_RESET 1
+INNODB_LOCKS information_schema.INNODB_LOCKS 1 +INNODB_LOCKS information_schema.INNODB_LOCKS 1
+INNODB_LOCK_WAITS information_schema.INNODB_LOCK_WAITS 1 +INNODB_LOCK_WAITS information_schema.INNODB_LOCK_WAITS 1
+INNODB_RSEG information_schema.INNODB_RSEG 1
+INNODB_TRX information_schema.INNODB_TRX 1 +INNODB_TRX information_schema.INNODB_TRX 1
KEY_COLUMN_USAGE information_schema.KEY_COLUMN_USAGE 1 KEY_COLUMN_USAGE information_schema.KEY_COLUMN_USAGE 1
PARTITIONS information_schema.PARTITIONS 1 PARTITIONS information_schema.PARTITIONS 1
PLUGINS information_schema.PLUGINS 1 PLUGINS information_schema.PLUGINS 1
@@ -1404,6 +1454,7 @@ diff mysql-test/r/information_schema_db.result.orig mysql-test/r/information_schema_db.result
TRIGGERS information_schema.TRIGGERS 1 --- mysql-test/r/information_schema_db.result.orig 2008-08-04 09:27:49.000000000 +0300
USER_PRIVILEGES information_schema.USER_PRIVILEGES 1 +++ mysql-test/r/information_schema_db.result 2008-10-07 12:26:31.000000000 +0300
VIEWS information_schema.VIEWS 1 @@ -33,6 +33,13 @@
+XTRADB_ENHANCEMENTS information_schema.XTRADB_ENHANCEMENTS 1 TRIGGERS
create table t1(f1 int); USER_PRIVILEGES
create view v1 as select f1+1 as a from t1; VIEWS
create table t2 (f1 int, f2 int); +INNODB_CMP_RESET
+INNODB_TRX
+INNODB_CMPMEM_RESET
+INNODB_LOCK_WAITS
+INNODB_CMPMEM
+INNODB_CMP
+INNODB_LOCKS
show tables from INFORMATION_SCHEMA like 'T%';
Tables_in_information_schema (T%)
TABLES
diff mysql-test/r/mysqlshow.result.orig mysql-test/r/mysqlshow.result
--- mysql-test/r/mysqlshow.result.orig 2008-08-04 09:27:51.000000000 +0300
+++ mysql-test/r/mysqlshow.result 2008-10-07 12:35:39.000000000 +0300
@@ -107,6 +107,13 @@
| TRIGGERS |
| USER_PRIVILEGES |
| VIEWS |
+| INNODB_CMP_RESET |
+| INNODB_TRX |
+| INNODB_CMPMEM_RESET |
+| INNODB_LOCK_WAITS |
+| INNODB_CMPMEM |
+| INNODB_CMP |
+| INNODB_LOCKS |
+---------------------------------------+
Database: INFORMATION_SCHEMA
+---------------------------------------+
@@ -140,6 +147,13 @@
| TRIGGERS |
| USER_PRIVILEGES |
| VIEWS |
+| INNODB_CMP_RESET |
+| INNODB_TRX |
+| INNODB_CMPMEM_RESET |
+| INNODB_LOCK_WAITS |
+| INNODB_CMPMEM |
+| INNODB_CMP |
+| INNODB_LOCKS |
+---------------------------------------+
Wildcard: inf_rmation_schema
+--------------------+
--- mysql-test/t/innodb-index.test.orig 2009-04-16 22:12:38.000000000 +0000 This part of the innodb-index test causes mysqld to print some warnings
+++ mysql-test/t/innodb-index.test 2009-04-16 22:16:58.000000000 +0000 and subsequently the whole mysql-test suite to fail.
@@ -344,6 +344,11 @@
A permanent solution is probably to remove the printouts from the source
let $per_table=`select @@innodb_file_per_table`; code or to somehow tell the mysql-test suite that warnings are expected.
let $format=`select @@innodb_file_format`; Currently we simply do not execute the problematic tests. Please
+ coordinate a permanent solution with Marko, who added those tests.
+set @old_innodb_file_per_table=@@innodb_file_per_table;
+set @old_innodb_file_format=@@innodb_file_format; This cannot be proposed to MySQL because it touches files that are not
+set @old_innodb_file_format_check=@@innodb_file_format_check; in the MySQL source repository.
+
set global innodb_file_per_table=on; Index: storage/innobase/mysql-test/innodb-index.result
set global innodb_file_format='Barracuda'; ===================================================================
# Test creating a table that could lead to undo log overflow. --- storage/innobase/mysql-test/innodb-index.result (revision 2870)
@@ -499,3 +504,8 @@ +++ storage/innobase/mysql-test/innodb-index.result (working copy)
@@ -43,19 +43,12 @@ t1 CREATE TABLE `t1` (
DROP TABLE t2; `b` int(11) DEFAULT NULL,
DROP TABLE t1; `c` char(10) NOT NULL,
+ `d` varchar(20) DEFAULT NULL,
+set global innodb_file_per_table=@old_innodb_file_per_table; KEY `d2` (`d`),
+set global innodb_file_format=@old_innodb_file_format; KEY `b` (`b`)
+set global innodb_file_format_check=@old_innodb_file_format_check;
+
--- mysql-test/r/innodb-index.result.orig 2009-04-16 22:18:18.000000000 +0000
+++ mysql-test/r/innodb-index.result 2009-04-16 22:18:47.000000000 +0000
@@ -877,6 +877,9 @@
44
commit;
drop table t1;
+set @old_innodb_file_per_table=@@innodb_file_per_table;
+set @old_innodb_file_format=@@innodb_file_format;
+set @old_innodb_file_format_check=@@innodb_file_format_check;
set global innodb_file_per_table=on;
set global innodb_file_format='Barracuda';
create table t1(a blob,b blob,c blob,d blob,e blob,f blob,g blob,h blob,
@@ -1125,3 +1128,6 @@
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
DROP TABLE t2; -CREATE TABLE `t1#1`(a INT PRIMARY KEY) ENGINE=InnoDB;
DROP TABLE t1; -alter table t1 add unique index (c), add index (d);
+set global innodb_file_per_table=@old_innodb_file_per_table; -ERROR HY000: Table 'test.t1#1' already exists
+set global innodb_file_format=@old_innodb_file_format; -rename table `t1#1` to `t1#2`;
+set global innodb_file_format_check=@old_innodb_file_format_check; -alter table t1 add unique index (c), add index (d);
-ERROR HY000: Table 'test.t1#2' already exists
-drop table `t1#2`;
alter table t1 add unique index (c), add index (d);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL,
`b` int(11) DEFAULT NULL,
Index: storage/innobase/mysql-test/innodb-index.test
===================================================================
--- storage/innobase/mysql-test/innodb-index.test (revision 2870)
+++ storage/innobase/mysql-test/innodb-index.test (working copy)
@@ -14,22 +14,12 @@ select * from t1 force index (d2) order
--error ER_DUP_ENTRY
alter table t1 add unique index (b);
show create table t1;
alter table t1 add index (b);
show create table t1;
-# Check how existing tables interfere with temporary tables.
-CREATE TABLE `t1#1`(a INT PRIMARY KEY) ENGINE=InnoDB;
-
---error 156
-alter table t1 add unique index (c), add index (d);
-rename table `t1#1` to `t1#2`;
---error 156
-alter table t1 add unique index (c), add index (d);
-drop table `t1#2`;
-
alter table t1 add unique index (c), add index (d);
show create table t1;
explain select * from t1 force index(c) order by c;
alter table t1 add primary key (a), drop index c;
show create table t1;
--error ER_MULTIPLE_PRI_KEY
...@@ -331,15 +331,8 @@ sync_cell_get_event( ...@@ -331,15 +331,8 @@ sync_cell_get_event(
return(((mutex_t *) cell->wait_object)->event); return(((mutex_t *) cell->wait_object)->event);
} else if (type == RW_LOCK_WAIT_EX) { } else if (type == RW_LOCK_WAIT_EX) {
return(((rw_lock_t *) cell->wait_object)->wait_ex_event); return(((rw_lock_t *) cell->wait_object)->wait_ex_event);
#ifdef INNODB_RW_LOCKS_USE_ATOMICS
} else if (type == RW_LOCK_SHARED) {
return(((rw_lock_t *) cell->wait_object)->s_event);
} else { /* RW_LOCK_EX */
return(((rw_lock_t *) cell->wait_object)->x_event);
#else
} else { /* RW_LOCK_SHARED and RW_LOCK_EX wait on the same event */ } else { /* RW_LOCK_SHARED and RW_LOCK_EX wait on the same event */
return(((rw_lock_t *) cell->wait_object)->event); return(((rw_lock_t *) cell->wait_object)->event);
#endif
} }
} }
...@@ -510,7 +503,7 @@ sync_array_cell_print( ...@@ -510,7 +503,7 @@ sync_array_cell_print(
|| type == RW_LOCK_WAIT_EX || type == RW_LOCK_WAIT_EX
|| type == RW_LOCK_SHARED) { || type == RW_LOCK_SHARED) {
fputs(type == RW_LOCK_SHARED ? "S-lock on" : "X-lock on", file); fputs(type == RW_LOCK_EX ? "X-lock on" : "S-lock on", file);
rwlock = cell->old_wait_rw_lock; rwlock = cell->old_wait_rw_lock;
...@@ -530,21 +523,12 @@ sync_array_cell_print( ...@@ -530,21 +523,12 @@ sync_array_cell_print(
} }
fprintf(file, fprintf(file,
#ifdef INNODB_RW_LOCKS_USE_ATOMICS
"number of readers %lu, s_waiters flag %lu, x_waiters flag %lu, "
#else
"number of readers %lu, waiters flag %lu, " "number of readers %lu, waiters flag %lu, "
#endif
"lock_word: %lx\n" "lock_word: %lx\n"
"Last time read locked in file %s line %lu\n" "Last time read locked in file %s line %lu\n"
"Last time write locked in file %s line %lu\n", "Last time write locked in file %s line %lu\n",
(ulong) rw_lock_get_reader_count(rwlock), (ulong) rw_lock_get_reader_count(rwlock),
#ifdef INNODB_RW_LOCKS_USE_ATOMICS
(ulong) rwlock->s_waiters,
(ulong) (rwlock->x_waiters || rwlock->wait_ex_waiters),
#else
(ulong) rwlock->waiters, (ulong) rwlock->waiters,
#endif
rwlock->lock_word, rwlock->lock_word,
rwlock->last_s_file_name, rwlock->last_s_file_name,
(ulong) rwlock->last_s_line, (ulong) rwlock->last_s_line,
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment