An error occurred fetching the project authors.
- 01 Aug, 2007 1 commit
-
-
unknown authored
Marko after applying latest snapshot). storage/innobase/handler/ha_innodb.cc: Remove redundant assignment to thd_to_trx(thd); trx is declared as a reference to thd_to_trx(thd) at the top of the function, so this assignment isn't useful. storage/innobase/include/trx0trx.h: Remove two unused members from struct trx_struct. allow_duplicates and replace_duplicates are not used; a single duplicates member is used instead to represent both flags.
-
- 25 Jul, 2007 1 commit
-
-
unknown authored
Fixes: - Bug #23710: crash_commit_before fails if innodb_file_per_table=1 - Bug #28254: innodb crash if shutdown during innodb_table_monitor is running - Bug #28604: innodb_force_recovery restricts data dump - Bug #29097: fsp_get_available_space_in_free_extents() is capped at 4TB - Bug #29155: Innodb "Parallel recovery" is not prevented storage/innobase/Makefile.am: Apply snapshot innodb-51-ss1644 Revision r1632: Add include/lock0priv.h to noinst_HEADERS in Makefile.am. Revision r1636: Move lock_get_type() from lock/lock0lock.c to include/lock0priv.ic: * lock0lock.c: remove lock_get_type() and include include/lock0priv.ic * lock0priv.h: include lock0priv.ic and add lock_get_type() prototype * Makefile.am: add lock0priv.ic to noinst_HEADERS * lock0priv.ic: introduce this new file containing the body of lock_get_type() This move is necessary in order to use lock_get_type() from other lock/ source files (it's going to be used in lock/lock0iter.c). Approved by: Heikki Revision r1638: Introduce a lock queue iterator for easy (and opaque) traversing of lock queues. Supports table and record lock queues via the same interface. There is only "get previous" method because currently there is no need for "get next" - it would be unused. Feel free to add one if needed. Approved by: Heikki storage/innobase/buf/buf0buf.c: Apply snapshot innodb-51-ss1644 Revision r1624: Fix change missed as part of Bug 15815. Use a function to check if a block needs to be made younger. Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/buf/buf0lru.c: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/fsp/fsp0fsp.c: Apply snapshot innodb-51-ss1644 Revision r1605: Fix Bug#29097 "fsp_get_available_space_in_free_extents() is capped at 4TB" by typecasting the variables before multiplying them, so that the result of the multiplication is of type "unsigned long long". I verified this fix by creating a sparse file of 6TB and forcing InnoDB to use it without overwriting it with zeroes (by commenting the code that overwrites :newraw files). New type ullint is introduced with the sole purpose of shortening "unsigned long long", please do not define it to something else than "unsigned long long". Approved by: Heikki storage/innobase/handler/ha_innodb.cc: Apply snapshot innodb-51-ss1644 Revision r1605: Fix Bug#29097 "fsp_get_available_space_in_free_extents() is capped at 4TB" by typecasting the variables before multiplying them, so that the result of the multiplication is of type "unsigned long long". I verified this fix by creating a sparse file of 6TB and forcing InnoDB to use it without overwriting it with zeroes (by commenting the code that overwrites :newraw files). New type ullint is introduced with the sole purpose of shortening "unsigned long long", please do not define it to something else than "unsigned long long". Approved by: Heikki Revision r1573: create_table_def(): Eliminate the inline function call to dict_table_is_comp() that was introduced in r1571. Inlining is disabled in ha_innodb.cc. Revision r1574: innodb_check_for_record_too_big_error(): Divide the return value of page_get_free_space_of_empty_noninline() by 2. Until r1571, that function did not return the same value as page_get_free_space_of_empty(). Revision r1571: Fix a severe bug that was introduced in r1422 when fixing Bug 21101. When creating an index containing a too long record, InnoDB would dereference a NULL pointer when trying to determine the maximum row length. innodb_check_for_record_too_big_error(): Replace the dict_table_t* parameter with a Boolean flag. There is not always a dict_table_t object when this function is called. page_get_free_space_of_empty_noninline(): Move the definition and declaration from row0mysql (!) to page0page. Make the signature identical with page_get_free_space_of_empty(). create_clustered_index_when_no_primary(): Add the parameter "comp". Remove unnecessary casts. storage/innobase/include/buf0buf.ic: Apply snapshot innodb-51-ss1644 Revision r1624: Fix change missed as part of Bug 15815. Use a function to check if a block needs to be made younger. storage/innobase/include/fsp0fsp.h: Apply snapshot innodb-51-ss1644 Revision r1605: Fix Bug#29097 "fsp_get_available_space_in_free_extents() is capped at 4TB" by typecasting the variables before multiplying them, so that the result of the multiplication is of type "unsigned long long". I verified this fix by creating a sparse file of 6TB and forcing InnoDB to use it without overwriting it with zeroes (by commenting the code that overwrites :newraw files). New type ullint is introduced with the sole purpose of shortening "unsigned long long", please do not define it to something else than "unsigned long long". Approved by: Heikki storage/innobase/include/lock0lock.h: Apply snapshot innodb-51-ss1644 Revision r1623: Fix typo in comment. Revision r1628: lock_has_to_wait() is needed in the INFORMATION_SCHEMA implementation in order to determine which lock is blocking which. Make it non-static and put its definition in include/lock0lock.h. Approved by: Heikki (via IM) storage/innobase/include/mem0mem.ic: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/include/page0page.h: Apply snapshot innodb-51-ss1644 Revision r1571: Fix a severe bug that was introduced in r1422 when fixing Bug 21101. When creating an index containing a too long record, InnoDB would dereference a NULL pointer when trying to determine the maximum row length. innodb_check_for_record_too_big_error(): Replace the dict_table_t* parameter with a Boolean flag. There is not always a dict_table_t object when this function is called. page_get_free_space_of_empty_noninline(): Move the definition and declaration from row0mysql (!) to page0page. Make the signature identical with page_get_free_space_of_empty(). create_clustered_index_when_no_primary(): Add the parameter "comp". Remove unnecessary casts. storage/innobase/include/row0mysql.h: Apply snapshot innodb-51-ss1644 Revision r1571: Fix a severe bug that was introduced in r1422 when fixing Bug 21101. When creating an index containing a too long record, InnoDB would dereference a NULL pointer when trying to determine the maximum row length. innodb_check_for_record_too_big_error(): Replace the dict_table_t* parameter with a Boolean flag. There is not always a dict_table_t object when this function is called. page_get_free_space_of_empty_noninline(): Move the definition and declaration from row0mysql (!) to page0page. Make the signature identical with page_get_free_space_of_empty(). create_clustered_index_when_no_primary(): Add the parameter "comp". Remove unnecessary casts. storage/innobase/include/univ.i: Apply snapshot innodb-51-ss1644 Revision r1605: Fix Bug#29097 "fsp_get_available_space_in_free_extents() is capped at 4TB" by typecasting the variables before multiplying them, so that the result of the multiplication is of type "unsigned long long". I verified this fix by creating a sparse file of 6TB and forcing InnoDB to use it without overwriting it with zeroes (by commenting the code that overwrites :newraw files). New type ullint is introduced with the sole purpose of shortening "unsigned long long", please do not define it to something else than "unsigned long long". Approved by: Heikki Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/lock/lock0lock.c: Apply snapshot innodb-51-ss1644 Revision r1631: Move lock_rec_find_set_bit() and lock_rec_get_prev() from lock/lock0lock.c to include/lock0priv.h and make them non-static. They will be used in lock/lock0iter.c. Approved by: Heikki Revision r1636: Move lock_get_type() from lock/lock0lock.c to include/lock0priv.ic: * lock0lock.c: remove lock_get_type() and include include/lock0priv.ic * lock0priv.h: include lock0priv.ic and add lock_get_type() prototype * Makefile.am: add lock0priv.ic to noinst_HEADERS * lock0priv.ic: introduce this new file containing the body of lock_get_type() This move is necessary in order to use lock_get_type() from other lock/ source files (it's going to be used in lock/lock0iter.c). Approved by: Heikki Revision r1628: lock_has_to_wait() is needed in the INFORMATION_SCHEMA implementation in order to determine which lock is blocking which. Make it non-static and put its definition in include/lock0lock.h. Approved by: Heikki (via IM) Revision r1629: Add "const" qualifiers to lock_get_type() and lock_get_mode(). Approved by: Sunny Revision r1626: Move lock_*struct structures from lock/lock0lock.c to include/lock0priv.h. This is needed in order to add more code to lock/ that uses members of these structures (internal to the lock module) but in a separate file, rather than lock0lock.c. lock0lock.c is a way too big already. Approved by: Sunny storage/innobase/log/log0recv.c: Apply snapshot innodb-51-ss1644 Revision r1607: Bug#23710 At InnoDB startup consider the case where log scan went beyond checkpoint_lsn as a crash and initiate crash recovery code path. reviewed by: Heikki storage/innobase/mem/mem0mem.c: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/mem/mem0pool.c: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/os/os0file.c: Apply snapshot innodb-51-ss1644 Revision r1613: Fix Bug#29155 by enabling file locking on FreeBSD. It has been disabled because InnoDB has refused to start on FreeBSD & LinuxThreads, but now it starts just fine. Approved by: Heikki storage/innobase/page/page0page.c: Apply snapshot innodb-51-ss1644 Revision r1571: Fix a severe bug that was introduced in r1422 when fixing Bug 21101. When creating an index containing a too long record, InnoDB would dereference a NULL pointer when trying to determine the maximum row length. innodb_check_for_record_too_big_error(): Replace the dict_table_t* parameter with a Boolean flag. There is not always a dict_table_t object when this function is called. page_get_free_space_of_empty_noninline(): Move the definition and declaration from row0mysql (!) to page0page. Make the signature identical with page_get_free_space_of_empty(). create_clustered_index_when_no_primary(): Add the parameter "comp". Remove unnecessary casts. storage/innobase/rem/rem0rec.c: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/row/row0mysql.c: Apply snapshot innodb-51-ss1644 Revision r1571: Fix a severe bug that was introduced in r1422 when fixing Bug 21101. When creating an index containing a too long record, InnoDB would dereference a NULL pointer when trying to determine the maximum row length. innodb_check_for_record_too_big_error(): Replace the dict_table_t* parameter with a Boolean flag. There is not always a dict_table_t object when this function is called. page_get_free_space_of_empty_noninline(): Move the definition and declaration from row0mysql (!) to page0page. Make the signature identical with page_get_free_space_of_empty(). create_clustered_index_when_no_primary(): Add the parameter "comp". Remove unnecessary casts. storage/innobase/sync/sync0rw.c: Apply snapshot innodb-51-ss1644 Revision r1598: Add some comments. Approved by: Heikki (via IM) storage/innobase/sync/sync0sync.c: Apply snapshot innodb-51-ss1644 Revision r1598: Add some comments. Approved by: Heikki (via IM) storage/innobase/trx/trx0sys.c: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip. storage/innobase/trx/trx0trx.c: Apply snapshot innodb-51-ss1644 Revision r1595: trx_commit_for_mysql(): Avoid acquiring and releasing kernel_mutex when trx->sess or trx_dummy_sess is non-NULL. storage/innobase/ut/ut0mem.c: Apply snapshot innodb-51-ss1644 Revision r1581: Port extra Valgrind instrumentation (UNIV_DEBUG_VALGRIND) from branches/zip.
-
- 10 Jul, 2007 1 commit
-
-
unknown authored
After applying the snapshots, ensure that code conforms to the final version of WL 3914. It is signficant that, after these changes, InnoDB does not define MYSQL_SERVER, and can be built as an independent storage engine plugin. Fixes: Bug#9709: InnoDB inconsistensy causes "Operating System Error 32/33" Bug#18828: If InnoDB runs out of undo slots, it returns misleading 'table is full' Bug#20090: InnoDB: Error: trying to declare trx to enter InnoDB Bug#20352: Make ibuf_contract_for_n_pages tunable Bug#21101: Wrong error on exceeding max row size for InnoDB table Bug#21293: Deadlock detection prefers to kill long running FOR UPDATE queries Bug#22819: SHOW INNODB STATUS crashes the server with an assertion failure under high load Bug#25078: Make the replication thread to ignore innodb_thread_concurrency Bug#25645: Assertion failure in file srv0srv.c Bug#28138: indexing column prefixes produces corruption in InnoDB BitKeeper/deleted/.del-Makefile.am~55504c43d99979e4: Delete: storage/innobase/buf/Makefile.am BitKeeper/deleted/.del-Makefile.am~79bb55303929b560: Delete: storage/innobase/dict/Makefile.am BitKeeper/deleted/.del-Makefile.am~7cd88e5f9a8d7ce8: Delete: storage/innobase/data/Makefile.am BitKeeper/deleted/.del-Makefile.am~e19a1fb29b1fe527: Delete: storage/innobase/btr/Makefile.am BitKeeper/deleted/.del-Makefile.am~4ae65b009d41d1d: Delete: storage/innobase/eval/Makefile.am BitKeeper/deleted/.del-Makefile.am~679131a02af3f6fb: Delete: storage/innobase/fsp/Makefile.am BitKeeper/deleted/.del-Makefile.am~6acac9ae30eabdb3: Delete: storage/innobase/dyn/Makefile.am BitKeeper/deleted/.del-Makefile.am~a5e6b4385717fcb7: Delete: storage/innobase/fil/Makefile.am BitKeeper/deleted/.del-Makefile.am~11d601934b49c19: Delete: storage/innobase/fut/Makefile.am BitKeeper/deleted/.del-Makefile.am~5aab37bf3b6c430: Delete: storage/innobase/ibuf/Makefile.am BitKeeper/deleted/.del-Makefile.am~af2d719bb6e66986: Delete: storage/innobase/handler/Makefile.am BitKeeper/deleted/.del-Makefile.am~f0dbbc7a78648e18: Delete: storage/innobase/ha/Makefile.am BitKeeper/deleted/.del-Makefile.am~41684e54a5b0d26a: Delete: storage/innobase/log/Makefile.am BitKeeper/deleted/.del-Makefile.am~edd95d7290ddeff3: Delete: storage/innobase/lock/Makefile.am BitKeeper/deleted/.del-Makefile.i: Delete: storage/innobase/include/Makefile.i BitKeeper/deleted/.del-Makefile.am~2a6ccdba41b591a3: Delete: storage/innobase/mach/Makefile.am BitKeeper/deleted/.del-Makefile.am~2bd35bda856342: Delete: storage/innobase/os/Makefile.am BitKeeper/deleted/.del-Makefile.am~8448688c5ab92132: Delete: storage/innobase/mem/Makefile.am BitKeeper/deleted/.del-Makefile.am~b5a7a8cfa711b6de: Delete: storage/innobase/mtr/Makefile.am BitKeeper/deleted/.del-Makefile.am~2cee8a309eb8eee2: Delete: storage/innobase/page/Makefile.am BitKeeper/deleted/.del-Makefile.am~3d0553f8aa9c456b: Delete: storage/innobase/read/Makefile.am BitKeeper/deleted/.del-Makefile.am~7b0c4abae6684f8c: Delete: storage/innobase/pars/Makefile.am BitKeeper/deleted/.del-Makefile.am~d0e0dd55cbd413f0: Delete: storage/innobase/que/Makefile.am BitKeeper/deleted/.del-Makefile.am~20a219ccf7825d65: Delete: storage/innobase/row/Makefile.am BitKeeper/deleted/.del-Makefile.am~37bdfb2973b2442b: Delete: storage/innobase/rem/Makefile.am BitKeeper/deleted/.del-Makefile.am~557098c4e5c01ee2: Delete: storage/innobase/thr/Makefile.am BitKeeper/deleted/.del-Makefile.am~fdfe12f48c2499af: Delete: storage/innobase/sync/Makefile.am BitKeeper/deleted/.del-Makefile.am~feb2280a52035d8d: Delete: storage/innobase/srv/Makefile.am BitKeeper/deleted/.del-Makefile.am~456d34c4816dbda4: Delete: storage/innobase/ut/Makefile.am BitKeeper/deleted/.del-Makefile.am~5ec2ef0d2c35e138: Delete: storage/innobase/usr/Makefile.am BitKeeper/deleted/.del-Makefile.am~d25c456e48393313: Delete: storage/innobase/trx/Makefile.am mysql-test/r/innodb.result: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1421: Fix the innodb test by shifting some of the contents of the .result file. Approved by: Marko Revision r1422: Fix for Bug#21101 - returns wrong error message when table column defs exceed the max row size. The fix returns a more appropriate error message. Add a test case to innodb.test and expected output to innodb.result. mysql-test/t/innodb.test: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1422: Fix for Bug#21101 - returns wrong error message when table column defs exceed the max row size. The fix returns a more appropriate error message. Add a test case to innodb.test and expected output to innodb.result. storage/innobase/btr/btr0btr.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1546: When buffering an insert to a prefix index of a variable-length column, do not incorrectly mark the column as fixed-length. (Bug#28138) ibuf_entry_build(): Instead of prefix_len, pass fixed_len to dtype_new_store_for_order_and_null_size(). Add debug assertions. btr_index_rec_validate(): Correct a comment about prefix indexes. rec_get_converted_size_new(), rec_convert_dtuple_to_rec_new(): Add debug assertions and comments. dict_col_type_assert_equal(): New debug function. storage/innobase/data/data0data.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1490: Add #include <ctype.h>. Apparently, this header is no longer included by the common headers. This may be related to WL#2936 (pluggable storage engines). storage/innobase/data/data0type.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko storage/innobase/dict/dict0crea.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. storage/innobase/dict/dict0dict.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1490: Add #include <ctype.h>. Apparently, this header is no longer included by the common headers. This may be related to WL#2936 (pluggable storage engines). Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko Revision r1528: Define an auxiliary macro UT_BITS_IN_BYTES() and use it where possible. Revision r1529: Revert r799, which was supposed to prevent similar cases as Bug#21638. In reality, the patch breaks the handling of prefix indexes of variable-length columns in ROW_FORMAT=COMPACT. Reverting the patch is only a partial fix of Bug#28138. Revision r1535: Document that DICT_MAX_INDEX_COL_LEN must not be changed. storage/innobase/fsp/fsp0fsp.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko Revision r1528: Define an auxiliary macro UT_BITS_IN_BYTES() and use it where possible. storage/innobase/ibuf/ibuf0ibuf.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1420: Output to the error log information about the limitations of UNIV_IBUF_DEBUG. innobase_start_or_create_for_mysql(): Note that crash recovery is broken when UNIV_IBUF_DEBUG is defined. ibuf_counts[]: Make this a two-dimensional array. No need to allocate anything from the heap. Eliminate ibuf_counts_inited, as the array will be zero-filled by the runtime environment. ibuf_count_check(): New function, to print out an explanation before assertion failure. Revision r1528: Define an auxiliary macro UT_BITS_IN_BYTES() and use it where possible. Revision r1546: When buffering an insert to a prefix index of a variable-length column, do not incorrectly mark the column as fixed-length. (Bug#28138) ibuf_entry_build(): Instead of prefix_len, pass fixed_len to dtype_new_store_for_order_and_null_size(). Add debug assertions. btr_index_rec_validate(): Correct a comment about prefix indexes. rec_get_converted_size_new(), rec_convert_dtuple_to_rec_new(): Add debug assertions and comments. dict_col_type_assert_equal(): New debug function. storage/innobase/include/db0err.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. storage/innobase/include/dict0dict.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1546: When buffering an insert to a prefix index of a variable-length column, do not incorrectly mark the column as fixed-length. (Bug#28138) ibuf_entry_build(): Instead of prefix_len, pass fixed_len to dtype_new_store_for_order_and_null_size(). Add debug assertions. btr_index_rec_validate(): Correct a comment about prefix indexes. rec_get_converted_size_new(), rec_convert_dtuple_to_rec_new(): Add debug assertions and comments. dict_col_type_assert_equal(): New debug function. storage/innobase/include/dict0dict.ic: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1546: When buffering an insert to a prefix index of a variable-length column, do not incorrectly mark the column as fixed-length. (Bug#28138) ibuf_entry_build(): Instead of prefix_len, pass fixed_len to dtype_new_store_for_order_and_null_size(). Add debug assertions. btr_index_rec_validate(): Correct a comment about prefix indexes. rec_get_converted_size_new(), rec_convert_dtuple_to_rec_new(): Add debug assertions and comments. dict_col_type_assert_equal(): New debug function. storage/innobase/include/dict0mem.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1535: Document that DICT_MAX_INDEX_COL_LEN must not be changed. Revision r1536: Change the comment to a more appropriate one. Discussed with Heikki on IM. Approved by: Heikki storage/innobase/include/ha_prototypes.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1482: Fix Bug#25078 by always letting the replication thread on the slave server to enter InnoDB. This can be made further customizable by the user if we introduce a new config parameter. This will wait until config parameters can be easily added. Approved by: Marko Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki storage/innobase/include/os0file.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1431: Fix Bug#9709 by retrying (forever) if ERROR_SHARING_VIOLATION or ERROR_LOCK_VIOLATION is encountered during file operation. This is caused by backup software, so InnoDB should retry while the backup software is done with the file. Approved by: Heikki storage/innobase/include/rem0rec.ic: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1569: Fix some in:/out: comments. Approved by: Marko storage/innobase/include/row0mysql.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1422: Fix for Bug#21101 - returns wrong error message when table column defs exceed the max row size. The fix returns a more appropriate error message. Add a test case to innodb.test and expected output to innodb.result. storage/innobase/include/trx0trx.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1462: Fix typo in comment. Revision r1486: Improve the comment for trx_struct::undo_no. Suggested by: Heikki Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1497: Add the number of locks acquired by a transaction to its weight when choosing the lightest transaction to kill when a deadlock occurs. This fixes Bug#21293 partially. Approved by: Heikki Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki storage/innobase/include/trx0undo.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. storage/innobase/include/ut0ut.h: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1528: Define an auxiliary macro UT_BITS_IN_BYTES() and use it where possible. storage/innobase/lock/lock0lock.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1457: Fix Bug#22819, remove assertion. (http://bugs.mysql.com/bug.php?id=22819) Revision r1497: Add the number of locks acquired by a transaction to its weight when choosing the lightest transaction to kill when a deadlock occurs. This fixes Bug#21293 partially. Approved by: Heikki Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko storage/innobase/log/log0log.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1521: Forward port r1520 from branches/5.0 Patch to allow monitor threads to stop before proceeding with normal shutdown. Also have a separate time counter for tablespace monitor. reviewed by: Heikki Revision r1524: Undo bad space formatting introduced in earlier commit r1521 spotted by: Marko Revision r1533: logs_empty_and_mark_files_at_shutdown(): Remove trailing whitespace that was added in r1521. storage/innobase/os/os0file.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1431: Fix Bug#9709 by retrying (forever) if ERROR_SHARING_VIOLATION or ERROR_LOCK_VIOLATION is encountered during file operation. This is caused by backup software, so InnoDB should retry while the backup software is done with the file. Approved by: Heikki storage/innobase/rem/rem0rec.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1528: Define an auxiliary macro UT_BITS_IN_BYTES() and use it where possible. Revision r1531: rec_get_converted_size_new(): Simplify and move a debug assertion. Revision r1546: When buffering an insert to a prefix index of a variable-length column, do not incorrectly mark the column as fixed-length. (Bug#28138) ibuf_entry_build(): Instead of prefix_len, pass fixed_len to dtype_new_store_for_order_and_null_size(). Add debug assertions. btr_index_rec_validate(): Correct a comment about prefix indexes. rec_get_converted_size_new(), rec_convert_dtuple_to_rec_new(): Add debug assertions and comments. dict_col_type_assert_equal(): New debug function. Revision r1555: rec_get_converted_size_new(): The total size of the infimum and supremum records in ROW_FORMAT=COMPACT is REC_N_NEW_EXTRA_BYTES + 8. The REC_N_NEW_EXTRA_BYTES was accidentally omitted in r1546. This function should never be called on those records, though. Revision r1569: Fix some in:/out: comments. Approved by: Marko storage/innobase/row/row0ins.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1485: Minor cleanup. row_ins_check_foreign_constraint(), row_ins_scan_sec_index_for_duplicate(): Make use of the predicates page_rec_is_infimum() and page_rec_is_supremum(). Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko storage/innobase/row/row0mysql.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1422: Fix for Bug#21101 - returns wrong error message when table column defs exceed the max row size. The fix returns a more appropriate error message. Add a test case to innodb.test and expected output to innodb.result. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. storage/innobase/row/row0row.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko Revision r1529: Revert r799, which was supposed to prevent similar cases as Bug#21638. In reality, the patch breaks the handling of prefix indexes of variable-length columns in ROW_FORMAT=COMPACT. Reverting the patch is only a partial fix of Bug#28138. storage/innobase/row/row0sel.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1452: Fix phantom reads (http://bugs.mysql.com/27197) following Heikki's patch in the bug followup. Approved by: Heikki Revision r1455: Reindent with tabs instead of spaces. Spotted by: Marko storage/innobase/srv/srv0srv.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1424: Bug#20352. Added variable srv_insert_buffer_batch_size. We want to make this variable settable. Since the pluggable engine interface currently doesn't provide a usable mechanism, we will add the latter functionality once it's available. Revision r1426: Fix code indentation from r1424. Revision r1459: Fix typo in the comment. Revision r1482: Fix Bug#25078 by always letting the replication thread on the slave server to enter InnoDB. This can be made further customizable by the user if we introduce a new config parameter. This will wait until config parameters can be easily added. Approved by: Marko Revision r1487: Fix typo in comment. Spotted by: Marko Revision r1521: Forward port r1520 from branches/5.0 Patch to allow monitor threads to stop before proceeding with normal shutdown. Also have a separate time counter for tablespace monitor. reviewed by: Heikki Revision r1532: srv_lock_timeout_and_monitor_thread(): Correct the indentation that was broken in r1521. Revision r1553: Fix Bug#20090 as suggested in the bug followup by Heikki. Approved by: Heikki storage/innobase/srv/srv0start.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1420: Output to the error log information about the limitations of UNIV_IBUF_DEBUG. innobase_start_or_create_for_mysql(): Note that crash recovery is broken when UNIV_IBUF_DEBUG is defined. ibuf_counts[]: Make this a two-dimensional array. No need to allocate anything from the heap. Eliminate ibuf_counts_inited, as the array will be zero-filled by the runtime environment. ibuf_count_check(): New function, to print out an explanation before assertion failure. storage/innobase/sync/sync0arr.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko storage/innobase/trx/trx0rec.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. storage/innobase/trx/trx0trx.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1491: Fix typo in comment. Revision r1497: Add the number of locks acquired by a transaction to its weight when choosing the lightest transaction to kill when a deadlock occurs. This fixes Bug#21293 partially. Approved by: Heikki Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki Revision r1522: trx0trx.c: Add missing #include "ha_prototypes.h". storage/innobase/trx/trx0undo.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. storage/innobase/ut/ut0ut.c: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1490: Add #include <ctype.h>. Apparently, this header is no longer included by the common headers. This may be related to WL#2936 (pluggable storage engines). mysql-test/r/innodb_trx_weight.result: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1498: Add a test about the behavior introduced in r1497. Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki mysql-test/include/innodb_trx_weight.inc: Apply the following innodb-5.1-* snapshots: ss1489, ss1496, ss1550, ss1569. Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki Revision r1556: mysql-test/innodb_trx_weight.inc: Add username root to the "connect" statement. The Unix user running mysql-test-run usually does not have any privileges on the MySQL test database. mysql-test/t/innodb_trx_weight.test: Fixes after merging InnoDB snapshots. Revision r1498: Add a test about the behavior introduced in r1497. Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki sql/sql_class.cc: Fixes after merging InnoDB snapshots. storage/innobase/Makefile.am: Fixes after merging InnoDB snapshots. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. storage/innobase/handler/ha_innodb.cc: Fixes after merging InnoDB snapshots. Revision r1422: Fix for Bug#21101 - returns wrong error message when table column defs exceed the max row size. The fix returns a more appropriate error message. Add a test case to innodb.test and expected output to innodb.result. Revision r1423: Fix for Bug#18828. Return DB_TOO_MANY_CONCURRENT_TRXS when we run out of UNDO slots in the rollback segment. This is a partial fix since the MySQL error code requested to properly report the error condition back to the client has not yet materialized. Currently we have #ifdef'd the error code translation in ha_innodb.cc. This will have to be changed as and when MySQl add the new requested code or an equivalent code that we can then use. Given the above, currently we will get the old behaviour, not the "fixed" and intended behaviour. Revision r1425: Fixed a missing function decoration that slipped into r1422. Revision r1434: Fix typo. Revision r1442: Potential fix for Bug#25645: "Move innobase_release_stat_resources(trx) outside the 'if' in ha_innobase::external_lock(). That would add more safety that whatever MySQL does at a query end, there would be no risk of a hang on the btr search latch." Also call innobase_release_temporary_latches() in the beginning of ha_innobase::close(). Approved by: Heikki Revision r1453: Bugfix: only call innobase_release_temporary_latches() in case of current_thd is not NULL, otherwise we get NULL pointer dereferencing. Approved by: Heikki Revision r1474: Fix typo in comment: the exact prototype is in include/data0type.ic, not in data/data0type.ic Revision r1482: Fix Bug#25078 by always letting the replication thread on the slave server to enter InnoDB. This can be made further customizable by the user if we introduce a new config parameter. This will wait until config parameters can be easily added. Approved by: Marko Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. Revision r1489: thd_to_trx(), check_trx_exists(): Remove the handlerton parameter. It is a singleton object whose address is stored into innodb_hton_ptr. Revision r1492: Convert innobase_buffer_pool_size and innobase_log_file_size types from longlong to long long because MYSQL_SYSVAR_LONGLONG marco expects long long type. Also change ((ulint)innobase_buffer_pool_size) / 1024 to (ulint)(innobase_buffer_pool_size / 1024) and remove comment which is no longer true. Provided that innobase_buffer_pool_size is always 64bits these statements are equivalent if ulint is 64 bit (well it will screw up if innobase_buffer_pool_size is negative). And if ulint is 32 bit the later variant gives a little more chance that the value will fit. Approved by: Heikki Revision r1493: ha_innodb.cc: Remove the declarations of some global InnoDB variables whose name starts with srv_. These variables are declared in the header files that are covered by #include directives in ha_innodb.cc. Revision r1495: Introduce the function reset_template() for resetting some fields of row_prebuilt_t; currently prebuilt->read_just_key and prebuilt->keep_other_fields_on_keyread. Revision r1496: ha_innobase::extra(): Replace references to prebuilt->trx with thd_to_trx(ha_thd()), in order to avoid potential memory corruption. Revision r1501: Fix Bug#21293: Consider transactions that had edited non-transactional tables heavier than ones that had not. This helps killing the "right" transaction in case of a deadlock. Approved by: Heikki Revision r1513: Split ut_a(a && b [&& c...]); into separate ut_a(a); ut_a(b); [ut_a(c); ...]. This makes it possible to see which expression was false by looking at the error message. Approved by: Marko Revision r1527: Cleanup in ha_innodb.cc: thd_is_replication_slave_thread(), thd_has_edited_nontrans_tables(): Remove blank line between the function comment and the function definition. There should be exactly one line between the return type and the function comment, and this line should be one of '', 'static', 'UNIV_INLINE', and 'extern "C"'. Revision r1538: Do not return error in ha_innobase::info if srv_force_recovery >= 4. This is to allow for normal processing of the query by MySQL instead of generating an error. Reviewed by: Heikki Revision r1551: ha_innobase::innobase_read_and_init_auto_inc(): Remember and restore prebuilt->sql_stat_start. In an ALTER TABLE statement in the innodb_gis test, an ut_ad() assertion failed, because no IX lock had been acquired on the table, because prebuilt->sql_stat_start was inadvertently reset to FALSE, by this function. This function was called via ha_innobase::info() and mysql_prepare_alter_table(). storage/innobase/plug.in: Fixes after merging InnoDB snapshots. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead. storage/innobase/handler/ha_innodb.h: Fixes after merging InnoDB snapshots. Revision r1488: Make InnoDB pluggable. That is, merge the modifications from MySQL WL#2936 and adapt some things. Note that ha_innodb.cc depends on mysql_tmpfile() being declared in <mysql/plugin.h>. Until the function is declared there, you can uncomment the buggy definition of mysql_tmpfile in ha_innodb.cc. Remove storage/innobase/*/Makefile.am. The whole compilation is driven by storage/innobase/Makefile.am and storage/innobase/plug.in. plug.in: Declare InnoDB as a dynamic plugin. ha_innodb.h: Remove the declarations of many global variables. The variables are no longer directly referenced outside of storage/innobase. trx_t: Add the field trx->duplicates. trx_create(): Initialize the fields trx->active_trans and trx->duplicates. innobase_query_is_update(): Remove. Consult trx->duplicates instead.
-
- 04 Jul, 2007 1 commit
-
-
unknown authored
Add more accessors to MySQL internals in mysql/plugin.h, for storage engine plugins. Add some accessors specific to the InnoDB storage engine, to allow InnoDB to be compiled as a plugin (without MYSQL_SERVER). InnoDB has additional requirements, due to its foreign key support, etc. include/m_string.h: Add structure tag to LEX_STRING definition, so that it can be referred to by forward declarations. Allow struct st_mysql_lex_string to be defined here, or in mysql/plugin.h. include/my_global.h: Define INNODB_COMPATIBILITY_HOOKS unconditionally; it brackets some definitions needed for the InnoDB storage engine plugin which do not belong in our general plugin interface. include/mysql/plugin.h: Additional accessors for MySQL internals: - Full definition of MYSQL_LEX_STRING (identical to LEX_STRING from m_string.h) - Full definition of MYSQL_XID (binary compatible with XID from handler.h) - mysql_tmpfile(), creates a temporary file in mysqld's tmpdir - thd_killed(), to check killed state of connection - thd_alloc() and similar allocation functions - thd_get_xid(), to get XID of connection's transaction - mysql_query_cache_invalidate4, to invalidate a table's query cache entries sql/handler.h: Use MYSQL_XIDDATASIZE definition from mysql/plugin.h, to avoid redundant definitions sql/log.cc: Add definitions for two InnoDB compatibility hooks: - mysql_bin_log_file(), to get log filename - mysql_bin_log_file_pos, to get position in file These are defined only if INNODB_COMPATIBILITY_HOOKS is defined; they are needed by the InnoDB plugin, but aren't part of the general plugin interface. They are declared in ha_innodb.h for InnoDB's use. sql/mysql_priv.h: Expose some server internals when INNODB_COMPATIBILITY_HOOKS is defined, so that InnoDB can be built as a plugin when MYSQL_SERVER is not defined. Move make_lex_string inside THD class. sql/sql_cache.cc: Add definiton of mysql_query_cache_invalidate4(), a part of the plugin API (mysql/plugin.h). sql/sql_class.cc: Add definitions for several accessor functions which form part of the plugin API (mysql/plugin.h): - mysql_tmpfile() - thd_alloc() and friends - thd_make_lex_string() - thd_get_xid() Add definitons for accessor functions which InnoDB requires, but which are not part of the plugin interface: - thd_charset() - thd_query() - thd_slave_thread() - thd_non_transactional_update() - thd_binlog_format() Move definition of make_lex_string() from sql_show.cc into THD class sql/sql_class.h: Remove LEX_STRING_make(), and move make_lex_string() from sql_show.cc inside THD class. sql/sql_parse.cc: Use thd->make_lex_string() instead of thd->LEX_STRING_make() sql/sql_show.cc: Move make_lex_string() inside THD class storage/innobase/handler/ha_innodb.cc: Call thd_make_lex_string() instead of make_lex_string().
-
- 22 Jun, 2007 2 commits
- 21 Jun, 2007 2 commits
-
-
unknown authored
Minor fixes to get proper detection of transaction isolation level when inside external_lock(). mysql-test/t/disabled.def: Enabling innodb.test again. mysql-test/t/innodb.test: Fixing some error codes. Test currently requires MIXED or ROW mode since READ-COMMITTED and READ-UNCOMMITTED are not safe for STATEMENT mode, i.e., when the binary log is enabled. storage/innobase/handler/ha_innodb.cc: Using tx_isolation since trx->isolation_level is not defined when inside external_lock().
-
unknown authored
Moving error generating code from table_flags() to external_lock(). include/my_base.h: Adding handler error code HA_ERR_LOGGING_IMPOSSIBLE storage/innobase/handler/ha_innodb.cc: Moving error generating code from table_flags() to external_lock().
-
- 14 Jun, 2007 1 commit
-
-
unknown authored
Temporarily using thd_tx_isolation() until decision is made on how to get the isolation level. storage/innobase/handler/ha_innodb.cc: Using thd_tx_isolation() instead of direct access to variable. mysql-test/r/binlog_tx_isolation.result: New BitKeeper file ``mysql-test/r/binlog_tx_isolation.result''
-
- 12 Jun, 2007 1 commit
-
-
unknown authored
replication): Patch to add binlog format capabilities to the InnoDB storage engine. The engine will not allow statement format logging when in READ COMMITTED or READ UNCOMMITTED transaction isolation level. In addition, an error is generated when trying to use READ COMMITTED or READ UNCOMMITTED transaction isolation level in STATEMENT binlog mode. sql/handler.h: Adding declaration of already global arrays. sql/share/errmsg.txt: Adding error messages for invalid changes of transaction isolation level and binlog mode switch. Removing messages that are not needed any more (this cset it pushed together with the cset that introduced these messages, so it is safe to remove the messages). sql/sql_base.cc: Some changes to error reporting code to get more informative messages. storage/innobase/handler/ha_innodb.cc: Adding capabilities to storage engine. Ha_innobase:table_flags() now compute flags on a per-statement basis and the statement capabilities flag is just set if the transaction isolation level is below READ COMMITTED. An informative message is printed in the event that the transaction isolation level is below READ COMMITTED and the binlog mode is STATEMENT. storage/innobase/handler/ha_innodb.h: Accomodating to changes in the server code that switched from ulong to Table_flags as type for the table flags. mysql-test/r/binlog_innodb.result: New BitKeeper file ``mysql-test/r/binlog_innodb.result'' mysql-test/t/binlog_innodb.test: New BitKeeper file ``mysql-test/t/binlog_innodb.test''
-
- 10 May, 2007 1 commit
-
-
unknown authored
The following type conversions was done: - Changed byte to uchar - Changed gptr to uchar* - Change my_string to char * - Change my_size_t to size_t - Change size_s to size_t Removed declaration of byte, gptr, my_string, my_size_t and size_s. Following function parameter changes was done: - All string functions in mysys/strings was changed to use size_t instead of uint for string lengths. - All read()/write() functions changed to use size_t (including vio). - All protocoll functions changed to use size_t instead of uint - Functions that used a pointer to a string length was changed to use size_t* - Changed malloc(), free() and related functions from using gptr to use void * as this requires fewer casts in the code and is more in line with how the standard functions work. - Added extra length argument to dirname_part() to return the length of the created string. - Changed (at least) following functions to take uchar* as argument: - db_dump() - my_net_write() - net_write_command() - net_store_data() - DBUG_DUMP() - decimal2bin() & bin2decimal() - Changed my_compress() and my_uncompress() to use size_t. Changed one argument to my_uncompress() from a pointer to a value as we only return one value (makes function easier to use). - Changed type of 'pack_data' argument to packfrm() to avoid casts. - Changed in readfrm() and writefrom(), ha_discover and handler::discover() the type for argument 'frmdata' to uchar** to avoid casts. - Changed most Field functions to use uchar* instead of char* (reduced a lot of casts). - Changed field->val_xxx(xxx, new_ptr) to take const pointers. Other changes: - Removed a lot of not needed casts - Added a few new cast required by other changes - Added some cast to my_multi_malloc() arguments for safety (as string lengths needs to be uint, not size_t). - Fixed all calls to hash-get-key functions to use size_t*. (Needed to be done explicitely as this conflict was often hided by casting the function to hash_get_key). - Changed some buffers to memory regions to uchar* to avoid casts. - Changed some string lengths from uint to size_t. - Changed field->ptr to be uchar* instead of char*. This allowed us to get rid of a lot of casts. - Some changes from true -> TRUE, false -> FALSE, unsigned char -> uchar - Include zlib.h in some files as we needed declaration of crc32() - Changed MY_FILE_ERROR to be (size_t) -1. - Changed many variables to hold the result of my_read() / my_write() to be size_t. This was needed to properly detect errors (which are returned as (size_t) -1). - Removed some very old VMS code - Changed packfrm()/unpackfrm() to not be depending on uint size (portability fix) - Removed windows specific code to restore cursor position as this causes slowdown on windows and we should not mix read() and pread() calls anyway as this is not thread safe. Updated function comment to reflect this. Changed function that depended on original behavior of my_pwrite() to itself restore the cursor position (one such case). - Added some missing checking of return value of malloc(). - Changed definition of MOD_PAD_CHAR_TO_FULL_LENGTH to avoid 'long' overflow. - Changed type of table_def::m_size from my_size_t to ulong to reflect that m_size is the number of elements in the array, not a string/memory length. - Moved THD::max_row_length() to table.cc (as it's not depending on THD). Inlined max_row_length_blob() into this function. - More function comments - Fixed some compiler warnings when compiled without partitions. - Removed setting of LEX_STRING() arguments in declaration (portability fix). - Some trivial indentation/variable name changes. - Some trivial code simplifications: - Replaced some calls to alloc_root + memcpy to use strmake_root()/strdup_root(). - Changed some calls from memdup() to strmake() (Safety fix) - Simpler loops in client-simple.c BitKeeper/etc/ignore: added libmysqld/ha_ndbcluster_cond.cc --- added debian/defs.mk debian/control client/completion_hash.cc: Remove not needed casts client/my_readline.h: Remove some old types client/mysql.cc: Simplify types client/mysql_upgrade.c: Remove some old types Update call to dirname_part client/mysqladmin.cc: Remove some old types client/mysqlbinlog.cc: Remove some old types Change some buffers to be uchar to avoid casts client/mysqlcheck.c: Remove some old types client/mysqldump.c: Remove some old types Remove some not needed casts Change some string lengths to size_t client/mysqlimport.c: Remove some old types client/mysqlshow.c: Remove some old types client/mysqlslap.c: Remove some old types Remove some not needed casts client/mysqltest.c: Removed some old types Removed some not needed casts Updated hash-get-key function arguments Updated parameters to dirname_part() client/readline.cc: Removed some old types Removed some not needed casts Changed some string lengths to use size_t client/sql_string.cc: Removed some old types dbug/dbug.c: Removed some old types Changed some string lengths to use size_t Changed some prototypes to avoid casts extra/comp_err.c: Removed some old types extra/innochecksum.c: Removed some old types extra/my_print_defaults.c: Removed some old types extra/mysql_waitpid.c: Removed some old types extra/perror.c: Removed some old types extra/replace.c: Removed some old types Updated parameters to dirname_part() extra/resolve_stack_dump.c: Removed some old types extra/resolveip.c: Removed some old types include/config-win.h: Removed some old types include/decimal.h: Changed binary strings to be uchar* instead of char* include/ft_global.h: Removed some old types include/hash.h: Removed some old types include/heap.h: Removed some old types Changed records_under_level to be 'ulong' instead of 'uint' to clarify usage of variable include/keycache.h: Removed some old types include/m_ctype.h: Removed some old types Changed some string lengths to use size_t Changed character length functions to return uint unsigned char -> uchar include/m_string.h: Removed some old types Changed some string lengths to use size_t include/my_alloc.h: Changed some string lengths to use size_t include/my_base.h: Removed some old types include/my_dbug.h: Removed some old types Changed some string lengths to use size_t Changed db_dump() to take uchar * as argument for memory to reduce number of casts in usage include/my_getopt.h: Removed some old types include/my_global.h: Removed old types: my_size_t -> size_t byte -> uchar gptr -> uchar * include/my_list.h: Removed some old types include/my_nosys.h: Removed some old types include/my_pthread.h: Removed some old types include/my_sys.h: Removed some old types Changed MY_FILE_ERROR to be in line with new definitions of my_write()/my_read() Changed some string lengths to use size_t my_malloc() / my_free() now uses void * Updated parameters to dirname_part() & my_uncompress() include/my_tree.h: Removed some old types include/my_trie.h: Removed some old types include/my_user.h: Changed some string lengths to use size_t include/my_vle.h: Removed some old types include/my_xml.h: Removed some old types Changed some string lengths to use size_t include/myisam.h: Removed some old types include/myisammrg.h: Removed some old types include/mysql.h: Removed some old types Changed byte streams to use uchar* instead of char* include/mysql_com.h: Removed some old types Changed some string lengths to use size_t Changed some buffers to be uchar* to avoid casts include/queues.h: Removed some old types include/sql_common.h: Removed some old types include/sslopt-longopts.h: Removed some old types include/violite.h: Removed some old types Changed some string lengths to use size_t libmysql/client_settings.h: Removed some old types libmysql/libmysql.c: Removed some old types libmysql/manager.c: Removed some old types libmysqld/emb_qcache.cc: Removed some old types libmysqld/emb_qcache.h: Removed some old types libmysqld/lib_sql.cc: Removed some old types Removed some not needed casts Changed some buffers to be uchar* to avoid casts true -> TRUE, false -> FALSE mysys/array.c: Removed some old types mysys/charset.c: Changed some string lengths to use size_t mysys/checksum.c: Include zlib to get definition for crc32 Removed some old types mysys/default.c: Removed some old types Changed some string lengths to use size_t mysys/default_modify.c: Changed some string lengths to use size_t Removed some not needed casts mysys/hash.c: Removed some old types Changed some string lengths to use size_t Note: Prototype of hash_key() has changed which may cause problems if client uses hash_init() with a cast for the hash-get-key function. hash_element now takes 'ulong' as the index type (cleanup) mysys/list.c: Removed some old types mysys/mf_cache.c: Changed some string lengths to use size_t mysys/mf_dirname.c: Removed some old types Changed some string lengths to use size_t Added argument to dirname_part() to avoid calculation of length for 'to' mysys/mf_fn_ext.c: Removed some old types Updated parameters to dirname_part() mysys/mf_format.c: Removed some old types Changed some string lengths to use size_t mysys/mf_getdate.c: Removed some old types mysys/mf_iocache.c: Removed some old types Changed some string lengths to use size_t Changed calculation of 'max_length' to be done the same way in all functions mysys/mf_iocache2.c: Removed some old types Changed some string lengths to use size_t Clean up comments Removed not needed indentation mysys/mf_keycache.c: Removed some old types mysys/mf_keycaches.c: Removed some old types mysys/mf_loadpath.c: Removed some old types mysys/mf_pack.c: Removed some old types Changed some string lengths to use size_t Removed some not needed casts Removed very old VMS code Updated parameters to dirname_part() Use result of dirnam_part() to remove call to strcat() mysys/mf_path.c: Removed some old types mysys/mf_radix.c: Removed some old types mysys/mf_same.c: Removed some old types mysys/mf_sort.c: Removed some old types mysys/mf_soundex.c: Removed some old types mysys/mf_strip.c: Removed some old types mysys/mf_tempdir.c: Removed some old types mysys/mf_unixpath.c: Removed some old types mysys/mf_wfile.c: Removed some old types mysys/mulalloc.c: Removed some old types mysys/my_alloc.c: Removed some old types Changed some string lengths to use size_t Use void* as type for allocated memory area Removed some not needed casts Changed argument 'Size' to 'length' according coding guidelines mysys/my_chsize.c: Changed some buffers to be uchar* to avoid casts mysys/my_compress.c: More comments Removed some old types Changed string lengths to use size_t Changed arguments to my_uncompress() to make them easier to understand Changed packfrm()/unpackfrm() to not be depending on uint size (portability fix) Changed type of 'pack_data' argument to packfrm() to avoid casts. mysys/my_conio.c: Changed some string lengths to use size_t mysys/my_create.c: Removed some old types mysys/my_div.c: Removed some old types mysys/my_error.c: Removed some old types mysys/my_fopen.c: Removed some old types mysys/my_fstream.c: Removed some old types Changed some string lengths to use size_t writen -> written mysys/my_getopt.c: Removed some old types mysys/my_getwd.c: Removed some old types More comments mysys/my_init.c: Removed some old types mysys/my_largepage.c: Removed some old types Changed some string lengths to use size_t mysys/my_lib.c: Removed some old types mysys/my_lockmem.c: Removed some old types mysys/my_malloc.c: Removed some old types Changed malloc(), free() and related functions to use void * Changed all functions to use size_t mysys/my_memmem.c: Indentation cleanup mysys/my_once.c: Removed some old types Changed malloc(), free() and related functions to use void * mysys/my_open.c: Removed some old types mysys/my_pread.c: Removed some old types Changed all functions to use size_t Added comment for how my_pread() / my_pwrite() are supposed to work. Removed windows specific code to restore cursor position as this causes slowdown on windows and we should not mix read() and pread() calls anyway as this is not thread safe. (If we ever would really need this, it should be enabled only with a flag argument) mysys/my_quick.c: Removed some old types Changed all functions to use size_t mysys/my_read.c: Removed some old types Changed all functions to use size_t mysys/my_realloc.c: Removed some old types Use void* as type for allocated memory area Changed all functions to use size_t mysys/my_static.c: Removed some old types mysys/my_static.h: Removed some old types mysys/my_vle.c: Removed some old types mysys/my_wincond.c: Removed some old types mysys/my_windac.c: Removed some old types mysys/my_write.c: Removed some old types Changed all functions to use size_t mysys/ptr_cmp.c: Removed some old types Changed all functions to use size_t mysys/queues.c: Removed some old types mysys/safemalloc.c: Removed some old types Changed malloc(), free() and related functions to use void * Changed all functions to use size_t mysys/string.c: Removed some old types Changed all functions to use size_t mysys/testhash.c: Removed some old types mysys/thr_alarm.c: Removed some old types mysys/thr_lock.c: Removed some old types mysys/tree.c: Removed some old types mysys/trie.c: Removed some old types mysys/typelib.c: Removed some old types plugin/daemon_example/daemon_example.cc: Removed some old types regex/reginit.c: Removed some old types server-tools/instance-manager/buffer.cc: Changed some string lengths to use size_t Changed buffer to be of type uchar* server-tools/instance-manager/buffer.h: Changed some string lengths to use size_t Changed buffer to be of type uchar* server-tools/instance-manager/commands.cc: Removed some old types Changed some string lengths to use size_t Changed buffer to be of type uchar* server-tools/instance-manager/instance_map.cc: Removed some old types Changed some string lengths to use size_t Changed buffer to be of type uchar* server-tools/instance-manager/instance_options.cc: Changed buffer to be of type uchar* Replaced alloc_root + strcpy() with strdup_root() server-tools/instance-manager/mysql_connection.cc: Changed buffer to be of type uchar* server-tools/instance-manager/options.cc: Removed some old types server-tools/instance-manager/parse.cc: Changed some string lengths to use size_t server-tools/instance-manager/parse.h: Removed some old types Changed some string lengths to use size_t server-tools/instance-manager/protocol.cc: Changed some buffers to be uchar* to avoid casts Changed some string lengths to use size_t server-tools/instance-manager/protocol.h: Changed some string lengths to use size_t server-tools/instance-manager/user_map.cc: Removed some old types Changed some string lengths to use size_t sql/derror.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Changed some string lengths to use size_t sql/discover.cc: Changed in readfrm() and writefrom() the type for argument 'frmdata' to uchar** to avoid casts Changed some string lengths to use size_t Changed some buffers to be uchar* to avoid casts sql/event_data_objects.cc: Removed some old types Added missing casts for alloc() and sprintf() sql/event_db_repository.cc: Changed some buffers to be uchar* to avoid casts Added missing casts for sprintf() sql/event_queue.cc: Removed some old types sql/field.cc: Removed some old types Changed memory buffers to be uchar* Changed some string lengths to use size_t Removed a lot of casts Safety fix in Field_blob::val_decimal() to not access zero pointer sql/field.h: Removed some old types Changed memory buffers to be uchar* (except of store() as this would have caused too many other changes). Changed some string lengths to use size_t Removed some not needed casts Changed val_xxx(xxx, new_ptr) to take const pointers sql/field_conv.cc: Removed some old types Added casts required because memory area pointers are now uchar* sql/filesort.cc: Initalize variable that was used unitialized in error conditions sql/gen_lex_hash.cc: Removed some old types Changed memory buffers to be uchar* Changed some string lengths to use size_t Removed a lot of casts Safety fix in Field_blob::val_decimal() to not access zero pointer sql/gstream.h: Added required cast sql/ha_ndbcluster.cc: Removed some old types Updated hash-get-key function arguments Changed some buffers to be uchar* to avoid casts Added required casts Removed some not needed casts sql/ha_ndbcluster.h: Removed some old types sql/ha_ndbcluster_binlog.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Replaced sql_alloc() + memcpy() + set end 0 with sql_strmake() Changed some string lengths to use size_t Added missing casts for alloc() and sprintf() sql/ha_ndbcluster_binlog.h: Removed some old types sql/ha_ndbcluster_cond.cc: Removed some old types Removed some not needed casts sql/ha_ndbcluster_cond.h: Removed some old types sql/ha_partition.cc: Removed some old types Changed prototype for change_partition() to avoid casts sql/ha_partition.h: Removed some old types sql/handler.cc: Removed some old types Changed some string lengths to use size_t sql/handler.h: Removed some old types Changed some string lengths to use size_t Changed type for 'frmblob' parameter for discover() and ha_discover() to get fewer casts sql/hash_filo.h: Removed some old types Changed all functions to use size_t sql/hostname.cc: Removed some old types sql/item.cc: Removed some old types Changed some string lengths to use size_t Use strmake() instead of memdup() to create a null terminated string. Updated calls to new Field() sql/item.h: Removed some old types Changed malloc(), free() and related functions to use void * Changed some buffers to be uchar* to avoid casts sql/item_cmpfunc.cc: Removed some old types Changed some buffers to be uchar* to avoid casts sql/item_cmpfunc.h: Removed some old types sql/item_create.cc: Removed some old types sql/item_func.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts Added test for failing alloc() in init_result_field() Remove old confusing comment Fixed compiler warning sql/item_func.h: Removed some old types sql/item_row.cc: Removed some old types sql/item_row.h: Removed some old types sql/item_strfunc.cc: Include zlib (needed becasue we call crc32) Removed some old types sql/item_strfunc.h: Removed some old types Changed some types to match new function prototypes sql/item_subselect.cc: Removed some old types sql/item_subselect.h: Removed some old types sql/item_sum.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/item_sum.h: Removed some old types sql/item_timefunc.cc: Removed some old types Changed some string lengths to use size_t sql/item_timefunc.h: Removed some old types sql/item_xmlfunc.cc: Changed some string lengths to use size_t sql/item_xmlfunc.h: Removed some old types sql/key.cc: Removed some old types Removed some not needed casts sql/lock.cc: Removed some old types Added some cast to my_multi_malloc() arguments for safety sql/log.cc: Removed some old types Changed some string lengths to use size_t Changed some buffers to be uchar* to avoid casts Changed usage of pwrite() to not assume it holds the cursor position for the file Made usage of my_read() safer sql/log_event.cc: Removed some old types Added checking of return value of malloc() in pack_info() Changed some buffers to be uchar* to avoid casts Removed some 'const' to avoid casts Added missing casts for alloc() and sprintf() Added required casts Removed some not needed casts Added some cast to my_multi_malloc() arguments for safety sql/log_event.h: Removed some old types Changed some buffers to be uchar* to avoid casts sql/log_event_old.cc: Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/log_event_old.h: Changed some buffers to be uchar* to avoid casts sql/mf_iocache.cc: Removed some old types sql/my_decimal.cc: Changed memory area to use uchar* sql/my_decimal.h: Changed memory area to use uchar* sql/mysql_priv.h: Removed some old types Changed malloc(), free() and related functions to use void * Changed some string lengths to use size_t Changed definition of MOD_PAD_CHAR_TO_FULL_LENGTH to avoid long overflow Changed some buffers to be uchar* to avoid casts sql/mysqld.cc: Removed some old types sql/net_serv.cc: Removed some old types Changed some string lengths to use size_t Changed some buffers to be uchar* to avoid casts Ensure that vio_read()/vio_write() return values are stored in a size_t variable Removed some not needed casts sql/opt_range.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/opt_range.h: Removed some old types Changed some buffers to be uchar* to avoid casts sql/opt_sum.cc: Removed some old types Removed some not needed casts sql/parse_file.cc: Removed some old types Changed some string lengths to use size_t Changed alloc_root + memcpy + set end 0 -> strmake_root() sql/parse_file.h: Removed some old types sql/partition_info.cc: Removed some old types Added missing casts for alloc() Changed some buffers to be uchar* to avoid casts sql/partition_info.h: Changed some buffers to be uchar* to avoid casts sql/protocol.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/protocol.h: Removed some old types Changed some buffers to be uchar* to avoid casts Changed some string lengths to use size_t sql/records.cc: Removed some old types sql/repl_failsafe.cc: Removed some old types Changed some string lengths to use size_t Added required casts sql/rpl_filter.cc: Removed some old types Updated hash-get-key function arguments Changed some string lengths to use size_t sql/rpl_filter.h: Changed some string lengths to use size_t sql/rpl_injector.h: Removed some old types sql/rpl_record.cc: Removed some old types Removed some not needed casts Changed some buffers to be uchar* to avoid casts sql/rpl_record.h: Removed some old types Changed some buffers to be uchar* to avoid casts sql/rpl_record_old.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/rpl_record_old.h: Removed some old types Changed some buffers to be uchar* to avoid cast sql/rpl_rli.cc: Removed some old types sql/rpl_tblmap.cc: Removed some old types sql/rpl_tblmap.h: Removed some old types sql/rpl_utility.cc: Removed some old types sql/rpl_utility.h: Removed some old types Changed type of m_size from my_size_t to ulong to reflect that m_size is the number of elements in the array, not a string/memory length sql/set_var.cc: Removed some old types Updated parameters to dirname_part() sql/set_var.h: Removed some old types sql/slave.cc: Removed some old types Changed some string lengths to use size_t sql/slave.h: Removed some old types sql/sp.cc: Removed some old types Added missing casts for printf() sql/sp.h: Removed some old types Updated hash-get-key function arguments sql/sp_cache.cc: Removed some old types Added missing casts for printf() Updated hash-get-key function arguments sql/sp_head.cc: Removed some old types Added missing casts for alloc() and printf() Added required casts Updated hash-get-key function arguments sql/sp_head.h: Removed some old types sql/sp_pcontext.cc: Removed some old types sql/sp_pcontext.h: Removed some old types sql/sql_acl.cc: Removed some old types Changed some string lengths to use size_t Changed some buffers to be uchar* to avoid casts Removed some not needed casts Added required casts sql/sql_analyse.cc: Changed some buffers to be uchar* to avoid casts sql/sql_analyse.h: Changed some buffers to be uchar* to avoid casts sql/sql_array.h: Removed some old types sql/sql_base.cc: Removed some old types Updated hash-get-key function arguments sql/sql_binlog.cc: Removed some old types Added missing casts for printf() sql/sql_cache.cc: Removed some old types Updated hash-get-key function arguments Removed some not needed casts Changed some string lengths to use size_t sql/sql_cache.h: Removed some old types Removed reference to not existing function cache_key() Updated hash-get-key function arguments sql/sql_class.cc: Removed some old types Updated hash-get-key function arguments Added missing casts for alloc() Updated hash-get-key function arguments Moved THD::max_row_length() to table.cc (as it's not depending on THD) Removed some not needed casts sql/sql_class.h: Removed some old types Changed malloc(), free() and related functions to use void * Removed some not needed casts Changed some string lengths to use size_t Moved max_row_length and max_row_length_blob() to table.cc, as they are not depending on THD sql/sql_connect.cc: Removed some old types Added required casts sql/sql_db.cc: Removed some old types Removed some not needed casts Added some cast to my_multi_malloc() arguments for safety Added missing casts for alloc() sql/sql_delete.cc: Removed some old types sql/sql_handler.cc: Removed some old types Updated hash-get-key function arguments Added some cast to my_multi_malloc() arguments for safety sql/sql_help.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/sql_insert.cc: Removed some old types Added missing casts for alloc() and printf() sql/sql_lex.cc: Removed some old types sql/sql_lex.h: Removed some old types Removed some not needed casts sql/sql_list.h: Removed some old types Removed some not needed casts sql/sql_load.cc: Removed some old types Removed compiler warning sql/sql_manager.cc: Removed some old types sql/sql_map.cc: Removed some old types sql/sql_map.h: Removed some old types sql/sql_olap.cc: Removed some old types sql/sql_parse.cc: Removed some old types Trivial move of code lines to make things more readable Changed some string lengths to use size_t Added missing casts for alloc() sql/sql_partition.cc: Removed some old types Removed compiler warnings about not used functions Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/sql_partition.h: Removed some old types Changed some buffers to be uchar* to avoid casts sql/sql_plugin.cc: Removed some old types Added missing casts for alloc() Updated hash-get-key function arguments sql/sql_prepare.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Added missing casts for alloc() and printf() sql-common/client.c: Removed some old types Changed some memory areas to use uchar* sql-common/my_user.c: Changed some string lengths to use size_t sql-common/pack.c: Changed some buffers to be uchar* to avoid casts sql/sql_repl.cc: Added required casts Changed some buffers to be uchar* to avoid casts Changed some string lengths to use size_t sql/sql_select.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some old types sql/sql_select.h: Removed some old types Changed some buffers to be uchar* to avoid casts sql/sql_servers.cc: Removed some old types Updated hash-get-key function arguments sql/sql_show.cc: Removed some old types Added missing casts for alloc() Removed some not needed casts sql/sql_string.cc: Removed some old types Added required casts sql/sql_table.cc: Removed some old types Removed compiler warning about not used variable Changed some buffers to be uchar* to avoid casts Removed some not needed casts sql/sql_test.cc: Removed some old types sql/sql_trigger.cc: Removed some old types Added missing casts for alloc() sql/sql_udf.cc: Removed some old types Updated hash-get-key function arguments sql/sql_union.cc: Removed some old types sql/sql_update.cc: Removed some old types Removed some not needed casts sql/sql_view.cc: Removed some old types sql/sql_yacc.yy: Removed some old types Changed some string lengths to use size_t Added missing casts for alloc() sql/stacktrace.c: Removed some old types sql/stacktrace.h: Removed some old types sql/structs.h: Removed some old types sql/table.cc: Removed some old types Updated hash-get-key function arguments Changed some buffers to be uchar* to avoid casts Removed setting of LEX_STRING() arguments in declaration Added required casts More function comments Moved max_row_length() here from sql_class.cc/sql_class.h sql/table.h: Removed some old types Changed some string lengths to use size_t sql/thr_malloc.cc: Use void* as type for allocated memory area Changed all functions to use size_t sql/tzfile.h: Changed some buffers to be uchar* to avoid casts sql/tztime.cc: Changed some buffers to be uchar* to avoid casts Updated hash-get-key function arguments Added missing casts for alloc() Removed some not needed casts sql/uniques.cc: Removed some old types Removed some not needed casts sql/unireg.cc: Removed some old types Changed some buffers to be uchar* to avoid casts Removed some not needed casts Added missing casts for alloc() storage/archive/archive_reader.c: Removed some old types storage/archive/azio.c: Removed some old types Removed some not needed casts storage/archive/ha_archive.cc: Removed some old types Changed type for 'frmblob' in archive_discover() to match handler Updated hash-get-key function arguments Removed some not needed casts storage/archive/ha_archive.h: Removed some old types storage/blackhole/ha_blackhole.cc: Removed some old types storage/blackhole/ha_blackhole.h: Removed some old types storage/csv/ha_tina.cc: Removed some old types Updated hash-get-key function arguments Changed some buffers to be uchar* to avoid casts storage/csv/ha_tina.h: Removed some old types Removed some not needed casts storage/csv/transparent_file.cc: Removed some old types Changed type of 'bytes_read' to be able to detect read errors Fixed indentation storage/csv/transparent_file.h: Removed some old types storage/example/ha_example.cc: Removed some old types Updated hash-get-key function arguments storage/example/ha_example.h: Removed some old types storage/federated/ha_federated.cc: Removed some old types Updated hash-get-key function arguments Removed some not needed casts storage/federated/ha_federated.h: Removed some old types storage/heap/_check.c: Changed some buffers to be uchar* to avoid casts storage/heap/_rectest.c: Removed some old types storage/heap/ha_heap.cc: Removed some old types storage/heap/ha_heap.h: Removed some old types storage/heap/heapdef.h: Removed some old types storage/heap/hp_block.c: Removed some old types Changed some string lengths to use size_t storage/heap/hp_clear.c: Removed some old types storage/heap/hp_close.c: Removed some old types storage/heap/hp_create.c: Removed some old types storage/heap/hp_delete.c: Removed some old types storage/heap/hp_hash.c: Removed some old types storage/heap/hp_info.c: Removed some old types storage/heap/hp_open.c: Removed some old types storage/heap/hp_rfirst.c: Removed some old types storage/heap/hp_rkey.c: Removed some old types storage/heap/hp_rlast.c: Removed some old types storage/heap/hp_rnext.c: Removed some old types storage/heap/hp_rprev.c: Removed some old types storage/heap/hp_rrnd.c: Removed some old types storage/heap/hp_rsame.c: Removed some old types storage/heap/hp_scan.c: Removed some old types storage/heap/hp_test1.c: Removed some old types storage/heap/hp_test2.c: Removed some old types storage/heap/hp_update.c: Removed some old types storage/heap/hp_write.c: Removed some old types Changed some string lengths to use size_t storage/innobase/handler/ha_innodb.cc: Removed some old types Updated hash-get-key function arguments Added missing casts for alloc() and printf() Removed some not needed casts storage/innobase/handler/ha_innodb.h: Removed some old types storage/myisam/ft_boolean_search.c: Removed some old types storage/myisam/ft_nlq_search.c: Removed some old types storage/myisam/ft_parser.c: Removed some old types Changed some buffers to be uchar* to avoid casts storage/myisam/ft_static.c: Removed some old types storage/myisam/ft_stopwords.c: Removed some old types storage/myisam/ft_update.c: Removed some old types Changed some buffers to be uchar* to avoid casts storage/myisam/ftdefs.h: Removed some old types Changed some buffers to be uchar* to avoid casts storage/myisam/fulltext.h: Removed some old types storage/myisam/ha_myisam.cc: Removed some old types storage/myisam/ha_myisam.h: Removed some old types storage/myisam/mi_cache.c: Removed some old types Changed some buffers to be uchar* to avoid casts storage/myisam/mi_check.c: Removed some old types storage/myisam/mi_checksum.c: Removed some old types storage/myisam/mi_close.c: Removed some old types storage/myisam/mi_create.c: Removed some old types storage/myisam/mi_delete.c: Removed some old types storage/myisam/mi_delete_all.c: Removed some old types storage/myisam/mi_dynrec.c: Removed some old types storage/myisam/mi_extra.c: Removed some old types storage/myisam/mi_key.c: Removed some old types storage/myisam/mi_locking.c: Removed some old types storage/myisam/mi_log.c: Removed some old types storage/myisam/mi_open.c: Removed some old types Removed some not needed casts Check argument of my_write()/my_pwrite() in functions returning int Added casting of string lengths to size_t storage/myisam/mi_packrec.c: Removed some old types Changed some buffers to be uchar* to avoid casts storage/myisam/mi_page.c: Removed some old types storage/myisam/mi_preload.c: Removed some old types storage/myisam/mi_range.c: Removed some old types storage/myisam/mi_rfirst.c: Removed some old types storage/myisam/mi_rkey.c: Removed some old types storage/myisam/mi_rlast.c: Removed some old types storage/myisam/mi_rnext.c: Removed some old types storage/myisam/mi_rnext_same.c: Removed some old types storage/myisam/mi_rprev.c: Removed some old types storage/myisam/mi_rrnd.c: Removed some old types storage/myisam/mi_rsame.c: Removed some old types storage/myisam/mi_rsamepos.c: Removed some old types storage/myisam/mi_scan.c: Removed some old types storage/myisam/mi_search.c: Removed some old types storage/myisam/mi_static.c: Removed some old types storage/myisam/mi_statrec.c: Removed some old types storage/myisam/mi_test1.c: Removed some old types storage/myisam/mi_test2.c: Removed some old types storage/myisam/mi_test3.c: Removed some old types storage/myisam/mi_unique.c: Removed some old types storage/myisam/mi_update.c: Removed some old types storage/myisam/mi_write.c: Removed some old types storage/myisam/myisam_ftdump.c: Removed some old types storage/myisam/myisamchk.c: Removed some old types storage/myisam/myisamdef.h: Removed some old types storage/myisam/myisamlog.c: Removed some old types Indentation fix storage/myisam/myisampack.c: Removed some old types storage/myisam/rt_index.c: Removed some old types storage/myisam/rt_split.c: Removed some old types storage/myisam/sort.c: Removed some old types storage/myisam/sp_defs.h: Removed some old types storage/myisam/sp_key.c: Removed some old types storage/myisammrg/ha_myisammrg.cc: Removed some old types storage/myisammrg/ha_myisammrg.h: Removed some old types storage/myisammrg/myrg_close.c: Removed some old types storage/myisammrg/myrg_def.h: Removed some old types storage/myisammrg/myrg_delete.c: Removed some old types storage/myisammrg/myrg_open.c: Removed some old types Updated parameters to dirname_part() storage/myisammrg/myrg_queue.c: Removed some old types storage/myisammrg/myrg_rfirst.c: Removed some old types storage/myisammrg/myrg_rkey.c: Removed some old types storage/myisammrg/myrg_rlast.c: Removed some old types storage/myisammrg/myrg_rnext.c: Removed some old types storage/myisammrg/myrg_rnext_same.c: Removed some old types storage/myisammrg/myrg_rprev.c: Removed some old types storage/myisammrg/myrg_rrnd.c: Removed some old types storage/myisammrg/myrg_rsame.c: Removed some old types storage/myisammrg/myrg_update.c: Removed some old types storage/myisammrg/myrg_write.c: Removed some old types storage/ndb/include/util/ndb_opts.h: Removed some old types storage/ndb/src/cw/cpcd/main.cpp: Removed some old types storage/ndb/src/kernel/vm/Configuration.cpp: Removed some old types storage/ndb/src/mgmclient/main.cpp: Removed some old types storage/ndb/src/mgmsrv/InitConfigFileParser.cpp: Removed some old types Removed old disabled code storage/ndb/src/mgmsrv/main.cpp: Removed some old types storage/ndb/src/ndbapi/NdbBlob.cpp: Removed some old types storage/ndb/src/ndbapi/NdbOperationDefine.cpp: Removed not used variable storage/ndb/src/ndbapi/NdbOperationInt.cpp: Added required casts storage/ndb/src/ndbapi/NdbScanOperation.cpp: Added required casts storage/ndb/tools/delete_all.cpp: Removed some old types storage/ndb/tools/desc.cpp: Removed some old types storage/ndb/tools/drop_index.cpp: Removed some old types storage/ndb/tools/drop_tab.cpp: Removed some old types storage/ndb/tools/listTables.cpp: Removed some old types storage/ndb/tools/ndb_config.cpp: Removed some old types storage/ndb/tools/restore/consumer_restore.cpp: Changed some buffers to be uchar* to avoid casts with new defintion of packfrm() storage/ndb/tools/restore/restore_main.cpp: Removed some old types storage/ndb/tools/select_all.cpp: Removed some old types storage/ndb/tools/select_count.cpp: Removed some old types storage/ndb/tools/waiter.cpp: Removed some old types strings/bchange.c: Changed function to use uchar * and size_t strings/bcmp.c: Changed function to use uchar * and size_t strings/bmove512.c: Changed function to use uchar * and size_t strings/bmove_upp.c: Changed function to use uchar * and size_t strings/ctype-big5.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-bin.c: Changed functions to use size_t strings/ctype-cp932.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-czech.c: Fixed indentation Changed functions to use size_t strings/ctype-euc_kr.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-eucjpms.c: Changed functions to use size_t Changed character length functions to return uint unsigned char -> uchar strings/ctype-gb2312.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-gbk.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-latin1.c: Changed functions to use size_t Changed character length functions to return uint unsigned char -> uchar strings/ctype-mb.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-simple.c: Changed functions to use size_t Simpler loops for caseup/casedown unsigned int -> uint unsigned char -> uchar strings/ctype-sjis.c: Changed functions to use size_t Changed character length functions to return uint strings/ctype-tis620.c: Changed functions to use size_t Changed character length functions to return uint unsigned char -> uchar strings/ctype-uca.c: Changed functions to use size_t unsigned char -> uchar strings/ctype-ucs2.c: Moved inclusion of stdarg.h to other includes usigned char -> uchar Changed functions to use size_t Changed character length functions to return uint strings/ctype-ujis.c: Changed functions to use size_t Changed character length functions to return uint unsigned char -> uchar strings/ctype-utf8.c: Changed functions to use size_t unsigned char -> uchar Indentation fixes strings/ctype-win1250ch.c: Indentation fixes Changed functions to use size_t strings/ctype.c: Changed functions to use size_t strings/decimal.c: Changed type for memory argument to uchar * strings/do_ctype.c: Indentation fixes strings/my_strtoll10.c: unsigned char -> uchar strings/my_vsnprintf.c: Changed functions to use size_t strings/r_strinstr.c: Removed some old types Changed functions to use size_t strings/str_test.c: Removed some old types strings/strappend.c: Changed functions to use size_t strings/strcont.c: Removed some old types strings/strfill.c: Removed some old types strings/strinstr.c: Changed functions to use size_t strings/strlen.c: Changed functions to use size_t strings/strmake.c: Changed functions to use size_t strings/strnlen.c: Changed functions to use size_t strings/strnmov.c: Changed functions to use size_t strings/strto.c: unsigned char -> uchar strings/strtod.c: Changed functions to use size_t strings/strxnmov.c: Changed functions to use size_t strings/xml.c: Changed functions to use size_t Indentation fixes tests/mysql_client_test.c: Removed some old types tests/thread_test.c: Removed some old types vio/test-ssl.c: Removed some old types vio/test-sslclient.c: Removed some old types vio/test-sslserver.c: Removed some old types vio/vio.c: Removed some old types vio/vio_priv.h: Removed some old types Changed vio_read()/vio_write() to work with size_t vio/viosocket.c: Changed vio_read()/vio_write() to work with size_t Indentation fixes vio/viossl.c: Changed vio_read()/vio_write() to work with size_t Indentation fixes vio/viosslfactories.c: Removed some old types vio/viotest-ssl.c: Removed some old types win/README: More explanations
-
- 01 May, 2007 1 commit
-
-
unknown authored
storage/innobase/handler/ha_innodb.cc: strict compilers did not permit auto casting 'longlong*' to 'long long *' storage/innobase/handler/ha_innodb.h: strict compilers did not permit auto casting 'longlong*' to 'long long *'
-
- 30 Apr, 2007 1 commit
-
-
unknown authored
include/my_global.h: only use compile_time_assert on gcc mysql-test/mysql-test-run.pl: better --datadir for mysqld --help sql/mysql_priv.h: error-prone but concatenation-friendly IF_NETWARE() storage/innobase/handler/ha_innodb.cc: no preprocessor directives inside macro arguments
-
- 29 Apr, 2007 1 commit
-
-
unknown authored
-
- 19 Apr, 2007 1 commit
-
-
unknown authored
Fixes: - Bug #26662: mysqld assertion when creating temporary (InnoDB) table on a tmpfs filesystem Fix by not open(2)ing with O_DIRECT but rather calling fcntl(2) to set this flag immediately after open(2)ing. This way an error caused by O_DIRECT not being supported can easily be ignored. - Bug #23313: AUTO_INCREMENT=# not reported back for InnoDB tables - Bug #21404: AUTO_INCREMENT value reset when Adding FKEY (or ALTER?) Report the current value of the AUTO_INCREMENT counter to MySQL. mysql-test/r/innodb.result: Applied innodb-5.1-ss1404 snapshot Revision r1404: Report the current value of the AUTO_INCREMENT counter to MySQL. (Bug #23313, Bug #21404) ha_innobase::update_create_info(): New function, to report the auto_increment_value. mysql-test/t/innodb.test: Applied innodb-5.1-ss1404 snapshot Revision r1404: Report the current value of the AUTO_INCREMENT counter to MySQL. (Bug #23313, Bug #21404) ha_innobase::update_create_info(): New function, to report the auto_increment_value. storage/innobase/handler/ha_innodb.cc: Applied innodb-5.1-ss1404 snapshot Revision r1404: Report the current value of the AUTO_INCREMENT counter to MySQL. (Bug #23313, Bug #21404) ha_innobase::update_create_info(): New function, to report the auto_increment_value. storage/innobase/handler/ha_innodb.h: Applied innodb-5.1-ss1404 snapshot Revision r1404: Report the current value of the AUTO_INCREMENT counter to MySQL. (Bug #23313, Bug #21404) ha_innobase::update_create_info(): New function, to report the auto_increment_value. storage/innobase/os/os0file.c: Applied innodb-5.1-ss1404 snapshot Revision r1395: * Fix Bug#26662 by not open(2)ing with O_DIRECT but rather calling fcntl(2) to set this flag immediately after open(2)ing. This way an error caused by O_DIRECT not being supported can easily be ignored. * Add support for skipping the OS caching on Solaris by calling directio() instead of fcntl(). Approved by: Heikki Revision r1391: Merge the bodies of os_file_handle_error() and os_file_handle_error_no_exit() into a generic function which is called from both os_file_handle_error() and os_file_handle_error_no_exit() Approved by: Marko storage/innobase/plug.in: Applied innodb-5.1-ss1404 snapshot Revision r1395: * Fix Bug#26662 by not open(2)ing with O_DIRECT but rather calling fcntl(2) to set this flag immediately after open(2)ing. This way an error caused by O_DIRECT not being supported can easily be ignored. * Add support for skipping the OS caching on Solaris by calling directio() instead of fcntl(). Approved by: Heikki
-
- 16 Apr, 2007 1 commit
-
-
unknown authored
client/mysqltest.c: warnings extra/comp_err.c: warnings sql/event_queue.cc: warnings sql/handler.h: warnings sql/opt_range.cc: warnings sql/opt_range.h: warnings sql/rpl_mi.cc: warnings sql/sql_class.cc: wl#2936 post-merge fixes, warnings
-
- 15 Apr, 2007 1 commit
-
-
unknown authored
fixed an assert crash include/mysql/plugin.h: more wl#2936 fixes: no implicit ha_thd() calls mysql-test/mysql-test-run.pl: don't load system-wide plugins mysql-test/r/partition_innodb.result: fix the test mysql-test/t/partition_innodb.test: fix the test sql/handler.cc: more wl#2936 fixes: no implicit ha_thd() calls sql/handler.h: more wl#2936 fixes: no implicit ha_thd() calls sql/sql_class.cc: more wl#2936 fixes: no implicit ha_thd() calls sql/sql_plugin.cc: more wl#2936 fixes: assert crash storage/innobase/handler/ha_innodb.cc: more wl#2936 fixes: no implicit ha_thd() calls
-
- 13 Apr, 2007 1 commit
-
-
unknown authored
include/mysql/plugin.h: warning. no int/realsize mysys/my_getopt.c: combination of prefixes (e.g. --loose-skip-) didn't work sql/event_queue.cc: warning sql/handler.cc: assert sql/handler.h: comment sql/item_create.cc: warnings sql/log.cc: warnings sql/mysqld.cc: wl#2936 - fixing problems (memory leak in load_defaults, garbage in opt_[slow_]logname sql/partition_element.h: warnings sql/rpl_utility.h: warnings sql/set_var.cc: comment sql/set_var.h: warnings sql/sql_class.cc: warnings sql/sql_parse.cc: warnings sql/sql_plugin.cc: wl#2936 - fixing problems: portability, coding style, reporting of spurious errors, crashes, incorrect help output storage/example/ha_example.cc: comment storage/innobase/handler/ha_innodb.cc: wl#2936 - fixing problems (crash)
-
- 03 Apr, 2007 1 commit
-
-
unknown authored
client/mysqldump.c: fixed typo include/mysql_com.h: added new constants SYSTEM_CHARSET_MBMAXLEN, NAME_CHAR_LEN, USERNAME_CHAR_LENGTH increased NAME_LEN, USERNAME_LENGTH mysql-test/r/create.result: result fix mysql-test/r/grant.result: result fix mysql-test/r/mysql.result: result fix mysql-test/r/sp.result: result fix mysql-test/t/create.test: test case mysql-test/t/grant.test: test case sql/events.cc: NAME_LEN is replaced with NAME_CHAR_LEN sql/item_strfunc.h: fixed calculation of max_length sql/mysql_priv.h: check_string_length function is replaced with check_string_byte_length added new function check_string_char_length sql/sp.cc: NAME_LEN is replaced with NAME_CHAR_LEN sql/sp_head.cc: NAME_LEN is replaced with NAME_CHAR_LEN sql/sp_head.h: changed parameter of 'check_routine_name' function sql/sql_class.cc: NAME_LEN is replaced with NAME_CHAR_LEN sql/share/errmsg.txt: increased argument lengths according to new constants sql/sql_parse.cc: removed unnecessary checks added function 'check_string_char_length' sql/sql_plugin.cc: check that name is not longer than NAME_CHAR_LEN symbols sql/sql_show.cc: NAME_LEN is replaced with NAME_CHAR_LEN sql/sql_table.cc: check that key name is not longer than NAME_LEN symbols sql/sql_udf.cc: check that udf name is not longer than NAME_CHAR_LEN symbols sql/sql_yacc.yy: check that user name is not longer than USERNAME_CHAR_LENGTH symbols sql/table.cc: check that db or table or column name is not longer than NAME_LEN symbols storage/innobase/handler/ha_innodb.cc: removed unnecessary multiplication tests/mysql_client_test.c: NAME_LEN is replaced with NAME_CHAR_LEN
-
- 29 Mar, 2007 2 commits
-
-
unknown authored
Bug #27381: InnoDB exits when attempting to rename table to non-existant database Fix Bug#27381 by calling os_file_handle_error_no_exit() instead of os_file_handle_error(). mysql-test/t/innodb.test: Applied innodb-5.1-ss1381 snapshot Revision r1373: Port r1372 from branches/5.0: Merge a change from MySQL AB, and remove the innodb_gis test case. ChangeSet 2007/02/19 13:57:06+03:00 kaa@polly.local Bug#18743: Several test cases fails if "classic" configuration in 5.0 The problem happened because those tests were using "cp932" and "ucs2" without checking whether these character sets are available. This fix moves test parts to make character set specific parts be tested only if they are: - some parts were moved to "ctype_ucs.test" and "ctype_cp932.test" - some parts were moved to the newly added tests "innodb-ucs2.test", "mysqlbinglog-cp932.test" and "sp-ucs2.test" mysql-test/t/innodb.test 2007/02/19 13:57:02+03:00 kaa@polly.local +0 -222 Moved ucs2-specific test cases to innodb-ucs2.test storage/innobase/Makefile.am: Applied innodb-5.1-ss1381 snapshot Revision r1353: Makefile.am: EXTRA_DIST: Add the grammar source files to the source distribution of MySQL. storage/innobase/dict/dict0dict.c: Applied innodb-5.1-ss1381 snapshot Revision r1350: Lock the data dictionary during rollback. This removes the rare debug assertion failure ut_ad(mutex_own(&(dict_sys->mutex))) in dict_table_get_on_id() after the rollback following crash recovery. storage/innobase/handler/ha_innodb.cc: Applied innodb-5.1-ss1381 snapshot Revision r1377: Add static qualifiers to some symbols in ha_innodb.cc that are not referenced from other modules. Revision r1380: Remove ha_innobase::last_query_id and references to thd->query_id. MySQL calls external_lock at the beginning and end of a statement when it is not calling start_stmt or commit or rollback. Thus, statement boundaries can be (and are already) detected without monitoring thd->query_id. The function innobase_commit() seemingly lacks the call to innobase_release_stat_resources(), which should be called at the end of every SQL statement. The call was replaced by equivalent statements by Vadim Tkachenko when he implemented innodb_commit_concurrency in MySQL 5.0: http://mysql.bkbits.net:8080/mysql-5.0/?PAGE=patch&REV=1.1886.70.1 Revision r1355: class ha_innobase: Replace statistic_increment() with ha_statistic_increment(). ha_innobase::change_active_index(): Do not call current_thd unless UNIV_DEBUG is defined. Revision r1369: Merge a change from MySQL AB: ChangeSet@1.2409.1.83 2007-03-06 10:36:15-07:00 tsmith@hindu.god Bug #26598: Create variable to allow turning off of statistic gathering on metadata commands Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). Revision r1342: Minor cleanup in ha_innodb.cc. Remove the unused constants HA_INNOBASE_ROWS_IN_TABLE and HA_INNOBASE_RANGE_COUNT. Declare innobase_active_counter static. Revision r1381: innobase_commit(): Correct the comments and formatting that were broken when innodb_commit_concurrency was implemented. Revision r1360: Minor cleanup. innobase_query_caching_of_table_permitted(): Make static. ha_innobase::register_query_cache_table(): Move the function definition from ha_innodb.h to ha_innodb.cc. Add comments. storage/innobase/handler/ha_innodb.h: Applied innodb-5.1-ss1381 snapshot Revision r1377: Add static qualifiers to some symbols in ha_innodb.cc that are not referenced from other modules. Revision r1380: Remove ha_innobase::last_query_id and references to thd->query_id. MySQL calls external_lock at the beginning and end of a statement when it is not calling start_stmt or commit or rollback. Thus, statement boundaries can be (and are already) detected without monitoring thd->query_id. The function innobase_commit() seemingly lacks the call to innobase_release_stat_resources(), which should be called at the end of every SQL statement. The call was replaced by equivalent statements by Vadim Tkachenko when he implemented innodb_commit_concurrency in MySQL 5.0: http://mysql.bkbits.net:8080/mysql-5.0/?PAGE=patch&REV=1.1886.70.1 Revision r1369: Merge a change from MySQL AB: ChangeSet@1.2409.1.83 2007-03-06 10:36:15-07:00 tsmith@hindu.god Bug #26598: Create variable to allow turning off of statistic gathering on metadata commands Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). Revision r1360: Minor cleanup. innobase_query_caching_of_table_permitted(): Make static. ha_innobase::register_query_cache_table(): Move the function definition from ha_innodb.h to ha_innodb.cc. Add comments. storage/innobase/include/trx0trx.h: Applied innodb-5.1-ss1381 snapshot Revision r1344: Rename the Boolean field trx->type to trx->is_purge and remove the constants TRX_USER and TRX_PURGE. Revision r1343: trx_sig_struct: Remove state. It is always assigned to TRX_SIG_WAITING and never tested. storage/innobase/os/os0file.c: Applied innodb-5.1-ss1381 snapshot Revision r1352: Fix typo in comment in os/os0file.c Approved by: heikki Revision r1366: Fix Bug#27381 by calling os_file_handle_error_no_exit() instead of os_file_handle_error(). Approved by: Heikki storage/innobase/row/row0undo.c: Applied innodb-5.1-ss1381 snapshot Revision r1350: Lock the data dictionary during rollback. This removes the rare debug assertion failure ut_ad(mutex_own(&(dict_sys->mutex))) in dict_table_get_on_id() after the rollback following crash recovery. storage/innobase/trx/trx0purge.c: Applied innodb-5.1-ss1381 snapshot Revision r1344: Rename the Boolean field trx->type to trx->is_purge and remove the constants TRX_USER and TRX_PURGE. storage/innobase/trx/trx0trx.c: Applied innodb-5.1-ss1381 snapshot Revision r1344: Rename the Boolean field trx->type to trx->is_purge and remove the constants TRX_USER and TRX_PURGE. Revision r1343: trx_sig_struct: Remove state. It is always assigned to TRX_SIG_WAITING and never tested.
-
unknown authored
"Plugin Server Variables" Post review cleanups. include/mysql/plugin.h: WL2936 post review clean up fix macros to ensure correct type declarations sql/ha_partition.cc: WL2936 post review clean up add in missing my_afree() sql/handler.cc: WL2936 post review clean up remove stray semicolon sql/sql_plugin.cc: WL2936 post review clean up fixup comments and debug code storage/innobase/handler/ha_innodb.cc: WL2936 Include some of Marko Mäkelä's patches storage/innobase/handler/ha_innodb.h: WL2936 Include some of Marko Mäkelä's patches
-
- 22 Mar, 2007 1 commit
-
-
unknown authored
innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Fixes: - Bug #21409: Incorrect result returned when in READ-COMMITTED with query_cache ON At low transaction isolation levels we let each consistent read set its own snapshot. - Bug #23666: strange Innodb_row_lock_time_% values in show status; also millisecs wrong On Windows ut_usectime returns secs and usecs relative to the UNIX epoch (which is Jan, 1 1970). - Bug #25494: LATEST DEADLOCK INFORMATION is not always cleared lock_deadlock_recursive(): When the search depth or length is exceeded, rewind lock_latest_err_file and display the two transactions at the point of aborting the search. - Bug #25927: Foreign key with ON DELETE SET NULL on NOT NULL can crash server Prevent ALTER TABLE ... MODIFY ... NOT NULL on columns for which there is a foreign key constraint ON ... SET NULL. - Bug #26835: Repeatable corruption of utf8-enabled tables inside InnoDB The bug could be reproduced as follows: Define a table so that the first column of the clustered index is a VARCHAR or a UTF-8 CHAR in a collation where sequences of bytes of differing length are considered equivalent. Insert and delete a record. Before the delete-marked record is purged, insert another record whose first column is of different length but equivalent to the first record. Under certain conditions, the insertion can be incorrectly performed as update-in-place. Likewise, an operation that could be done as update-in-place can unnecessarily be performed as delete and insert, but that would not cause corruption but merely degraded performance. mysql-test/r/innodb.result: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1284: Merge changes from MySQL AB: ChangeSet 2007/01/24 14:49:36+04:00 holyfoot@mysql.com bug 22682 Test fails --without-geometry geometry dependent parts moved to proper .test files mysql-test/r/innodb.result 2007/01/24 14:49:34+04:00 holyfoot@mysql.com +0 -2 result fixed mysql-test/r/innodb_gis.result 2007/01/24 14:49:34+04:00 holyfoot@mysql.com +2 -0 result fixed mysql-test/t/innodb.test 2007/01/24 14:49:34+04:00 holyfoot@mysql.com +0 -6 HAVE_GEOMETRY dependent part moved to innodb_gis.test mysql-test/t/innodb_gis.test 2007/01/24 14:49:35+04:00 holyfoot@mysql.com +6 -0 HAVE_GEOMETRY dependent part moved here from innodb.test Revision r1186: dict_load_foreign(): Use a local variable instead of the 10-bit field foreign->n_fields in order to preserve ON UPDATE CASCADE and ON DELETE CASCADE flags. For some reason, gcc does not warn about shifting a 10-bit field to right by 24 bits. (Bug 24741) This bug was introduced while reducing the memory footprint of the InnoDB data dictionary (Bug 20877). innodb.test, innodb.result: Add a test case. Revision r1318: Add a test case for r1316 (Bug #25927). Revision r1340: innodb.test, innodb.result: Add test case for Bug #26835. The bug could be reproduced as follows: Define a table so that the first column of the clustered index is a VARCHAR or a UTF-8 CHAR in a collation where sequences of bytes of differing length are considered equivalent. Insert and delete a record. Before the delete-marked record is purged, insert another record whose first column is of different length but equivalent to the first record. Under certain conditions, the insertion can be incorrectly performed as update-in-place. Likewise, an operation that could be done as update-in-place can unnecessarily be performed as delete and insert, but that would not cause corruption but merely degraded performance. mysql-test/t/innodb.test: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1284: Merge changes from MySQL AB: ChangeSet 2007/01/24 14:49:36+04:00 holyfoot@mysql.com bug 22682 Test fails --without-geometry geometry dependent parts moved to proper .test files mysql-test/r/innodb.result 2007/01/24 14:49:34+04:00 holyfoot@mysql.com +0 -2 result fixed mysql-test/r/innodb_gis.result 2007/01/24 14:49:34+04:00 holyfoot@mysql.com +2 -0 result fixed mysql-test/t/innodb.test 2007/01/24 14:49:34+04:00 holyfoot@mysql.com +0 -6 HAVE_GEOMETRY dependent part moved to innodb_gis.test mysql-test/t/innodb_gis.test 2007/01/24 14:49:35+04:00 holyfoot@mysql.com +6 -0 HAVE_GEOMETRY dependent part moved here from innodb.test Revision r1283: Merge changes from MySQL AB: ChangeSet 2007/01/22 18:42:52+02:00 monty@mysql.com Give warnings for unused objects Changed error message to be compatible with old error file Added new error message for new DUP_ENTRY syntax mysql-test/t/innodb.test 2007/01/22 18:42:49+02:00 monty@mysql.com +14 -14 Changed to use new error message Revision r1186: dict_load_foreign(): Use a local variable instead of the 10-bit field foreign->n_fields in order to preserve ON UPDATE CASCADE and ON DELETE CASCADE flags. For some reason, gcc does not warn about shifting a 10-bit field to right by 24 bits. (Bug 24741) This bug was introduced while reducing the memory footprint of the InnoDB data dictionary (Bug 20877). innodb.test, innodb.result: Add a test case. Revision r1318: Add a test case for r1316 (Bug #25927). Revision r1329: Merge changes from MySQL AB to mysql-test directives. The results are not affected. Revision r1340: innodb.test, innodb.result: Add test case for Bug #26835. The bug could be reproduced as follows: Define a table so that the first column of the clustered index is a VARCHAR or a UTF-8 CHAR in a collation where sequences of bytes of differing length are considered equivalent. Insert and delete a record. Before the delete-marked record is purged, insert another record whose first column is of different length but equivalent to the first record. Under certain conditions, the insertion can be incorrectly performed as update-in-place. Likewise, an operation that could be done as update-in-place can unnecessarily be performed as delete and insert, but that would not cause corruption but merely degraded performance. storage/innobase/buf/buf0buf.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/buf/buf0flu.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/buf/buf0lru.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/dict/dict0boot.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/dict/dict0crea.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 storage/innobase/dict/dict0dict.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1316: Prevent ALTER TABLE ... MODIFY ... NOT NULL on columns for which there is a foreign key constraint ON ... SET NULL. (Bug #25927) dict_foreign_find_index(): Add paramettter check_null. dict_foreign_add_to_cache(): Do not allow ON DELETE SET NULL or ON UPDATE SET NULL if any of the referencing columns are declared NOT NULL. Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 storage/innobase/dict/dict0load.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1186: dict_load_foreign(): Use a local variable instead of the 10-bit field foreign->n_fields in order to preserve ON UPDATE CASCADE and ON DELETE CASCADE flags. For some reason, gcc does not warn about shifting a 10-bit field to right by 24 bits. (Bug 24741) This bug was introduced while reducing the memory footprint of the InnoDB data dictionary (Bug 20877). innodb.test, innodb.result: Add a test case. Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 storage/innobase/fil/fil0fil.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/fsp/fsp0fsp.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/ha/ha0ha.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/handler/ha_innodb.cc: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1204: Change this in ha_innobase: void* innobase_prebuilt; to this: row_prebuilt_t* prebuilt; by introducing the typedef in ha_innodb.h, and remove all the now needless local variables and casts in ha_innodb.cc. Revision r1298: ha_innodb.cc: Remove all references to thd->ha_data[hton->slot]. thd_to_trx(thd, hton): Accessor for getting the InnoDB trx object of a MySQL thread object and an InnoDB handlerton. Revision r1292: Remove the declarations of some global functions in ha_innodb.h and declare them static in ha_innodb.cc. These functions are invoked via function pointers in handlerton. Revision r1300: ha_innodb.cc: Replace thd->tablespace_op with thd_tablespace_op(thd). Plugins must treat class THD as an opaque type. Revision r1198: Merge a change from MySQL AB: ChangeSet@1.2372, 2006-12-31 02:29:11+01:00, kent@mysql.com +79 -0 Many files: Removed "MySQL Finland AB & TCX DataKonsult AB" from copyright header Adjusted year(s) in copyright header Added GPL copyright text Revision r1271: Merge changes from MySQL AB: Rename some FIELD_TYPE_ constants to MYSQL_TYPE_. Change the scope of a type cast of two dividends. Revision r1299: ha_innodb.cc: Replace thd->in_lock_tables with thd_in_lock_tables(thd). Plugins must treat class THD as an opaque type. Revision r1201: Apply patch from MySQL: ChangeSet@1.2353, 2006-12-19 16:57:51-07:00, tsmith@siva.hindu.god +13 -0 Added innodb_rollback_on_timeout option to restore the 4.1 InnoDB timeout behavior (Bug 24200) Revision r1322: ha_innodb.cc: Remove the unused innobase_repl_ variables. Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 Revision r1334: Fix for Bug# 21409. At low transaction isolation levels we let each consistent read set its own snapshot storage/innobase/handler/ha_innodb.h: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1204: Change this in ha_innobase: void* innobase_prebuilt; to this: row_prebuilt_t* prebuilt; by introducing the typedef in ha_innodb.h, and remove all the now needless local variables and casts in ha_innodb.cc. Revision r1292: Remove the declarations of some global functions in ha_innodb.h and declare them static in ha_innodb.cc. These functions are invoked via function pointers in handlerton. Revision r1198: Merge a change from MySQL AB: ChangeSet@1.2372, 2006-12-31 02:29:11+01:00, kent@mysql.com +79 -0 Many files: Removed "MySQL Finland AB & TCX DataKonsult AB" from copyright header Adjusted year(s) in copyright header Added GPL copyright text Revision r1201: Apply patch from MySQL: ChangeSet@1.2353, 2006-12-19 16:57:51-07:00, tsmith@siva.hindu.god +13 -0 Added innodb_rollback_on_timeout option to restore the 4.1 InnoDB timeout behavior (Bug 24200) storage/innobase/ibuf/ibuf0ibuf.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/buf0buf.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/buf0flu.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/dict0dict.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/ha0ha.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/lock0lock.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/log0log.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/mem0mem.h: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1241: Remove the unused function mem_strdupq(). storage/innobase/include/mem0mem.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1241: Remove the unused function mem_strdupq(). storage/innobase/include/rem0rec.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1338: rec_offs_nth_size(): Treat n==0 as a special case. (Bug #26835) storage/innobase/include/sync0rw.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/sync0sync.h: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1247: Rename mutex_enter_nowait to mutex_enter_nowait_func and add macro mutex_enter_nowait that supplies the default __FILE__ and __LINE__ arguments. Adjust callers. storage/innobase/include/sync0sync.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1294: Fixed inline asm code, it didn't work with GCC > ver 3.x. Revision r1244: Add ut_ad() debug assertions. UT_LIST_ADD_FIRST(), UT_LIST_ADD_LAST(), UT_LIST_INSERT_AFTER(): Assert against some trivial cases of cyclic lists. mutex_enter_func(): Assert that the current thread is not holding the mutex. Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/trx0sys.ic: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/include/univ.i: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1285: Merge a change from MySQL AB: ChangeSet 2006/10/26 15:41:47-04:00 iggy@amd64. Post Merge Cleanup storage/innobase/include/univ.i 2006/10/26 15:38:50-04:00 iggy@amd64. +9 -0 Post Merge Cleanup storage/innobase/include/ut0lst.h: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1244: Add ut_ad() debug assertions. UT_LIST_ADD_FIRST(), UT_LIST_ADD_LAST(), UT_LIST_INSERT_AFTER(): Assert against some trivial cases of cyclic lists. mutex_enter_func(): Assert that the current thread is not holding the mutex. storage/innobase/lock/lock0lock.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1330: lock_deadlock_recursive(): When the search depth or length is exceeded, rewind lock_latest_err_file and display the two transactions at the point of aborting the search. (Bug #25494) Revision r1332: lock_deadlock_recursive(): When aborting the search, display a note regardless of start->undo_no. Otherwise, aborted searches may show up as genuine deadlocks. This mistake was made in r1330. storage/innobase/log/log0log.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1247: Rename mutex_enter_nowait to mutex_enter_nowait_func and add macro mutex_enter_nowait that supplies the default __FILE__ and __LINE__ arguments. Adjust callers. storage/innobase/log/log0recv.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/mem/mem0pool.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/pars/pars0pars.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/que/que0que.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/read/read0read.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/row/row0mysql.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1201: Apply patch from MySQL: ChangeSet@1.2353, 2006-12-19 16:57:51-07:00, tsmith@siva.hindu.god +13 -0 Added innodb_rollback_on_timeout option to restore the 4.1 InnoDB timeout behavior (Bug 24200) Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 storage/innobase/row/row0vers.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/srv/srv0que.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/srv/srv0srv.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1262: Fix for Bug# 23666. On Windows ut_usectime returns secs and usecs relative to the UNIX epoch (which is Jan, 1 1970). Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/sync/sync0rw.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1247: Rename mutex_enter_nowait to mutex_enter_nowait_func and add macro mutex_enter_nowait that supplies the default __FILE__ and __LINE__ arguments. Adjust callers. Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 storage/innobase/sync/sync0sync.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1247: Rename mutex_enter_nowait to mutex_enter_nowait_func and add macro mutex_enter_nowait that supplies the default __FILE__ and __LINE__ arguments. Adjust callers. storage/innobase/thr/thr0loc.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/trx/trx0purge.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/trx/trx0roll.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/trx/trx0rseg.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/trx/trx0sys.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/trx/trx0trx.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. Revision r1324: Merge changes from MySQL AB: ChangeSet@1.2452, 2007-02-23 13:13:55+02:00, monty@mysql.com +177 -0 Fixed compiler warnings ... Fixed compiler warnings detected on windows64 storage/innobase/trx/trx0undo.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/usr/usr0sess.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1242: Merge r1239 from branches/zip: Make mutex_own() work with UNIV_DEBUG, without UNIV_SYNC_DEBUG. storage/innobase/ut/ut0ut.c: Apply the following InnoDB snapshots: innodb-5.1-ss1318 innodb-5.1-ss1330 innodb-5.1-ss1332 innodb-5.1-ss1340 Revision r1262: Fix for Bug# 23666. On Windows ut_usectime returns secs and usecs relative to the UNIX epoch (which is Jan, 1 1970).
-
- 16 Mar, 2007 1 commit
-
-
unknown authored
s/ulonglong/key_part_map/, comments include/heap.h: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ include/my_base.h: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ include/myisam.h: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ include/myisammrg.h: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ sql/event_db_repository.cc: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ sql/ha_partition.cc: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ sql/ha_partition.h: wl#3700 - post-review fixes: s/ulonglong/key_part_map/ sql/sql_select.h: wl#3700 - post-review fixes: remove tab_to_keypart_map()
-
- 06 Mar, 2007 1 commit
-
-
unknown authored
Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). sql/mysqld.cc: Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). sql/set_var.cc: Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). storage/innobase/handler/ha_innodb.cc: Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). storage/innobase/handler/ha_innodb.h: Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). storage/innobase/include/srv0srv.h: Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default). storage/innobase/srv/srv0srv.c: Add innodb_stats_on_metadata option, which enables gathering index statistics when processing metadata commands such as SHOW TABLE STATUS. Default behavior of the server does not change (this option is enabled by default).
-
- 02 Mar, 2007 1 commit
-
-
unknown authored
"Server Variables for Plugins" Implement support for plugins to declare server variables. Demonstrate functionality by removing InnoDB specific code from sql/* New feature for HASH - HASH_UNIQUE flag New feature for DYNAMIC_ARRAY - initializer accepts preallocated ptr. Completed support for plugin reference counting. include/hash.h: New flag for HASH HASH_UNIQUE include/my_getopt.h: New data types for options: ENUM and SET. Use typelib to enumerate possible values. New flag variable: my_getopt_skip_unknown include/my_sys.h: change to DYNAMIC_ARRAY init functions to support pre-allocated buffers include/mysql.h: relocate inclusion of typelib due to longlong requirement include/mysql/plugin.h: wl2936 New declarations for plugin server variable support. New functions for use by plugins include/mysys_err.h: new my_getopt return value: EXIT_ARGUMENT_INVALID include/typelib.h: new typelib function: find_typeset(), returns an int which is a SET of the elements in the typelib mysql-test/r/im_utils.result: change to more specific command line settings --skip-innodb => --skip-plugin-innodb etc. mysql-test/r/log_tables.result: set default storage engine to MEMORY so that test will succeed even when some of the other named storage engines are not present mysql-test/r/ndb_dd_basic.result: change in error message mysql-test/r/partition_innodb.result: change in results mysql-test/r/ps_1general.result: bdb doesn't exist, use myisam for a non-transactional engine mysql-test/r/variables.result: information schema doesn't sort row results for server variables. mysql-test/t/log_tables.test: set default storage engine to MEMORY so that test will succeed even when some of the other named storage engines are not present mysql-test/t/ndb_dd_basic.test: ALTER LOGFILE GROUP no longer silently fail here mysql-test/t/partition_innodb.test: ALTER TABLE no longer silently fails for unknown storage engine mysql-test/t/ps_1general.test: remove unneccessary parts use myisam as it is an always present non-transactional engine mysql-test/t/variables.test: information schema doesn't sort row results for server variables. mysql-test/t/warnings_engine_disabled-master.opt: use the new style command line option mysys/array.c: change to DYNAMIC_ARRAY init functions to support pre-allocated buffers mysys/hash.c: New flag for HASH HASH_UNIQUE Implement HASH_UNIQUE functionality by performing a hash_search mysys/my_getopt.c: New data types for options: ENUM and SET. Use typelib to enumerate possible values. New flag variable: my_getopt_skip_unknown mysys/typelib.c: new typelib function: find_typeset(), returns an int which is a SET of the elements in the typelib sql/ha_ndbcluster.cc: use ha_statistic_increment() method instead of statistic_increment() function ha_ndbcluster variable has gone away. sql/ha_partition.cc: fix for reference counting sql/ha_partition.h: fix for reference counting sql/handler.cc: fixes for reference counting sql/handler.h: fixes for reference counting some new methods to aid storage engine writers sql/item_func.cc: find_sys_var() function now requires thd sql/item_sum.cc: fixes for ref counting sql/mysql_priv.h: remove unneccessary globals. new lock: LOCK_system_variables_hash sql/mysqld.cc: Remove InnoBase specific code. Support plugin command line processing. sql/set_var.cc: Remove InnoBase specific declarations Remove redundant declarations changes to permit new variables at run time changes for ref counting sql/set_var.h: changes to permit new variables at run time changes for ref counting sql/sql_base.cc: changes for ref counting sql/sql_cache.cc: mark code as needing work in the future sql/sql_class.cc: new functions to aid plugin authors initialize variables for dynamic plugin variables sql/sql_class.h: remove InnoBase specific declarations New declarations for plugin variables. sql/sql_connect.cc: initialization and cleanup of plugin variables sql/sql_delete.cc: change for ref counting sql/sql_insert.cc: change for ref counting sql/sql_lex.cc: changes for ref counting and plugin variables sql/sql_lex.h: add properties for plugin ref counting, add to distructor to clean up sql/sql_partition.cc: changes for ref counting sql/sql_plugin.cc: WL2936 Plugin Variables New methods and code to support server variables for plugins. New code to complete plugin reference counting Debug code adds further indirection so that malloc debugging can be used to aid finding plugin ref count leaks sql/sql_plugin.h: WL2936 Plugin Variables New methods and code to support server variables for plugins. New code to complete plugin reference counting Debug code adds further indirection so that malloc debugging can be used to aid finding plugin ref count leaks sql/sql_repl.cc: replication system variables moved here from set_var.cc sql/sql_repl.h: new function to initialise replication server variables sql/sql_select.cc: changes for ref counting sql/sql_show.cc: changes for ref counting sql/sql_table.cc: changes for ref counting sql/sql_tablespace.cc: use supplied functions instead of digging into data structures manually sql/sql_yacc.yy: changes for ref counting find_sys_var() now requires thd parameter changes on reporting errors to keep user-visible behaviour the same. sql/structs.h: changes for ref counting sql/table.cc: changes for ref counting sql/table.h: changes for ref counting storage/federated/ha_federated.cc: use ha_statistic_increment() method instead of statistic_increment() function storage/heap/ha_heap.cc: use ha_statistic_increment() method instead of statistic_increment() function storage/innobase/handler/ha_innodb.cc: use ha_statistic_increment() method instead of statistic_increment() function WL2936 Move InnoBase specific code out of mysqld.cc and into here Declare all required server variables for InnoBase storage/innobase/include/trx0trx.h: store a bit more state so that InnoBase does not have to dig into mysqld internal data structures. storage/myisam/ha_myisam.cc: use ha_statistic_increment() method instead of statistic_increment() function storage/myisammrg/ha_myisammrg.cc: use ha_statistic_increment() method instead of statistic_increment() function
-
- 23 Feb, 2007 1 commit
-
-
unknown authored
Fixed compile-pentium64 scripts Fixed wrong estimate of update_with_key_prefix in sql-bench Merge bk-internal.mysql.com:/home/bk/mysql-5.1 into mysql.com:/home/my/mysql-5.1 Fixed unsafe define of uint4korr() Fixed that --extern works with mysql-test-run.pl Small trivial cleanups This also fixes a bug in counting number of rows that are updated when we have many simultanous queries Move all connection handling and command exectuion main loop from sql_parse.cc to sql_connection.cc Split handle_one_connection() into reusable sub functions. Split create_new_thread() into reusable sub functions. Added thread_scheduler; Preliminary interface code for future thread_handling code. Use 'my_thread_id' for internal thread id's Make thr_alarm_kill() to depend on thread_id instead of thread Make thr_abort_locks_for_thread() depend on thread_id instead of thread In store_globals(), set my_thread_var->id to be thd->thread_id. Use my_thread_var->id as basis for my_thread_name() The above changes makes the connection we have between THD and threads more soft. Added a lot of DBUG_PRINT() and DBUG_ASSERT() functions Fixed compiler warnings Fixed core dumps when running with --debug Removed setting of signal masks (was never used) Made event code call pthread_exit() (portability fix) Fixed that event code doesn't call DBUG_xxx functions before my_thread_init() is called. Made handling of thread_id and thd->variables.pseudo_thread_id uniform. Removed one common 'not freed memory' warning from mysqltest Fixed a couple of usage of not initialized warnings (unlikely cases) Suppress compiler warnings from bdb and (for the moment) warnings from ndb BitKeeper/deleted/.del-SETUP.sh.rej: Rename: BUILD/SETUP.sh.rej -> BitKeeper/deleted/.del-SETUP.sh.rej BitKeeper/deleted/.del-configure.in.rej: Rename: configure.in.rej -> BitKeeper/deleted/.del-configure.in.rej BitKeeper/deleted/.del-my_global.h.rej: Rename: include/my_global.h.rej -> BitKeeper/deleted/.del-my_global.h.rej BitKeeper/deleted/.del-my_pthread.h.rej: Rename: include/my_pthread.h.rej -> BitKeeper/deleted/.del-my_pthread.h.rej BitKeeper/deleted/.del-mysql_client_test.c.rej: Rename: tests/mysql_client_test.c.rej -> BitKeeper/deleted/.del-mysql_client_test.c.rej BitKeeper/deleted/.del-mysqld.cc.rej~35c1c438e11ebd89: Rename: sql/mysqld.cc.rej -> BitKeeper/deleted/.del-mysqld.cc.rej~35c1c438e11ebd89 BitKeeper/deleted/.del-sql_parse.cc.rej: Rename: sql/sql_parse.cc.rej -> BitKeeper/deleted/.del-sql_parse.cc.rej BitKeeper/deleted/.del-table.cc.rej: Rename: sql/table.cc.rej -> BitKeeper/deleted/.del-table.cc.rej BitKeeper/deleted/.del-thr_alarm.c.rej: Rename: mysys/thr_alarm.c.rej -> BitKeeper/deleted/.del-thr_alarm.c.rej BUILD/compile-pentium64: Update this to be in line with compile-pentium BUILD/compile-pentium: Send command line options to SETUP.sh BUILD/compile-solaris-sparc-debug: Update scripts BUILD/compile-solaris-sparc-forte: Update scripts BUILD/compile-solaris-sparc-purify: Update scripts BUILD/compile-solaris-sparc: Update scripts BitKeeper/deleted/.del-DbtupSystemRestart.cpp~15b54d7e4e75d2d: Removed compiler warning BitKeeper/deleted/.del-ha_berkeley.cc: Moved get_auto_primary_key() here as int5store() gives (wrong) compiler warnings in win64 configure.in: Added detection of port_create and port.h (for future)as --- manual merge BitKeeper/deleted/.del-ha_berkeley.h: Moved get_auto_primary_key() to ha_berkeley.cc BitKeeper/deleted/.del-mysqlmanager.c~e97636d71145a0b: Fixed compiler warnings BitKeeper/etc/ignore: added storage/ndb/src/ndbapi/ndberror_check client/mysqlbinlog.cc: Removed not needed 'static' (caused compiler warning) client/mysqldump.c: Fixed compiler warnings from 'max' build client/mysqltest.c: Free warning and query memory no abort. (Removes strange warnings on screen if mysql-test-run fails) Removed compiler warnings Portability fix for windows (windows doesn't have mode_t) client/sql_string.h: Removed compiler warning cmd-line-utils/readline/xmalloc.c: Fixed compiler warnings from 'max' build extra/charset2html.c: Fixed compiler warnings extra/comp_err.c: Fixed compiler warnings from 'max' build extra/yassl/include/lock.hpp: Fix for windows64 extra/yassl/include/openssl/ssl.h: Changed prototype for SSL_set_fd() to fix compiler warnings (and possible errors) on windows 64 bit extra/yassl/include/socket_wrapper.hpp: Moved socket_t to ssl.h, to be able to removed compiler warnings on windows 64 bit extra/yassl/include/yassl.hpp: Fix for windows64 extra/yassl/src/ssl.cpp: Removed compiler warning Detect wrong parameter (Happens when running test suite on solaris) Changed prototype for SSL_set_fd() to fix compiler warnings (and possible errors) on windows 64 bit extra/yassl/taocrypt/src/integer.cpp: Fixed compiler warnings extra/yassl/testsuite/testsuite.cpp: Removed compiler warning include/config-win.h: Added HAVE_WINSOCK2 (for future) include/my_dbug.h: Fixed DBUG_PROCESS() so that we don't get compiler warnings for it include/my_global.h: Fixed unsafe define of uint4korr() manual merge (ignore changes from 5.0) Fixed warnings on win64 when using int5store and int6store include/my_pthread.h: Added my_thread_id typedef Renamed 'my_thread_id() function to my_thead_dbug_id() include/thr_alarm.h: Make thr_alarm_kill() to depend on thread_id instead of thread include/thr_lock.h: Make thr_abort_locks_for_thread() depend on thread_id instead of thread libmysql/libmysql.def: Fixed compiler warnings on win64 libmysqld/CMakeLists.txt: Added missing files libmysqld/Makefile.am: Added new files libmysqld/lib_sql.cc: Remove not needed code (store_globals() now takes care of things) mysql-test/lib/mtr_report.pl: Removed wrong messages when using --extern mysql-test/mysql-test-run.pl: Fixed that --extern works Print help on stdout instead of stderr (make it easier to pipe it to less) Fixed typo that caused mysql-test-run.pl to fail on Solaris mysql-test/r/keywords.result: manual merge mysql-test/r/ndb_lock.result: After merge fixes mysql-test/r/ps.result: Portability fix mysql-test/t/disabled.def: Disabled ndb_alter_table as this very often fails for me (and have done it for a long time) mysql-test/t/keywords.test: manual merge mysql-test/t/ndb_lock.test: Added other possible error code mysql-test/t/ps.test: Portability fix (when compiling without DLOPEN) mysql-test/t/wait_timeout.test: Don't run this if we are not using a thread per connection (as other thread_handling code may not support timeouts) mysys/base64.c: Fixed compiler warnings on win64 mysys/mf_keycache.c: Fixed compiler warnings mysys/my_getopt.c: Fixed compiler warning mysys/my_init.c: Fixed compiler warning Re-indented long comment mysys/my_thr_init.c: Always use mysys_var->id to generate thread name (makes things uniform accross thread implementations and thread usage) Always generate my_thread_name() when using DBUG Ensure mysys_var->pthread_self is set Fixed compiler warnings mysys/ptr_cmp.c: Fixed compiler warnings from 'max' build mysys/thr_alarm.c: Change thr_alarm_kill() to use mysys_var->id instead of thread id Fixed compiler warning on windows mysys/thr_lock.c: Change thr_abort_locks_for_thread() to use mysys_var->id instead of thread id Add purecov statements around not tested code Fixed compiler warnings mysys/thr_mutex.c: my_thread_id() -> my_thread_dbug_id() server-tools/instance-manager/guardian.cc: Fixed compiler warning server-tools/instance-manager/instance.cc: Fixed compiler warning server-tools/instance-manager/mysql_connection.cc: Fixed compiler warnings server-tools/instance-manager/mysqlmanager.cc: Fixed compiler warnings sql/CMakeLists.txt: Added missing files sql/Makefile.am: Added new files sql/event_scheduler.cc: Added pthread_exit() calls Ensure DBUG_xxx calls are not made before my_thread_init() Use common functions to set up thread handling sql/field.h: manual merge sql/ha_ndbcluster.cc: Removed some trivial 'current_thd' calls sql/handler.cc: Avoid warnings on KILL_CONNECTION Don't print out null pointer with printf() (Causes crashes on Solaris) sql/item.cc: Fixed compiler warnings from 'max' build sql/item_cmpfunc.cc: After merge fixes sql/item_func.cc: Merge embedded and normal code usage (GET_LOCK, RELEASE_LOCK now works on my_thread_id instead of pthread_t) Fixed compiler warning sql/item_strfunc.cc: Fixed compiler warning sql/item_timefunc.cc: Fixed compiler warnings sql/lock.cc: Use (new) parameter to thr_abort_locks_for_thread() sql/log.cc: Fixed compiler warning sql/log_event.cc: Fixed compiler warnings about not used variable sql/mysql_priv.h: Remove TEST_NO_THREADS (not needed with new scheduler interface) Added functions from sql_connect.cc and new functions from sql_parse.cc sql/mysqld.cc: Use thread_scheduler structure to dispatch calls (make code more dynamic) Change --one-thread option to use thread_scheduler interface Made ONE_THREAD option independent of DBUG_BUILD --one-thread is now depricated. One should instead use '--thread-handling=no-threads' Remove not used uname() function. Split create_new_thread() into reusable sub functions. Preliminary interface code for future thread_handling code. Fixed compiler warnings sql/parse_file.cc: Don't send zero pointer to fn_format() (Causes crashes when using --debug) sql/repl_failsafe.cc: Setup pseudo_thread_id same way as other code sql/set_var.cc: Added variables 'thread_handling' Prepare for future variable 'thread_pool_size' Fixed compiler warnings sql/set_var.h: Fixed compiler warning sql/slave.cc: Setup pseudo_thread_id same way as other code Removed not used signal mask sql/sql_acl.cc: Fixed compiler warnings from 'max' build sql/sql_base.cc: Fixed long comments Normalized variable setup Don't destroy value of thd->variables.pseduo_thread_id More DBUG_PRINT()'s More DBUG_ASSERT()'s Fixed compiler warnings from 'max' build sql/sql_class.cc: Remove thd->real_id and thd->dbug_thread_id Added DBUG_ASSERT() Use thread_scheduler to signal threads to be killed. In THD::store_globals(), set my_thread_var->id to be thd->thread_id. Fixed compiler warnings sql/sql_class.h: Use 'my_thread_id' for internal thread id's Remove not needed THD elements: block_signals and dbug_thread_id Added 'thread_scheduler' scheduling extension element to THD sql/sql_insert.cc: After merge fixes (This actually fixes a bug in old code when many connections are in use) Setup pseudo_thread_id same way as other code Removed not used signal mask Initialize variable that may be used unitialized on error conditions (not fatal) sql/sql_parse.cc: Move connection related code to sql_connect.cc Remove setting of signal mask (not needed) Ensure TABLE_LIST->alias is set for generated TABLE_LIST elements (fixed core dumps when running with --debug) Added previous 'optional' element to reset_mgh() Removed not needed DBUG_PRINT call sql/sql_partition.cc: Fixed compiler warnings sql/sql_prepare.cc: Removed not needed casts Fixed compiler warnings from 'max' build sql/sql_select.cc: Fixed compiler warnings sql-bench/bench-init.pl.sh: Added --one-missing-tests sql-bench/example: Better example sql-bench/run-all-tests.sh: Added --only-missing-tests sql-bench/test-insert.sh: Fixed wrong estimate of update_with_key_prefix sql/sql_show.cc: Don't send pthread_kill() to threads to detect if they exists. (Not that useful and causes problems with future thread_handling code) Fixed compiler warnings sql/sql_table.cc: Simplify code Fixed compiler warnings sql/sql_test.cc: Remove dbug_thread_id from test output sql/sql_view.cc: Don't send zero pointer to fn_format() sql/tztime.cc: Fixed compiler warning sql/udf_example.def: Fixed compiler warnings on win64 sql/unireg.cc: Initialize variable that may be used unitialized on error conditions storage/archive/archive_test.c: Fixed compiler warnings storage/archive/azio.c: Fixed compiler warnings storage/innobase/dict/dict0crea.c: Fixed compiler warnings detected on windows64 storage/innobase/dict/dict0dict.c: Fixed compiler warnings detected on windows64 storage/innobase/dict/dict0load.c: Fixed compiler warnings detected on windows64 storage/innobase/dict/dict0mem.c: Fixed compiler warnings detected on windows64 storage/innobase/eval/eval0proc.c: Fixed compiler warnings detected on windows64 storage/innobase/handler/ha_innodb.cc: Fixed compiler warnings detected on windows64 storage/innobase/include/ut0byte.ic: Fixed compiler warnings on win64 storage/innobase/include/ut0ut.ic: Fixed compiler warnings on win64 storage/innobase/mtr/mtr0log.c: Fixed compiler warnings detected on windows64 storage/innobase/pars/pars0lex.l: Fixed warnings on win64 storage/innobase/rem/rem0cmp.c: Fixed compiler warnings detected on windows64 storage/innobase/row/row0mysql.c: Fixed compiler warnings detected on windows64 storage/innobase/row/row0sel.c: Fixed compiler warnings detected on windows64 storage/innobase/sync/sync0rw.c: Fixed compiler warnings detected on windows64 storage/innobase/trx/trx0trx.c: Fixed compiler warnings detected on windows64 storage/myisam/mi_log.c: my_thread_id() -> my_thread_debug_id() storage/myisam/mi_packrec.c: Fixed compiler warnings detected on windows64 storage/myisam/myisamchk.c: Fixed compiler warnings from 'max' build storage/ndb/src/common/debugger/EventLogger.cpp: Fixed compiler warnings storage/ndb/src/common/util/ConfigValues.cpp: Removed compiler warnings storage/ndb/src/common/util/NdbSqlUtil.cpp: Removed compiler warnings storage/ndb/src/cw/cpcd/CPCD.hpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/backup/Backup.cpp: Fixed compiler warnings detected on windows64 storage/ndb/src/kernel/blocks/dbacc/Dbacc.hpp: Fixed compiler warnings detected on windows64 storage/ndb/src/kernel/blocks/dbacc/DbaccMain.cpp: Fixed compiler warnings detected on windows64 storage/ndb/src/kernel/blocks/dbdict/Dbdict.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbdict/Dbdict.hpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbdih/DbdihMain.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dblqh/DblqhMain.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtc/DbtcMain.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/Dbtup.hpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupDiskAlloc.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupExecQuery.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupFixAlloc.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupMeta.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupRoutines.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupScan.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/DbtupVarAlloc.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/tuppage.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtup/tuppage.hpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/dbtux/DbtuxStat.cpp: Fixed compiler warnings storage/ndb/src/kernel/blocks/diskpage.hpp: Fixed compiler warnings storage/ndb/src/kernel/vm/ndbd_malloc.cpp: Fixed compiler warnings storage/ndb/src/kernel/vm/ndbd_malloc_impl.cpp: Fixed compiler warnings storage/ndb/src/mgmclient/main.cpp: Fixed compiler warnings storage/ndb/src/ndbapi/NdbEventOperationImpl.cpp: Fixed compiler warnings storage/ndb/src/ndbapi/NdbOperationExec.cpp: Fixed compiler warnings storage/ndb/src/ndbapi/SignalSender.cpp: Fixed compiler warnings storage/ndb/tools/restore/consumer_restore.cpp: Fixed compiler warnings strings/ctype-ucs2.c: Fixed compiler warnings strings/ctype-utf8.c: Fixed compiler warnings strings/decimal.c: Fixed compiler warnings strings/my_strchr.c: Fixed conflict between function and prototype support-files/compiler_warnings.supp: Ignore warnings from sql_yacc.cc that are hard to remove Ignore some not important warnings from windows 64 bit build Suppress warnings from bdb and (for the moment) warnings from ndb Suppress all warnings for all pushbuild platforms (should make all trees green) vio/viosslfactories.c: Added DBUG_PRINT BUILD/compile-pentium64-max: New BitKeeper file ``BUILD/compile-pentium64-max'' libmysqld/scheduler.cc: New BitKeeper file ``libmysqld/scheduler.cc'' libmysqld/sql_connect.cc: New BitKeeper file ``libmysqld/sql_connect.cc'' mysql-test/include/one_thread_per_connection.inc: New BitKeeper file ``mysql-test/include/one_thread_per_connection.inc'' mysql-test/r/no-threads.result: New BitKeeper file ``mysql-test/r/no-threads.result'' mysql-test/r/one_thread_per_connection.require: New BitKeeper file ``mysql-test/r/one_thread_per_connection.require'' mysql-test/t/no-threads-master.opt: New BitKeeper file ``mysql-test/t/no-threads-master.opt'' mysql-test/t/no-threads.test: New BitKeeper file ``mysql-test/t/no-threads.test'' sql/scheduler.cc: New BitKeeper file ``sql/scheduler.cc'' sql/scheduler.h: New BitKeeper file ``sql/scheduler.h'' sql/sql_connect.cc: New BitKeeper file ``sql/sql_connect.cc''
-
- 29 Jan, 2007 1 commit
-
-
unknown authored
index_read(), index_read_idx(), index_read_last(), and records_in_range() - instead of 'uint keylen' argument take 'ulonglong keypart_map', a bitmap showing which keyparts are present in the key value. Fallback method is provided for handlers that are lagging behind.
-
- 15 Jan, 2007 1 commit
-
-
unknown authored
added new field 'REFERENCED_TABLE_NAME' to 'referential_constraints' table field 'UNIQUE_CONSTRAINT_NAME' contains the name of the referenced index mysql-test/r/information_schema_inno.result: result fix mysql-test/t/information_schema_inno.test: test fix sql/sql_show.cc: added new field 'REFERENCED_TABLE_NAME' to 'referential_constraints' table field 'UNIQUE_CONSTRAINT_NAME' contains the name of the referenced index sql/table.h: added 'referenced_key_name' member to 'st_foreign_key_info' struct storage/innobase/handler/ha_innodb.cc: added the filling of referenced key name
-
- 09 Jan, 2007 1 commit
-
-
unknown authored
Unencode internal db & table name mysql-test/r/information_schema_inno.result: test result mysql-test/t/information_schema_inno.test: test case storage/innobase/handler/ha_innodb.cc: Unencode internal db & table name
-
- 05 Jan, 2007 1 commit
-
-
unknown authored
Fixes: - Bug #24712: SHOW TABLE STATUS for file-per-table showing incorrect time fields - Bug #24386: Performance degradation caused by instrumentation in mutex_struct - Bug #24190: many exportable definitions of field_in_record_is_null - Bug #21468: InnoDB crash during recovery with corrupted data pages: XA bug? storage/innobase/buf/buf0buf.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1045: buf_page_init_for_read(): Correct the indentation. storage/innobase/buf/buf0flu.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1038: Port r983 from branches/zip: Enclose some more debug code in #ifdef UNIV_SYNC_DEBUG to allow the code to be built with UNIV_DEBUG but without UNIV_SYNC_DEBUG. storage/innobase/dict/dict0dict.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1124: Unify dict_table_get_and_increment_handle_count() with dict_table_get() by adding a second parameter, adjust callers. storage/innobase/ha/ha0ha.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/ha/hash0hash.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/handler/ha_innodb.cc: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1028: Merge a change from MySQL AB. ChangeSet 2006/11/10 17:22:43+02:00 aelkin@dsl-hkibras-fe30f900-107.dhcp.inet.fi Bug #24190 many exportable definitions of field_in_record_is_null mysql had several(2) exportable definitions of field_in_record_is_null function. Fixed with adding static. storage/innobase/handler/ha_innodb.cc 2006/11/10 17:22:36+02:00 aelkin@dsl-hkibras-fe30f900-107.dhcp.inet.fi +1 -1 made static Revision r1008: Minor cleanup. ha_innobase::rnd_pos(): Use correct format in DBUG_PRINT statements. buf_page_release(): Remove the local variable buf_fix_count. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) Revision r1124: Unify dict_table_get_and_increment_handle_count() with dict_table_get() by adding a second parameter, adjust callers. Revision r1134: Fix a potential bug in ha_innodb.cc:innobase_query_is_update() where the function can be called with "current_thd == NULL". Minor non-functional fix in log0recv.c Revision r1098: Fix bug #24712: SHOW TABLE STATUS for file-per-table showing incorrect time fields Revision r1109: ha_innodb.cc: Remove unused define MAX_ULONG_BIT. storage/innobase/include/btr0sea.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1088: Replace the Latin abbreviation "cf." in comments. storage/innobase/include/buf0buf.ic: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1008: Minor cleanup. ha_innobase::rnd_pos(): Use correct format in DBUG_PRINT statements. buf_page_release(): Remove the local variable buf_fix_count. storage/innobase/include/data0type.ic: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1088: Replace the Latin abbreviation "cf." in comments. storage/innobase/include/dict0dict.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1124: Unify dict_table_get_and_increment_handle_count() with dict_table_get() by adding a second parameter, adjust callers. storage/innobase/include/ha0ha.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/include/hash0hash.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/include/sync0rw.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/include/sync0sync.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1038: Port r983 from branches/zip: Enclose some more debug code in #ifdef UNIV_SYNC_DEBUG to allow the code to be built with UNIV_DEBUG but without UNIV_SYNC_DEBUG. Revision r1037: Port r972 from branches/zip: Enclose some debug code in #ifdef UNIV_SYNC_DEBUG. The code was previously unused in non-debug builds. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) Revision r1084: Remove the unused constants SYNC_INFINITE_TIME and SYNC_TIME_EXCEEDED. storage/innobase/include/sync0sync.ic: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/include/univ.i: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1006: Introduce #define UNIV_LIST_DEBUG for enabling the debug code in UT_LIST_REMOVE_CLEAR(). Revision r1088: Replace the Latin abbreviation "cf." in comments. Revision r1083: univ.i: Document the debug flags (UNIV_DEBUG et al). storage/innobase/include/ut0lst.h: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1006: Introduce #define UNIV_LIST_DEBUG for enabling the debug code in UT_LIST_REMOVE_CLEAR(). storage/innobase/lock/lock0lock.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1009: Remove duplicate printing of row lock counts in SHOW INNODB STATUS, and in the remaining print, add a comma so it doesn't get combined with the heap size. Both problems were introduced in r383. storage/innobase/log/log0recv.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1134: Fix a potential bug in ha_innodb.cc:innobase_query_is_update() where the function can be called with "current_thd == NULL". Minor non-functional fix in log0recv.c Revision r1078: Merge r1067:1077 from branches/5.0: innobase_start_or_create_for_mysql(): Remove unnecessary delay now that we moved the setting sync_order_checks_on=TRUE to log0recv.c, to the start of the rollback phase in crash recovery. Fix assertion failure sync0sync.c line 1239 (the latter ut_error in sync_thread_reset_level()) in crash recovery when UNIV_SYNC_DEBUG is enabled. Revision r1080: Merge r1079 from branches/5.0: recv_recovery_from_checkpoint_finish(): Add 1 sec delay before switching on the sync order checks in crash recovery, so that file I/O threads have time to suspend themselves. storage/innobase/row/row0ins.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1124: Unify dict_table_get_and_increment_handle_count() with dict_table_get() by adding a second parameter, adjust callers. storage/innobase/row/row0sel.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1038: Port r983 from branches/zip: Enclose some more debug code in #ifdef UNIV_SYNC_DEBUG to allow the code to be built with UNIV_DEBUG but without UNIV_SYNC_DEBUG. Revision r1124: Unify dict_table_get_and_increment_handle_count() with dict_table_get() by adding a second parameter, adjust callers. storage/innobase/row/row0upd.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1124: Unify dict_table_get_and_increment_handle_count() with dict_table_get() by adding a second parameter, adjust callers. storage/innobase/srv/srv0start.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1038: Port r983 from branches/zip: Enclose some more debug code in #ifdef UNIV_SYNC_DEBUG to allow the code to be built with UNIV_DEBUG but without UNIV_SYNC_DEBUG. Revision r1078: Merge r1067:1077 from branches/5.0: innobase_start_or_create_for_mysql(): Remove unnecessary delay now that we moved the setting sync_order_checks_on=TRUE to log0recv.c, to the start of the rollback phase in crash recovery. Fix assertion failure sync0sync.c line 1239 (the latter ut_error in sync_thread_reset_level()) in crash recovery when UNIV_SYNC_DEBUG is enabled. Revision r1070: Remove another accidentally committed change to srv0start.c. The change was accidentally committed with the merge in r1068. This revision corresponds to r1051 with a properly merged r1067 of branches/5.0. Revision r1068: Merge r1067 from branches/5.0: trx_rollback_for_mysql(), trx_commit_for_mysql(): Protect the creation of trx_dummy_sess with kernel_mutex. This error was introduced in r1046 and r1050. Revision r1069: Remove an accidentally committed change to srv0start.c. The change was accidentally committed with the merge in r1068. storage/innobase/sync/sync0rw.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/sync/sync0sync.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1038: Port r983 from branches/zip: Enclose some more debug code in #ifdef UNIV_SYNC_DEBUG to allow the code to be built with UNIV_DEBUG but without UNIV_SYNC_DEBUG. Revision r1037: Port r972 from branches/zip: Enclose some debug code in #ifdef UNIV_SYNC_DEBUG. The code was previously unused in non-debug builds. Revision r1039: Port r1034 from branches/zip: Remove some instrumentation and reduce the output of SHOW MUTEX STATUS in non-debug builds. (Bug #24386) storage/innobase/trx/trx0roll.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1049: Merge r1048 from branches/5.0: trx_rollback_for_mysql(): Do not set trx->sess back to NULL. This bug was introduced in r1046. Revision r1047: Merge r1046 from branches/5.0: branches/5.0: trx_rollback_for_mysql(): Ensure that trx->sess is non-NULL when calling trx_general_rollback_for_mysql(). This removes a segmentation fault when rolling back a prepared transaction in XA recovery. (Bug #21468) Revision r1068: Merge r1067 from branches/5.0: trx_rollback_for_mysql(), trx_commit_for_mysql(): Protect the creation of trx_dummy_sess with kernel_mutex. This error was introduced in r1046 and r1050. Revision r1051: Merge r1050 from branches/5.0: trx_rollback_for_mysql(): Fix the comment introduced in r1046. trx_commit_for_mysql(): Use the dummy trx->sess also for committing a prepared transaction in XA recovery, just in case our code would need the session object also in that case (does not seem to need it right now). storage/innobase/trx/trx0trx.c: Applied innodb-5.1-ss1039 and innodb-5.1-ss1134 snapshots. Revision r1009: Remove duplicate printing of row lock counts in SHOW INNODB STATUS, and in the remaining print, add a comma so it doesn't get combined with the heap size. Both problems were introduced in r383. Revision r1068: Merge r1067 from branches/5.0: trx_rollback_for_mysql(), trx_commit_for_mysql(): Protect the creation of trx_dummy_sess with kernel_mutex. This error was introduced in r1046 and r1050. Revision r1051: Merge r1050 from branches/5.0: trx_rollback_for_mysql(): Fix the comment introduced in r1046. trx_commit_for_mysql(): Use the dummy trx->sess also for committing a prepared transaction in XA recovery, just in case our code would need the session object also in that case (does not seem to need it right now).
-
- 02 Dec, 2006 1 commit
-
-
unknown authored
This finishes the work (someone) started to remove FIELD_ types and use the Enum MYSQL types. The second part to this is to actually deprecate the FIELD defines in mysql_com.h client/mysql.cc: Field update to MYSQL client/mysqldump.c: Field -> MySQL include/mysql.h: Field -> MySQL server-tools/instance-manager/protocol.cc: Field -> MySQL sql/field.cc: Field -> MySQL sql/field.h: Field -> MySQL sql/field_conv.cc: Field -> MySQL sql/handler.cc: Field -> MySQL sql/item.cc: Field -> MYSQL sql/item_func.cc: Field -> MySQL sql/item_subselect.cc: Field -> MySQL sql/item_subselect.h: Field -> MySQL sql/item_sum.h: Field -> MySQL sql/item_timefunc.cc: Field -> MySQL sql/log_event.cc: Field -> MySQL sql/opt_range.cc: Field -> MySQL sql/sp.cc: Field -> MySQL sql/sql_acl.cc: Field -> MYSQL sql/sql_analyse.cc: Field -> MYSQL sql/sql_insert.cc: Field -> MySQL sql/sql_load.cc: Field -> MySQL sql/sql_parse.cc: Field -> MySQL sql/sql_select.cc: Field -> MySQL sql/sql_select.h: Field -> MySQL sql/sql_show.cc: Field -> MySQL sql/sql_table.cc: Field -> MySQL sql/sql_yacc.yy: Field -> MySQL sql/table.cc: Field -> MySQL sql/unireg.cc: Field -> MySQL storage/innobase/handler/ha_innodb.cc: Field -> MySQL storage/myisam/ha_myisam.cc: Field -> MySQL tests/mysql_client_test.c: Field -> MySQL
-
- 21 Nov, 2006 1 commit
-
-
unknown authored
Moved .progress files into the log directory Moved 'cluster' database tables into the MySQL database, to not have 'cluster' beeing a reserved database name Fixed bug where mysqld got a core dump when trying to use a table created by MySQL 3.23 Fixed some compiler warnings Fixed small memory leak in libmysql Note that this doesn't changeset doesn't include the new mysqldump.c code required to run some tests. This will be added when I merge 5.0 to 5.1 client/client_priv.h: Added OPT_DEBUG_INFO and OPT_COLUMN_TYPES client/mysql.cc: Split --debug-info into --debug-info and --column-type-info client/mysql_upgrade.c: Give only error info at end if using --debug-info client/mysqladmin.cc: Added --debug-info to detect memory leaks in mysqltest client/mysqlbinlog.cc: Added --debug-info to detect memory leaks in mysqltest client/mysqlcheck.c: Added --debug-info to detect memory leaks in mysqltest client/mysqlimport.c: Added --debug-info to detect memory leaks in mysqltest client/mysqlshow.c: Added --debug-info to detect memory leaks in mysqltest client/mysqltest.c: Added --debug-info to detect memory leaks in mysqltest Added option --logdir to force .progress files in a specific directory libmysql/libmysql.c: Fixed memory leak mysql-test/include/ndb_setup_slave.inc: Moved cluster tables under 'mysql' mysql-test/include/query_cache.inc: Added more tests for query cache mysql-test/lib/init_db.sql: Move cluster.binlog_index -> mysql.binlog_index mysql-test/lib/mtr_report.pl: Find memory leaks mysql-test/mysql-test-run-shell.sh: Added --debug-info to programs to detect memory leaks mysql-test/mysql-test-run.pl: Added --debug-info to programs to detect memory leaks Force log files to var/log cluster tables moved under 'mysql' mysql-test/r/cache_innodb.result: New query cache test with innodb mysql-test/r/connect.result: binlog_index is now in mysql mysql-test/r/drop.result: Removed 'cluster' database mysql-test/r/information_schema.result: Removed 'cluster' database mysql-test/r/mysqlcheck.result: cluster.binlog_index -> mysql.binlog_index mysql-test/r/ndb_binlog_basic.result: cluster.binlog_index -> mysql.binlog_index mysql-test/r/ndb_binlog_ddl_multi.result: cluster -> mysql mysql-test/r/ndb_binlog_discover.result: cluster -> mysql mysql-test/r/ndb_binlog_multi.result: cluster -> mysql mysql-test/r/ndb_restore_compat.result: cluster -> mysql mysql-test/r/ps_1general.result: Removed cluster database mysql-test/r/rpl_create_database.result: Removed cluster database mysql-test/r/rpl_load_from_master.result: Removed cluster database mysql-test/r/rpl_loaddata_m.result: Removed cluster database mysql-test/r/rpl_ndb_bank.result: cluster -> mysql mysql-test/r/rpl_ndb_dd_advance.result: cluster -> mysql mysql-test/r/rpl_ndb_dd_basic.result: cluster -> mysql mysql-test/r/rpl_ndb_idempotent.result: cluster -> mysql mysql-test/r/rpl_ndb_log.result: cluster -> mysql mysql-test/r/rpl_ndb_multi.result: cluster -> mysql mysql-test/r/rpl_ndb_sync.result: cluster -> mysql mysql-test/r/rpl_row_basic_11bugs.result: Removed cluster database mysql-test/r/rpl_truncate_7ndb.result: Position have changed mysql-test/r/rpl_truncate_7ndb_2.result: cluster -> mysql mysql-test/r/schema.result: Removed cluster database mysql-test/r/show_check.result: Removed cluster database mysql-test/r/system_mysql_db.result: binlog_index moved under mysql mysql-test/r/upgrade.result: More tests mysql-test/t/information_schema.test: cluster -> mysql mysql-test/t/mysqldump.test: More test to detect memory leaks mysql-test/t/ndb_binlog_basic.test: cluster -> mysql mysql-test/t/ndb_binlog_multi.test: cluster -> mysql mysql-test/t/ndb_restore_compat.test: cluster -> mysql mysql-test/t/rpl_ndb_bank.test: cluster -> mysql mysql-test/t/rpl_ndb_dd_advance.test: cluster -> mysql mysql-test/t/rpl_ndb_idempotent.test: cluster -> mysql mysql-test/t/rpl_ndb_multi.test: cluster -> mysql mysql-test/t/rpl_ndb_sync.test: cluster -> mysql mysql-test/t/system_mysql_db_fix.test: Drop also binlog_index mysql-test/t/upgrade.test: Check that tables created with 3.23 works mysys/my_error.c: Remove all registered errors (to avoid memory leaks) mysys/my_init.c: call my_error_unregister_all() to avoid some possible memory leaks mysys/mysys_priv.h: Added prototype scripts/mysql_create_system_tables.sh: cluster -> mysql scripts/mysql_fix_privilege_tables.sql: Changed -- to # Create binlog_index table if it dosesn't exist sql/field.cc: Made offset() inline sql/field.h: Changed prototype of offset() to not make it depending on TABLE structure sql/field_conv.cc: Removed some usage of current_thd sql/ha_ndbcluster_tables.h: cluster -> mysql sql/item_sum.cc: Usage of new 'offset' parameters sql/key.cc: Changed 'find_ref_key' to not be dependent on field->table (This fixed a crash when using a table created in MySQL 3.23) sql/mysql_priv.h: Changed find_ref_key() to not use field->table sql/mysqld.cc: Fix that plugin_init() works properly on bootstrap (Previously we got warnings from plugin_init) sql/sql_class.cc: new 'field->offset()' sql/sql_select.cc: New field->offset() sql/table.cc: We don't need field->table to be set in find_ref_key() or find_field() anymore. storage/archive/ha_archive.cc: New field->offset() storage/federated/ha_federated.cc: New field->offset() storage/innobase/handler/ha_innodb.cc: Fixed compiler warnings storage/myisam/ha_myisam.cc: Fixed compiler warnings (Wrong paramter to sprintf()) New field->offset() storage/myisam/ha_myisam.h: Fixed wrong type of table_flags storage/ndb/tools/restore/Restore.cpp: Fixed compiler warning mysql-test/r/1st.result: New BitKeeper file ``mysql-test/r/1st.result'' mysql-test/std_data/old_table-323.frm: New BitKeeper file ``mysql-test/std_data/old_table-323.frm'' mysql-test/t/1st.test: New BitKeeper file ``mysql-test/t/1st.test''
-
- 10 Nov, 2006 1 commit
-
-
unknown authored
mysql had several(2) exportable definitions of field_in_record_is_null function. Fixed with adding static. storage/federated/ha_federated.cc: made static storage/innobase/handler/ha_innodb.cc: made static
-
- 20 Oct, 2006 1 commit
-
-
unknown authored
Fixes: - Bug #18077: InnoDB uses full explicit table locks in stored FUNCTION storage/innobase/btr/btr0btr.c: Apply InnoDB snapshot ss923 Revision r919: btr_page_get_father_for_rec(): Remove bogus comment about removed dict_tree_t. storage/innobase/dict/dict0dict.c: Apply InnoDB snapshot ss923 Revision r892: Merge changes from MySQL AB. dict_col_copy_type_noninline(): Remove the return statement. Some compilers do not allow return expressions of void type. innobase_start_or_create_for_mysql(): Do not cap srv_max_threads to 1000 on Windows. Makefile.am (EXTRA_DIST): Add plug.in Revision r897: dict_index_get_if_in_cache(): Enclose in #ifdef UNIV_DEBUG. Replace the search loop with a call to dict_index_find_on_id_low(). storage/innobase/handler/ha_innodb.cc: Apply InnoDB snapshot ss923 Revision r887: storage/innobase/handler: Merge changes from MySQL AB: ChangeSet 2006/09/30 18:44:42-07:00 brian@zim.(none) Merge zim.(none):/home/brian/mysql/merge-5.1 into zim.(none):/home/brian/mysql/arch-5.1 ChangeSet 2006/09/30 12:49:46-07:00 brian@zim.(none) This patch adds handlerton passing to functions. NDB and Innodb still require a global hanlderton in the main code due to the nature of the sql_cache call back function (should be solveable... another patch). Partitioning now has a flag to allow disabling of engines from being compatible with partitioning. Cleaned up heap naming convention on panic call. ChangeSet 2006/09/29 17:19:02-07:00 brian@zim.(none) This removes the passing of global hton to engine instance. ChangeSet 2006/09/28 13:22:56+02:00 gbichot@dl145h.mysql.com Merge gbichot@bk-internal:/home/bk/mysql-5.1-arch into dl145h.mysql.com:/users/gbichot/mysql-5.1-arch ChangeSet 2006/09/28 13:19:43+02:00 gbichot@dl145h.mysql.com In the handlerton, cursor creation function don't have an argument and so the engine calls current_thd to derive transaction information; instead we now pass THD to those functions, it looks more logical (it makes the implicit current_thd parameter more visible). Approved by Brian and Monty. ChangeSet 2006/09/26 22:51:53-07:00 brian@zim.(none) Merge zim.(none):/home/brian/mysql/merge-5.1 into zim.(none):/home/brian/mysql/arch-5.1 Revision r895: Merge changes from MySQL AB, and remove two compilation warnings. ha_innodb.cc: innodb_mutex_show_status(): Add (ulong) casts to ulonglong expressions being passed to fprintf %lu. The warnings were apparently introduced by MySQL AB developers. mysql_declare_plugin(innobase): Add PLUGIN_LICENSE_GPL. have_innodb.inc: Merge changes from MySQL AB. Revision r923: ha_innobase::store_lock(): When downgrading table locks, do not check thd->in_lock_tables but test if thd->lex->sql_command == SQLCOM_LOCK_TABLES instead. Otherwise, stored functions will use table locks. (Bug #18077) This patch is from Heikki. storage/innobase/include/dict0dict.h: Apply InnoDB snapshot ss923 Revision r897: dict_index_get_if_in_cache(): Enclose in #ifdef UNIV_DEBUG. Replace the search loop with a call to dict_index_find_on_id_low(). storage/innobase/include/mem0dbg.h: Apply InnoDB snapshot ss923 Revision r901: Enclose some mem debug functions in #ifdef UNIV_DEBUG or #ifdef UNIV_MEM_DEBUG. storage/innobase/include/mtr0mtr.h: Apply InnoDB snapshot ss923 Revision r866: mtr_print(), mtr_memo_contains(): Disable unless #ifdef UNIV_DEBUG. storage/innobase/include/mtr0mtr.ic: Apply InnoDB snapshot ss923 Revision r866: mtr_print(), mtr_memo_contains(): Disable unless #ifdef UNIV_DEBUG. storage/innobase/include/sync0rw.h: Apply InnoDB snapshot ss923 Revision r907: Send all SHOW ENGINE INNODB STATUS information to the client also when UNIV_SYNC_DEBUG is defined. rw_lock_list_print_info(): Add parameter "file". mutex_list_print_info(): Add parameter "file". Make the function static. storage/innobase/include/sync0sync.h: Apply InnoDB snapshot ss923 Revision r907: Send all SHOW ENGINE INNODB STATUS information to the client also when UNIV_SYNC_DEBUG is defined. rw_lock_list_print_info(): Add parameter "file". mutex_list_print_info(): Add parameter "file". Make the function static. storage/innobase/include/univ.i: Apply InnoDB snapshot ss923 Revision r894: univ.i: Indent some of the directives, and remove conditions about Windows in the "#else" branch of "#if building on Windows". storage/innobase/mem/mem0dbg.c: Apply InnoDB snapshot ss923 Revision r901: Enclose some mem debug functions in #ifdef UNIV_DEBUG or #ifdef UNIV_MEM_DEBUG. Revision r902: mem0dbg.c: Enclose some more function definitions in #ifdef UNIV_MEM_DEBUG. The declarations were already enclosed in #ifdef UNIV_MEM_DEBUG. storage/innobase/mem/mem0pool.c: Apply InnoDB snapshot ss923 Revision r896: mem0pool.c: Remove obsolete comments about the dictionary cache being managed with an LRU algorithm. storage/innobase/mtr/mtr0mtr.c: Apply InnoDB snapshot ss923 Revision r866: mtr_print(), mtr_memo_contains(): Disable unless #ifdef UNIV_DEBUG. storage/innobase/row/row0purge.c: Apply InnoDB snapshot ss923 Revision r869: row_purge_parse_undo_rec(): Correct a faulty condition. Luckily, this bug would only surface if the InnoDB SQL interpreter were used for updating fixed-length columns. Currently (as the UPD_NODE_NO_SIZE_CHANGE flag is never set), cmpl_info can only be 0 or UPD_NODE_NO_ORD_CHANGE. Luckily, UPD_NODE_NO_ORD_CHANGE is 1, and the condition was simplified to !cmpl_info. storage/innobase/sync/sync0rw.c: Apply InnoDB snapshot ss923 Revision r907: Send all SHOW ENGINE INNODB STATUS information to the client also when UNIV_SYNC_DEBUG is defined. rw_lock_list_print_info(): Add parameter "file". mutex_list_print_info(): Add parameter "file". Make the function static. storage/innobase/sync/sync0sync.c: Apply InnoDB snapshot ss923 Revision r907: Send all SHOW ENGINE INNODB STATUS information to the client also when UNIV_SYNC_DEBUG is defined. rw_lock_list_print_info(): Add parameter "file". mutex_list_print_info(): Add parameter "file". Make the function static.
-
- 05 Oct, 2006 1 commit
-
-
unknown authored
Added license information display to output of plugins schema, and tagged all plugins with GPL flag. include/mysql/plugin.h: Adding license information. plugin/fulltext/plugin_example.c: License sql/ha_ndbcluster.cc: License sql/ha_partition.cc: License sql/handler.h: License sql/log.cc: License sql/sql_show.cc: Additional PLUIN display information storage/archive/ha_archive.cc: License information added storage/blackhole/ha_blackhole.cc: License information added storage/csv/ha_tina.cc: License Information storage/example/ha_example.cc: License information storage/federated/ha_federated.cc: License Information storage/heap/ha_heap.cc: License Information storage/innobase/handler/ha_innodb.cc: License Information storage/myisam/ha_myisam.cc: License Information storage/myisammrg/ha_myisammrg.cc: License Information
-
- 30 Sep, 2006 2 commits
-
-
unknown authored
This patch adds handlerton passing to functions. NDB and Innodb still require a global hanlderton in the main code due to the nature of the sql_cache call back function (should be solveable... another patch). Partitioning now has a flag to allow disabling of engines from being compatible with partitioning. Cleaned up heap naming convention on panic call. include/heap.h: Added new function sql/ha_ndbcluster.cc: Updated hanlderton functions sql/ha_ndbcluster_binlog.cc: Updated handlerton functions. sql/handler.cc: Updated handlerton functions. sql/handler.h: Updated hanlderton functions sql/log.cc: Updated handlerton functions sql/mysql_priv.h: Updated handlerton functions sql/mysqld.cc: Added Legacy handlerton functions sql/partition_info.cc: Added flag support for marking engines not compatible with partitioning sql/sql_cursor.cc: Updated hanlderton functions sql/sql_show.cc: Updated hanlderton functions sql/sql_tablespace.cc: Update for handlerton functions storage/archive/ha_archive.cc: Update for hanlderton functions storage/archive/ha_archive.h: Update for handlerton functions storage/blackhole/ha_blackhole.cc: Update for handlerton functions storage/csv/ha_tina.cc: Update for handlerton functions storage/csv/ha_tina.h: Update for handlerton functions storage/federated/ha_federated.cc: Updated for handlerton functions storage/federated/ha_federated.h: Updated for handlerton functions storage/heap/ha_heap.cc: Update for handlerton functions storage/heap/hp_panic.c: Update of function name storage/heap/hp_test1.c: Update of function name storage/heap/hp_test2.c: Update of function name. storage/innobase/handler/ha_innodb.cc: Update of function name storage/innobase/handler/ha_innodb.h: Update of function name storage/myisam/ha_myisam.cc: Update of function name. storage/myisammrg/ha_myisammrg.cc: Update of function name
-
unknown authored
sql/ha_ndbcluster.cc: Removed global hton sql/ha_ndbcluster.h: Removed global hton need sql/ha_partition.cc: Removed global hton sql/ha_partition.h: Removed global hton sql/handler.cc: Removed global hton sql/handler.h: Removed global hton storage/archive/ha_archive.cc: Removed global hton storage/archive/ha_archive.h: Global hton removed storage/blackhole/ha_blackhole.cc: Global removed hton storage/blackhole/ha_blackhole.h: Global hton removal storage/csv/ha_tina.cc: Global hton removal storage/csv/ha_tina.h: Removed global removed storage/example/ha_example.cc: Global removed hton storage/example/ha_example.h: Global removed hton storage/federated/ha_federated.cc: Global removed hton storage/federated/ha_federated.h: Global removed hton storage/heap/ha_heap.cc: Global removed hton storage/heap/ha_heap.h: Global removed hton storage/innobase/handler/ha_innodb.cc: Global removed hton storage/innobase/handler/ha_innodb.h: Removed global hton storage/myisam/ha_myisam.cc: Globally removed hton storage/myisam/ha_myisam.h: Globally removed hton storage/myisammrg/ha_myisammrg.cc: Globally removed hton storage/myisammrg/ha_myisammrg.h: Globaly removed hton
-
- 28 Sep, 2006 1 commit
-
-
unknown authored
and so the engine calls current_thd to derive transaction information; instead we now pass THD to those functions, it looks more logical (it makes the implicit current_thd parameter more visible). Approved by Brian and Monty. sql/handler.h: cursor's creation functions in the handlerton need a THD, it's better than have the engine call current_thd sql/sql_cursor.cc: pass the THD instead of letting the engine call current_thd storage/innobase/handler/ha_innodb.cc: use the passed THD instead of current_thd storage/innobase/handler/ha_innodb.h: use the passed THD instead of current_thd
-
- 27 Sep, 2006 1 commit
-
-
unknown authored
include/mysql/plugin.h: Field Removed sql/ha_ndbcluster.cc: Field Removed sql/ha_partition.cc: Field Removed sql/log.cc: Removed Field storage/archive/ha_archive.cc: Removed Field storage/blackhole/ha_blackhole.cc: Removed Field storage/csv/ha_tina.cc: Removed Field storage/example/ha_example.cc: Removed Field storage/federated/ha_federated.cc: Removed Field storage/heap/ha_heap.cc: Removed Field storage/innobase/handler/ha_innodb.cc: Removed Field storage/myisam/ha_myisam.cc: Removed Field storage/myisammrg/ha_myisammrg.cc: Removed Field
-
- 21 Sep, 2006 1 commit
-
-
unknown authored
Bugs fixed: - Bug #20877: InnoDB data dictionary memory footprint is too big - Bug #13544: Second delete of same row in transaction illustrates non-optimal locking - Bug #20791: valgrind errors in InnoDB storage/innobase/btr/btr0btr.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r823: Minor cleanup related to Bug #20877. btr_print_recursive(): Replace tree->tree_indexes with tree->index. This should have been done in r453. univ.i: Add UNIV_BTR_PRINT. rw_lock_t: Reduce writer_is_wait_ex to a bit and move it close to other bitfields. Change the types to unsigned, in case ulint or ibool bitfields will not work. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/btr/btr0cur.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r816: Remove more remnants of mixed indexes. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r830: page_align(ptr): New utility function to replace ut_align_down(ptr, UNIV_PAGE_SIZE) calls. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/btr/btr0pcur.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r830: page_align(ptr): New utility function to replace ut_align_down(ptr, UNIV_PAGE_SIZE) calls. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/btr/btr0sea.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r824: Reduce the size of btr_search_t from 13 machine words to 7. This structure is reserved for every index in the data dictionary cache. (Bug #20877) We could shrink the structure further to three 32-bit words or two 64-bit words by turning the remaining fields to bit-fields. Unfortunately, the fields are not protected by any mutex, and thus we would better keep each field aligned to a machine word. btr_search_t, buf_block_t: Rename "ulint side" to "ibool left_side". Remove BTR_SEARCH_LEFT_SIDE and BTR_SEARCH_RIGHT_SIDE, and also rename some local variables and function parameters from "ulint side" to "ibool left_side". btr_search_t: Remove the unused fields last_search, n_direction, direction, and modify_clock. Remove the unused constants BTR_SEA_NO_DIRECTION, BTR_SEA_LEFT, BTR_SEA_RIGHT, and BTR_SEA_SAME_REC. btr_search_t: Remove magic_n unless #defined UNIV_DEBUG. Turn an assertion about the magic number into a debug assertion. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/buf/buf0buf.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r824: Reduce the size of btr_search_t from 13 machine words to 7. This structure is reserved for every index in the data dictionary cache. (Bug #20877) We could shrink the structure further to three 32-bit words or two 64-bit words by turning the remaining fields to bit-fields. Unfortunately, the fields are not protected by any mutex, and thus we would better keep each field aligned to a machine word. btr_search_t, buf_block_t: Rename "ulint side" to "ibool left_side". Remove BTR_SEARCH_LEFT_SIDE and BTR_SEARCH_RIGHT_SIDE, and also rename some local variables and function parameters from "ulint side" to "ibool left_side". btr_search_t: Remove the unused fields last_search, n_direction, direction, and modify_clock. Remove the unused constants BTR_SEA_NO_DIRECTION, BTR_SEA_LEFT, BTR_SEA_RIGHT, and BTR_SEA_SAME_REC. btr_search_t: Remove magic_n unless #defined UNIV_DEBUG. Turn an assertion about the magic number into a debug assertion. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/buf/buf0flu.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/buf/buf0lru.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/buf/buf0rea.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/data/data0data.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/data/data0type.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. storage/innobase/dict/dict0boot.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r827: Make dict_index_find_cols() always succeed. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/dict/dict0crea.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r827: Make dict_index_find_cols() always succeed. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r833: Tweak the bit-field definitions introduced since r813 to address Bug #20877. rw_lock_t: Do not make writer_is_wait_ex a bit-field. There are no fields yet that could be fused to the same machine word, but we play it safe, because the field writer_is_wait_ex may be modified by several threads simultaneously. Such fields should always be allocated an own machine word. dict_table_t: Change the type of all bit-fields to "unsigned". Make "space" a bit-field of 32 bits. Move name_hash and id_hash after all bit-fields, so that the bit-fields can be allocated together. Do not make autoinc_inited a bit-field, as we cannot allocate any field from the same machine word. dict_build_table_def_step(): Pass a local variable to fil_create_new_single_table_tablespace() and initialize table->space from it after the call, now that table->space is a bit-field. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/dict/dict0dict.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r818: Remove dict_col_t::hash, dict_col_t::table, dict_sys->col_hash, and DICT_POOL_PER_COL_HASH. (Bug #20877) The col->table pointer was only needed for maintaining a hash table of all defined columns in all tables. The hash table was only looked up in dict_index_find_cols(). Removing the col->hash and col->table pointers reduces the size of a table column by two machine words (usually 8 or 16 bytes). dict_col_add_to_cache(), dict_col_reposition_in_cache(), dict_col_remove_from_cache(): Remove. These only updated dict_sys->col_hash. dict_index_find_cols(): Use a linear search instead of the hash table. The time complexity is affected, but this function is only invoked by dict_index_add_to_cache(), and we only search the columns of a single table (typically at most a few dozen) as opposed to all columns of all tables. Revision r819: dict_col_t: Reduce ord_part to one bit. dict_index_add_to_cache(): Instead of incrementing ord_part, set it. dict_index_remove_from_cache(): Do not touch ord_part. dtype_t: Reduce mbminlen from 3 to 2 bits. row_upd(): Add a UNIV_LIKELY hint around node->in_mysql_interface. Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r821: dict_table_t: Rename the integer field max_row_size to the Boolean field big_rows. (Bug #20877) BIG_ROW_SIZE: Move the definition from row0sel.c to dict_table_add_to_cache(). Revision r826: The code base was reindented in r763 and automatic .emacs indentation settings introduced. Some problems were found, so from this commit on one additional indentation rule is introduced: (add-to-list 'c-offsets-alist '(arglist-intro . +)) Note that fixing some of the unfortunate line-splits done in r764 will be done in a future change. Revision r827: Make dict_index_find_cols() always succeed. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r831: Add dict_col_get_clust_pos_noninline(), which was forgotten from r820. Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r836: Remove dict_col_t::name, replace it with a packed array of column names in dict_table_t. This saves 8-15+ bytes of memory per column on 64-bit machines. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. Revision r845: Split long lines with [] operators better. storage/innobase/dict/dict0load.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/dict/dict0mem.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r818: Remove dict_col_t::hash, dict_col_t::table, dict_sys->col_hash, and DICT_POOL_PER_COL_HASH. (Bug #20877) The col->table pointer was only needed for maintaining a hash table of all defined columns in all tables. The hash table was only looked up in dict_index_find_cols(). Removing the col->hash and col->table pointers reduces the size of a table column by two machine words (usually 8 or 16 bytes). dict_col_add_to_cache(), dict_col_reposition_in_cache(), dict_col_remove_from_cache(): Remove. These only updated dict_sys->col_hash. dict_index_find_cols(): Use a linear search instead of the hash table. The time complexity is affected, but this function is only invoked by dict_index_add_to_cache(), and we only search the columns of a single table (typically at most a few dozen) as opposed to all columns of all tables. Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r821: dict_table_t: Rename the integer field max_row_size to the Boolean field big_rows. (Bug #20877) BIG_ROW_SIZE: Move the definition from row0sel.c to dict_table_add_to_cache(). Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r836: Remove dict_col_t::name, replace it with a packed array of column names in dict_table_t. This saves 8-15+ bytes of memory per column on 64-bit machines. storage/innobase/eval/eval0eval.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r826: The code base was reindented in r763 and automatic .emacs indentation settings introduced. Some problems were found, so from this commit on one additional indentation rule is introduced: (add-to-list 'c-offsets-alist '(arglist-intro . +)) Note that fixing some of the unfortunate line-splits done in r764 will be done in a future change. storage/innobase/eval/eval0proc.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/fil/fil0fil.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/fsp/fsp0fsp.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. Revision r845: Split long lines with [] operators better. storage/innobase/handler/ha_innodb.cc: Applied innodb-5.1 snapshots ss799 and ss854 storage/innobase/handler/ha_innodb.h: Applied innodb-5.1 snapshots ss799 and ss854 storage/innobase/ibuf/ibuf0ibuf.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/include/btr0btr.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". storage/innobase/include/btr0btr.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. storage/innobase/include/btr0cur.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". storage/innobase/include/btr0cur.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". storage/innobase/include/btr0pcur.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r817: btr0pcur.h: Change FIXME to TODO. storage/innobase/include/btr0sea.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r824: Reduce the size of btr_search_t from 13 machine words to 7. This structure is reserved for every index in the data dictionary cache. (Bug #20877) We could shrink the structure further to three 32-bit words or two 64-bit words by turning the remaining fields to bit-fields. Unfortunately, the fields are not protected by any mutex, and thus we would better keep each field aligned to a machine word. btr_search_t, buf_block_t: Rename "ulint side" to "ibool left_side". Remove BTR_SEARCH_LEFT_SIDE and BTR_SEARCH_RIGHT_SIDE, and also rename some local variables and function parameters from "ulint side" to "ibool left_side". btr_search_t: Remove the unused fields last_search, n_direction, direction, and modify_clock. Remove the unused constants BTR_SEA_NO_DIRECTION, BTR_SEA_LEFT, BTR_SEA_RIGHT, and BTR_SEA_SAME_REC. btr_search_t: Remove magic_n unless #defined UNIV_DEBUG. Turn an assertion about the magic number into a debug assertion. storage/innobase/include/buf0buf.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r824: Reduce the size of btr_search_t from 13 machine words to 7. This structure is reserved for every index in the data dictionary cache. (Bug #20877) We could shrink the structure further to three 32-bit words or two 64-bit words by turning the remaining fields to bit-fields. Unfortunately, the fields are not protected by any mutex, and thus we would better keep each field aligned to a machine word. btr_search_t, buf_block_t: Rename "ulint side" to "ibool left_side". Remove BTR_SEARCH_LEFT_SIDE and BTR_SEARCH_RIGHT_SIDE, and also rename some local variables and function parameters from "ulint side" to "ibool left_side". btr_search_t: Remove the unused fields last_search, n_direction, direction, and modify_clock. Remove the unused constants BTR_SEA_NO_DIRECTION, BTR_SEA_LEFT, BTR_SEA_RIGHT, and BTR_SEA_SAME_REC. btr_search_t: Remove magic_n unless #defined UNIV_DEBUG. Turn an assertion about the magic number into a debug assertion. storage/innobase/include/data0data.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. storage/innobase/include/data0type.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r819: dict_col_t: Reduce ord_part to one bit. dict_index_add_to_cache(): Instead of incrementing ord_part, set it. dict_index_remove_from_cache(): Do not touch ord_part. dtype_t: Reduce mbminlen from 3 to 2 bits. row_upd(): Add a UNIV_LIKELY hint around node->in_mysql_interface. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. storage/innobase/include/data0type.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r816: Remove more remnants of mixed indexes. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/include/dict0boot.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r816: Remove more remnants of mixed indexes. storage/innobase/include/dict0dict.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r816: Remove more remnants of mixed indexes. Revision r818: Remove dict_col_t::hash, dict_col_t::table, dict_sys->col_hash, and DICT_POOL_PER_COL_HASH. (Bug #20877) The col->table pointer was only needed for maintaining a hash table of all defined columns in all tables. The hash table was only looked up in dict_index_find_cols(). Removing the col->hash and col->table pointers reduces the size of a table column by two machine words (usually 8 or 16 bytes). dict_col_add_to_cache(), dict_col_reposition_in_cache(), dict_col_remove_from_cache(): Remove. These only updated dict_sys->col_hash. dict_index_find_cols(): Use a linear search instead of the hash table. The time complexity is affected, but this function is only invoked by dict_index_add_to_cache(), and we only search the columns of a single table (typically at most a few dozen) as opposed to all columns of all tables. Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r827: Make dict_index_find_cols() always succeed. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r831: Add dict_col_get_clust_pos_noninline(), which was forgotten from r820. Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r836: Remove dict_col_t::name, replace it with a packed array of column names in dict_table_t. This saves 8-15+ bytes of memory per column on 64-bit machines. storage/innobase/include/dict0dict.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. storage/innobase/include/dict0mem.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r815: dict_index_t: Remove tree_indexes. It should have been removed in r453 when the list in dict_tree_t was replaced with the pointer tree_index. Revision r818: Remove dict_col_t::hash, dict_col_t::table, dict_sys->col_hash, and DICT_POOL_PER_COL_HASH. (Bug #20877) The col->table pointer was only needed for maintaining a hash table of all defined columns in all tables. The hash table was only looked up in dict_index_find_cols(). Removing the col->hash and col->table pointers reduces the size of a table column by two machine words (usually 8 or 16 bytes). dict_col_add_to_cache(), dict_col_reposition_in_cache(), dict_col_remove_from_cache(): Remove. These only updated dict_sys->col_hash. dict_index_find_cols(): Use a linear search instead of the hash table. The time complexity is affected, but this function is only invoked by dict_index_add_to_cache(), and we only search the columns of a single table (typically at most a few dozen) as opposed to all columns of all tables. Revision r819: dict_col_t: Reduce ord_part to one bit. dict_index_add_to_cache(): Instead of incrementing ord_part, set it. dict_index_remove_from_cache(): Do not touch ord_part. dtype_t: Reduce mbminlen from 3 to 2 bits. row_upd(): Add a UNIV_LIKELY hint around node->in_mysql_interface. Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r821: dict_table_t: Rename the integer field max_row_size to the Boolean field big_rows. (Bug #20877) BIG_ROW_SIZE: Move the definition from row0sel.c to dict_table_add_to_cache(). Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r833: Tweak the bit-field definitions introduced since r813 to address Bug #20877. rw_lock_t: Do not make writer_is_wait_ex a bit-field. There are no fields yet that could be fused to the same machine word, but we play it safe, because the field writer_is_wait_ex may be modified by several threads simultaneously. Such fields should always be allocated an own machine word. dict_table_t: Change the type of all bit-fields to "unsigned". Make "space" a bit-field of 32 bits. Move name_hash and id_hash after all bit-fields, so that the bit-fields can be allocated together. Do not make autoinc_inited a bit-field, as we cannot allocate any field from the same machine word. dict_build_table_def_step(): Pass a local variable to fil_create_new_single_table_tablespace() and initialize table->space from it after the call, now that table->space is a bit-field. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r835: Change the recently introduced ulint bit-fields to unsigned. Revision r836: Remove dict_col_t::name, replace it with a packed array of column names in dict_table_t. This saves 8-15+ bytes of memory per column on 64-bit machines. storage/innobase/include/dict0types.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". storage/innobase/include/ibuf0ibuf.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/include/page0page.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r830: page_align(ptr): New utility function to replace ut_align_down(ptr, UNIV_PAGE_SIZE) calls. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. storage/innobase/include/page0page.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r830: page_align(ptr): New utility function to replace ut_align_down(ptr, UNIV_PAGE_SIZE) calls. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/include/read0read.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/include/rem0cmp.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. storage/innobase/include/rem0cmp.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. storage/innobase/include/rem0rec.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. storage/innobase/include/rem0rec.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/include/rem0types.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. storage/innobase/include/row0upd.ic: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. storage/innobase/include/sync0rw.h: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r823: Minor cleanup related to Bug #20877. btr_print_recursive(): Replace tree->tree_indexes with tree->index. This should have been done in r453. univ.i: Add UNIV_BTR_PRINT. rw_lock_t: Reduce writer_is_wait_ex to a bit and move it close to other bitfields. Change the types to unsigned, in case ulint or ibool bitfields will not work. Revision r833: Tweak the bit-field definitions introduced since r813 to address Bug #20877. rw_lock_t: Do not make writer_is_wait_ex a bit-field. There are no fields yet that could be fused to the same machine word, but we play it safe, because the field writer_is_wait_ex may be modified by several threads simultaneously. Such fields should always be allocated an own machine word. dict_table_t: Change the type of all bit-fields to "unsigned". Make "space" a bit-field of 32 bits. Move name_hash and id_hash after all bit-fields, so that the bit-fields can be allocated together. Do not make autoinc_inited a bit-field, as we cannot allocate any field from the same machine word. dict_build_table_def_step(): Pass a local variable to fil_create_new_single_table_tablespace() and initialize table->space from it after the call, now that table->space is a bit-field. storage/innobase/include/univ.i: Applied innodb-5.1 snapshots ss799 and ss854 Revision r823: Minor cleanup related to Bug #20877. btr_print_recursive(): Replace tree->tree_indexes with tree->index. This should have been done in r453. univ.i: Add UNIV_BTR_PRINT. rw_lock_t: Reduce writer_is_wait_ex to a bit and move it close to other bitfields. Change the types to unsigned, in case ulint or ibool bitfields will not work. storage/innobase/lock/lock0lock.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/log/log0log.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/log/log0recv.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/mem/mem0dbg.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/mem/mem0pool.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/mtr/mtr0log.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/mtr/mtr0mtr.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/os/os0file.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/os/os0thread.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/page/page0cur.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/page/page0page.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. storage/innobase/pars/pars0opt.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/pars/pars0pars.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/pars/pars0sym.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. storage/innobase/read/read0read.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/rem/rem0cmp.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/rem/rem0rec.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0ins.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0mysql.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0purge.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r828: Remove dict_tree_t, which should have been removed in r453. There always was a one-to-one mapping between dict_tree_t and dict_index_t. This saves 6 machine words per B-tree index in the data dictionary cache plus the memory allocation overhead. We save one mem_heap_t object per index (15 machine words). Considering the internal fragmentation of the buddy allocator in mem_area_alloc(), this should save 32 machine words per index (128 bytes on 32-bit systems and 256 bytes on 64-bit systems). (Bug #20877) struct dict_tree_struct, dict_tree_t: Remove. struct dict_index_struct: Add page and lock. dict_tree_create(): Remove. Replace the invocation with assignment to index->page and a call to rw_lock_create(&index->lock). dict_tree_free(): Remove. Replace the invocation wtih a call to rw_lock_free(&index->lock). dict_index_get_tree(): Remove. dict_tree_get_space_reserve(): Rename to dict_index_get_space_reserve() and remove the parameter, which was unused. btr_level_list_remove(): Remove the unused parameter "tree". Replace the occurrences of "tree" with "index" in names of variables, functions and data types, e.g. "dict_tree_t tree" becomes "dict_index_t index". Remove local variables "tree" or "index" of functions that needed both "tree" and "index". Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0row.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0sel.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r821: dict_table_t: Rename the integer field max_row_size to the Boolean field big_rows. (Bug #20877) BIG_ROW_SIZE: Move the definition from row0sel.c to dict_table_add_to_cache(). Revision r825: row_search_for_mysql(): Skip setting the next-key lock on an already delete-marked record in a clustered index where the search criteria is unique, within the same transaction (Bug #13544). Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r837: page_offset(): New function to replace many ut_align_offset(., UNIV_PAGE_SIZE) calls. dict_index_build_node_ptr(): Correct a typo in a comment. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. Revision r845: Split long lines with [] operators better. storage/innobase/row/row0uins.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0umod.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/row/row0upd.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r819: dict_col_t: Reduce ord_part to one bit. dict_index_add_to_cache(): Instead of incrementing ord_part, set it. dict_index_remove_from_cache(): Do not touch ord_part. dtype_t: Reduce mbminlen from 3 to 2 bits. row_upd(): Add a UNIV_LIKELY hint around node->in_mysql_interface. Revision r820: Remove dict_col_t::clust_pos. dict_col_get_clust_pos(): Add parameter clust_index. Replace the look-up with a linear search of all columns in the clustered index. row_upd_index_replace_new_col_vals(): Compute clust_index outside the loops. Compute clust_pos outside the inner loop. row_upd_changes_ord_field_binary(), row_upd_changes_first_fields_binary(): Compute clust_index outside the loops. Declare the auxiliary variables inside the loop scope. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. Revision r851: row_upd_sec_step(): Fix false comment. storage/innobase/row/row0vers.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/srv/srv0srv.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. Revision r832: Add dict_table_get_col_name() in preparation for getting rid of dict_col_t::name, and use it instead of col->name everywhere. Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/srv/srv0start.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/sync/sync0arr.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/sync/sync0rw.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r813: Reduce the size of the data dictionary cache. (Bug #20877) dtype_t: Remove unused field "prec", which was supposed to be used for the precision of decimal columns in stand-alone InnoDB. dtype_get_prec(): Remove. dtype_set(), dict_mem_table_add_col(): Remove parameter "prec". dtype_t: Turn all fields (mtype, prtype, len, mbminlen, mbmaxlen, len) into bit-fields. dict_table_t, dict_index_t, dict_tree_t: Omit magic_n from non-debug builds. dict_col_t: Turn ind, clust_pos, and ord_part into bit-fields. Replace the default clust_pos value ULINT_UNDEFINED with REC_MAX_N_FIELDS and replace all references to clust_pos with calls to the accessor function dict_col_get_clust_pos(). dict_field_t: Turn prefix_len and fixed_len into bit-fields. dict_tree_t: Remove pad[64]. dict_table_t: Turn the fields ibd_file_missing, tablespace_discarded, cached, flags, stat_initialized, and autoinc_inited into bit-fields. Remove does_not_fit_in_memory from non-debug builds. dict_index_t: Turn the fields trx_id_offset, n_user_defined_cols, n_uniq, n_def, n_fields, n_nullable, and cached into bit-fields. dict_foreign_struct: Turn n_fields and type into bit-fields. rw_lock_t: Turn cline, last_s_line, and last_x_line into bit-fields. Omit level unless #defined UNIV_SYNC_DEBUG. Move REC_MAX_N_FIELDS (and REC_MAX_HEAP_NO and REC_MAX_N_OWNED) from rem0rec.c to rem0types.h, as they are needed in dict0dict.ic. dict_col_get_clust_pos(): Map REC_MAX_N_FIELDS to ULINT_UNDEFINED. storage/innobase/sync/sync0sync.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/trx/trx0purge.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/trx/trx0rec.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r834: dict_col_t: Copy the fields of "dtype_t type" directly to this structure, so that all integer fields can be packed into 64 bits. (Bug #20877) dtype_t: Change the type of all bit-fields to unsigned. dict_table_get_nth_col(), dict_table_get_sys_col_noninline(), dict_table_get_sys_col(), dict_field_get_col(): Return const dict_col_t*, so that changes to dict_col_t can be detected more easily. Add const to many dict_col_t* declarations. dict_index_get_nth_type(): Replace with dict_index_get_nth_col(). dict_col_get_type(): Replace with dict_col_copy_type(). dict_col_get_min_size(), dict_col_get_max_size(), dict_col_get_fixed_size(), dict_col_get_sql_null_size(): New functions. dtype_get_at_most_n_mbchars(): Replace the parameter dtype with the parameters prtype, mbminlen, mbmaxlen. dtype_get_pad_char(), cmp_data_data(), cmp_data_data_slow(), cmp_whole_field(): Replace the dtype_t* parameter with the ulint parameters mtype, prtype. dtype_copy(): Add a const qualifier to type2 (the one being copied from). dtype_set_mblen(): Replaced with dtype_get_mblen(). dtype_get_fixed_size_low(), dtype_get_min_size_low(), dtype_get_fixed_max_low(): Replace dtype_get_fixed_size(), dtype_get_min_size(), and dtype_get_max_size(). These are used by the dict_col_get_{fixed,min,max}_size() functions. cmp_types_are_equal(): Replace with cmp_cols_are_equal(). dict_table_get_col_name(): Add a const qualifier parameter to the parameter "table". dtype_binary, dtype_binary_val: Remove. dtype_is_fixed_size(): Remove. Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/trx/trx0rseg.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/trx/trx0sys.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r829: Erase the magic number in the trx sys header using a redo-logged write; it should be redo-logged because the data structure is file-based; this patch does not fix any bug; the original erase operation was added in r781 to fix Valgrind Bug #20791 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/trx/trx0trx.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826. storage/innobase/trx/trx0undo.c: Applied innodb-5.1 snapshots ss799 and ss854 Revision r838: Revamp the line splits done in r763 and r764 that can now be done better, thanks to r826.
-