Merge lp:~stewart/percona-server/5.5.20 into lp:percona-server/5.5
- 5.5.20
- Merge into 5.5
Proposed by
Stewart Smith
Status: | Merged |
---|---|
Approved by: | Stewart Smith |
Approved revision: | no longer in the source branch. |
Merged at revision: | 214 |
Proposed branch: | lp:~stewart/percona-server/5.5.20 |
Merge into: | lp:percona-server/5.5 |
Diff against target: |
5315 lines (+680/-631) 46 files modified
Makefile (+2/-2) patches/bug860910.patch (+1/-1) patches/control_online_alter_index.patch (+1/-1) patches/group_commit.patch (+26/-26) patches/innodb_adaptive_hash_index_partitions.patch (+8/-8) patches/innodb_admin_command_base.patch (+1/-1) patches/innodb_buffer_pool_pages_i_s.patch (+3/-3) patches/innodb_buffer_pool_shm.patch (+2/-2) patches/innodb_deadlock_count.patch (+3/-3) patches/innodb_dict_size_limit.patch (+9/-9) patches/innodb_expand_fast_index_creation.patch (+5/-5) patches/innodb_expand_import.patch (+11/-11) patches/innodb_extend_slow.patch (+27/-27) patches/innodb_extra_rseg.patch (+1/-1) patches/innodb_fake_changes.patch (+8/-8) patches/innodb_fast_checksum.patch (+4/-4) patches/innodb_files_extend.patch (+17/-17) patches/innodb_fix_misc.patch (+27/-27) patches/innodb_io_patches.patch (+41/-17) patches/innodb_kill_idle_transaction.patch (+5/-5) patches/innodb_lru_dump_restore.patch (+19/-19) patches/innodb_opt_lru_count.patch (+16/-16) patches/innodb_overwrite_relay_log_info.patch (+2/-2) patches/innodb_pass_corrupt_table.patch (+40/-40) patches/innodb_recovery_patches.patch (+2/-2) patches/innodb_separate_doublewrite.patch (+20/-20) patches/innodb_show_lock_name.patch (+4/-4) patches/innodb_show_status.patch (+8/-8) patches/innodb_show_status_extend.patch (+7/-7) patches/innodb_show_sys_tables.patch (+1/-1) patches/innodb_split_buf_pool_mutex.patch (+232/-203) patches/innodb_stats.patch (+24/-24) patches/innodb_thread_concurrency_timer_based.patch (+6/-6) patches/log_connection_error.patch (+3/-3) patches/log_warnings_suppress.patch (+4/-4) patches/mysql-test.diff (+0/-4) patches/optimizer_fix.patch (+2/-2) patches/processlist_row_stats.patch (+1/-1) patches/query_cache_enhance.patch (+2/-2) patches/response_time_distribution.patch (+15/-15) patches/show_slave_status_nolock.patch (+2/-2) patches/show_temp.patch (+5/-5) patches/slow_extended.patch (+11/-11) patches/sql_no_fcache.patch (+8/-8) patches/subunit.patch (+5/-5) patches/userstat.patch (+39/-39) |
To merge this branch: | bzr merge lp:~stewart/percona-server/5.5.20 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Stewart Smith (community) | Approve | ||
Review via email: mp+91605@code.launchpad.net |
Commit message
Description of the change
To post a comment you must log in.
Revision history for this message
Stewart Smith (stewart) : | # |
review:
Approve
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'Makefile' | |||
2 | --- Makefile 2012-01-09 02:00:29 +0000 | |||
3 | +++ Makefile 2012-02-06 05:02:26 +0000 | |||
4 | @@ -1,7 +1,7 @@ | |||
5 | 1 | FETCH_CMD=wget | 1 | FETCH_CMD=wget |
6 | 2 | MASTER_SITE=http://s3.amazonaws.com/percona.com/downloads/community | 2 | MASTER_SITE=http://s3.amazonaws.com/percona.com/downloads/community |
9 | 3 | MYSQL_VERSION=5.5.19 | 3 | MYSQL_VERSION=5.5.20 |
10 | 4 | PERCONA_SERVER_VERSION=rel24.0 | 4 | PERCONA_SERVER_VERSION=rel24.1 |
11 | 5 | PERCONA_SERVER ?=Percona-Server-$(MYSQL_VERSION)-$(PERCONA_SERVER_VERSION) | 5 | PERCONA_SERVER ?=Percona-Server-$(MYSQL_VERSION)-$(PERCONA_SERVER_VERSION) |
12 | 6 | PERCONA_SERVER_SHORT_1 ?=Percona-Server-$(MYSQL_VERSION) | 6 | PERCONA_SERVER_SHORT_1 ?=Percona-Server-$(MYSQL_VERSION) |
13 | 7 | PERCONA_SERVER_SHORT_2 ?=Percona-Server | 7 | PERCONA_SERVER_SHORT_2 ?=Percona-Server |
14 | 8 | 8 | ||
15 | === modified file 'patches/bug860910.patch' | |||
16 | --- patches/bug860910.patch 2011-12-27 15:32:16 +0000 | |||
17 | +++ patches/bug860910.patch 2012-02-06 05:02:26 +0000 | |||
18 | @@ -77,7 +77,7 @@ | |||
19 | 77 | +--source include/rpl_end.inc | 77 | +--source include/rpl_end.inc |
20 | 78 | --- a/sql/log.cc | 78 | --- a/sql/log.cc |
21 | 79 | +++ b/sql/log.cc | 79 | +++ b/sql/log.cc |
23 | 80 | @@ -5076,6 +5076,12 @@ | 80 | @@ -5112,6 +5112,12 @@ |
24 | 81 | user_var_event->type, | 81 | user_var_event->type, |
25 | 82 | user_var_event->charset_number, | 82 | user_var_event->charset_number, |
26 | 83 | flags); | 83 | flags); |
27 | 84 | 84 | ||
28 | === modified file 'patches/control_online_alter_index.patch' | |||
29 | --- patches/control_online_alter_index.patch 2011-12-27 15:32:16 +0000 | |||
30 | +++ patches/control_online_alter_index.patch 2012-02-06 05:02:26 +0000 | |||
31 | @@ -58,7 +58,7 @@ | |||
32 | 58 | for (idx_p= index_drop_buffer, idx_end_p= idx_p + index_drop_count; | 58 | for (idx_p= index_drop_buffer, idx_end_p= idx_p + index_drop_count; |
33 | 59 | --- a/sql/sys_vars.cc | 59 | --- a/sql/sys_vars.cc |
34 | 60 | +++ b/sql/sys_vars.cc | 60 | +++ b/sql/sys_vars.cc |
36 | 61 | @@ -2192,6 +2192,13 @@ | 61 | @@ -2265,6 +2265,13 @@ |
37 | 62 | GLOBAL_VAR(opt_optimizer_fix), | 62 | GLOBAL_VAR(opt_optimizer_fix), |
38 | 63 | NO_CMD_LINE, DEFAULT(TRUE)); | 63 | NO_CMD_LINE, DEFAULT(TRUE)); |
39 | 64 | 64 | ||
40 | 65 | 65 | ||
41 | === modified file 'patches/group_commit.patch' | |||
42 | --- patches/group_commit.patch 2012-01-11 15:14:15 +0000 | |||
43 | +++ patches/group_commit.patch 2012-02-06 05:02:26 +0000 | |||
44 | @@ -522,7 +522,7 @@ | |||
45 | 522 | sync_period_ptr(sync_period), | 522 | sync_period_ptr(sync_period), |
46 | 523 | is_relay_log(0), signal_cnt(0), | 523 | is_relay_log(0), signal_cnt(0), |
47 | 524 | description_event_for_exec(0), description_event_for_queue(0) | 524 | description_event_for_exec(0), description_event_for_queue(0) |
49 | 525 | @@ -5325,19 +5327,15 @@ | 525 | @@ -5361,19 +5363,15 @@ |
50 | 526 | SYNOPSIS | 526 | SYNOPSIS |
51 | 527 | write_cache() | 527 | write_cache() |
52 | 528 | cache Cache to write to the binary log | 528 | cache Cache to write to the binary log |
53 | @@ -544,7 +544,7 @@ | |||
54 | 544 | if (reinit_io_cache(cache, READ_CACHE, 0, 0, 0)) | 544 | if (reinit_io_cache(cache, READ_CACHE, 0, 0, 0)) |
55 | 545 | return ER_ERROR_ON_WRITE; | 545 | return ER_ERROR_ON_WRITE; |
56 | 546 | uint length= my_b_bytes_in_cache(cache), group, carry, hdr_offs; | 546 | uint length= my_b_bytes_in_cache(cache), group, carry, hdr_offs; |
58 | 547 | @@ -5448,6 +5446,8 @@ | 547 | @@ -5484,6 +5482,8 @@ |
59 | 548 | } | 548 | } |
60 | 549 | 549 | ||
61 | 550 | /* Write data to the binary log file */ | 550 | /* Write data to the binary log file */ |
62 | @@ -553,7 +553,7 @@ | |||
63 | 553 | if (my_b_write(&log_file, cache->read_pos, length)) | 553 | if (my_b_write(&log_file, cache->read_pos, length)) |
64 | 554 | return ER_ERROR_ON_WRITE; | 554 | return ER_ERROR_ON_WRITE; |
65 | 555 | thd->binlog_bytes_written+= length; | 555 | thd->binlog_bytes_written+= length; |
67 | 556 | @@ -5456,9 +5456,6 @@ | 556 | @@ -5492,9 +5492,6 @@ |
68 | 557 | 557 | ||
69 | 558 | DBUG_ASSERT(carry == 0); | 558 | DBUG_ASSERT(carry == 0); |
70 | 559 | 559 | ||
71 | @@ -563,7 +563,7 @@ | |||
72 | 563 | return 0; // All OK | 563 | return 0; // All OK |
73 | 564 | } | 564 | } |
74 | 565 | 565 | ||
76 | 566 | @@ -5499,8 +5496,6 @@ | 566 | @@ -5535,8 +5532,6 @@ |
77 | 567 | if (!is_open()) | 567 | if (!is_open()) |
78 | 568 | DBUG_RETURN(error); | 568 | DBUG_RETURN(error); |
79 | 569 | 569 | ||
80 | @@ -572,7 +572,7 @@ | |||
81 | 572 | Incident incident= INCIDENT_LOST_EVENTS; | 572 | Incident incident= INCIDENT_LOST_EVENTS; |
82 | 573 | Incident_log_event ev(thd, incident, write_error_msg); | 573 | Incident_log_event ev(thd, incident, write_error_msg); |
83 | 574 | if (lock) | 574 | if (lock) |
85 | 575 | @@ -5549,112 +5544,332 @@ | 575 | @@ -5585,112 +5580,332 @@ |
86 | 576 | 'cache' needs to be reinitialized after this functions returns. | 576 | 'cache' needs to be reinitialized after this functions returns. |
87 | 577 | */ | 577 | */ |
88 | 578 | 578 | ||
89 | @@ -971,7 +971,7 @@ | |||
90 | 971 | /** | 971 | /** |
91 | 972 | Wait until we get a signal that the relay log has been updated. | 972 | Wait until we get a signal that the relay log has been updated. |
92 | 973 | 973 | ||
94 | 974 | @@ -6059,6 +6274,68 @@ | 974 | @@ -6095,6 +6310,68 @@ |
95 | 975 | } | 975 | } |
96 | 976 | 976 | ||
97 | 977 | 977 | ||
98 | @@ -1040,7 +1040,7 @@ | |||
99 | 1040 | /********* transaction coordinator log for 2pc - mmap() based solution *******/ | 1040 | /********* transaction coordinator log for 2pc - mmap() based solution *******/ |
100 | 1041 | 1041 | ||
101 | 1042 | /* | 1042 | /* |
103 | 1043 | @@ -6195,6 +6472,7 @@ | 1043 | @@ -6231,6 +6508,7 @@ |
104 | 1044 | mysql_mutex_init(key_LOCK_pool, &LOCK_pool, MY_MUTEX_INIT_FAST); | 1044 | mysql_mutex_init(key_LOCK_pool, &LOCK_pool, MY_MUTEX_INIT_FAST); |
105 | 1045 | mysql_cond_init(key_COND_active, &COND_active, 0); | 1045 | mysql_cond_init(key_COND_active, &COND_active, 0); |
106 | 1046 | mysql_cond_init(key_COND_pool, &COND_pool, 0); | 1046 | mysql_cond_init(key_COND_pool, &COND_pool, 0); |
107 | @@ -1048,7 +1048,7 @@ | |||
108 | 1048 | 1048 | ||
109 | 1049 | inited=6; | 1049 | inited=6; |
110 | 1050 | 1050 | ||
112 | 1051 | @@ -6202,6 +6480,8 @@ | 1051 | @@ -6238,6 +6516,8 @@ |
113 | 1052 | active=pages; | 1052 | active=pages; |
114 | 1053 | pool=pages+1; | 1053 | pool=pages+1; |
115 | 1054 | pool_last=pages+npages-1; | 1054 | pool_last=pages+npages-1; |
116 | @@ -1057,7 +1057,7 @@ | |||
117 | 1057 | 1057 | ||
118 | 1058 | return 0; | 1058 | return 0; |
119 | 1059 | 1059 | ||
121 | 1060 | @@ -6307,7 +6587,7 @@ | 1060 | @@ -6343,7 +6623,7 @@ |
122 | 1061 | to the position in memory where xid was logged to. | 1061 | to the position in memory where xid was logged to. |
123 | 1062 | */ | 1062 | */ |
124 | 1063 | 1063 | ||
125 | @@ -1066,7 +1066,7 @@ | |||
126 | 1066 | { | 1066 | { |
127 | 1067 | int err; | 1067 | int err; |
128 | 1068 | PAGE *p; | 1068 | PAGE *p; |
130 | 1069 | @@ -6446,7 +6726,9 @@ | 1069 | @@ -6482,7 +6762,9 @@ |
131 | 1070 | mysql_mutex_destroy(&LOCK_sync); | 1070 | mysql_mutex_destroy(&LOCK_sync); |
132 | 1071 | mysql_mutex_destroy(&LOCK_active); | 1071 | mysql_mutex_destroy(&LOCK_active); |
133 | 1072 | mysql_mutex_destroy(&LOCK_pool); | 1072 | mysql_mutex_destroy(&LOCK_pool); |
134 | @@ -1076,7 +1076,7 @@ | |||
135 | 1076 | case 5: | 1076 | case 5: |
136 | 1077 | data[0]='A'; // garble the first (signature) byte, in case mysql_file_delete fails | 1077 | data[0]='A'; // garble the first (signature) byte, in case mysql_file_delete fails |
137 | 1078 | case 4: | 1078 | case 4: |
139 | 1079 | @@ -6656,42 +6938,87 @@ | 1079 | @@ -6692,42 +6974,87 @@ |
140 | 1080 | mysql_cond_destroy(&COND_prep_xids); | 1080 | mysql_cond_destroy(&COND_prep_xids); |
141 | 1081 | } | 1081 | } |
142 | 1082 | 1082 | ||
143 | @@ -1176,7 +1176,7 @@ | |||
144 | 1176 | } | 1176 | } |
145 | 1177 | 1177 | ||
146 | 1178 | int TC_LOG_BINLOG::recover(IO_CACHE *log, Format_description_log_event *fdle) | 1178 | int TC_LOG_BINLOG::recover(IO_CACHE *log, Format_description_log_event *fdle) |
148 | 1179 | @@ -6760,9 +7087,67 @@ | 1179 | @@ -6796,9 +7123,67 @@ |
149 | 1180 | { | 1180 | { |
150 | 1181 | return (ulonglong) mysql_bin_log.get_log_file()->pos_in_file; | 1181 | return (ulonglong) mysql_bin_log.get_log_file()->pos_in_file; |
151 | 1182 | } | 1182 | } |
152 | @@ -1244,7 +1244,7 @@ | |||
153 | 1244 | struct st_mysql_storage_engine binlog_storage_engine= | 1244 | struct st_mysql_storage_engine binlog_storage_engine= |
154 | 1245 | { MYSQL_HANDLERTON_INTERFACE_VERSION }; | 1245 | { MYSQL_HANDLERTON_INTERFACE_VERSION }; |
155 | 1246 | 1246 | ||
157 | 1247 | @@ -6777,7 +7162,7 @@ | 1247 | @@ -6813,7 +7198,7 @@ |
158 | 1248 | binlog_init, /* Plugin Init */ | 1248 | binlog_init, /* Plugin Init */ |
159 | 1249 | NULL, /* Plugin Deinit */ | 1249 | NULL, /* Plugin Deinit */ |
160 | 1250 | 0x0100 /* 1.0 */, | 1250 | 0x0100 /* 1.0 */, |
161 | @@ -1446,7 +1446,7 @@ | |||
162 | 1446 | class Log_event_handler | 1446 | class Log_event_handler |
163 | 1447 | --- a/sql/mysqld.cc | 1447 | --- a/sql/mysqld.cc |
164 | 1448 | +++ b/sql/mysqld.cc | 1448 | +++ b/sql/mysqld.cc |
166 | 1449 | @@ -1490,6 +1490,7 @@ | 1449 | @@ -1495,6 +1495,7 @@ |
167 | 1450 | ha_end(); | 1450 | ha_end(); |
168 | 1451 | if (tc_log) | 1451 | if (tc_log) |
169 | 1452 | tc_log->close(); | 1452 | tc_log->close(); |
170 | @@ -1454,7 +1454,7 @@ | |||
171 | 1454 | delegates_destroy(); | 1454 | delegates_destroy(); |
172 | 1455 | xid_cache_free(); | 1455 | xid_cache_free(); |
173 | 1456 | table_def_free(); | 1456 | table_def_free(); |
175 | 1457 | @@ -4061,6 +4062,8 @@ | 1457 | @@ -3911,6 +3912,8 @@ |
176 | 1458 | query_response_time_init(); | 1458 | query_response_time_init(); |
177 | 1459 | #endif // HAVE_RESPONSE_TIME_DISTRIBUTION | 1459 | #endif // HAVE_RESPONSE_TIME_DISTRIBUTION |
178 | 1460 | /* We have to initialize the storage engines before CSV logging */ | 1460 | /* We have to initialize the storage engines before CSV logging */ |
179 | @@ -1463,7 +1463,7 @@ | |||
180 | 1463 | init_global_table_stats(); | 1463 | init_global_table_stats(); |
181 | 1464 | init_global_index_stats(); | 1464 | init_global_index_stats(); |
182 | 1465 | 1465 | ||
184 | 1466 | @@ -8004,6 +8007,7 @@ | 1466 | @@ -7872,6 +7875,7 @@ |
185 | 1467 | key_LOCK_error_messages, key_LOG_INFO_lock, key_LOCK_thread_count, | 1467 | key_LOCK_error_messages, key_LOG_INFO_lock, key_LOCK_thread_count, |
186 | 1468 | key_PARTITION_LOCK_auto_inc; | 1468 | key_PARTITION_LOCK_auto_inc; |
187 | 1469 | PSI_mutex_key key_RELAYLOG_LOCK_index; | 1469 | PSI_mutex_key key_RELAYLOG_LOCK_index; |
188 | @@ -1471,7 +1471,7 @@ | |||
189 | 1471 | 1471 | ||
190 | 1472 | static PSI_mutex_info all_server_mutexes[]= | 1472 | static PSI_mutex_info all_server_mutexes[]= |
191 | 1473 | { | 1473 | { |
193 | 1474 | @@ -8024,6 +8028,7 @@ | 1474 | @@ -7892,6 +7896,7 @@ |
194 | 1475 | { &key_delayed_insert_mutex, "Delayed_insert::mutex", 0}, | 1475 | { &key_delayed_insert_mutex, "Delayed_insert::mutex", 0}, |
195 | 1476 | { &key_hash_filo_lock, "hash_filo::lock", 0}, | 1476 | { &key_hash_filo_lock, "hash_filo::lock", 0}, |
196 | 1477 | { &key_LOCK_active_mi, "LOCK_active_mi", PSI_FLAG_GLOBAL}, | 1477 | { &key_LOCK_active_mi, "LOCK_active_mi", PSI_FLAG_GLOBAL}, |
197 | @@ -1479,7 +1479,7 @@ | |||
198 | 1479 | { &key_LOCK_connection_count, "LOCK_connection_count", PSI_FLAG_GLOBAL}, | 1479 | { &key_LOCK_connection_count, "LOCK_connection_count", PSI_FLAG_GLOBAL}, |
199 | 1480 | { &key_LOCK_crypt, "LOCK_crypt", PSI_FLAG_GLOBAL}, | 1480 | { &key_LOCK_crypt, "LOCK_crypt", PSI_FLAG_GLOBAL}, |
200 | 1481 | { &key_LOCK_delayed_create, "LOCK_delayed_create", PSI_FLAG_GLOBAL}, | 1481 | { &key_LOCK_delayed_create, "LOCK_delayed_create", PSI_FLAG_GLOBAL}, |
202 | 1482 | @@ -8039,6 +8044,7 @@ | 1482 | @@ -7907,6 +7912,7 @@ |
203 | 1483 | "LOCK_global_index_stats", PSI_FLAG_GLOBAL}, | 1483 | "LOCK_global_index_stats", PSI_FLAG_GLOBAL}, |
204 | 1484 | { &key_LOCK_gdl, "LOCK_gdl", PSI_FLAG_GLOBAL}, | 1484 | { &key_LOCK_gdl, "LOCK_gdl", PSI_FLAG_GLOBAL}, |
205 | 1485 | { &key_LOCK_global_system_variables, "LOCK_global_system_variables", PSI_FLAG_GLOBAL}, | 1485 | { &key_LOCK_global_system_variables, "LOCK_global_system_variables", PSI_FLAG_GLOBAL}, |
206 | @@ -1487,7 +1487,7 @@ | |||
207 | 1487 | { &key_LOCK_manager, "LOCK_manager", PSI_FLAG_GLOBAL}, | 1487 | { &key_LOCK_manager, "LOCK_manager", PSI_FLAG_GLOBAL}, |
208 | 1488 | { &key_LOCK_prepared_stmt_count, "LOCK_prepared_stmt_count", PSI_FLAG_GLOBAL}, | 1488 | { &key_LOCK_prepared_stmt_count, "LOCK_prepared_stmt_count", PSI_FLAG_GLOBAL}, |
209 | 1489 | { &key_LOCK_rpl_status, "LOCK_rpl_status", PSI_FLAG_GLOBAL}, | 1489 | { &key_LOCK_rpl_status, "LOCK_rpl_status", PSI_FLAG_GLOBAL}, |
211 | 1490 | @@ -8050,6 +8056,7 @@ | 1490 | @@ -7918,6 +7924,7 @@ |
212 | 1491 | { &key_LOCK_temporary_tables, "THD::LOCK_temporary_tables", 0}, | 1491 | { &key_LOCK_temporary_tables, "THD::LOCK_temporary_tables", 0}, |
213 | 1492 | { &key_LOCK_user_conn, "LOCK_user_conn", PSI_FLAG_GLOBAL}, | 1492 | { &key_LOCK_user_conn, "LOCK_user_conn", PSI_FLAG_GLOBAL}, |
214 | 1493 | { &key_LOCK_uuid_generator, "LOCK_uuid_generator", PSI_FLAG_GLOBAL}, | 1493 | { &key_LOCK_uuid_generator, "LOCK_uuid_generator", PSI_FLAG_GLOBAL}, |
215 | @@ -1495,7 +1495,7 @@ | |||
216 | 1495 | { &key_LOG_LOCK_log, "LOG::LOCK_log", 0}, | 1495 | { &key_LOG_LOCK_log, "LOG::LOCK_log", 0}, |
217 | 1496 | { &key_master_info_data_lock, "Master_info::data_lock", 0}, | 1496 | { &key_master_info_data_lock, "Master_info::data_lock", 0}, |
218 | 1497 | { &key_master_info_run_lock, "Master_info::run_lock", 0}, | 1497 | { &key_master_info_run_lock, "Master_info::run_lock", 0}, |
220 | 1498 | @@ -8097,6 +8104,7 @@ | 1498 | @@ -7965,6 +7972,7 @@ |
221 | 1499 | key_TABLE_SHARE_cond, key_user_level_lock_cond, | 1499 | key_TABLE_SHARE_cond, key_user_level_lock_cond, |
222 | 1500 | key_COND_thread_count, key_COND_thread_cache, key_COND_flush_thread_cache; | 1500 | key_COND_thread_count, key_COND_thread_cache, key_COND_flush_thread_cache; |
223 | 1501 | PSI_cond_key key_RELAYLOG_update_cond; | 1501 | PSI_cond_key key_RELAYLOG_update_cond; |
224 | @@ -1503,7 +1503,7 @@ | |||
225 | 1503 | 1503 | ||
226 | 1504 | static PSI_cond_info all_server_conds[]= | 1504 | static PSI_cond_info all_server_conds[]= |
227 | 1505 | { | 1505 | { |
229 | 1506 | @@ -8113,8 +8121,10 @@ | 1506 | @@ -7981,8 +7989,10 @@ |
230 | 1507 | { &key_RELAYLOG_update_cond, "MYSQL_RELAY_LOG::update_cond", 0}, | 1507 | { &key_RELAYLOG_update_cond, "MYSQL_RELAY_LOG::update_cond", 0}, |
231 | 1508 | { &key_COND_cache_status_changed, "Query_cache::COND_cache_status_changed", 0}, | 1508 | { &key_COND_cache_status_changed, "Query_cache::COND_cache_status_changed", 0}, |
232 | 1509 | { &key_COND_manager, "COND_manager", PSI_FLAG_GLOBAL}, | 1509 | { &key_COND_manager, "COND_manager", PSI_FLAG_GLOBAL}, |
233 | @@ -1516,7 +1516,7 @@ | |||
234 | 1516 | { &key_item_func_sleep_cond, "Item_func_sleep::cond", 0}, | 1516 | { &key_item_func_sleep_cond, "Item_func_sleep::cond", 0}, |
235 | 1517 | --- a/sql/mysqld.h | 1517 | --- a/sql/mysqld.h |
236 | 1518 | +++ b/sql/mysqld.h | 1518 | +++ b/sql/mysqld.h |
238 | 1519 | @@ -273,6 +273,7 @@ | 1519 | @@ -274,6 +274,7 @@ |
239 | 1520 | key_structure_guard_mutex, key_TABLE_SHARE_LOCK_ha_data, | 1520 | key_structure_guard_mutex, key_TABLE_SHARE_LOCK_ha_data, |
240 | 1521 | key_LOCK_error_messages, key_LOCK_thread_count, key_PARTITION_LOCK_auto_inc; | 1521 | key_LOCK_error_messages, key_LOCK_thread_count, key_PARTITION_LOCK_auto_inc; |
241 | 1522 | extern PSI_mutex_key key_RELAYLOG_LOCK_index; | 1522 | extern PSI_mutex_key key_RELAYLOG_LOCK_index; |
242 | @@ -1524,7 +1524,7 @@ | |||
243 | 1524 | 1524 | ||
244 | 1525 | extern PSI_rwlock_key key_rwlock_LOCK_grant, key_rwlock_LOCK_logger, | 1525 | extern PSI_rwlock_key key_rwlock_LOCK_grant, key_rwlock_LOCK_logger, |
245 | 1526 | key_rwlock_LOCK_sys_init_connect, key_rwlock_LOCK_sys_init_slave, | 1526 | key_rwlock_LOCK_sys_init_connect, key_rwlock_LOCK_sys_init_slave, |
247 | 1527 | @@ -293,6 +294,7 @@ | 1527 | @@ -294,6 +295,7 @@ |
248 | 1528 | key_TABLE_SHARE_cond, key_user_level_lock_cond, | 1528 | key_TABLE_SHARE_cond, key_user_level_lock_cond, |
249 | 1529 | key_COND_thread_count, key_COND_thread_cache, key_COND_flush_thread_cache; | 1529 | key_COND_thread_count, key_COND_thread_cache, key_COND_flush_thread_cache; |
250 | 1530 | extern PSI_cond_key key_RELAYLOG_update_cond; | 1530 | extern PSI_cond_key key_RELAYLOG_update_cond; |
251 | @@ -1552,7 +1552,7 @@ | |||
252 | 1552 | mysql_mutex_destroy(&LOCK_thd_data); | 1552 | mysql_mutex_destroy(&LOCK_thd_data); |
253 | 1553 | mysql_mutex_destroy(&LOCK_temporary_tables); | 1553 | mysql_mutex_destroy(&LOCK_temporary_tables); |
254 | 1554 | #ifndef DBUG_OFF | 1554 | #ifndef DBUG_OFF |
256 | 1555 | @@ -5292,6 +5296,24 @@ | 1555 | @@ -5297,6 +5301,24 @@ |
257 | 1556 | DBUG_RETURN(0); | 1556 | DBUG_RETURN(0); |
258 | 1557 | } | 1557 | } |
259 | 1558 | 1558 | ||
260 | @@ -1887,7 +1887,7 @@ | |||
261 | 1887 | 1887 | ||
262 | 1888 | trx_deregister_from_2pc(trx); | 1888 | trx_deregister_from_2pc(trx); |
263 | 1889 | 1889 | ||
265 | 1890 | @@ -10982,6 +11149,7 @@ | 1890 | @@ -10981,6 +11148,7 @@ |
266 | 1891 | 1891 | ||
267 | 1892 | srv_active_wake_master_thread(); | 1892 | srv_active_wake_master_thread(); |
268 | 1893 | 1893 | ||
269 | @@ -1895,7 +1895,7 @@ | |||
270 | 1895 | if (thd_sql_command(thd) != SQLCOM_XA_PREPARE | 1895 | if (thd_sql_command(thd) != SQLCOM_XA_PREPARE |
271 | 1896 | && (all | 1896 | && (all |
272 | 1897 | || !thd_test_options( | 1897 | || !thd_test_options( |
274 | 1898 | @@ -11008,6 +11176,7 @@ | 1898 | @@ -11007,6 +11175,7 @@ |
275 | 1899 | mysql_mutex_lock(&prepare_commit_mutex); | 1899 | mysql_mutex_lock(&prepare_commit_mutex); |
276 | 1900 | trx_owns_prepare_commit_mutex_set(trx); | 1900 | trx_owns_prepare_commit_mutex_set(trx); |
277 | 1901 | } | 1901 | } |
278 | 1902 | 1902 | ||
279 | === modified file 'patches/innodb_adaptive_hash_index_partitions.patch' | |||
280 | --- patches/innodb_adaptive_hash_index_partitions.patch 2012-01-11 15:14:15 +0000 | |||
281 | +++ patches/innodb_adaptive_hash_index_partitions.patch 2012-02-06 05:02:26 +0000 | |||
282 | @@ -851,7 +851,7 @@ | |||
283 | 851 | 851 | ||
284 | 852 | #ifdef UNIV_DEBUG | 852 | #ifdef UNIV_DEBUG |
285 | 853 | block->page.in_page_hash = FALSE; | 853 | block->page.in_page_hash = FALSE; |
287 | 854 | @@ -1427,7 +1428,11 @@ | 854 | @@ -1429,7 +1430,11 @@ |
288 | 855 | ulint p; | 855 | ulint p; |
289 | 856 | 856 | ||
290 | 857 | #ifdef UNIV_SYNC_DEBUG | 857 | #ifdef UNIV_SYNC_DEBUG |
291 | @@ -864,7 +864,7 @@ | |||
292 | 864 | #endif /* UNIV_SYNC_DEBUG */ | 864 | #endif /* UNIV_SYNC_DEBUG */ |
293 | 865 | ut_ad(!btr_search_enabled); | 865 | ut_ad(!btr_search_enabled); |
294 | 866 | 866 | ||
296 | 867 | @@ -2142,6 +2147,7 @@ | 867 | @@ -2144,6 +2149,7 @@ |
297 | 868 | { | 868 | { |
298 | 869 | block->check_index_page_at_flush = FALSE; | 869 | block->check_index_page_at_flush = FALSE; |
299 | 870 | block->index = NULL; | 870 | block->index = NULL; |
300 | @@ -874,7 +874,7 @@ | |||
301 | 874 | block->n_fields = 1; | 874 | block->n_fields = 1; |
302 | 875 | --- a/storage/innobase/buf/buf0lru.c | 875 | --- a/storage/innobase/buf/buf0lru.c |
303 | 876 | +++ b/storage/innobase/buf/buf0lru.c | 876 | +++ b/storage/innobase/buf/buf0lru.c |
305 | 877 | @@ -560,7 +560,7 @@ | 877 | @@ -576,7 +576,7 @@ |
306 | 878 | 878 | ||
307 | 879 | mutex_exit(&buf_pool->LRU_list_mutex); | 879 | mutex_exit(&buf_pool->LRU_list_mutex); |
308 | 880 | 880 | ||
309 | @@ -883,7 +883,7 @@ | |||
310 | 883 | chunk = buf_pool->chunks; | 883 | chunk = buf_pool->chunks; |
311 | 884 | for (j = buf_pool->n_chunks; j--; chunk++) { | 884 | for (j = buf_pool->n_chunks; j--; chunk++) { |
312 | 885 | buf_block_t* block = chunk->blocks; | 885 | buf_block_t* block = chunk->blocks; |
314 | 886 | @@ -572,16 +572,16 @@ | 886 | @@ -588,16 +588,16 @@ |
315 | 887 | continue; | 887 | continue; |
316 | 888 | } | 888 | } |
317 | 889 | 889 | ||
318 | @@ -905,7 +905,7 @@ | |||
319 | 905 | 905 | ||
320 | 906 | --- a/storage/innobase/dict/dict0dict.c | 906 | --- a/storage/innobase/dict/dict0dict.c |
321 | 907 | +++ b/storage/innobase/dict/dict0dict.c | 907 | +++ b/storage/innobase/dict/dict0dict.c |
323 | 908 | @@ -1846,7 +1846,7 @@ | 908 | @@ -1851,7 +1851,7 @@ |
324 | 909 | zero. */ | 909 | zero. */ |
325 | 910 | 910 | ||
326 | 911 | for (;;) { | 911 | for (;;) { |
327 | @@ -916,7 +916,7 @@ | |||
328 | 916 | } | 916 | } |
329 | 917 | --- a/storage/innobase/handler/ha_innodb.cc | 917 | --- a/storage/innobase/handler/ha_innodb.cc |
330 | 918 | +++ b/storage/innobase/handler/ha_innodb.cc | 918 | +++ b/storage/innobase/handler/ha_innodb.cc |
332 | 919 | @@ -11833,6 +11833,11 @@ | 919 | @@ -11832,6 +11832,11 @@ |
333 | 920 | "Disable with --skip-innodb-adaptive-hash-index.", | 920 | "Disable with --skip-innodb-adaptive-hash-index.", |
334 | 921 | NULL, innodb_adaptive_hash_index_update, TRUE); | 921 | NULL, innodb_adaptive_hash_index_update, TRUE); |
335 | 922 | 922 | ||
336 | @@ -928,7 +928,7 @@ | |||
337 | 928 | static MYSQL_SYSVAR_ULONG(replication_delay, srv_replication_delay, | 928 | static MYSQL_SYSVAR_ULONG(replication_delay, srv_replication_delay, |
338 | 929 | PLUGIN_VAR_RQCMDARG, | 929 | PLUGIN_VAR_RQCMDARG, |
339 | 930 | "Replication thread delay (ms) on the slave server if " | 930 | "Replication thread delay (ms) on the slave server if " |
341 | 931 | @@ -12253,6 +12258,7 @@ | 931 | @@ -12252,6 +12257,7 @@ |
342 | 932 | MYSQL_SYSVAR(use_sys_stats_table), | 932 | MYSQL_SYSVAR(use_sys_stats_table), |
343 | 933 | MYSQL_SYSVAR(stats_sample_pages), | 933 | MYSQL_SYSVAR(stats_sample_pages), |
344 | 934 | MYSQL_SYSVAR(adaptive_hash_index), | 934 | MYSQL_SYSVAR(adaptive_hash_index), |
345 | @@ -1411,7 +1411,7 @@ | |||
346 | 1411 | 1411 | ||
347 | 1412 | --- a/storage/innobase/include/buf0buf.h | 1412 | --- a/storage/innobase/include/buf0buf.h |
348 | 1413 | +++ b/storage/innobase/include/buf0buf.h | 1413 | +++ b/storage/innobase/include/buf0buf.h |
350 | 1414 | @@ -1580,6 +1580,7 @@ | 1414 | @@ -1600,6 +1600,7 @@ |
351 | 1415 | complete, though: there may | 1415 | complete, though: there may |
352 | 1416 | have been hash collisions, | 1416 | have been hash collisions, |
353 | 1417 | record deletions, etc. */ | 1417 | record deletions, etc. */ |
354 | 1418 | 1418 | ||
355 | === modified file 'patches/innodb_admin_command_base.patch' | |||
356 | --- patches/innodb_admin_command_base.patch 2011-12-27 15:32:16 +0000 | |||
357 | +++ patches/innodb_admin_command_base.patch 2012-02-06 05:02:26 +0000 | |||
358 | @@ -7,7 +7,7 @@ | |||
359 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
360 | 8 | --- a/storage/innobase/handler/ha_innodb.cc | 8 | --- a/storage/innobase/handler/ha_innodb.cc |
361 | 9 | +++ b/storage/innobase/handler/ha_innodb.cc | 9 | +++ b/storage/innobase/handler/ha_innodb.cc |
363 | 10 | @@ -11999,7 +11999,8 @@ | 10 | @@ -12041,7 +12041,8 @@ |
364 | 11 | i_s_innodb_sys_foreign_cols, | 11 | i_s_innodb_sys_foreign_cols, |
365 | 12 | i_s_innodb_sys_stats, | 12 | i_s_innodb_sys_stats, |
366 | 13 | i_s_innodb_table_stats, | 13 | i_s_innodb_table_stats, |
367 | 14 | 14 | ||
368 | === modified file 'patches/innodb_buffer_pool_pages_i_s.patch' | |||
369 | --- patches/innodb_buffer_pool_pages_i_s.patch 2011-12-27 15:32:16 +0000 | |||
370 | +++ patches/innodb_buffer_pool_pages_i_s.patch 2012-02-06 05:02:26 +0000 | |||
371 | @@ -7,7 +7,7 @@ | |||
372 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
373 | 8 | --- a/storage/innobase/buf/buf0buf.c | 8 | --- a/storage/innobase/buf/buf0buf.c |
374 | 9 | +++ b/storage/innobase/buf/buf0buf.c | 9 | +++ b/storage/innobase/buf/buf0buf.c |
376 | 10 | @@ -4161,6 +4161,36 @@ | 10 | @@ -4163,6 +4163,36 @@ |
377 | 11 | mutex_exit(block_mutex); | 11 | mutex_exit(block_mutex); |
378 | 12 | } | 12 | } |
379 | 13 | 13 | ||
380 | @@ -46,7 +46,7 @@ | |||
381 | 46 | @return TRUE */ | 46 | @return TRUE */ |
382 | 47 | --- a/storage/innobase/handler/ha_innodb.cc | 47 | --- a/storage/innobase/handler/ha_innodb.cc |
383 | 48 | +++ b/storage/innobase/handler/ha_innodb.cc | 48 | +++ b/storage/innobase/handler/ha_innodb.cc |
385 | 49 | @@ -12296,6 +12296,9 @@ | 49 | @@ -12338,6 +12338,9 @@ |
386 | 50 | i_s_innodb_sys_stats, | 50 | i_s_innodb_sys_stats, |
387 | 51 | i_s_innodb_table_stats, | 51 | i_s_innodb_table_stats, |
388 | 52 | i_s_innodb_index_stats, | 52 | i_s_innodb_index_stats, |
389 | @@ -793,7 +793,7 @@ | |||
390 | 793 | #endif /* i_s_h */ | 793 | #endif /* i_s_h */ |
391 | 794 | --- a/storage/innobase/include/buf0buf.h | 794 | --- a/storage/innobase/include/buf0buf.h |
392 | 795 | +++ b/storage/innobase/include/buf0buf.h | 795 | +++ b/storage/innobase/include/buf0buf.h |
394 | 796 | @@ -1161,6 +1161,14 @@ | 796 | @@ -1181,6 +1181,14 @@ |
395 | 797 | /*===========*/ | 797 | /*===========*/ |
396 | 798 | const buf_pool_t* buf_pool) /*!< in: buffer pool */ | 798 | const buf_pool_t* buf_pool) /*!< in: buffer pool */ |
397 | 799 | __attribute__((nonnull, const)); | 799 | __attribute__((nonnull, const)); |
398 | 800 | 800 | ||
399 | === modified file 'patches/innodb_buffer_pool_shm.patch' | |||
400 | --- patches/innodb_buffer_pool_shm.patch 2011-12-27 15:32:16 +0000 | |||
401 | +++ patches/innodb_buffer_pool_shm.patch 2012-02-06 05:02:26 +0000 | |||
402 | @@ -55,7 +55,7 @@ | |||
403 | 55 | srv_mem_pool_size = (ulint) innobase_additional_mem_pool_size; | 55 | srv_mem_pool_size = (ulint) innobase_additional_mem_pool_size; |
404 | 56 | 56 | ||
405 | 57 | srv_n_file_io_threads = (ulint) innobase_file_io_threads; | 57 | srv_n_file_io_threads = (ulint) innobase_file_io_threads; |
407 | 58 | @@ -11864,6 +11872,16 @@ | 58 | @@ -11863,6 +11871,16 @@ |
408 | 59 | "Number of buffer pool instances, set to higher value on high-end machines to increase scalability", | 59 | "Number of buffer pool instances, set to higher value on high-end machines to increase scalability", |
409 | 60 | NULL, NULL, 1L, 1L, MAX_BUFFER_POOLS, 1L); | 60 | NULL, NULL, 1L, 1L, MAX_BUFFER_POOLS, 1L); |
410 | 61 | 61 | ||
411 | @@ -72,7 +72,7 @@ | |||
412 | 72 | static MYSQL_SYSVAR_ULONG(commit_concurrency, innobase_commit_concurrency, | 72 | static MYSQL_SYSVAR_ULONG(commit_concurrency, innobase_commit_concurrency, |
413 | 73 | PLUGIN_VAR_RQCMDARG, | 73 | PLUGIN_VAR_RQCMDARG, |
414 | 74 | "Helps in performance tuning in heavily concurrent environments.", | 74 | "Helps in performance tuning in heavily concurrent environments.", |
416 | 75 | @@ -12170,6 +12188,8 @@ | 75 | @@ -12209,6 +12227,8 @@ |
417 | 76 | MYSQL_SYSVAR(autoextend_increment), | 76 | MYSQL_SYSVAR(autoextend_increment), |
418 | 77 | MYSQL_SYSVAR(buffer_pool_size), | 77 | MYSQL_SYSVAR(buffer_pool_size), |
419 | 78 | MYSQL_SYSVAR(buffer_pool_instances), | 78 | MYSQL_SYSVAR(buffer_pool_instances), |
420 | 79 | 79 | ||
421 | === modified file 'patches/innodb_deadlock_count.patch' | |||
422 | --- patches/innodb_deadlock_count.patch 2011-10-28 08:46:55 +0000 | |||
423 | +++ patches/innodb_deadlock_count.patch 2012-02-06 05:02:26 +0000 | |||
424 | @@ -28,7 +28,7 @@ | |||
425 | 28 | Gets the size of a lock struct. | 28 | Gets the size of a lock struct. |
426 | 29 | --- a/storage/innobase/include/srv0srv.h | 29 | --- a/storage/innobase/include/srv0srv.h |
427 | 30 | +++ b/storage/innobase/include/srv0srv.h | 30 | +++ b/storage/innobase/include/srv0srv.h |
429 | 31 | @@ -767,6 +767,7 @@ | 31 | @@ -770,6 +770,7 @@ |
430 | 32 | ulint innodb_buffer_pool_read_ahead_evicted;/*!< srv_read_ahead evicted*/ | 32 | ulint innodb_buffer_pool_read_ahead_evicted;/*!< srv_read_ahead evicted*/ |
431 | 33 | ulint innodb_dblwr_pages_written; /*!< srv_dblwr_pages_written */ | 33 | ulint innodb_dblwr_pages_written; /*!< srv_dblwr_pages_written */ |
432 | 34 | ulint innodb_dblwr_writes; /*!< srv_dblwr_writes */ | 34 | ulint innodb_dblwr_writes; /*!< srv_dblwr_writes */ |
433 | @@ -48,7 +48,7 @@ | |||
434 | 48 | break; | 48 | break; |
435 | 49 | --- a/storage/innobase/srv/srv0srv.c | 49 | --- a/storage/innobase/srv/srv0srv.c |
436 | 50 | +++ b/storage/innobase/srv/srv0srv.c | 50 | +++ b/storage/innobase/srv/srv0srv.c |
438 | 51 | @@ -474,6 +474,7 @@ | 51 | @@ -477,6 +477,7 @@ |
439 | 52 | static ulint srv_n_rows_deleted_old = 0; | 52 | static ulint srv_n_rows_deleted_old = 0; |
440 | 53 | static ulint srv_n_rows_read_old = 0; | 53 | static ulint srv_n_rows_read_old = 0; |
441 | 54 | 54 | ||
442 | @@ -56,7 +56,7 @@ | |||
443 | 56 | UNIV_INTERN ulint srv_n_lock_wait_count = 0; | 56 | UNIV_INTERN ulint srv_n_lock_wait_count = 0; |
444 | 57 | UNIV_INTERN ulint srv_n_lock_wait_current_count = 0; | 57 | UNIV_INTERN ulint srv_n_lock_wait_current_count = 0; |
445 | 58 | UNIV_INTERN ib_int64_t srv_n_lock_wait_time = 0; | 58 | UNIV_INTERN ib_int64_t srv_n_lock_wait_time = 0; |
447 | 59 | @@ -2290,6 +2291,7 @@ | 59 | @@ -2293,6 +2294,7 @@ |
448 | 60 | export_vars.innodb_buffer_pool_pages_data = LRU_len; | 60 | export_vars.innodb_buffer_pool_pages_data = LRU_len; |
449 | 61 | export_vars.innodb_buffer_pool_pages_dirty = flush_list_len; | 61 | export_vars.innodb_buffer_pool_pages_dirty = flush_list_len; |
450 | 62 | export_vars.innodb_buffer_pool_pages_free = free_len; | 62 | export_vars.innodb_buffer_pool_pages_free = free_len; |
451 | 63 | 63 | ||
452 | === modified file 'patches/innodb_dict_size_limit.patch' | |||
453 | --- patches/innodb_dict_size_limit.patch 2011-12-27 15:32:16 +0000 | |||
454 | +++ patches/innodb_dict_size_limit.patch 2012-02-06 05:02:26 +0000 | |||
455 | @@ -289,7 +289,7 @@ | |||
456 | 289 | mutex_exit(&(dict_sys->mutex)); | 289 | mutex_exit(&(dict_sys->mutex)); |
457 | 290 | 290 | ||
458 | 291 | if (table != NULL) { | 291 | if (table != NULL) { |
460 | 292 | @@ -1259,6 +1263,64 @@ | 292 | @@ -1264,6 +1268,64 @@ |
461 | 293 | dict_mem_table_free(table); | 293 | dict_mem_table_free(table); |
462 | 294 | } | 294 | } |
463 | 295 | 295 | ||
464 | @@ -354,7 +354,7 @@ | |||
465 | 354 | /****************************************************************//** | 354 | /****************************************************************//** |
466 | 355 | If the given column name is reserved for InnoDB system columns, return | 355 | If the given column name is reserved for InnoDB system columns, return |
467 | 356 | TRUE. | 356 | TRUE. |
469 | 357 | @@ -1763,6 +1825,11 @@ | 357 | @@ -1768,6 +1830,11 @@ |
470 | 358 | ut_ad(index->magic_n == DICT_INDEX_MAGIC_N); | 358 | ut_ad(index->magic_n == DICT_INDEX_MAGIC_N); |
471 | 359 | ut_ad(mutex_own(&(dict_sys->mutex))); | 359 | ut_ad(mutex_own(&(dict_sys->mutex))); |
472 | 360 | 360 | ||
473 | @@ -377,9 +377,9 @@ | |||
474 | 377 | {"have_atomic_builtins", | 377 | {"have_atomic_builtins", |
475 | 378 | (char*) &export_vars.innodb_have_atomic_builtins, SHOW_BOOL}, | 378 | (char*) &export_vars.innodb_have_atomic_builtins, SHOW_BOOL}, |
476 | 379 | {"log_waits", | 379 | {"log_waits", |
480 | 380 | @@ -11774,6 +11776,11 @@ | 380 | @@ -11813,6 +11815,11 @@ |
481 | 381 | "Choose method of innodb_adaptive_flushing. (native, [estimate], keep_average)", | 381 | NULL, NULL, 0, 0, 1, 0); |
482 | 382 | NULL, innodb_adaptive_flushing_method_update, 1, &adaptive_flushing_method_typelib); | 382 | #endif |
483 | 383 | 383 | ||
484 | 384 | +static MYSQL_SYSVAR_ULONG(dict_size_limit, srv_dict_size_limit, | 384 | +static MYSQL_SYSVAR_ULONG(dict_size_limit, srv_dict_size_limit, |
485 | 385 | + PLUGIN_VAR_RQCMDARG, | 385 | + PLUGIN_VAR_RQCMDARG, |
486 | @@ -389,7 +389,7 @@ | |||
487 | 389 | static struct st_mysql_sys_var* innobase_system_variables[]= { | 389 | static struct st_mysql_sys_var* innobase_system_variables[]= { |
488 | 390 | MYSQL_SYSVAR(additional_mem_pool_size), | 390 | MYSQL_SYSVAR(additional_mem_pool_size), |
489 | 391 | MYSQL_SYSVAR(autoextend_increment), | 391 | MYSQL_SYSVAR(autoextend_increment), |
491 | 392 | @@ -11843,6 +11850,7 @@ | 392 | @@ -11882,6 +11889,7 @@ |
492 | 393 | MYSQL_SYSVAR(flush_neighbor_pages), | 393 | MYSQL_SYSVAR(flush_neighbor_pages), |
493 | 394 | MYSQL_SYSVAR(read_ahead), | 394 | MYSQL_SYSVAR(read_ahead), |
494 | 395 | MYSQL_SYSVAR(adaptive_flushing_method), | 395 | MYSQL_SYSVAR(adaptive_flushing_method), |
495 | @@ -425,7 +425,7 @@ | |||
496 | 425 | or freed in a file segment. */ | 425 | or freed in a file segment. */ |
497 | 426 | --- a/storage/innobase/include/buf0buf.h | 426 | --- a/storage/innobase/include/buf0buf.h |
498 | 427 | +++ b/storage/innobase/include/buf0buf.h | 427 | +++ b/storage/innobase/include/buf0buf.h |
500 | 428 | @@ -1575,6 +1575,15 @@ | 428 | @@ -1595,6 +1595,15 @@ |
501 | 429 | #define BUF_POOL_ZIP_FOLD_BPAGE(b) BUF_POOL_ZIP_FOLD((buf_block_t*) (b)) | 429 | #define BUF_POOL_ZIP_FOLD_BPAGE(b) BUF_POOL_ZIP_FOLD((buf_block_t*) (b)) |
502 | 430 | /* @} */ | 430 | /* @} */ |
503 | 431 | 431 | ||
504 | @@ -495,7 +495,7 @@ | |||
505 | 495 | /*-------------------------------------------*/ | 495 | /*-------------------------------------------*/ |
506 | 496 | 496 | ||
507 | 497 | extern ulint srv_n_rows_inserted; | 497 | extern ulint srv_n_rows_inserted; |
509 | 498 | @@ -714,6 +715,7 @@ | 498 | @@ -717,6 +718,7 @@ |
510 | 499 | ulint innodb_data_writes; /*!< I/O write requests */ | 499 | ulint innodb_data_writes; /*!< I/O write requests */ |
511 | 500 | ulint innodb_data_written; /*!< Data bytes written */ | 500 | ulint innodb_data_written; /*!< Data bytes written */ |
512 | 501 | ulint innodb_data_reads; /*!< I/O read requests */ | 501 | ulint innodb_data_reads; /*!< I/O read requests */ |
513 | @@ -514,7 +514,7 @@ | |||
514 | 514 | /*-------------------------------------------*/ | 514 | /*-------------------------------------------*/ |
515 | 515 | UNIV_INTERN ulong srv_n_spin_wait_rounds = 30; | 515 | UNIV_INTERN ulong srv_n_spin_wait_rounds = 30; |
516 | 516 | UNIV_INTERN ulong srv_n_free_tickets_to_enter = 500; | 516 | UNIV_INTERN ulong srv_n_free_tickets_to_enter = 500; |
518 | 517 | @@ -2222,6 +2224,7 @@ | 517 | @@ -2225,6 +2227,7 @@ |
519 | 518 | export_vars.innodb_data_reads = os_n_file_reads; | 518 | export_vars.innodb_data_reads = os_n_file_reads; |
520 | 519 | export_vars.innodb_data_writes = os_n_file_writes; | 519 | export_vars.innodb_data_writes = os_n_file_writes; |
521 | 520 | export_vars.innodb_data_written = srv_data_written; | 520 | export_vars.innodb_data_written = srv_data_written; |
522 | 521 | 521 | ||
523 | === modified file 'patches/innodb_expand_fast_index_creation.patch' | |||
524 | --- patches/innodb_expand_fast_index_creation.patch 2011-12-27 15:32:16 +0000 | |||
525 | +++ patches/innodb_expand_fast_index_creation.patch 2012-02-06 05:02:26 +0000 | |||
526 | @@ -884,7 +884,7 @@ | |||
527 | 884 | 884 | ||
528 | 885 | --- a/sql/sql_lex.h | 885 | --- a/sql/sql_lex.h |
529 | 886 | +++ b/sql/sql_lex.h | 886 | +++ b/sql/sql_lex.h |
531 | 887 | @@ -1013,6 +1013,9 @@ | 887 | @@ -1014,6 +1014,9 @@ |
532 | 888 | List<Alter_column> alter_list; | 888 | List<Alter_column> alter_list; |
533 | 889 | List<Key> key_list; | 889 | List<Key> key_list; |
534 | 890 | List<Create_field> create_list; | 890 | List<Create_field> create_list; |
535 | @@ -894,7 +894,7 @@ | |||
536 | 894 | uint flags; | 894 | uint flags; |
537 | 895 | enum enum_enable_or_disable keys_onoff; | 895 | enum enum_enable_or_disable keys_onoff; |
538 | 896 | enum tablespace_op_type tablespace_op; | 896 | enum tablespace_op_type tablespace_op; |
540 | 897 | @@ -1024,6 +1027,8 @@ | 897 | @@ -1025,6 +1028,8 @@ |
541 | 898 | 898 | ||
542 | 899 | 899 | ||
543 | 900 | Alter_info() : | 900 | Alter_info() : |
544 | @@ -903,7 +903,7 @@ | |||
545 | 903 | flags(0), | 903 | flags(0), |
546 | 904 | keys_onoff(LEAVE_AS_IS), | 904 | keys_onoff(LEAVE_AS_IS), |
547 | 905 | tablespace_op(NO_TABLESPACE_OP), | 905 | tablespace_op(NO_TABLESPACE_OP), |
549 | 906 | @@ -1039,6 +1044,9 @@ | 906 | @@ -1040,6 +1045,9 @@ |
550 | 907 | alter_list.empty(); | 907 | alter_list.empty(); |
551 | 908 | key_list.empty(); | 908 | key_list.empty(); |
552 | 909 | create_list.empty(); | 909 | create_list.empty(); |
553 | @@ -1322,7 +1322,7 @@ | |||
554 | 1322 | 1322 | ||
555 | 1323 | --- a/sql/sys_vars.cc | 1323 | --- a/sql/sys_vars.cc |
556 | 1324 | +++ b/sql/sys_vars.cc | 1324 | +++ b/sql/sys_vars.cc |
558 | 1325 | @@ -710,6 +710,14 @@ | 1325 | @@ -783,6 +783,14 @@ |
559 | 1326 | ON_CHECK(event_scheduler_check), ON_UPDATE(event_scheduler_update)); | 1326 | ON_CHECK(event_scheduler_check), ON_UPDATE(event_scheduler_update)); |
560 | 1327 | #endif | 1327 | #endif |
561 | 1328 | 1328 | ||
562 | @@ -1425,7 +1425,7 @@ | |||
563 | 1425 | --expire-logs-days=# | 1425 | --expire-logs-days=# |
564 | 1426 | If non-zero, binary logs will be purged after | 1426 | If non-zero, binary logs will be purged after |
565 | 1427 | expire_logs_days days; possible purges happen at startup | 1427 | expire_logs_days days; possible purges happen at startup |
567 | 1428 | @@ -777,6 +781,7 @@ | 1428 | @@ -781,6 +785,7 @@ |
568 | 1429 | div-precision-increment 4 | 1429 | div-precision-increment 4 |
569 | 1430 | engine-condition-pushdown TRUE | 1430 | engine-condition-pushdown TRUE |
570 | 1431 | event-scheduler OFF | 1431 | event-scheduler OFF |
571 | 1432 | 1432 | ||
572 | === modified file 'patches/innodb_expand_import.patch' | |||
573 | --- patches/innodb_expand_import.patch 2011-12-27 15:32:16 +0000 | |||
574 | +++ patches/innodb_expand_import.patch 2012-02-06 05:02:26 +0000 | |||
575 | @@ -51,7 +51,7 @@ | |||
576 | 51 | #ifndef UNIV_HOTBACKUP | 51 | #ifndef UNIV_HOTBACKUP |
577 | 52 | # include "buf0lru.h" | 52 | # include "buf0lru.h" |
578 | 53 | # include "ibuf0ibuf.h" | 53 | # include "ibuf0ibuf.h" |
580 | 54 | @@ -3033,6 +3041,84 @@ | 54 | @@ -3041,6 +3049,84 @@ |
581 | 55 | } | 55 | } |
582 | 56 | 56 | ||
583 | 57 | /********************************************************************//** | 57 | /********************************************************************//** |
584 | @@ -136,7 +136,7 @@ | |||
585 | 136 | Tries to open a single-table tablespace and optionally checks the space id is | 136 | Tries to open a single-table tablespace and optionally checks the space id is |
586 | 137 | right in it. If does not succeed, prints an error message to the .err log. This | 137 | right in it. If does not succeed, prints an error message to the .err log. This |
587 | 138 | function is used to open a tablespace when we start up mysqld, and also in | 138 | function is used to open a tablespace when we start up mysqld, and also in |
589 | 139 | @@ -3055,8 +3141,11 @@ | 139 | @@ -3063,8 +3149,11 @@ |
590 | 140 | accessing the first page of the file */ | 140 | accessing the first page of the file */ |
591 | 141 | ulint id, /*!< in: space id */ | 141 | ulint id, /*!< in: space id */ |
592 | 142 | ulint flags, /*!< in: tablespace flags */ | 142 | ulint flags, /*!< in: tablespace flags */ |
593 | @@ -149,7 +149,7 @@ | |||
594 | 149 | { | 149 | { |
595 | 150 | os_file_t file; | 150 | os_file_t file; |
596 | 151 | char* filepath; | 151 | char* filepath; |
598 | 152 | @@ -3079,7 +3168,7 @@ | 152 | @@ -3087,7 +3176,7 @@ |
599 | 153 | 153 | ||
600 | 154 | file = os_file_create_simple_no_error_handling( | 154 | file = os_file_create_simple_no_error_handling( |
601 | 155 | innodb_file_data_key, filepath, OS_FILE_OPEN, | 155 | innodb_file_data_key, filepath, OS_FILE_OPEN, |
602 | @@ -158,7 +158,7 @@ | |||
603 | 158 | if (!success) { | 158 | if (!success) { |
604 | 159 | /* The following call prints an error message */ | 159 | /* The following call prints an error message */ |
605 | 160 | os_file_get_last_error(TRUE); | 160 | os_file_get_last_error(TRUE); |
607 | 161 | @@ -3126,6 +3215,453 @@ | 161 | @@ -3134,6 +3223,453 @@ |
608 | 162 | space_id = fsp_header_get_space_id(page); | 162 | space_id = fsp_header_get_space_id(page); |
609 | 163 | space_flags = fsp_header_get_flags(page); | 163 | space_flags = fsp_header_get_flags(page); |
610 | 164 | 164 | ||
611 | @@ -612,7 +612,7 @@ | |||
612 | 612 | ut_free(buf2); | 612 | ut_free(buf2); |
613 | 613 | 613 | ||
614 | 614 | if (UNIV_UNLIKELY(space_id != id | 614 | if (UNIV_UNLIKELY(space_id != id |
616 | 615 | @@ -3167,6 +3703,269 @@ | 615 | @@ -3175,6 +3711,269 @@ |
617 | 616 | os_file_close(file); | 616 | os_file_close(file); |
618 | 617 | mem_free(filepath); | 617 | mem_free(filepath); |
619 | 618 | 618 | ||
620 | @@ -884,7 +884,7 @@ | |||
621 | 884 | #endif /* !UNIV_HOTBACKUP */ | 884 | #endif /* !UNIV_HOTBACKUP */ |
622 | 885 | --- a/storage/innobase/handler/ha_innodb.cc | 885 | --- a/storage/innobase/handler/ha_innodb.cc |
623 | 886 | +++ b/storage/innobase/handler/ha_innodb.cc | 886 | +++ b/storage/innobase/handler/ha_innodb.cc |
625 | 887 | @@ -7422,6 +7422,14 @@ | 887 | @@ -7421,6 +7421,14 @@ |
626 | 888 | err = row_discard_tablespace_for_mysql(dict_table->name, trx); | 888 | err = row_discard_tablespace_for_mysql(dict_table->name, trx); |
627 | 889 | } else { | 889 | } else { |
628 | 890 | err = row_import_tablespace_for_mysql(dict_table->name, trx); | 890 | err = row_import_tablespace_for_mysql(dict_table->name, trx); |
629 | @@ -899,9 +899,9 @@ | |||
630 | 899 | } | 899 | } |
631 | 900 | 900 | ||
632 | 901 | err = convert_error_code_to_mysql(err, dict_table->flags, NULL); | 901 | err = convert_error_code_to_mysql(err, dict_table->flags, NULL); |
636 | 902 | @@ -11781,6 +11789,11 @@ | 902 | @@ -11820,6 +11828,11 @@ |
637 | 903 | "Choose method of innodb_adaptive_flushing. (native, [estimate], keep_average)", | 903 | NULL, NULL, 0, 0, 1, 0); |
638 | 904 | NULL, innodb_adaptive_flushing_method_update, 1, &adaptive_flushing_method_typelib); | 904 | #endif |
639 | 905 | 905 | ||
640 | 906 | +static MYSQL_SYSVAR_ULONG(import_table_from_xtrabackup, srv_expand_import, | 906 | +static MYSQL_SYSVAR_ULONG(import_table_from_xtrabackup, srv_expand_import, |
641 | 907 | + PLUGIN_VAR_RQCMDARG, | 907 | + PLUGIN_VAR_RQCMDARG, |
642 | @@ -911,7 +911,7 @@ | |||
643 | 911 | static MYSQL_SYSVAR_ULONG(dict_size_limit, srv_dict_size_limit, | 911 | static MYSQL_SYSVAR_ULONG(dict_size_limit, srv_dict_size_limit, |
644 | 912 | PLUGIN_VAR_RQCMDARG, | 912 | PLUGIN_VAR_RQCMDARG, |
645 | 913 | "Limit the allocated memory for dictionary cache. (0: unlimited)", | 913 | "Limit the allocated memory for dictionary cache. (0: unlimited)", |
647 | 914 | @@ -11855,6 +11868,7 @@ | 914 | @@ -11894,6 +11907,7 @@ |
648 | 915 | MYSQL_SYSVAR(flush_neighbor_pages), | 915 | MYSQL_SYSVAR(flush_neighbor_pages), |
649 | 916 | MYSQL_SYSVAR(read_ahead), | 916 | MYSQL_SYSVAR(read_ahead), |
650 | 917 | MYSQL_SYSVAR(adaptive_flushing_method), | 917 | MYSQL_SYSVAR(adaptive_flushing_method), |
651 | @@ -1120,7 +1120,7 @@ | |||
652 | 1120 | 1120 | ||
653 | 1121 | /** When mysqld is run, the default directory "." is the mysqld datadir, | 1121 | /** When mysqld is run, the default directory "." is the mysqld datadir, |
654 | 1122 | but in the MySQL Embedded Server Library and ibbackup it is not the default | 1122 | but in the MySQL Embedded Server Library and ibbackup it is not the default |
656 | 1123 | @@ -473,8 +474,11 @@ | 1123 | @@ -478,8 +479,11 @@ |
657 | 1124 | accessing the first page of the file */ | 1124 | accessing the first page of the file */ |
658 | 1125 | ulint id, /*!< in: space id */ | 1125 | ulint id, /*!< in: space id */ |
659 | 1126 | ulint flags, /*!< in: tablespace flags */ | 1126 | ulint flags, /*!< in: tablespace flags */ |
660 | 1127 | 1127 | ||
661 | === modified file 'patches/innodb_extend_slow.patch' | |||
662 | --- patches/innodb_extend_slow.patch 2011-12-27 15:32:16 +0000 | |||
663 | +++ patches/innodb_extend_slow.patch 2012-02-06 05:02:26 +0000 | |||
664 | @@ -48,7 +48,7 @@ | |||
665 | 48 | 48 | ||
666 | 49 | /* | 49 | /* |
667 | 50 | IMPLEMENTATION OF THE BUFFER POOL | 50 | IMPLEMENTATION OF THE BUFFER POOL |
669 | 51 | @@ -1869,8 +1903,16 @@ | 51 | @@ -1871,8 +1905,16 @@ |
670 | 52 | mutex_t* block_mutex; | 52 | mutex_t* block_mutex; |
671 | 53 | ibool must_read; | 53 | ibool must_read; |
672 | 54 | unsigned access_time; | 54 | unsigned access_time; |
673 | @@ -65,7 +65,7 @@ | |||
674 | 65 | buf_pool->stat.n_page_gets++; | 65 | buf_pool->stat.n_page_gets++; |
675 | 66 | 66 | ||
676 | 67 | for (;;) { | 67 | for (;;) { |
678 | 68 | @@ -1888,7 +1930,7 @@ | 68 | @@ -1890,7 +1932,7 @@ |
679 | 69 | //buf_pool_mutex_exit(buf_pool); | 69 | //buf_pool_mutex_exit(buf_pool); |
680 | 70 | rw_lock_s_unlock(&buf_pool->page_hash_latch); | 70 | rw_lock_s_unlock(&buf_pool->page_hash_latch); |
681 | 71 | 71 | ||
682 | @@ -74,7 +74,7 @@ | |||
683 | 74 | 74 | ||
684 | 75 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 75 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
685 | 76 | ut_a(++buf_dbg_counter % 37 || buf_validate()); | 76 | ut_a(++buf_dbg_counter % 37 || buf_validate()); |
687 | 77 | @@ -1984,6 +2026,13 @@ | 77 | @@ -1986,6 +2028,13 @@ |
688 | 78 | /* Let us wait until the read operation | 78 | /* Let us wait until the read operation |
689 | 79 | completes */ | 79 | completes */ |
690 | 80 | 80 | ||
691 | @@ -88,7 +88,7 @@ | |||
692 | 88 | for (;;) { | 88 | for (;;) { |
693 | 89 | enum buf_io_fix io_fix; | 89 | enum buf_io_fix io_fix; |
694 | 90 | 90 | ||
696 | 91 | @@ -1998,6 +2047,12 @@ | 91 | @@ -2000,6 +2049,12 @@ |
697 | 92 | break; | 92 | break; |
698 | 93 | } | 93 | } |
699 | 94 | } | 94 | } |
700 | @@ -101,7 +101,7 @@ | |||
701 | 101 | } | 101 | } |
702 | 102 | 102 | ||
703 | 103 | #ifdef UNIV_IBUF_COUNT_DEBUG | 103 | #ifdef UNIV_IBUF_COUNT_DEBUG |
705 | 104 | @@ -2312,6 +2367,11 @@ | 104 | @@ -2314,6 +2369,11 @@ |
706 | 105 | ibool must_read; | 105 | ibool must_read; |
707 | 106 | ulint retries = 0; | 106 | ulint retries = 0; |
708 | 107 | mutex_t* block_mutex = NULL; | 107 | mutex_t* block_mutex = NULL; |
709 | @@ -113,7 +113,7 @@ | |||
710 | 113 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 113 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
711 | 114 | 114 | ||
712 | 115 | ut_ad(mtr); | 115 | ut_ad(mtr); |
714 | 116 | @@ -2341,6 +2401,9 @@ | 116 | @@ -2343,6 +2403,9 @@ |
715 | 117 | || ibuf_page_low(space, zip_size, offset, | 117 | || ibuf_page_low(space, zip_size, offset, |
716 | 118 | FALSE, file, line, NULL)); | 118 | FALSE, file, line, NULL)); |
717 | 119 | #endif | 119 | #endif |
718 | @@ -123,7 +123,7 @@ | |||
719 | 123 | buf_pool->stat.n_page_gets++; | 123 | buf_pool->stat.n_page_gets++; |
720 | 124 | fold = buf_page_address_fold(space, offset); | 124 | fold = buf_page_address_fold(space, offset); |
721 | 125 | loop: | 125 | loop: |
723 | 126 | @@ -2411,9 +2474,9 @@ | 126 | @@ -2413,9 +2476,9 @@ |
724 | 127 | return(NULL); | 127 | return(NULL); |
725 | 128 | } | 128 | } |
726 | 129 | 129 | ||
727 | @@ -135,7 +135,7 @@ | |||
728 | 135 | 135 | ||
729 | 136 | retries = 0; | 136 | retries = 0; |
730 | 137 | } else if (retries < BUF_PAGE_READ_MAX_RETRIES) { | 137 | } else if (retries < BUF_PAGE_READ_MAX_RETRIES) { |
732 | 138 | @@ -2723,6 +2786,13 @@ | 138 | @@ -2725,6 +2788,13 @@ |
733 | 139 | /* Let us wait until the read operation | 139 | /* Let us wait until the read operation |
734 | 140 | completes */ | 140 | completes */ |
735 | 141 | 141 | ||
736 | @@ -149,7 +149,7 @@ | |||
737 | 149 | for (;;) { | 149 | for (;;) { |
738 | 150 | enum buf_io_fix io_fix; | 150 | enum buf_io_fix io_fix; |
739 | 151 | 151 | ||
741 | 152 | @@ -2737,6 +2807,12 @@ | 152 | @@ -2739,6 +2809,12 @@ |
742 | 153 | break; | 153 | break; |
743 | 154 | } | 154 | } |
744 | 155 | } | 155 | } |
745 | @@ -162,7 +162,7 @@ | |||
746 | 162 | } | 162 | } |
747 | 163 | 163 | ||
748 | 164 | fix_type = MTR_MEMO_BUF_FIX; | 164 | fix_type = MTR_MEMO_BUF_FIX; |
750 | 165 | @@ -2763,13 +2839,17 @@ | 165 | @@ -2765,13 +2841,17 @@ |
751 | 166 | read-ahead */ | 166 | read-ahead */ |
752 | 167 | 167 | ||
753 | 168 | buf_read_ahead_linear(space, zip_size, offset, | 168 | buf_read_ahead_linear(space, zip_size, offset, |
754 | @@ -181,7 +181,7 @@ | |||
755 | 181 | return(block); | 181 | return(block); |
756 | 182 | } | 182 | } |
757 | 183 | 183 | ||
759 | 184 | @@ -2793,6 +2873,7 @@ | 184 | @@ -2795,6 +2875,7 @@ |
760 | 185 | unsigned access_time; | 185 | unsigned access_time; |
761 | 186 | ibool success; | 186 | ibool success; |
762 | 187 | ulint fix_type; | 187 | ulint fix_type; |
763 | @@ -189,7 +189,7 @@ | |||
764 | 189 | 189 | ||
765 | 190 | ut_ad(block); | 190 | ut_ad(block); |
766 | 191 | ut_ad(mtr); | 191 | ut_ad(mtr); |
768 | 192 | @@ -2870,6 +2951,10 @@ | 192 | @@ -2872,6 +2953,10 @@ |
769 | 193 | #if defined UNIV_DEBUG_FILE_ACCESSES || defined UNIV_DEBUG | 193 | #if defined UNIV_DEBUG_FILE_ACCESSES || defined UNIV_DEBUG |
770 | 194 | ut_a(block->page.file_page_was_freed == FALSE); | 194 | ut_a(block->page.file_page_was_freed == FALSE); |
771 | 195 | #endif | 195 | #endif |
772 | @@ -200,7 +200,7 @@ | |||
773 | 200 | if (UNIV_UNLIKELY(!access_time)) { | 200 | if (UNIV_UNLIKELY(!access_time)) { |
774 | 201 | /* In the case of a first access, try to apply linear | 201 | /* In the case of a first access, try to apply linear |
775 | 202 | read-ahead */ | 202 | read-ahead */ |
777 | 203 | @@ -2877,7 +2962,7 @@ | 203 | @@ -2879,7 +2964,7 @@ |
778 | 204 | buf_read_ahead_linear(buf_block_get_space(block), | 204 | buf_read_ahead_linear(buf_block_get_space(block), |
779 | 205 | buf_block_get_zip_size(block), | 205 | buf_block_get_zip_size(block), |
780 | 206 | buf_block_get_page_no(block), | 206 | buf_block_get_page_no(block), |
781 | @@ -209,7 +209,7 @@ | |||
782 | 209 | } | 209 | } |
783 | 210 | 210 | ||
784 | 211 | #ifdef UNIV_IBUF_COUNT_DEBUG | 211 | #ifdef UNIV_IBUF_COUNT_DEBUG |
786 | 212 | @@ -2887,6 +2972,9 @@ | 212 | @@ -2889,6 +2974,9 @@ |
787 | 213 | buf_pool = buf_pool_from_block(block); | 213 | buf_pool = buf_pool_from_block(block); |
788 | 214 | buf_pool->stat.n_page_gets++; | 214 | buf_pool->stat.n_page_gets++; |
789 | 215 | 215 | ||
790 | @@ -219,7 +219,7 @@ | |||
791 | 219 | return(TRUE); | 219 | return(TRUE); |
792 | 220 | } | 220 | } |
793 | 221 | 221 | ||
795 | 222 | @@ -2909,6 +2997,7 @@ | 222 | @@ -2911,6 +2999,7 @@ |
796 | 223 | buf_pool_t* buf_pool; | 223 | buf_pool_t* buf_pool; |
797 | 224 | ibool success; | 224 | ibool success; |
798 | 225 | ulint fix_type; | 225 | ulint fix_type; |
799 | @@ -227,7 +227,7 @@ | |||
800 | 227 | 227 | ||
801 | 228 | ut_ad(mtr); | 228 | ut_ad(mtr); |
802 | 229 | ut_ad(mtr->state == MTR_ACTIVE); | 229 | ut_ad(mtr->state == MTR_ACTIVE); |
804 | 230 | @@ -2995,6 +3084,11 @@ | 230 | @@ -2997,6 +3086,11 @@ |
805 | 231 | #endif | 231 | #endif |
806 | 232 | buf_pool->stat.n_page_gets++; | 232 | buf_pool->stat.n_page_gets++; |
807 | 233 | 233 | ||
808 | @@ -355,7 +355,7 @@ | |||
809 | 355 | 355 | ||
810 | 356 | --- a/storage/innobase/fil/fil0fil.c | 356 | --- a/storage/innobase/fil/fil0fil.c |
811 | 357 | +++ b/storage/innobase/fil/fil0fil.c | 357 | +++ b/storage/innobase/fil/fil0fil.c |
813 | 358 | @@ -4757,7 +4757,7 @@ | 358 | @@ -4765,7 +4765,7 @@ |
814 | 359 | node->name, node->handle, buf, | 359 | node->name, node->handle, buf, |
815 | 360 | offset_low, offset_high, | 360 | offset_low, offset_high, |
816 | 361 | page_size * n_pages, | 361 | page_size * n_pages, |
817 | @@ -364,7 +364,7 @@ | |||
818 | 364 | #endif | 364 | #endif |
819 | 365 | if (success) { | 365 | if (success) { |
820 | 366 | node->size += n_pages; | 366 | node->size += n_pages; |
822 | 367 | @@ -5084,7 +5084,7 @@ | 367 | @@ -5092,7 +5092,7 @@ |
823 | 368 | i/o on a tablespace which does not exist */ | 368 | i/o on a tablespace which does not exist */ |
824 | 369 | UNIV_INTERN | 369 | UNIV_INTERN |
825 | 370 | ulint | 370 | ulint |
826 | @@ -373,7 +373,7 @@ | |||
827 | 373 | /*===*/ | 373 | /*===*/ |
828 | 374 | ulint type, /*!< in: OS_FILE_READ or OS_FILE_WRITE, | 374 | ulint type, /*!< in: OS_FILE_READ or OS_FILE_WRITE, |
829 | 375 | ORed to OS_FILE_LOG, if a log i/o | 375 | ORed to OS_FILE_LOG, if a log i/o |
831 | 376 | @@ -5109,8 +5109,9 @@ | 376 | @@ -5117,8 +5117,9 @@ |
832 | 377 | void* buf, /*!< in/out: buffer where to store read data | 377 | void* buf, /*!< in/out: buffer where to store read data |
833 | 378 | or from where to write; in aio this must be | 378 | or from where to write; in aio this must be |
834 | 379 | appropriately aligned */ | 379 | appropriately aligned */ |
835 | @@ -384,7 +384,7 @@ | |||
836 | 384 | { | 384 | { |
837 | 385 | ulint mode; | 385 | ulint mode; |
838 | 386 | fil_space_t* space; | 386 | fil_space_t* space; |
840 | 387 | @@ -5278,7 +5279,7 @@ | 387 | @@ -5286,7 +5287,7 @@ |
841 | 388 | #else | 388 | #else |
842 | 389 | /* Queue the aio request */ | 389 | /* Queue the aio request */ |
843 | 390 | ret = os_aio(type, mode | wake_later, node->name, node->handle, buf, | 390 | ret = os_aio(type, mode | wake_later, node->name, node->handle, buf, |
844 | @@ -445,7 +445,7 @@ | |||
845 | 445 | /*********************************************************************//** | 445 | /*********************************************************************//** |
846 | 446 | Note that a transaction has been registered with MySQL. | 446 | Note that a transaction has been registered with MySQL. |
847 | 447 | @return true if transaction is registered with MySQL 2PC coordinator */ | 447 | @return true if transaction is registered with MySQL 2PC coordinator */ |
849 | 448 | @@ -9418,6 +9454,25 @@ | 448 | @@ -9417,6 +9453,25 @@ |
850 | 449 | statement has ended */ | 449 | statement has ended */ |
851 | 450 | 450 | ||
852 | 451 | if (trx->n_mysql_tables_in_use == 0) { | 451 | if (trx->n_mysql_tables_in_use == 0) { |
853 | @@ -514,7 +514,7 @@ | |||
854 | 514 | order to contract the insert buffer tree. Technically, this function is like | 514 | order to contract the insert buffer tree. Technically, this function is like |
855 | 515 | --- a/storage/innobase/include/fil0fil.h | 515 | --- a/storage/innobase/include/fil0fil.h |
856 | 516 | +++ b/storage/innobase/include/fil0fil.h | 516 | +++ b/storage/innobase/include/fil0fil.h |
858 | 517 | @@ -615,9 +615,12 @@ | 517 | @@ -620,9 +620,12 @@ |
859 | 518 | Reads or writes data. This operation is asynchronous (aio). | 518 | Reads or writes data. This operation is asynchronous (aio). |
860 | 519 | @return DB_SUCCESS, or DB_TABLESPACE_DELETED if we are trying to do | 519 | @return DB_SUCCESS, or DB_TABLESPACE_DELETED if we are trying to do |
861 | 520 | i/o on a tablespace which does not exist */ | 520 | i/o on a tablespace which does not exist */ |
862 | @@ -528,7 +528,7 @@ | |||
863 | 528 | /*===*/ | 528 | /*===*/ |
864 | 529 | ulint type, /*!< in: OS_FILE_READ or OS_FILE_WRITE, | 529 | ulint type, /*!< in: OS_FILE_READ or OS_FILE_WRITE, |
865 | 530 | ORed to OS_FILE_LOG, if a log i/o | 530 | ORed to OS_FILE_LOG, if a log i/o |
867 | 531 | @@ -642,8 +645,9 @@ | 531 | @@ -647,8 +650,9 @@ |
868 | 532 | void* buf, /*!< in/out: buffer where to store read data | 532 | void* buf, /*!< in/out: buffer where to store read data |
869 | 533 | or from where to write; in aio this must be | 533 | or from where to write; in aio this must be |
870 | 534 | appropriately aligned */ | 534 | appropriately aligned */ |
871 | @@ -887,7 +887,7 @@ | |||
872 | 887 | /* The following counter is incremented whenever there is some user activity | 887 | /* The following counter is incremented whenever there is some user activity |
873 | 888 | in the server */ | 888 | in the server */ |
874 | 889 | UNIV_INTERN ulint srv_activity_count = 0; | 889 | UNIV_INTERN ulint srv_activity_count = 0; |
876 | 890 | @@ -1234,6 +1237,10 @@ | 890 | @@ -1237,6 +1240,10 @@ |
877 | 891 | ibool has_slept = FALSE; | 891 | ibool has_slept = FALSE; |
878 | 892 | srv_conc_slot_t* slot = NULL; | 892 | srv_conc_slot_t* slot = NULL; |
879 | 893 | ulint i; | 893 | ulint i; |
880 | @@ -898,7 +898,7 @@ | |||
881 | 898 | 898 | ||
882 | 899 | #ifdef UNIV_SYNC_DEBUG | 899 | #ifdef UNIV_SYNC_DEBUG |
883 | 900 | ut_ad(!sync_thread_levels_nonempty_trx(trx->has_search_latch)); | 900 | ut_ad(!sync_thread_levels_nonempty_trx(trx->has_search_latch)); |
885 | 901 | @@ -1314,6 +1321,7 @@ | 901 | @@ -1317,6 +1324,7 @@ |
886 | 902 | switches. */ | 902 | switches. */ |
887 | 903 | if (SRV_THREAD_SLEEP_DELAY > 0) { | 903 | if (SRV_THREAD_SLEEP_DELAY > 0) { |
888 | 904 | os_thread_sleep(SRV_THREAD_SLEEP_DELAY); | 904 | os_thread_sleep(SRV_THREAD_SLEEP_DELAY); |
889 | @@ -906,7 +906,7 @@ | |||
890 | 906 | } | 906 | } |
891 | 907 | 907 | ||
892 | 908 | trx->op_info = ""; | 908 | trx->op_info = ""; |
894 | 909 | @@ -1373,6 +1381,14 @@ | 909 | @@ -1376,6 +1384,14 @@ |
895 | 910 | #ifdef UNIV_SYNC_DEBUG | 910 | #ifdef UNIV_SYNC_DEBUG |
896 | 911 | ut_ad(!sync_thread_levels_nonempty_trx(trx->has_search_latch)); | 911 | ut_ad(!sync_thread_levels_nonempty_trx(trx->has_search_latch)); |
897 | 912 | #endif /* UNIV_SYNC_DEBUG */ | 912 | #endif /* UNIV_SYNC_DEBUG */ |
898 | @@ -921,7 +921,7 @@ | |||
899 | 921 | trx->op_info = "waiting in InnoDB queue"; | 921 | trx->op_info = "waiting in InnoDB queue"; |
900 | 922 | 922 | ||
901 | 923 | thd_wait_begin(trx->mysql_thd, THD_WAIT_USER_LOCK); | 923 | thd_wait_begin(trx->mysql_thd, THD_WAIT_USER_LOCK); |
903 | 924 | @@ -1381,6 +1397,12 @@ | 924 | @@ -1384,6 +1400,12 @@ |
904 | 925 | 925 | ||
905 | 926 | trx->op_info = ""; | 926 | trx->op_info = ""; |
906 | 927 | 927 | ||
907 | 928 | 928 | ||
908 | === modified file 'patches/innodb_extra_rseg.patch' | |||
909 | --- patches/innodb_extra_rseg.patch 2011-12-27 15:32:16 +0000 | |||
910 | +++ patches/innodb_extra_rseg.patch 2012-02-06 05:02:26 +0000 | |||
911 | @@ -7,7 +7,7 @@ | |||
912 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
913 | 8 | --- a/storage/innobase/handler/ha_innodb.cc | 8 | --- a/storage/innobase/handler/ha_innodb.cc |
914 | 9 | +++ b/storage/innobase/handler/ha_innodb.cc | 9 | +++ b/storage/innobase/handler/ha_innodb.cc |
916 | 10 | @@ -11664,6 +11664,7 @@ | 10 | @@ -11706,6 +11706,7 @@ |
917 | 11 | NULL, /* reserved */ | 11 | NULL, /* reserved */ |
918 | 12 | 0, /* flags */ | 12 | 0, /* flags */ |
919 | 13 | }, | 13 | }, |
920 | 14 | 14 | ||
921 | === modified file 'patches/innodb_fake_changes.patch' | |||
922 | --- patches/innodb_fake_changes.patch 2011-12-27 15:32:16 +0000 | |||
923 | +++ patches/innodb_fake_changes.patch 2012-02-06 05:02:26 +0000 | |||
924 | @@ -214,7 +214,7 @@ | |||
925 | 214 | /* Transaction is deregistered only in a commit or a rollback. If | 214 | /* Transaction is deregistered only in a commit or a rollback. If |
926 | 215 | it is deregistered we know there cannot be resources to be freed | 215 | it is deregistered we know there cannot be resources to be freed |
927 | 216 | and we could return immediately. For the time being, we play safe | 216 | and we could return immediately. For the time being, we play safe |
929 | 217 | @@ -7544,6 +7557,12 @@ | 217 | @@ -7543,6 +7556,12 @@ |
930 | 218 | 218 | ||
931 | 219 | trx = innobase_trx_allocate(thd); | 219 | trx = innobase_trx_allocate(thd); |
932 | 220 | 220 | ||
933 | @@ -227,7 +227,7 @@ | |||
934 | 227 | /* Latch the InnoDB data dictionary exclusively so that no deadlocks | 227 | /* Latch the InnoDB data dictionary exclusively so that no deadlocks |
935 | 228 | or lock waits can happen in it during a table create operation. | 228 | or lock waits can happen in it during a table create operation. |
936 | 229 | Drop table etc. do this latching in row0mysql.c. */ | 229 | Drop table etc. do this latching in row0mysql.c. */ |
938 | 230 | @@ -7764,6 +7783,10 @@ | 230 | @@ -7763,6 +7782,10 @@ |
939 | 231 | DBUG_RETURN(HA_ERR_CRASHED); | 231 | DBUG_RETURN(HA_ERR_CRASHED); |
940 | 232 | } | 232 | } |
941 | 233 | 233 | ||
942 | @@ -238,7 +238,7 @@ | |||
943 | 238 | /* Truncate the table in InnoDB */ | 238 | /* Truncate the table in InnoDB */ |
944 | 239 | 239 | ||
945 | 240 | error = row_truncate_table_for_mysql(prebuilt->table, prebuilt->trx); | 240 | error = row_truncate_table_for_mysql(prebuilt->table, prebuilt->trx); |
947 | 241 | @@ -7820,6 +7843,12 @@ | 241 | @@ -7819,6 +7842,12 @@ |
948 | 242 | 242 | ||
949 | 243 | trx = innobase_trx_allocate(thd); | 243 | trx = innobase_trx_allocate(thd); |
950 | 244 | 244 | ||
951 | @@ -251,7 +251,7 @@ | |||
952 | 251 | name_len = strlen(name); | 251 | name_len = strlen(name); |
953 | 252 | 252 | ||
954 | 253 | ut_a(name_len < 1000); | 253 | ut_a(name_len < 1000); |
956 | 254 | @@ -7906,6 +7935,12 @@ | 254 | @@ -7905,6 +7934,12 @@ |
957 | 255 | trx->mysql_thd = NULL; | 255 | trx->mysql_thd = NULL; |
958 | 256 | #else | 256 | #else |
959 | 257 | trx = innobase_trx_allocate(thd); | 257 | trx = innobase_trx_allocate(thd); |
960 | @@ -264,7 +264,7 @@ | |||
961 | 264 | #endif | 264 | #endif |
962 | 265 | row_drop_database_for_mysql(namebuf, trx); | 265 | row_drop_database_for_mysql(namebuf, trx); |
963 | 266 | my_free(namebuf); | 266 | my_free(namebuf); |
965 | 267 | @@ -8011,6 +8046,11 @@ | 267 | @@ -8010,6 +8045,11 @@ |
966 | 268 | trx_search_latch_release_if_reserved(parent_trx); | 268 | trx_search_latch_release_if_reserved(parent_trx); |
967 | 269 | 269 | ||
968 | 270 | trx = innobase_trx_allocate(thd); | 270 | trx = innobase_trx_allocate(thd); |
969 | @@ -276,7 +276,7 @@ | |||
970 | 276 | 276 | ||
971 | 277 | error = innobase_rename_table(trx, from, to, TRUE); | 277 | error = innobase_rename_table(trx, from, to, TRUE); |
972 | 278 | 278 | ||
974 | 279 | @@ -10881,6 +10921,10 @@ | 279 | @@ -10880,6 +10920,10 @@ |
975 | 280 | return(0); | 280 | return(0); |
976 | 281 | } | 281 | } |
977 | 282 | 282 | ||
978 | @@ -287,8 +287,8 @@ | |||
979 | 287 | thd_get_xid(thd, (MYSQL_XID*) &trx->xid); | 287 | thd_get_xid(thd, (MYSQL_XID*) &trx->xid); |
980 | 288 | 288 | ||
981 | 289 | /* Release a possible FIFO ticket and search latch. Since we will | 289 | /* Release a possible FIFO ticket and search latch. Since we will |
984 | 290 | @@ -12438,6 +12482,7 @@ | 290 | @@ -12480,6 +12524,7 @@ |
985 | 291 | MYSQL_SYSVAR(rollback_segments), | 291 | #endif |
986 | 292 | MYSQL_SYSVAR(corrupt_table_action), | 292 | MYSQL_SYSVAR(corrupt_table_action), |
987 | 293 | MYSQL_SYSVAR(lazy_drop_table), | 293 | MYSQL_SYSVAR(lazy_drop_table), |
988 | 294 | + MYSQL_SYSVAR(fake_changes), | 294 | + MYSQL_SYSVAR(fake_changes), |
989 | 295 | 295 | ||
990 | === modified file 'patches/innodb_fast_checksum.patch' | |||
991 | --- patches/innodb_fast_checksum.patch 2011-12-27 15:32:16 +0000 | |||
992 | +++ patches/innodb_fast_checksum.patch 2012-02-06 05:02:26 +0000 | |||
993 | @@ -106,7 +106,7 @@ | |||
994 | 106 | /* We overwrite the first 4 bytes of the end lsn field to store | 106 | /* We overwrite the first 4 bytes of the end lsn field to store |
995 | 107 | --- a/storage/innobase/fil/fil0fil.c | 107 | --- a/storage/innobase/fil/fil0fil.c |
996 | 108 | +++ b/storage/innobase/fil/fil0fil.c | 108 | +++ b/storage/innobase/fil/fil0fil.c |
998 | 109 | @@ -3095,13 +3095,24 @@ | 109 | @@ -3103,13 +3103,24 @@ |
999 | 110 | return(TRUE); | 110 | return(TRUE); |
1000 | 111 | } | 111 | } |
1001 | 112 | 112 | ||
1002 | @@ -132,7 +132,7 @@ | |||
1003 | 132 | return(FALSE); | 132 | return(FALSE); |
1004 | 133 | } | 133 | } |
1005 | 134 | 134 | ||
1007 | 135 | @@ -3117,7 +3128,9 @@ | 135 | @@ -3125,7 +3136,9 @@ |
1008 | 136 | if (!zip_size) { | 136 | if (!zip_size) { |
1009 | 137 | mach_write_to_4(page + FIL_PAGE_SPACE_OR_CHKSUM, | 137 | mach_write_to_4(page + FIL_PAGE_SPACE_OR_CHKSUM, |
1010 | 138 | srv_use_checksums | 138 | srv_use_checksums |
1011 | @@ -161,7 +161,7 @@ | |||
1012 | 161 | 161 | ||
1013 | 162 | srv_blocking_lru_restore = (ibool) innobase_blocking_lru_restore; | 162 | srv_blocking_lru_restore = (ibool) innobase_blocking_lru_restore; |
1014 | 163 | 163 | ||
1016 | 164 | @@ -11542,6 +11544,15 @@ | 164 | @@ -11541,6 +11543,15 @@ |
1017 | 165 | "Disable with --skip-innodb-checksums.", | 165 | "Disable with --skip-innodb-checksums.", |
1018 | 166 | NULL, NULL, TRUE); | 166 | NULL, NULL, TRUE); |
1019 | 167 | 167 | ||
1020 | @@ -177,7 +177,7 @@ | |||
1021 | 177 | static MYSQL_SYSVAR_STR(data_home_dir, innobase_data_home_dir, | 177 | static MYSQL_SYSVAR_STR(data_home_dir, innobase_data_home_dir, |
1022 | 178 | PLUGIN_VAR_READONLY, | 178 | PLUGIN_VAR_READONLY, |
1023 | 179 | "The common part for InnoDB table spaces.", | 179 | "The common part for InnoDB table spaces.", |
1025 | 180 | @@ -12073,6 +12084,7 @@ | 180 | @@ -12112,6 +12123,7 @@ |
1026 | 181 | MYSQL_SYSVAR(buffer_pool_size), | 181 | MYSQL_SYSVAR(buffer_pool_size), |
1027 | 182 | MYSQL_SYSVAR(buffer_pool_instances), | 182 | MYSQL_SYSVAR(buffer_pool_instances), |
1028 | 183 | MYSQL_SYSVAR(checksums), | 183 | MYSQL_SYSVAR(checksums), |
1029 | 184 | 184 | ||
1030 | === modified file 'patches/innodb_files_extend.patch' | |||
1031 | --- patches/innodb_files_extend.patch 2011-12-27 15:32:16 +0000 | |||
1032 | +++ patches/innodb_files_extend.patch 2012-02-06 05:02:26 +0000 | |||
1033 | @@ -16,7 +16,7 @@ | |||
1034 | 16 | fprintf(stderr, | 16 | fprintf(stderr, |
1035 | 17 | "InnoDB: Error: the size of single-table" | 17 | "InnoDB: Error: the size of single-table" |
1036 | 18 | " tablespace file %s\n" | 18 | " tablespace file %s\n" |
1038 | 19 | @@ -4161,7 +4161,7 @@ | 19 | @@ -4169,7 +4169,7 @@ |
1039 | 20 | 20 | ||
1040 | 21 | size = (((ib_int64_t)size_high) << 32) + (ib_int64_t)size_low; | 21 | size = (((ib_int64_t)size_high) << 32) + (ib_int64_t)size_low; |
1041 | 22 | #ifndef UNIV_HOTBACKUP | 22 | #ifndef UNIV_HOTBACKUP |
1042 | @@ -25,7 +25,7 @@ | |||
1043 | 25 | fprintf(stderr, | 25 | fprintf(stderr, |
1044 | 26 | "InnoDB: Error: the size of single-table tablespace" | 26 | "InnoDB: Error: the size of single-table tablespace" |
1045 | 27 | " file %s\n" | 27 | " file %s\n" |
1047 | 28 | @@ -4181,7 +4181,7 @@ | 28 | @@ -4189,7 +4189,7 @@ |
1048 | 29 | /* Align the memory for file i/o if we might have O_DIRECT set */ | 29 | /* Align the memory for file i/o if we might have O_DIRECT set */ |
1049 | 30 | page = ut_align(buf2, UNIV_PAGE_SIZE); | 30 | page = ut_align(buf2, UNIV_PAGE_SIZE); |
1050 | 31 | 31 | ||
1051 | @@ -34,7 +34,7 @@ | |||
1052 | 34 | success = os_file_read(file, page, 0, 0, UNIV_PAGE_SIZE); | 34 | success = os_file_read(file, page, 0, 0, UNIV_PAGE_SIZE); |
1053 | 35 | 35 | ||
1054 | 36 | /* We have to read the tablespace id from the file */ | 36 | /* We have to read the tablespace id from the file */ |
1056 | 37 | @@ -5159,9 +5159,9 @@ | 37 | @@ -5167,9 +5167,9 @@ |
1057 | 38 | ut_ad(ut_is_2pow(zip_size)); | 38 | ut_ad(ut_is_2pow(zip_size)); |
1058 | 39 | ut_ad(buf); | 39 | ut_ad(buf); |
1059 | 40 | ut_ad(len > 0); | 40 | ut_ad(len > 0); |
1060 | @@ -49,7 +49,7 @@ | |||
1061 | 49 | # ifndef UNIV_LOG_DEBUG | 49 | # ifndef UNIV_LOG_DEBUG |
1062 | 50 | --- a/storage/innobase/fsp/fsp0fsp.c | 50 | --- a/storage/innobase/fsp/fsp0fsp.c |
1063 | 51 | +++ b/storage/innobase/fsp/fsp0fsp.c | 51 | +++ b/storage/innobase/fsp/fsp0fsp.c |
1065 | 52 | @@ -656,16 +656,18 @@ | 52 | @@ -595,16 +595,18 @@ |
1066 | 53 | 0 for uncompressed pages */ | 53 | 0 for uncompressed pages */ |
1067 | 54 | ulint offset) /*!< in: page offset */ | 54 | ulint offset) /*!< in: page offset */ |
1068 | 55 | { | 55 | { |
1069 | @@ -78,7 +78,7 @@ | |||
1070 | 78 | ut_ad(ut_is_2pow(zip_size)); | 78 | ut_ad(ut_is_2pow(zip_size)); |
1071 | 79 | 79 | ||
1072 | 80 | if (!zip_size) { | 80 | if (!zip_size) { |
1074 | 81 | @@ -1464,12 +1466,12 @@ | 81 | @@ -1403,12 +1405,12 @@ |
1075 | 82 | mtr); | 82 | mtr); |
1076 | 83 | xdes_init(descr, mtr); | 83 | xdes_init(descr, mtr); |
1077 | 84 | 84 | ||
1078 | @@ -175,7 +175,7 @@ | |||
1079 | 175 | #ifndef MYSQL_SERVER | 175 | #ifndef MYSQL_SERVER |
1080 | 176 | innodb_overwrite_relay_log_info = FALSE; | 176 | innodb_overwrite_relay_log_info = FALSE; |
1081 | 177 | #endif | 177 | #endif |
1083 | 178 | @@ -7290,9 +7352,9 @@ | 178 | @@ -7289,9 +7351,9 @@ |
1084 | 179 | | DICT_TF_COMPACT | 179 | | DICT_TF_COMPACT |
1085 | 180 | | DICT_TF_FORMAT_ZIP | 180 | | DICT_TF_FORMAT_ZIP |
1086 | 181 | << DICT_TF_FORMAT_SHIFT; | 181 | << DICT_TF_FORMAT_SHIFT; |
1087 | @@ -188,7 +188,7 @@ | |||
1088 | 188 | } | 188 | } |
1089 | 189 | } | 189 | } |
1090 | 190 | 190 | ||
1092 | 191 | @@ -11553,6 +11615,16 @@ | 191 | @@ -11552,6 +11614,16 @@ |
1093 | 192 | "#### Attention: The checksum is not compatible for normal or disabled version! ####", | 192 | "#### Attention: The checksum is not compatible for normal or disabled version! ####", |
1094 | 193 | NULL, NULL, FALSE); | 193 | NULL, NULL, FALSE); |
1095 | 194 | 194 | ||
1096 | @@ -205,7 +205,7 @@ | |||
1097 | 205 | static MYSQL_SYSVAR_STR(data_home_dir, innobase_data_home_dir, | 205 | static MYSQL_SYSVAR_STR(data_home_dir, innobase_data_home_dir, |
1098 | 206 | PLUGIN_VAR_READONLY, | 206 | PLUGIN_VAR_READONLY, |
1099 | 207 | "The common part for InnoDB table spaces.", | 207 | "The common part for InnoDB table spaces.", |
1101 | 208 | @@ -12079,6 +12151,8 @@ | 208 | @@ -12118,6 +12190,8 @@ |
1102 | 209 | NULL, NULL, 0, &corrupt_table_action_typelib); | 209 | NULL, NULL, 0, &corrupt_table_action_typelib); |
1103 | 210 | 210 | ||
1104 | 211 | static struct st_mysql_sys_var* innobase_system_variables[]= { | 211 | static struct st_mysql_sys_var* innobase_system_variables[]= { |
1105 | @@ -216,7 +216,7 @@ | |||
1106 | 216 | MYSQL_SYSVAR(buffer_pool_size), | 216 | MYSQL_SYSVAR(buffer_pool_size), |
1107 | 217 | --- a/storage/innobase/include/buf0buf.h | 217 | --- a/storage/innobase/include/buf0buf.h |
1108 | 218 | +++ b/storage/innobase/include/buf0buf.h | 218 | +++ b/storage/innobase/include/buf0buf.h |
1110 | 219 | @@ -1705,7 +1705,7 @@ | 219 | @@ -1725,7 +1725,7 @@ |
1111 | 220 | time_t last_printout_time; | 220 | time_t last_printout_time; |
1112 | 221 | /*!< when buf_print_io was last time | 221 | /*!< when buf_print_io was last time |
1113 | 222 | called */ | 222 | called */ |
1114 | @@ -225,7 +225,7 @@ | |||
1115 | 225 | /*!< Statistics of buddy system, | 225 | /*!< Statistics of buddy system, |
1116 | 226 | indexed by block size */ | 226 | indexed by block size */ |
1117 | 227 | buf_pool_stat_t stat; /*!< current statistics */ | 227 | buf_pool_stat_t stat; /*!< current statistics */ |
1119 | 228 | @@ -1803,7 +1803,7 @@ | 228 | @@ -1823,7 +1823,7 @@ |
1120 | 229 | UT_LIST_BASE_NODE_T(buf_page_t) zip_clean; | 229 | UT_LIST_BASE_NODE_T(buf_page_t) zip_clean; |
1121 | 230 | /*!< unmodified compressed pages */ | 230 | /*!< unmodified compressed pages */ |
1122 | 231 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ | 231 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ |
1123 | @@ -234,7 +234,7 @@ | |||
1124 | 234 | /*!< buddy free lists */ | 234 | /*!< buddy free lists */ |
1125 | 235 | 235 | ||
1126 | 236 | buf_page_t watch[BUF_POOL_WATCH_SIZE]; | 236 | buf_page_t watch[BUF_POOL_WATCH_SIZE]; |
1128 | 237 | @@ -1811,9 +1811,9 @@ | 237 | @@ -1831,9 +1831,9 @@ |
1129 | 238 | pool watches. Protected by | 238 | pool watches. Protected by |
1130 | 239 | buf_pool->mutex. */ | 239 | buf_pool->mutex. */ |
1131 | 240 | 240 | ||
1132 | @@ -249,7 +249,7 @@ | |||
1133 | 249 | #endif | 249 | #endif |
1134 | 250 | --- a/storage/innobase/include/buf0types.h | 250 | --- a/storage/innobase/include/buf0types.h |
1135 | 251 | +++ b/storage/innobase/include/buf0types.h | 251 | +++ b/storage/innobase/include/buf0types.h |
1137 | 252 | @@ -67,12 +67,13 @@ | 252 | @@ -70,12 +70,13 @@ |
1138 | 253 | #define BUF_BUDDY_LOW (1 << BUF_BUDDY_LOW_SHIFT) | 253 | #define BUF_BUDDY_LOW (1 << BUF_BUDDY_LOW_SHIFT) |
1139 | 254 | 254 | ||
1140 | 255 | #define BUF_BUDDY_SIZES (UNIV_PAGE_SIZE_SHIFT - BUF_BUDDY_LOW_SHIFT) | 255 | #define BUF_BUDDY_SIZES (UNIV_PAGE_SIZE_SHIFT - BUF_BUDDY_LOW_SHIFT) |
1141 | @@ -412,7 +412,7 @@ | |||
1142 | 412 | dest_offset = nth_file * group->file_size; | 412 | dest_offset = nth_file * group->file_size; |
1143 | 413 | 413 | ||
1144 | 414 | #ifdef UNIV_DEBUG | 414 | #ifdef UNIV_DEBUG |
1146 | 415 | @@ -1794,9 +1799,7 @@ | 415 | @@ -1797,9 +1802,7 @@ |
1147 | 416 | ulint i; | 416 | ulint i; |
1148 | 417 | 417 | ||
1149 | 418 | ut_ad(mutex_own(&(log_sys->mutex))); | 418 | ut_ad(mutex_own(&(log_sys->mutex))); |
1150 | @@ -423,7 +423,7 @@ | |||
1151 | 423 | 423 | ||
1152 | 424 | buf = group->checkpoint_buf; | 424 | buf = group->checkpoint_buf; |
1153 | 425 | 425 | ||
1155 | 426 | @@ -1810,6 +1813,7 @@ | 426 | @@ -1813,6 +1816,7 @@ |
1156 | 427 | mach_write_to_4(buf + LOG_CHECKPOINT_LOG_BUF_SIZE, log_sys->buf_size); | 427 | mach_write_to_4(buf + LOG_CHECKPOINT_LOG_BUF_SIZE, log_sys->buf_size); |
1157 | 428 | 428 | ||
1158 | 429 | #ifdef UNIV_LOG_ARCHIVE | 429 | #ifdef UNIV_LOG_ARCHIVE |
1159 | @@ -431,7 +431,7 @@ | |||
1160 | 431 | if (log_sys->archiving_state == LOG_ARCH_OFF) { | 431 | if (log_sys->archiving_state == LOG_ARCH_OFF) { |
1161 | 432 | archived_lsn = IB_ULONGLONG_MAX; | 432 | archived_lsn = IB_ULONGLONG_MAX; |
1162 | 433 | } else { | 433 | } else { |
1164 | 434 | @@ -1823,7 +1827,9 @@ | 434 | @@ -1826,7 +1830,9 @@ |
1165 | 435 | 435 | ||
1166 | 436 | mach_write_to_8(buf + LOG_CHECKPOINT_ARCHIVED_LSN, archived_lsn); | 436 | mach_write_to_8(buf + LOG_CHECKPOINT_ARCHIVED_LSN, archived_lsn); |
1167 | 437 | #else /* UNIV_LOG_ARCHIVE */ | 437 | #else /* UNIV_LOG_ARCHIVE */ |
1168 | @@ -538,7 +538,7 @@ | |||
1169 | 538 | readahead request. */ | 538 | readahead request. */ |
1170 | 539 | --- a/storage/innobase/srv/srv0start.c | 539 | --- a/storage/innobase/srv/srv0start.c |
1171 | 540 | +++ b/storage/innobase/srv/srv0start.c | 540 | +++ b/storage/innobase/srv/srv0start.c |
1173 | 541 | @@ -1562,11 +1562,13 @@ | 541 | @@ -1582,11 +1582,13 @@ |
1174 | 542 | } | 542 | } |
1175 | 543 | #endif /* UNIV_LOG_ARCHIVE */ | 543 | #endif /* UNIV_LOG_ARCHIVE */ |
1176 | 544 | 544 | ||
1177 | @@ -554,7 +554,7 @@ | |||
1178 | 554 | 554 | ||
1179 | 555 | return(DB_ERROR); | 555 | return(DB_ERROR); |
1180 | 556 | } | 556 | } |
1182 | 557 | @@ -1575,7 +1577,7 @@ | 557 | @@ -1595,7 +1597,7 @@ |
1183 | 558 | 558 | ||
1184 | 559 | for (i = 0; i < srv_n_data_files; i++) { | 559 | for (i = 0; i < srv_n_data_files; i++) { |
1185 | 560 | #ifndef __WIN__ | 560 | #ifndef __WIN__ |
1186 | 561 | 561 | ||
1187 | === modified file 'patches/innodb_fix_misc.patch' | |||
1188 | --- patches/innodb_fix_misc.patch 2011-12-27 15:32:16 +0000 | |||
1189 | +++ patches/innodb_fix_misc.patch 2012-02-06 05:02:26 +0000 | |||
1190 | @@ -12,7 +12,7 @@ | |||
1191 | 12 | # should be done or reviewed by the maintainer! | 12 | # should be done or reviewed by the maintainer! |
1192 | 13 | --- a/storage/innobase/buf/buf0buf.c | 13 | --- a/storage/innobase/buf/buf0buf.c |
1193 | 14 | +++ b/storage/innobase/buf/buf0buf.c | 14 | +++ b/storage/innobase/buf/buf0buf.c |
1195 | 15 | @@ -1979,6 +1979,27 @@ | 15 | @@ -1981,6 +1981,27 @@ |
1196 | 16 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ | 16 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ |
1197 | 17 | } | 17 | } |
1198 | 18 | 18 | ||
1199 | @@ -40,7 +40,7 @@ | |||
1200 | 40 | if (UNIV_UNLIKELY(!bpage->zip.data)) { | 40 | if (UNIV_UNLIKELY(!bpage->zip.data)) { |
1201 | 41 | /* There is no compressed page. */ | 41 | /* There is no compressed page. */ |
1202 | 42 | err_exit: | 42 | err_exit: |
1204 | 43 | @@ -2487,6 +2508,27 @@ | 43 | @@ -2489,6 +2510,27 @@ |
1205 | 44 | block = (buf_block_t*) buf_page_hash_get_low( | 44 | block = (buf_block_t*) buf_page_hash_get_low( |
1206 | 45 | buf_pool, space, offset, fold); | 45 | buf_pool, space, offset, fold); |
1207 | 46 | if (block) { | 46 | if (block) { |
1208 | @@ -68,7 +68,7 @@ | |||
1209 | 68 | block_mutex = buf_page_get_mutex_enter((buf_page_t*)block); | 68 | block_mutex = buf_page_get_mutex_enter((buf_page_t*)block); |
1210 | 69 | ut_a(block_mutex); | 69 | ut_a(block_mutex); |
1211 | 70 | } | 70 | } |
1213 | 71 | @@ -3409,11 +3451,28 @@ | 71 | @@ -3411,11 +3453,28 @@ |
1214 | 72 | 72 | ||
1215 | 73 | fold = buf_page_address_fold(space, offset); | 73 | fold = buf_page_address_fold(space, offset); |
1216 | 74 | 74 | ||
1217 | @@ -97,7 +97,7 @@ | |||
1218 | 97 | if (watch_page && !buf_pool_watch_is_sentinel(buf_pool, watch_page)) { | 97 | if (watch_page && !buf_pool_watch_is_sentinel(buf_pool, watch_page)) { |
1219 | 98 | /* The page is already in the buffer pool. */ | 98 | /* The page is already in the buffer pool. */ |
1220 | 99 | watch_page = NULL; | 99 | watch_page = NULL; |
1222 | 100 | @@ -3544,6 +3603,7 @@ | 100 | @@ -3546,6 +3605,7 @@ |
1223 | 101 | bpage->state = BUF_BLOCK_ZIP_PAGE; | 101 | bpage->state = BUF_BLOCK_ZIP_PAGE; |
1224 | 102 | bpage->space = space; | 102 | bpage->space = space; |
1225 | 103 | bpage->offset = offset; | 103 | bpage->offset = offset; |
1226 | @@ -105,7 +105,7 @@ | |||
1227 | 105 | 105 | ||
1228 | 106 | #ifdef UNIV_DEBUG | 106 | #ifdef UNIV_DEBUG |
1229 | 107 | bpage->in_page_hash = FALSE; | 107 | bpage->in_page_hash = FALSE; |
1231 | 108 | @@ -3628,6 +3688,7 @@ | 108 | @@ -3630,6 +3690,7 @@ |
1232 | 109 | 109 | ||
1233 | 110 | fold = buf_page_address_fold(space, offset); | 110 | fold = buf_page_address_fold(space, offset); |
1234 | 111 | 111 | ||
1235 | @@ -113,7 +113,7 @@ | |||
1236 | 113 | //buf_pool_mutex_enter(buf_pool); | 113 | //buf_pool_mutex_enter(buf_pool); |
1237 | 114 | mutex_enter(&buf_pool->LRU_list_mutex); | 114 | mutex_enter(&buf_pool->LRU_list_mutex); |
1238 | 115 | rw_lock_x_lock(&buf_pool->page_hash_latch); | 115 | rw_lock_x_lock(&buf_pool->page_hash_latch); |
1240 | 116 | @@ -3635,6 +3696,21 @@ | 116 | @@ -3637,6 +3698,21 @@ |
1241 | 117 | block = (buf_block_t*) buf_page_hash_get_low( | 117 | block = (buf_block_t*) buf_page_hash_get_low( |
1242 | 118 | buf_pool, space, offset, fold); | 118 | buf_pool, space, offset, fold); |
1243 | 119 | 119 | ||
1244 | @@ -135,7 +135,7 @@ | |||
1245 | 135 | if (block | 135 | if (block |
1246 | 136 | && buf_page_in_file(&block->page) | 136 | && buf_page_in_file(&block->page) |
1247 | 137 | && !buf_pool_watch_is_sentinel(buf_pool, &block->page)) { | 137 | && !buf_pool_watch_is_sentinel(buf_pool, &block->page)) { |
1249 | 138 | @@ -3988,8 +4064,11 @@ | 138 | @@ -3990,8 +4066,11 @@ |
1250 | 139 | } | 139 | } |
1251 | 140 | 140 | ||
1252 | 141 | if (io_type == BUF_IO_WRITE | 141 | if (io_type == BUF_IO_WRITE |
1253 | @@ -176,7 +176,7 @@ | |||
1254 | 176 | return(TRUE); | 176 | return(TRUE); |
1255 | 177 | --- a/storage/innobase/buf/buf0lru.c | 177 | --- a/storage/innobase/buf/buf0lru.c |
1256 | 178 | +++ b/storage/innobase/buf/buf0lru.c | 178 | +++ b/storage/innobase/buf/buf0lru.c |
1258 | 179 | @@ -529,6 +529,62 @@ | 179 | @@ -545,6 +545,62 @@ |
1259 | 180 | } | 180 | } |
1260 | 181 | } | 181 | } |
1261 | 182 | 182 | ||
1262 | @@ -239,7 +239,7 @@ | |||
1263 | 239 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 239 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
1264 | 240 | /********************************************************************//** | 240 | /********************************************************************//** |
1265 | 241 | Insert a compressed block into buf_pool->zip_clean in the LRU order. */ | 241 | Insert a compressed block into buf_pool->zip_clean in the LRU order. */ |
1267 | 242 | @@ -1483,6 +1539,10 @@ | 242 | @@ -1499,6 +1555,10 @@ |
1268 | 243 | return(FALSE); | 243 | return(FALSE); |
1269 | 244 | } | 244 | } |
1270 | 245 | 245 | ||
1271 | @@ -296,7 +296,7 @@ | |||
1272 | 296 | 296 | ||
1273 | 297 | fil_system->spaces = hash_create(hash_size); | 297 | fil_system->spaces = hash_create(hash_size); |
1274 | 298 | fil_system->name_hash = hash_create(hash_size); | 298 | fil_system->name_hash = hash_create(hash_size); |
1276 | 299 | @@ -2344,7 +2347,11 @@ | 299 | @@ -2352,7 +2355,11 @@ |
1277 | 300 | completely and permanently. The flag is_being_deleted also prevents | 300 | completely and permanently. The flag is_being_deleted also prevents |
1278 | 301 | fil_flush() from being applied to this tablespace. */ | 301 | fil_flush() from being applied to this tablespace. */ |
1279 | 302 | 302 | ||
1280 | @@ -308,7 +308,7 @@ | |||
1281 | 308 | #endif | 308 | #endif |
1282 | 309 | /* printf("Deleting tablespace %s id %lu\n", space->name, id); */ | 309 | /* printf("Deleting tablespace %s id %lu\n", space->name, id); */ |
1283 | 310 | 310 | ||
1285 | 311 | @@ -4731,6 +4738,10 @@ | 311 | @@ -4739,6 +4746,10 @@ |
1286 | 312 | ulint page_size; | 312 | ulint page_size; |
1287 | 313 | ibool success = TRUE; | 313 | ibool success = TRUE; |
1288 | 314 | 314 | ||
1289 | @@ -319,7 +319,7 @@ | |||
1290 | 319 | fil_mutex_enter_and_prepare_for_io(space_id); | 319 | fil_mutex_enter_and_prepare_for_io(space_id); |
1291 | 320 | 320 | ||
1292 | 321 | space = fil_space_get_by_id(space_id); | 321 | space = fil_space_get_by_id(space_id); |
1294 | 322 | @@ -4742,6 +4753,7 @@ | 322 | @@ -4750,6 +4761,7 @@ |
1295 | 323 | *actual_size = space->size; | 323 | *actual_size = space->size; |
1296 | 324 | 324 | ||
1297 | 325 | mutex_exit(&fil_system->mutex); | 325 | mutex_exit(&fil_system->mutex); |
1298 | @@ -327,7 +327,7 @@ | |||
1299 | 327 | 327 | ||
1300 | 328 | return(TRUE); | 328 | return(TRUE); |
1301 | 329 | } | 329 | } |
1303 | 330 | @@ -4774,6 +4786,8 @@ | 330 | @@ -4782,6 +4794,8 @@ |
1304 | 331 | offset_low = ((start_page_no - file_start_page_no) | 331 | offset_low = ((start_page_no - file_start_page_no) |
1305 | 332 | % (4096 * ((1024 * 1024) / page_size))) | 332 | % (4096 * ((1024 * 1024) / page_size))) |
1306 | 333 | * page_size; | 333 | * page_size; |
1307 | @@ -336,7 +336,7 @@ | |||
1308 | 336 | #ifdef UNIV_HOTBACKUP | 336 | #ifdef UNIV_HOTBACKUP |
1309 | 337 | success = os_file_write(node->name, node->handle, buf, | 337 | success = os_file_write(node->name, node->handle, buf, |
1310 | 338 | offset_low, offset_high, | 338 | offset_low, offset_high, |
1312 | 339 | @@ -4783,8 +4797,10 @@ | 339 | @@ -4791,8 +4805,10 @@ |
1313 | 340 | node->name, node->handle, buf, | 340 | node->name, node->handle, buf, |
1314 | 341 | offset_low, offset_high, | 341 | offset_low, offset_high, |
1315 | 342 | page_size * n_pages, | 342 | page_size * n_pages, |
1316 | @@ -348,7 +348,7 @@ | |||
1317 | 348 | if (success) { | 348 | if (success) { |
1318 | 349 | node->size += n_pages; | 349 | node->size += n_pages; |
1319 | 350 | space->size += n_pages; | 350 | space->size += n_pages; |
1321 | 351 | @@ -4830,6 +4846,7 @@ | 351 | @@ -4838,6 +4854,7 @@ |
1322 | 352 | printf("Extended %s to %lu, actual size %lu pages\n", space->name, | 352 | printf("Extended %s to %lu, actual size %lu pages\n", space->name, |
1323 | 353 | size_after_extend, *actual_size); */ | 353 | size_after_extend, *actual_size); */ |
1324 | 354 | mutex_exit(&fil_system->mutex); | 354 | mutex_exit(&fil_system->mutex); |
1325 | @@ -356,7 +356,7 @@ | |||
1326 | 356 | 356 | ||
1327 | 357 | fil_flush(space_id, TRUE); | 357 | fil_flush(space_id, TRUE); |
1328 | 358 | 358 | ||
1330 | 359 | @@ -5192,6 +5209,22 @@ | 359 | @@ -5200,6 +5217,22 @@ |
1331 | 360 | srv_data_written+= len; | 360 | srv_data_written+= len; |
1332 | 361 | } | 361 | } |
1333 | 362 | 362 | ||
1334 | @@ -379,7 +379,7 @@ | |||
1335 | 379 | /* Reserve the fil_system mutex and make sure that we can open at | 379 | /* Reserve the fil_system mutex and make sure that we can open at |
1336 | 380 | least one file while holding it, if the file is not already open */ | 380 | least one file while holding it, if the file is not already open */ |
1337 | 381 | 381 | ||
1339 | 382 | @@ -5333,10 +5366,24 @@ | 382 | @@ -5341,10 +5374,24 @@ |
1340 | 383 | #else | 383 | #else |
1341 | 384 | /* Queue the aio request */ | 384 | /* Queue the aio request */ |
1342 | 385 | ret = os_aio(type, mode | wake_later, node->name, node->handle, buf, | 385 | ret = os_aio(type, mode | wake_later, node->name, node->handle, buf, |
1343 | @@ -405,7 +405,7 @@ | |||
1344 | 405 | ut_a(ret); | 405 | ut_a(ret); |
1345 | 406 | 406 | ||
1346 | 407 | if (mode == OS_AIO_SYNC) { | 407 | if (mode == OS_AIO_SYNC) { |
1348 | 408 | @@ -5436,6 +5483,7 @@ | 408 | @@ -5444,6 +5491,7 @@ |
1349 | 409 | fil_node_t* fil_node; | 409 | fil_node_t* fil_node; |
1350 | 410 | void* message; | 410 | void* message; |
1351 | 411 | ulint type; | 411 | ulint type; |
1352 | @@ -413,7 +413,7 @@ | |||
1353 | 413 | 413 | ||
1354 | 414 | ut_ad(fil_validate_skip()); | 414 | ut_ad(fil_validate_skip()); |
1355 | 415 | 415 | ||
1357 | 416 | @@ -5443,10 +5491,10 @@ | 416 | @@ -5451,10 +5499,10 @@ |
1358 | 417 | srv_set_io_thread_op_info(segment, "native aio handle"); | 417 | srv_set_io_thread_op_info(segment, "native aio handle"); |
1359 | 418 | #ifdef WIN_ASYNC_IO | 418 | #ifdef WIN_ASYNC_IO |
1360 | 419 | ret = os_aio_windows_handle(segment, 0, &fil_node, | 419 | ret = os_aio_windows_handle(segment, 0, &fil_node, |
1361 | @@ -426,7 +426,7 @@ | |||
1362 | 426 | #else | 426 | #else |
1363 | 427 | ut_error; | 427 | ut_error; |
1364 | 428 | ret = 0; /* Eliminate compiler warning */ | 428 | ret = 0; /* Eliminate compiler warning */ |
1366 | 429 | @@ -5455,7 +5503,22 @@ | 429 | @@ -5463,7 +5511,22 @@ |
1367 | 430 | srv_set_io_thread_op_info(segment, "simulated aio handle"); | 430 | srv_set_io_thread_op_info(segment, "simulated aio handle"); |
1368 | 431 | 431 | ||
1369 | 432 | ret = os_aio_simulated_handle(segment, &fil_node, | 432 | ret = os_aio_simulated_handle(segment, &fil_node, |
1370 | @@ -452,7 +452,7 @@ | |||
1371 | 452 | ut_a(ret); | 452 | ut_a(ret); |
1372 | 453 | --- a/storage/innobase/handler/ha_innodb.cc | 453 | --- a/storage/innobase/handler/ha_innodb.cc |
1373 | 454 | +++ b/storage/innobase/handler/ha_innodb.cc | 454 | +++ b/storage/innobase/handler/ha_innodb.cc |
1375 | 455 | @@ -12150,6 +12150,12 @@ | 455 | @@ -12189,6 +12189,12 @@ |
1376 | 456 | "except for the deletion.", | 456 | "except for the deletion.", |
1377 | 457 | NULL, NULL, 0, &corrupt_table_action_typelib); | 457 | NULL, NULL, 0, &corrupt_table_action_typelib); |
1378 | 458 | 458 | ||
1379 | @@ -465,15 +465,15 @@ | |||
1380 | 465 | static struct st_mysql_sys_var* innobase_system_variables[]= { | 465 | static struct st_mysql_sys_var* innobase_system_variables[]= { |
1381 | 466 | MYSQL_SYSVAR(page_size), | 466 | MYSQL_SYSVAR(page_size), |
1382 | 467 | MYSQL_SYSVAR(log_block_size), | 467 | MYSQL_SYSVAR(log_block_size), |
1386 | 468 | @@ -12244,6 +12250,7 @@ | 468 | @@ -12286,6 +12292,7 @@ |
1387 | 469 | MYSQL_SYSVAR(purge_batch_size), | 469 | MYSQL_SYSVAR(flush_checkpoint_debug), |
1388 | 470 | MYSQL_SYSVAR(rollback_segments), | 470 | #endif |
1389 | 471 | MYSQL_SYSVAR(corrupt_table_action), | 471 | MYSQL_SYSVAR(corrupt_table_action), |
1390 | 472 | + MYSQL_SYSVAR(lazy_drop_table), | 472 | + MYSQL_SYSVAR(lazy_drop_table), |
1391 | 473 | NULL | 473 | NULL |
1392 | 474 | }; | 474 | }; |
1393 | 475 | 475 | ||
1395 | 476 | @@ -12253,7 +12260,7 @@ | 476 | @@ -12295,7 +12302,7 @@ |
1396 | 477 | &innobase_storage_engine, | 477 | &innobase_storage_engine, |
1397 | 478 | innobase_hton_name, | 478 | innobase_hton_name, |
1398 | 479 | plugin_author, | 479 | plugin_author, |
1399 | @@ -484,7 +484,7 @@ | |||
1400 | 484 | NULL, /* Plugin Deinit */ | 484 | NULL, /* Plugin Deinit */ |
1401 | 485 | --- a/storage/innobase/include/buf0buf.h | 485 | --- a/storage/innobase/include/buf0buf.h |
1402 | 486 | +++ b/storage/innobase/include/buf0buf.h | 486 | +++ b/storage/innobase/include/buf0buf.h |
1404 | 487 | @@ -1455,6 +1455,7 @@ | 487 | @@ -1475,6 +1475,7 @@ |
1405 | 488 | 0 if the block was never accessed | 488 | 0 if the block was never accessed |
1406 | 489 | in the buffer pool */ | 489 | in the buffer pool */ |
1407 | 490 | /* @} */ | 490 | /* @} */ |
1408 | @@ -888,7 +888,7 @@ | |||
1409 | 888 | UNIV_INTERN ulong srv_n_free_tickets_to_enter = 500; | 888 | UNIV_INTERN ulong srv_n_free_tickets_to_enter = 500; |
1410 | 889 | --- a/storage/innobase/srv/srv0start.c | 889 | --- a/storage/innobase/srv/srv0start.c |
1411 | 890 | +++ b/storage/innobase/srv/srv0start.c | 890 | +++ b/storage/innobase/srv/srv0start.c |
1413 | 891 | @@ -2167,7 +2167,7 @@ | 891 | @@ -2187,7 +2187,7 @@ |
1414 | 892 | if (srv_print_verbose_log) { | 892 | if (srv_print_verbose_log) { |
1415 | 893 | ut_print_timestamp(stderr); | 893 | ut_print_timestamp(stderr); |
1416 | 894 | fprintf(stderr, | 894 | fprintf(stderr, |
1417 | 895 | 895 | ||
1418 | === modified file 'patches/innodb_io_patches.patch' | |||
1419 | --- patches/innodb_io_patches.patch 2012-01-10 11:30:16 +0000 | |||
1420 | +++ patches/innodb_io_patches.patch 2012-02-06 05:02:26 +0000 | |||
1421 | @@ -155,7 +155,7 @@ | |||
1422 | 155 | return(0); | 155 | return(0); |
1423 | 156 | --- a/storage/innobase/fil/fil0fil.c | 156 | --- a/storage/innobase/fil/fil0fil.c |
1424 | 157 | +++ b/storage/innobase/fil/fil0fil.c | 157 | +++ b/storage/innobase/fil/fil0fil.c |
1426 | 158 | @@ -2601,7 +2601,7 @@ | 158 | @@ -2609,7 +2609,7 @@ |
1427 | 159 | 159 | ||
1428 | 160 | os_thread_sleep(20000); | 160 | os_thread_sleep(20000); |
1429 | 161 | 161 | ||
1430 | @@ -164,7 +164,7 @@ | |||
1431 | 164 | 164 | ||
1432 | 165 | goto retry; | 165 | goto retry; |
1433 | 166 | 166 | ||
1435 | 167 | @@ -2815,7 +2815,7 @@ | 167 | @@ -2823,7 +2823,7 @@ |
1436 | 168 | goto error_exit; | 168 | goto error_exit; |
1437 | 169 | } | 169 | } |
1438 | 170 | 170 | ||
1439 | @@ -173,7 +173,7 @@ | |||
1440 | 173 | 173 | ||
1441 | 174 | if (!ret) { | 174 | if (!ret) { |
1442 | 175 | fputs("InnoDB: Error: file flush of tablespace ", stderr); | 175 | fputs("InnoDB: Error: file flush of tablespace ", stderr); |
1444 | 176 | @@ -3001,7 +3001,7 @@ | 176 | @@ -3009,7 +3009,7 @@ |
1445 | 177 | } | 177 | } |
1446 | 178 | } | 178 | } |
1447 | 179 | 179 | ||
1448 | @@ -182,7 +182,7 @@ | |||
1449 | 182 | if (!success) { | 182 | if (!success) { |
1450 | 183 | 183 | ||
1451 | 184 | goto func_exit; | 184 | goto func_exit; |
1453 | 185 | @@ -3023,7 +3023,7 @@ | 185 | @@ -3031,7 +3031,7 @@ |
1454 | 186 | 186 | ||
1455 | 187 | goto func_exit; | 187 | goto func_exit; |
1456 | 188 | } | 188 | } |
1457 | @@ -191,7 +191,7 @@ | |||
1458 | 191 | func_exit: | 191 | func_exit: |
1459 | 192 | os_file_close(file); | 192 | os_file_close(file); |
1460 | 193 | ut_free(buf2); | 193 | ut_free(buf2); |
1462 | 194 | @@ -4006,7 +4006,7 @@ | 194 | @@ -4014,7 +4014,7 @@ |
1463 | 195 | size_after_extend, *actual_size); */ | 195 | size_after_extend, *actual_size); */ |
1464 | 196 | mutex_exit(&fil_system->mutex); | 196 | mutex_exit(&fil_system->mutex); |
1465 | 197 | 197 | ||
1466 | @@ -200,7 +200,7 @@ | |||
1467 | 200 | 200 | ||
1468 | 201 | return(success); | 201 | return(success); |
1469 | 202 | } | 202 | } |
1471 | 203 | @@ -4577,8 +4577,9 @@ | 203 | @@ -4585,8 +4585,9 @@ |
1472 | 204 | void | 204 | void |
1473 | 205 | fil_flush( | 205 | fil_flush( |
1474 | 206 | /*======*/ | 206 | /*======*/ |
1475 | @@ -211,7 +211,7 @@ | |||
1476 | 211 | { | 211 | { |
1477 | 212 | fil_space_t* space; | 212 | fil_space_t* space; |
1478 | 213 | fil_node_t* node; | 213 | fil_node_t* node; |
1480 | 214 | @@ -4649,7 +4650,7 @@ | 214 | @@ -4657,7 +4658,7 @@ |
1481 | 215 | /* fprintf(stderr, "Flushing to file %s\n", | 215 | /* fprintf(stderr, "Flushing to file %s\n", |
1482 | 216 | node->name); */ | 216 | node->name); */ |
1483 | 217 | 217 | ||
1484 | @@ -220,7 +220,7 @@ | |||
1485 | 220 | 220 | ||
1486 | 221 | mutex_enter(&fil_system->mutex); | 221 | mutex_enter(&fil_system->mutex); |
1487 | 222 | 222 | ||
1489 | 223 | @@ -4732,7 +4733,7 @@ | 223 | @@ -4740,7 +4741,7 @@ |
1490 | 224 | a non-existing space id. */ | 224 | a non-existing space id. */ |
1491 | 225 | for (i = 0; i < n_space_ids; i++) { | 225 | for (i = 0; i < n_space_ids; i++) { |
1492 | 226 | 226 | ||
1493 | @@ -272,7 +272,7 @@ | |||
1494 | 272 | srv_force_recovery = (ulint) innobase_force_recovery; | 272 | srv_force_recovery = (ulint) innobase_force_recovery; |
1495 | 273 | 273 | ||
1496 | 274 | srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite; | 274 | srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite; |
1498 | 275 | @@ -11142,7 +11162,7 @@ | 275 | @@ -11141,7 +11161,7 @@ |
1499 | 276 | PLUGIN_VAR_OPCMDARG | PLUGIN_VAR_READONLY, | 276 | PLUGIN_VAR_OPCMDARG | PLUGIN_VAR_READONLY, |
1500 | 277 | "Purge threads can be either 0 or 1.", | 277 | "Purge threads can be either 0 or 1.", |
1501 | 278 | NULL, NULL, | 278 | NULL, NULL, |
1502 | @@ -281,7 +281,7 @@ | |||
1503 | 281 | 0, /* Minimum value */ | 281 | 0, /* Minimum value */ |
1504 | 282 | 1, 0); /* Maximum value */ | 282 | 1, 0); /* Maximum value */ |
1505 | 283 | 283 | ||
1507 | 284 | @@ -11184,12 +11204,18 @@ | 284 | @@ -11183,12 +11203,18 @@ |
1508 | 285 | innodb_file_format_max_validate, | 285 | innodb_file_format_max_validate, |
1509 | 286 | innodb_file_format_max_update, "Antelope"); | 286 | innodb_file_format_max_update, "Antelope"); |
1510 | 287 | 287 | ||
1511 | @@ -306,7 +306,7 @@ | |||
1512 | 306 | 306 | ||
1513 | 307 | static MYSQL_SYSVAR_STR(flush_method, innobase_file_flush_method, | 307 | static MYSQL_SYSVAR_STR(flush_method, innobase_file_flush_method, |
1514 | 308 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, | 308 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, |
1516 | 309 | @@ -11294,7 +11320,7 @@ | 309 | @@ -11293,7 +11319,7 @@ |
1517 | 310 | static MYSQL_SYSVAR_LONGLONG(buffer_pool_size, innobase_buffer_pool_size, | 310 | static MYSQL_SYSVAR_LONGLONG(buffer_pool_size, innobase_buffer_pool_size, |
1518 | 311 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, | 311 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, |
1519 | 312 | "The size of the memory buffer InnoDB uses to cache data and indexes of its tables.", | 312 | "The size of the memory buffer InnoDB uses to cache data and indexes of its tables.", |
1520 | @@ -315,7 +315,7 @@ | |||
1521 | 315 | 315 | ||
1522 | 316 | static MYSQL_SYSVAR_LONG(buffer_pool_instances, innobase_buffer_pool_instances, | 316 | static MYSQL_SYSVAR_LONG(buffer_pool_instances, innobase_buffer_pool_instances, |
1523 | 317 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, | 317 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, |
1525 | 318 | @@ -11451,6 +11477,135 @@ | 318 | @@ -11450,6 +11476,135 @@ |
1526 | 319 | "trigger a readahead.", | 319 | "trigger a readahead.", |
1527 | 320 | NULL, NULL, 56, 0, 64, 0); | 320 | NULL, NULL, 56, 0, 64, 0); |
1528 | 321 | 321 | ||
1529 | @@ -451,7 +451,7 @@ | |||
1530 | 451 | static struct st_mysql_sys_var* innobase_system_variables[]= { | 451 | static struct st_mysql_sys_var* innobase_system_variables[]= { |
1531 | 452 | MYSQL_SYSVAR(additional_mem_pool_size), | 452 | MYSQL_SYSVAR(additional_mem_pool_size), |
1532 | 453 | MYSQL_SYSVAR(autoextend_increment), | 453 | MYSQL_SYSVAR(autoextend_increment), |
1534 | 454 | @@ -11471,6 +11626,7 @@ | 454 | @@ -11470,6 +11625,7 @@ |
1535 | 455 | MYSQL_SYSVAR(file_format_check), | 455 | MYSQL_SYSVAR(file_format_check), |
1536 | 456 | MYSQL_SYSVAR(file_format_max), | 456 | MYSQL_SYSVAR(file_format_max), |
1537 | 457 | MYSQL_SYSVAR(flush_log_at_trx_commit), | 457 | MYSQL_SYSVAR(flush_log_at_trx_commit), |
1538 | @@ -459,7 +459,7 @@ | |||
1539 | 459 | MYSQL_SYSVAR(flush_method), | 459 | MYSQL_SYSVAR(flush_method), |
1540 | 460 | MYSQL_SYSVAR(force_recovery), | 460 | MYSQL_SYSVAR(force_recovery), |
1541 | 461 | MYSQL_SYSVAR(large_prefix), | 461 | MYSQL_SYSVAR(large_prefix), |
1543 | 462 | @@ -11510,6 +11666,13 @@ | 462 | @@ -11509,6 +11665,13 @@ |
1544 | 463 | MYSQL_SYSVAR(show_verbose_locks), | 463 | MYSQL_SYSVAR(show_verbose_locks), |
1545 | 464 | MYSQL_SYSVAR(show_locks_held), | 464 | MYSQL_SYSVAR(show_locks_held), |
1546 | 465 | MYSQL_SYSVAR(version), | 465 | MYSQL_SYSVAR(version), |
1547 | @@ -473,7 +473,7 @@ | |||
1548 | 473 | MYSQL_SYSVAR(use_sys_malloc), | 473 | MYSQL_SYSVAR(use_sys_malloc), |
1549 | 474 | MYSQL_SYSVAR(use_native_aio), | 474 | MYSQL_SYSVAR(use_native_aio), |
1550 | 475 | MYSQL_SYSVAR(change_buffering), | 475 | MYSQL_SYSVAR(change_buffering), |
1552 | 476 | @@ -11522,6 +11685,9 @@ | 476 | @@ -11521,6 +11684,9 @@ |
1553 | 477 | MYSQL_SYSVAR(purge_threads), | 477 | MYSQL_SYSVAR(purge_threads), |
1554 | 478 | MYSQL_SYSVAR(purge_batch_size), | 478 | MYSQL_SYSVAR(purge_batch_size), |
1555 | 479 | MYSQL_SYSVAR(rollback_segments), | 479 | MYSQL_SYSVAR(rollback_segments), |
1556 | @@ -524,7 +524,7 @@ | |||
1557 | 524 | /** read only pages belonging to the insert buffer tree */ | 524 | /** read only pages belonging to the insert buffer tree */ |
1558 | 525 | --- a/storage/innobase/include/fil0fil.h | 525 | --- a/storage/innobase/include/fil0fil.h |
1559 | 526 | +++ b/storage/innobase/include/fil0fil.h | 526 | +++ b/storage/innobase/include/fil0fil.h |
1561 | 527 | @@ -658,8 +658,9 @@ | 527 | @@ -663,8 +663,9 @@ |
1562 | 528 | void | 528 | void |
1563 | 529 | fil_flush( | 529 | fil_flush( |
1564 | 530 | /*======*/ | 530 | /*======*/ |
1565 | @@ -1600,7 +1600,7 @@ | |||
1566 | 1600 | mutex_enter(&kernel_mutex); | 1600 | mutex_enter(&kernel_mutex); |
1567 | 1601 | --- a/storage/innobase/srv/srv0start.c | 1601 | --- a/storage/innobase/srv/srv0start.c |
1568 | 1602 | +++ b/storage/innobase/srv/srv0start.c | 1602 | +++ b/storage/innobase/srv/srv0start.c |
1570 | 1603 | @@ -1217,6 +1217,9 @@ | 1603 | @@ -1237,6 +1237,9 @@ |
1571 | 1604 | } else if (0 == ut_strcmp(srv_file_flush_method_str, "O_DIRECT")) { | 1604 | } else if (0 == ut_strcmp(srv_file_flush_method_str, "O_DIRECT")) { |
1572 | 1605 | srv_unix_file_flush_method = SRV_UNIX_O_DIRECT; | 1605 | srv_unix_file_flush_method = SRV_UNIX_O_DIRECT; |
1573 | 1606 | 1606 | ||
1574 | @@ -1926,3 +1926,27 @@ | |||
1575 | 1926 | 1926 | ||
1576 | 1927 | # Performance schema variables are too long for files named | 1927 | # Performance schema variables are too long for files named |
1577 | 1928 | # 'mysql-test/suite/sys_vars/t/' ... | 1928 | # 'mysql-test/suite/sys_vars/t/' ... |
1578 | 1929 | --- a/mysql-test/suite/innodb/t/innodb_cmp_drop_table-master.opt | ||
1579 | 1930 | +++ b/mysql-test/suite/innodb/t/innodb_cmp_drop_table-master.opt | ||
1580 | 1931 | @@ -1 +1 @@ | ||
1581 | 1932 | ---innodb-buffer-pool-size=8M | ||
1582 | 1933 | +--innodb-buffer-pool-size=32M | ||
1583 | 1934 | --- a/mysql-test/suite/innodb/t/innodb_cmp_drop_table.test | ||
1584 | 1935 | +++ b/mysql-test/suite/innodb/t/innodb_cmp_drop_table.test | ||
1585 | 1936 | @@ -36,13 +36,14 @@ | ||
1586 | 1937 | |||
1587 | 1938 | -- disable_query_log | ||
1588 | 1939 | |||
1589 | 1940 | --- let $i = 400 | ||
1590 | 1941 | +-- let $i = 4000 | ||
1591 | 1942 | +begin; | ||
1592 | 1943 | while ($i) | ||
1593 | 1944 | { | ||
1594 | 1945 | insert into t2 values(repeat('abcdefghijklmnopqrstuvwxyz',1000)); | ||
1595 | 1946 | dec $i; | ||
1596 | 1947 | } | ||
1597 | 1948 | - | ||
1598 | 1949 | +commit; | ||
1599 | 1950 | -- enable_query_log | ||
1600 | 1951 | |||
1601 | 1952 | # now there should be no 8K pages in the buffer pool | ||
1602 | 1929 | 1953 | ||
1603 | === modified file 'patches/innodb_kill_idle_transaction.patch' | |||
1604 | --- patches/innodb_kill_idle_transaction.patch 2011-12-27 15:32:16 +0000 | |||
1605 | +++ patches/innodb_kill_idle_transaction.patch 2012-02-06 05:02:26 +0000 | |||
1606 | @@ -114,7 +114,7 @@ | |||
1607 | 114 | #ifdef HAVE_PSI_INTERFACE | 114 | #ifdef HAVE_PSI_INTERFACE |
1608 | 115 | /* Register keys with MySQL performance schema */ | 115 | /* Register keys with MySQL performance schema */ |
1609 | 116 | if (PSI_server) { | 116 | if (PSI_server) { |
1611 | 117 | @@ -11695,6 +11699,57 @@ | 117 | @@ -11694,6 +11698,57 @@ |
1612 | 118 | return(false); | 118 | return(false); |
1613 | 119 | } | 119 | } |
1614 | 120 | 120 | ||
1615 | @@ -172,7 +172,7 @@ | |||
1616 | 172 | static SHOW_VAR innodb_status_variables_export[]= { | 172 | static SHOW_VAR innodb_status_variables_export[]= { |
1617 | 173 | {"Innodb", (char*) &show_innodb_vars, SHOW_FUNC}, | 173 | {"Innodb", (char*) &show_innodb_vars, SHOW_FUNC}, |
1618 | 174 | {NullS, NullS, SHOW_LONG} | 174 | {NullS, NullS, SHOW_LONG} |
1620 | 175 | @@ -11986,6 +12041,15 @@ | 175 | @@ -11985,6 +12040,15 @@ |
1621 | 176 | "Number of times a thread is allowed to enter InnoDB within the same SQL query after it has once got the ticket", | 176 | "Number of times a thread is allowed to enter InnoDB within the same SQL query after it has once got the ticket", |
1622 | 177 | NULL, NULL, 500L, 1L, ~0L, 0); | 177 | NULL, NULL, 500L, 1L, ~0L, 0); |
1623 | 178 | 178 | ||
1624 | @@ -188,7 +188,7 @@ | |||
1625 | 188 | static MYSQL_SYSVAR_LONG(file_io_threads, innobase_file_io_threads, | 188 | static MYSQL_SYSVAR_LONG(file_io_threads, innobase_file_io_threads, |
1626 | 189 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY | PLUGIN_VAR_NOSYSVAR, | 189 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY | PLUGIN_VAR_NOSYSVAR, |
1627 | 190 | "Number of file I/O threads in InnoDB.", | 190 | "Number of file I/O threads in InnoDB.", |
1629 | 191 | @@ -12288,6 +12352,7 @@ | 191 | @@ -12327,6 +12391,7 @@ |
1630 | 192 | MYSQL_SYSVAR(fast_checksum), | 192 | MYSQL_SYSVAR(fast_checksum), |
1631 | 193 | MYSQL_SYSVAR(commit_concurrency), | 193 | MYSQL_SYSVAR(commit_concurrency), |
1632 | 194 | MYSQL_SYSVAR(concurrency_tickets), | 194 | MYSQL_SYSVAR(concurrency_tickets), |
1633 | @@ -198,7 +198,7 @@ | |||
1634 | 198 | MYSQL_SYSVAR(data_home_dir), | 198 | MYSQL_SYSVAR(data_home_dir), |
1635 | 199 | --- a/storage/innobase/include/srv0srv.h | 199 | --- a/storage/innobase/include/srv0srv.h |
1636 | 200 | +++ b/storage/innobase/include/srv0srv.h | 200 | +++ b/storage/innobase/include/srv0srv.h |
1638 | 201 | @@ -296,6 +296,7 @@ | 201 | @@ -299,6 +299,7 @@ |
1639 | 202 | extern ulint srv_activity_count; | 202 | extern ulint srv_activity_count; |
1640 | 203 | extern ulint srv_fatal_semaphore_wait_threshold; | 203 | extern ulint srv_fatal_semaphore_wait_threshold; |
1641 | 204 | extern ulint srv_dml_needed_delay; | 204 | extern ulint srv_dml_needed_delay; |
1642 | @@ -242,7 +242,7 @@ | |||
1643 | 242 | /* How much data manipulation language (DML) statements need to be delayed, | 242 | /* How much data manipulation language (DML) statements need to be delayed, |
1644 | 243 | in microseconds, in order to reduce the lagging of the purge thread. */ | 243 | in microseconds, in order to reduce the lagging of the purge thread. */ |
1645 | 244 | UNIV_INTERN ulint srv_dml_needed_delay = 0; | 244 | UNIV_INTERN ulint srv_dml_needed_delay = 0; |
1647 | 245 | @@ -2834,6 +2843,36 @@ | 245 | @@ -2837,6 +2846,36 @@ |
1648 | 246 | old_sema = sema; | 246 | old_sema = sema; |
1649 | 247 | } | 247 | } |
1650 | 248 | 248 | ||
1651 | 249 | 249 | ||
1652 | === modified file 'patches/innodb_lru_dump_restore.patch' | |||
1653 | --- patches/innodb_lru_dump_restore.patch 2011-12-27 15:32:16 +0000 | |||
1654 | +++ patches/innodb_lru_dump_restore.patch 2012-02-06 05:02:26 +0000 | |||
1655 | @@ -7,7 +7,7 @@ | |||
1656 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
1657 | 8 | --- a/storage/innobase/buf/buf0lru.c | 8 | --- a/storage/innobase/buf/buf0lru.c |
1658 | 9 | +++ b/storage/innobase/buf/buf0lru.c | 9 | +++ b/storage/innobase/buf/buf0lru.c |
1660 | 10 | @@ -2183,6 +2183,289 @@ | 10 | @@ -2197,6 +2197,289 @@ |
1661 | 11 | memset(&buf_LRU_stat_cur, 0, sizeof buf_LRU_stat_cur); | 11 | memset(&buf_LRU_stat_cur, 0, sizeof buf_LRU_stat_cur); |
1662 | 12 | } | 12 | } |
1663 | 13 | 13 | ||
1664 | @@ -310,7 +310,7 @@ | |||
1665 | 310 | /*==============*/ | 310 | /*==============*/ |
1666 | 311 | --- a/storage/innobase/fil/fil0fil.c | 311 | --- a/storage/innobase/fil/fil0fil.c |
1667 | 312 | +++ b/storage/innobase/fil/fil0fil.c | 312 | +++ b/storage/innobase/fil/fil0fil.c |
1669 | 313 | @@ -5299,6 +5299,70 @@ | 313 | @@ -5307,6 +5307,70 @@ |
1670 | 314 | return(DB_SUCCESS); | 314 | return(DB_SUCCESS); |
1671 | 315 | } | 315 | } |
1672 | 316 | 316 | ||
1673 | @@ -401,7 +401,7 @@ | |||
1674 | 401 | #ifdef HAVE_LARGE_PAGES | 401 | #ifdef HAVE_LARGE_PAGES |
1675 | 402 | if ((os_use_large_pages = (ibool) my_use_large_pages)) | 402 | if ((os_use_large_pages = (ibool) my_use_large_pages)) |
1676 | 403 | os_large_page_size = (ulint) opt_large_page_size; | 403 | os_large_page_size = (ulint) opt_large_page_size; |
1678 | 404 | @@ -11925,6 +11929,19 @@ | 404 | @@ -11964,6 +11968,19 @@ |
1679 | 405 | "Limit the allocated memory for dictionary cache. (0: unlimited)", | 405 | "Limit the allocated memory for dictionary cache. (0: unlimited)", |
1680 | 406 | NULL, NULL, 0, 0, LONG_MAX, 0); | 406 | NULL, NULL, 0, 0, LONG_MAX, 0); |
1681 | 407 | 407 | ||
1682 | @@ -421,7 +421,7 @@ | |||
1683 | 421 | static struct st_mysql_sys_var* innobase_system_variables[]= { | 421 | static struct st_mysql_sys_var* innobase_system_variables[]= { |
1684 | 422 | MYSQL_SYSVAR(additional_mem_pool_size), | 422 | MYSQL_SYSVAR(additional_mem_pool_size), |
1685 | 423 | MYSQL_SYSVAR(autoextend_increment), | 423 | MYSQL_SYSVAR(autoextend_increment), |
1687 | 424 | @@ -12009,6 +12026,8 @@ | 424 | @@ -12048,6 +12065,8 @@ |
1688 | 425 | MYSQL_SYSVAR(random_read_ahead), | 425 | MYSQL_SYSVAR(random_read_ahead), |
1689 | 426 | MYSQL_SYSVAR(read_ahead_threshold), | 426 | MYSQL_SYSVAR(read_ahead_threshold), |
1690 | 427 | MYSQL_SYSVAR(io_capacity), | 427 | MYSQL_SYSVAR(io_capacity), |
1691 | @@ -540,7 +540,7 @@ | |||
1692 | 540 | an exclusive lock on the buffer frame. The flag is cleared and the x-lock | 540 | an exclusive lock on the buffer frame. The flag is cleared and the x-lock |
1693 | 541 | --- a/storage/innobase/include/fil0fil.h | 541 | --- a/storage/innobase/include/fil0fil.h |
1694 | 542 | +++ b/storage/innobase/include/fil0fil.h | 542 | +++ b/storage/innobase/include/fil0fil.h |
1696 | 543 | @@ -648,6 +648,14 @@ | 543 | @@ -653,6 +653,14 @@ |
1697 | 544 | void* message, /*!< in: message for aio handler if non-sync | 544 | void* message, /*!< in: message for aio handler if non-sync |
1698 | 545 | aio used, else ignored */ | 545 | aio used, else ignored */ |
1699 | 546 | trx_t* trx); | 546 | trx_t* trx); |
1700 | @@ -557,7 +557,7 @@ | |||
1701 | 557 | handler for completed requests. The aio array of pending requests is divided | 557 | handler for completed requests. The aio array of pending requests is divided |
1702 | 558 | --- a/storage/innobase/include/srv0srv.h | 558 | --- a/storage/innobase/include/srv0srv.h |
1703 | 559 | +++ b/storage/innobase/include/srv0srv.h | 559 | +++ b/storage/innobase/include/srv0srv.h |
1705 | 560 | @@ -361,6 +361,12 @@ | 560 | @@ -364,6 +364,12 @@ |
1706 | 561 | reading of a disk page */ | 561 | reading of a disk page */ |
1707 | 562 | extern ulint srv_buf_pool_reads; | 562 | extern ulint srv_buf_pool_reads; |
1708 | 563 | 563 | ||
1709 | @@ -570,7 +570,7 @@ | |||
1710 | 570 | /** Status variables to be passed to MySQL */ | 570 | /** Status variables to be passed to MySQL */ |
1711 | 571 | typedef struct export_var_struct export_struc; | 571 | typedef struct export_var_struct export_struc; |
1712 | 572 | 572 | ||
1714 | 573 | @@ -666,6 +672,16 @@ | 573 | @@ -669,6 +675,16 @@ |
1715 | 574 | /*=====================*/ | 574 | /*=====================*/ |
1716 | 575 | void* arg); /*!< in: a dummy parameter required by | 575 | void* arg); /*!< in: a dummy parameter required by |
1717 | 576 | os_thread_create */ | 576 | os_thread_create */ |
1718 | @@ -602,10 +602,15 @@ | |||
1719 | 602 | /* structure to pass status variables to MySQL */ | 602 | /* structure to pass status variables to MySQL */ |
1720 | 603 | UNIV_INTERN export_struc export_vars; | 603 | UNIV_INTERN export_struc export_vars; |
1721 | 604 | 604 | ||
1725 | 605 | @@ -2710,6 +2716,58 @@ | 605 | @@ -2708,6 +2714,58 @@ |
1726 | 606 | OS_THREAD_DUMMY_RETURN; | 606 | /* We count the number of threads in os_thread_exit(). A created |
1727 | 607 | } | 607 | thread should always use that to exit and not use return() to exit. */ |
1728 | 608 | 608 | ||
1729 | 609 | + os_thread_exit(NULL); | ||
1730 | 610 | + | ||
1731 | 611 | + OS_THREAD_DUMMY_RETURN; | ||
1732 | 612 | +} | ||
1733 | 613 | + | ||
1734 | 609 | +/*********************************************************************//** | 614 | +/*********************************************************************//** |
1735 | 610 | +A thread which restores the buffer pool from a dump file on startup and does | 615 | +A thread which restores the buffer pool from a dump file on startup and does |
1736 | 611 | +periodic buffer pool dumps. | 616 | +periodic buffer pool dumps. |
1737 | @@ -653,14 +658,9 @@ | |||
1738 | 653 | + /* We count the number of threads in os_thread_exit(). A created | 658 | + /* We count the number of threads in os_thread_exit(). A created |
1739 | 654 | + thread should always use that to exit and not use return() to exit. */ | 659 | + thread should always use that to exit and not use return() to exit. */ |
1740 | 655 | + | 660 | + |
1749 | 656 | + os_thread_exit(NULL); | 661 | os_thread_exit(NULL); |
1750 | 657 | + | 662 | |
1751 | 658 | + OS_THREAD_DUMMY_RETURN; | 663 | OS_THREAD_DUMMY_RETURN; |
1744 | 659 | +} | ||
1745 | 660 | + | ||
1746 | 661 | /**********************************************************************//** | ||
1747 | 662 | Check whether any background thread is active. | ||
1748 | 663 | @return FALSE if all are are suspended or have exited. */ | ||
1752 | 664 | --- a/storage/innobase/srv/srv0start.c | 664 | --- a/storage/innobase/srv/srv0start.c |
1753 | 665 | +++ b/storage/innobase/srv/srv0start.c | 665 | +++ b/storage/innobase/srv/srv0start.c |
1754 | 666 | @@ -87,6 +87,7 @@ | 666 | @@ -87,6 +87,7 @@ |
1755 | @@ -683,7 +683,7 @@ | |||
1756 | 683 | 683 | ||
1757 | 684 | /** We use this mutex to test the return value of pthread_mutex_trylock | 684 | /** We use this mutex to test the return value of pthread_mutex_trylock |
1758 | 685 | on successful locking. HP-UX does NOT return 0, though Linux et al do. */ | 685 | on successful locking. HP-UX does NOT return 0, though Linux et al do. */ |
1760 | 686 | @@ -1821,6 +1822,15 @@ | 686 | @@ -1841,6 +1842,15 @@ |
1761 | 687 | os_thread_create(&srv_monitor_thread, NULL, | 687 | os_thread_create(&srv_monitor_thread, NULL, |
1762 | 688 | thread_ids + 4 + SRV_MAX_N_IO_THREADS); | 688 | thread_ids + 4 + SRV_MAX_N_IO_THREADS); |
1763 | 689 | 689 | ||
1764 | 690 | 690 | ||
1765 | === modified file 'patches/innodb_opt_lru_count.patch' | |||
1766 | --- patches/innodb_opt_lru_count.patch 2011-12-27 15:32:16 +0000 | |||
1767 | +++ patches/innodb_opt_lru_count.patch 2012-02-06 05:02:26 +0000 | |||
1768 | @@ -29,7 +29,7 @@ | |||
1769 | 29 | #if defined UNIV_AHI_DEBUG || defined UNIV_DEBUG | 29 | #if defined UNIV_AHI_DEBUG || defined UNIV_DEBUG |
1770 | 30 | block->n_pointers = 0; | 30 | block->n_pointers = 0; |
1771 | 31 | #endif /* UNIV_AHI_DEBUG || UNIV_DEBUG */ | 31 | #endif /* UNIV_AHI_DEBUG || UNIV_DEBUG */ |
1773 | 32 | @@ -1401,7 +1401,7 @@ | 32 | @@ -1403,7 +1403,7 @@ |
1774 | 33 | 33 | ||
1775 | 34 | memcpy(dpage, bpage, sizeof *dpage); | 34 | memcpy(dpage, bpage, sizeof *dpage); |
1776 | 35 | 35 | ||
1777 | @@ -38,7 +38,7 @@ | |||
1778 | 38 | ut_d(bpage->in_page_hash = FALSE); | 38 | ut_d(bpage->in_page_hash = FALSE); |
1779 | 39 | 39 | ||
1780 | 40 | /* relocate buf_pool->LRU */ | 40 | /* relocate buf_pool->LRU */ |
1782 | 41 | @@ -3223,8 +3223,8 @@ | 41 | @@ -3225,8 +3225,8 @@ |
1783 | 42 | bpage->in_zip_hash = FALSE; | 42 | bpage->in_zip_hash = FALSE; |
1784 | 43 | bpage->in_flush_list = FALSE; | 43 | bpage->in_flush_list = FALSE; |
1785 | 44 | bpage->in_free_list = FALSE; | 44 | bpage->in_free_list = FALSE; |
1786 | @@ -48,7 +48,7 @@ | |||
1787 | 48 | 48 | ||
1788 | 49 | ut_d(bpage->in_page_hash = TRUE); | 49 | ut_d(bpage->in_page_hash = TRUE); |
1789 | 50 | 50 | ||
1791 | 51 | @@ -3389,7 +3389,7 @@ | 51 | @@ -3391,7 +3391,7 @@ |
1792 | 52 | ibuf_merge_or_delete_for_page(NULL, space, offset, zip_size, TRUE); | 52 | ibuf_merge_or_delete_for_page(NULL, space, offset, zip_size, TRUE); |
1793 | 53 | 53 | ||
1794 | 54 | /* Flush pages from the end of the LRU list if necessary */ | 54 | /* Flush pages from the end of the LRU list if necessary */ |
1795 | @@ -94,7 +94,7 @@ | |||
1796 | 94 | 94 | ||
1797 | 95 | return(FALSE); | 95 | return(FALSE); |
1798 | 96 | } | 96 | } |
1800 | 97 | @@ -1985,8 +1988,14 @@ | 97 | @@ -2049,8 +2052,14 @@ |
1801 | 98 | buf_page_t* bpage; | 98 | buf_page_t* bpage; |
1802 | 99 | ulint n_replaceable; | 99 | ulint n_replaceable; |
1803 | 100 | ulint distance = 0; | 100 | ulint distance = 0; |
1804 | @@ -110,7 +110,7 @@ | |||
1805 | 110 | 110 | ||
1806 | 111 | n_replaceable = UT_LIST_GET_LEN(buf_pool->free); | 111 | n_replaceable = UT_LIST_GET_LEN(buf_pool->free); |
1807 | 112 | 112 | ||
1809 | 113 | @@ -1997,7 +2006,13 @@ | 113 | @@ -2061,7 +2070,13 @@ |
1810 | 114 | + BUF_FLUSH_EXTRA_MARGIN(buf_pool)) | 114 | + BUF_FLUSH_EXTRA_MARGIN(buf_pool)) |
1811 | 115 | && (distance < BUF_LRU_FREE_SEARCH_LEN(buf_pool))) { | 115 | && (distance < BUF_LRU_FREE_SEARCH_LEN(buf_pool))) { |
1812 | 116 | 116 | ||
1813 | @@ -125,7 +125,7 @@ | |||
1814 | 125 | 125 | ||
1815 | 126 | mutex_enter(block_mutex); | 126 | mutex_enter(block_mutex); |
1816 | 127 | 127 | ||
1818 | 128 | @@ -2012,11 +2027,18 @@ | 128 | @@ -2076,11 +2091,18 @@ |
1819 | 129 | bpage = UT_LIST_GET_PREV(LRU, bpage); | 129 | bpage = UT_LIST_GET_PREV(LRU, bpage); |
1820 | 130 | } | 130 | } |
1821 | 131 | 131 | ||
1822 | @@ -145,7 +145,7 @@ | |||
1823 | 145 | } | 145 | } |
1824 | 146 | 146 | ||
1825 | 147 | return(BUF_FLUSH_FREE_BLOCK_MARGIN(buf_pool) | 147 | return(BUF_FLUSH_FREE_BLOCK_MARGIN(buf_pool) |
1827 | 148 | @@ -2034,7 +2056,8 @@ | 148 | @@ -2098,7 +2120,8 @@ |
1828 | 149 | void | 149 | void |
1829 | 150 | buf_flush_free_margin( | 150 | buf_flush_free_margin( |
1830 | 151 | /*==================*/ | 151 | /*==================*/ |
1831 | @@ -155,7 +155,7 @@ | |||
1832 | 155 | { | 155 | { |
1833 | 156 | ulint n_to_flush; | 156 | ulint n_to_flush; |
1834 | 157 | 157 | ||
1836 | 158 | @@ -2045,7 +2068,7 @@ | 158 | @@ -2109,7 +2132,7 @@ |
1837 | 159 | 159 | ||
1838 | 160 | n_flushed = buf_flush_LRU(buf_pool, n_to_flush); | 160 | n_flushed = buf_flush_LRU(buf_pool, n_to_flush); |
1839 | 161 | 161 | ||
1840 | @@ -164,7 +164,7 @@ | |||
1841 | 164 | /* There was an LRU type flush batch already running; | 164 | /* There was an LRU type flush batch already running; |
1842 | 165 | let us wait for it to end */ | 165 | let us wait for it to end */ |
1843 | 166 | 166 | ||
1845 | 167 | @@ -2058,8 +2081,9 @@ | 167 | @@ -2122,8 +2145,9 @@ |
1846 | 168 | Flushes pages from the end of all the LRU lists. */ | 168 | Flushes pages from the end of all the LRU lists. */ |
1847 | 169 | UNIV_INTERN | 169 | UNIV_INTERN |
1848 | 170 | void | 170 | void |
1849 | @@ -175,7 +175,7 @@ | |||
1850 | 175 | { | 175 | { |
1851 | 176 | ulint i; | 176 | ulint i; |
1852 | 177 | 177 | ||
1854 | 178 | @@ -2068,7 +2092,7 @@ | 178 | @@ -2132,7 +2156,7 @@ |
1855 | 179 | 179 | ||
1856 | 180 | buf_pool = buf_pool_from_array(i); | 180 | buf_pool = buf_pool_from_array(i); |
1857 | 181 | 181 | ||
1858 | @@ -186,7 +186,7 @@ | |||
1859 | 186 | 186 | ||
1860 | 187 | --- a/storage/innobase/buf/buf0lru.c | 187 | --- a/storage/innobase/buf/buf0lru.c |
1861 | 188 | +++ b/storage/innobase/buf/buf0lru.c | 188 | +++ b/storage/innobase/buf/buf0lru.c |
1863 | 189 | @@ -923,7 +923,7 @@ | 189 | @@ -934,7 +934,7 @@ |
1864 | 190 | 190 | ||
1865 | 191 | /* No free block was found: try to flush the LRU list */ | 191 | /* No free block was found: try to flush the LRU list */ |
1866 | 192 | 192 | ||
1867 | @@ -195,7 +195,7 @@ | |||
1868 | 195 | ++srv_buf_pool_wait_free; | 195 | ++srv_buf_pool_wait_free; |
1869 | 196 | 196 | ||
1870 | 197 | os_aio_simulated_wake_handler_threads(); | 197 | os_aio_simulated_wake_handler_threads(); |
1872 | 198 | @@ -1120,7 +1120,7 @@ | 198 | @@ -1131,7 +1131,7 @@ |
1873 | 199 | 199 | ||
1874 | 200 | /* Remove the block from the LRU list */ | 200 | /* Remove the block from the LRU list */ |
1875 | 201 | UT_LIST_REMOVE(LRU, buf_pool->LRU, bpage); | 201 | UT_LIST_REMOVE(LRU, buf_pool->LRU, bpage); |
1876 | @@ -204,7 +204,7 @@ | |||
1877 | 204 | 204 | ||
1878 | 205 | buf_unzip_LRU_remove_block_if_needed(bpage); | 205 | buf_unzip_LRU_remove_block_if_needed(bpage); |
1879 | 206 | 206 | ||
1881 | 207 | @@ -1199,7 +1199,7 @@ | 207 | @@ -1210,7 +1210,7 @@ |
1882 | 208 | 208 | ||
1883 | 209 | ut_ad(!bpage->in_LRU_list); | 209 | ut_ad(!bpage->in_LRU_list); |
1884 | 210 | UT_LIST_ADD_LAST(LRU, buf_pool->LRU, bpage); | 210 | UT_LIST_ADD_LAST(LRU, buf_pool->LRU, bpage); |
1885 | @@ -213,7 +213,7 @@ | |||
1886 | 213 | 213 | ||
1887 | 214 | if (UT_LIST_GET_LEN(buf_pool->LRU) > BUF_LRU_OLD_MIN_LEN) { | 214 | if (UT_LIST_GET_LEN(buf_pool->LRU) > BUF_LRU_OLD_MIN_LEN) { |
1888 | 215 | 215 | ||
1890 | 216 | @@ -1269,7 +1269,7 @@ | 216 | @@ -1280,7 +1280,7 @@ |
1891 | 217 | buf_pool->LRU_old_len++; | 217 | buf_pool->LRU_old_len++; |
1892 | 218 | } | 218 | } |
1893 | 219 | 219 | ||
1894 | @@ -222,7 +222,7 @@ | |||
1895 | 222 | 222 | ||
1896 | 223 | if (UT_LIST_GET_LEN(buf_pool->LRU) > BUF_LRU_OLD_MIN_LEN) { | 223 | if (UT_LIST_GET_LEN(buf_pool->LRU) > BUF_LRU_OLD_MIN_LEN) { |
1897 | 224 | 224 | ||
1899 | 225 | @@ -1513,7 +1513,7 @@ | 225 | @@ -1524,7 +1524,7 @@ |
1900 | 226 | buf_page_set_old(b, buf_page_is_old(b)); | 226 | buf_page_set_old(b, buf_page_is_old(b)); |
1901 | 227 | #endif /* UNIV_LRU_DEBUG */ | 227 | #endif /* UNIV_LRU_DEBUG */ |
1902 | 228 | } else { | 228 | } else { |
1903 | @@ -271,7 +271,7 @@ | |||
1904 | 271 | if (buf_debug_prints) { | 271 | if (buf_debug_prints) { |
1905 | 272 | --- a/storage/innobase/include/buf0buf.h | 272 | --- a/storage/innobase/include/buf0buf.h |
1906 | 273 | +++ b/storage/innobase/include/buf0buf.h | 273 | +++ b/storage/innobase/include/buf0buf.h |
1908 | 274 | @@ -1404,11 +1404,11 @@ | 274 | @@ -1424,11 +1424,11 @@ |
1909 | 275 | 275 | ||
1910 | 276 | UT_LIST_NODE_T(buf_page_t) LRU; | 276 | UT_LIST_NODE_T(buf_page_t) LRU; |
1911 | 277 | /*!< node of the LRU list */ | 277 | /*!< node of the LRU list */ |
1912 | 278 | 278 | ||
1913 | === modified file 'patches/innodb_overwrite_relay_log_info.patch' | |||
1914 | --- patches/innodb_overwrite_relay_log_info.patch 2011-12-27 15:32:16 +0000 | |||
1915 | +++ patches/innodb_overwrite_relay_log_info.patch 2012-02-06 05:02:26 +0000 | |||
1916 | @@ -248,7 +248,7 @@ | |||
1917 | 248 | 248 | ||
1918 | 249 | trx_commit_for_mysql(trx); | 249 | trx_commit_for_mysql(trx); |
1919 | 250 | } | 250 | } |
1921 | 251 | @@ -11131,6 +11323,12 @@ | 251 | @@ -11130,6 +11322,12 @@ |
1922 | 252 | "The common part for InnoDB table spaces.", | 252 | "The common part for InnoDB table spaces.", |
1923 | 253 | NULL, NULL, NULL); | 253 | NULL, NULL, NULL); |
1924 | 254 | 254 | ||
1925 | @@ -261,7 +261,7 @@ | |||
1926 | 261 | static MYSQL_SYSVAR_BOOL(doublewrite, innobase_use_doublewrite, | 261 | static MYSQL_SYSVAR_BOOL(doublewrite, innobase_use_doublewrite, |
1927 | 262 | PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY, | 262 | PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY, |
1928 | 263 | "Enable InnoDB doublewrite buffer (enabled by default). " | 263 | "Enable InnoDB doublewrite buffer (enabled by default). " |
1930 | 264 | @@ -11608,6 +11806,7 @@ | 264 | @@ -11647,6 +11845,7 @@ |
1931 | 265 | MYSQL_SYSVAR(old_blocks_pct), | 265 | MYSQL_SYSVAR(old_blocks_pct), |
1932 | 266 | MYSQL_SYSVAR(old_blocks_time), | 266 | MYSQL_SYSVAR(old_blocks_time), |
1933 | 267 | MYSQL_SYSVAR(open_files), | 267 | MYSQL_SYSVAR(open_files), |
1934 | 268 | 268 | ||
1935 | === modified file 'patches/innodb_pass_corrupt_table.patch' | |||
1936 | --- patches/innodb_pass_corrupt_table.patch 2012-01-10 11:28:15 +0000 | |||
1937 | +++ patches/innodb_pass_corrupt_table.patch 2012-02-06 05:02:26 +0000 | |||
1938 | @@ -338,7 +338,7 @@ | |||
1939 | 338 | if (!ready) { | 338 | if (!ready) { |
1940 | 339 | 339 | ||
1941 | 340 | return(block); | 340 | return(block); |
1943 | 341 | @@ -1945,6 +1951,13 @@ | 341 | @@ -1947,6 +1953,13 @@ |
1944 | 342 | return(NULL); | 342 | return(NULL); |
1945 | 343 | } | 343 | } |
1946 | 344 | 344 | ||
1947 | @@ -352,7 +352,7 @@ | |||
1948 | 352 | block_mutex = buf_page_get_mutex_enter(bpage); | 352 | block_mutex = buf_page_get_mutex_enter(bpage); |
1949 | 353 | 353 | ||
1950 | 354 | rw_lock_s_unlock(&buf_pool->page_hash_latch); | 354 | rw_lock_s_unlock(&buf_pool->page_hash_latch); |
1952 | 355 | @@ -2524,6 +2537,13 @@ | 355 | @@ -2526,6 +2539,13 @@ |
1953 | 356 | return(NULL); | 356 | return(NULL); |
1954 | 357 | } | 357 | } |
1955 | 358 | 358 | ||
1956 | @@ -366,7 +366,7 @@ | |||
1957 | 366 | switch (buf_block_get_state(block)) { | 366 | switch (buf_block_get_state(block)) { |
1958 | 367 | buf_page_t* bpage; | 367 | buf_page_t* bpage; |
1959 | 368 | ibool success; | 368 | ibool success; |
1961 | 369 | @@ -3198,6 +3218,7 @@ | 369 | @@ -3200,6 +3220,7 @@ |
1962 | 370 | bpage->newest_modification = 0; | 370 | bpage->newest_modification = 0; |
1963 | 371 | bpage->oldest_modification = 0; | 371 | bpage->oldest_modification = 0; |
1964 | 372 | HASH_INVALIDATE(bpage, hash); | 372 | HASH_INVALIDATE(bpage, hash); |
1965 | @@ -374,7 +374,7 @@ | |||
1966 | 374 | #if defined UNIV_DEBUG_FILE_ACCESSES || defined UNIV_DEBUG | 374 | #if defined UNIV_DEBUG_FILE_ACCESSES || defined UNIV_DEBUG |
1967 | 375 | bpage->file_page_was_freed = FALSE; | 375 | bpage->file_page_was_freed = FALSE; |
1968 | 376 | #endif /* UNIV_DEBUG_FILE_ACCESSES || UNIV_DEBUG */ | 376 | #endif /* UNIV_DEBUG_FILE_ACCESSES || UNIV_DEBUG */ |
1970 | 377 | @@ -3836,6 +3857,7 @@ | 377 | @@ -3838,6 +3859,7 @@ |
1971 | 378 | (ulong) bpage->offset); | 378 | (ulong) bpage->offset); |
1972 | 379 | } | 379 | } |
1973 | 380 | 380 | ||
1974 | @@ -382,7 +382,7 @@ | |||
1975 | 382 | /* From version 3.23.38 up we store the page checksum | 382 | /* From version 3.23.38 up we store the page checksum |
1976 | 383 | to the 4 first bytes of the page end lsn field */ | 383 | to the 4 first bytes of the page end lsn field */ |
1977 | 384 | 384 | ||
1979 | 385 | @@ -3877,6 +3899,23 @@ | 385 | @@ -3879,6 +3901,23 @@ |
1980 | 386 | REFMAN "forcing-innodb-recovery.html\n" | 386 | REFMAN "forcing-innodb-recovery.html\n" |
1981 | 387 | "InnoDB: about forcing recovery.\n", stderr); | 387 | "InnoDB: about forcing recovery.\n", stderr); |
1982 | 388 | 388 | ||
1983 | @@ -406,7 +406,7 @@ | |||
1984 | 406 | if (srv_force_recovery < SRV_FORCE_IGNORE_CORRUPT) { | 406 | if (srv_force_recovery < SRV_FORCE_IGNORE_CORRUPT) { |
1985 | 407 | /* If page space id is larger than TRX_SYS_SPACE | 407 | /* If page space id is larger than TRX_SYS_SPACE |
1986 | 408 | (0), we will attempt to mark the corresponding | 408 | (0), we will attempt to mark the corresponding |
1988 | 409 | @@ -3893,6 +3932,7 @@ | 409 | @@ -3895,6 +3934,7 @@ |
1989 | 410 | } | 410 | } |
1990 | 411 | } | 411 | } |
1991 | 412 | } | 412 | } |
1992 | @@ -414,7 +414,7 @@ | |||
1993 | 414 | 414 | ||
1994 | 415 | if (recv_recovery_is_on()) { | 415 | if (recv_recovery_is_on()) { |
1995 | 416 | /* Pages must be uncompressed for crash recovery. */ | 416 | /* Pages must be uncompressed for crash recovery. */ |
1997 | 417 | @@ -3902,8 +3942,11 @@ | 417 | @@ -3904,8 +3944,11 @@ |
1998 | 418 | 418 | ||
1999 | 419 | if (uncompressed && !recv_no_ibuf_operations) { | 419 | if (uncompressed && !recv_no_ibuf_operations) { |
2000 | 420 | ibuf_merge_or_delete_for_page( | 420 | ibuf_merge_or_delete_for_page( |
2001 | @@ -462,7 +462,7 @@ | |||
2002 | 462 | /* If table->ibd_file_missing == TRUE, this will | 462 | /* If table->ibd_file_missing == TRUE, this will |
2003 | 463 | print an error message and return without doing | 463 | print an error message and return without doing |
2004 | 464 | anything. */ | 464 | anything. */ |
2006 | 465 | @@ -1293,7 +1294,7 @@ | 465 | @@ -1298,7 +1299,7 @@ |
2007 | 466 | + dict_sys->size) > srv_dict_size_limit ) { | 466 | + dict_sys->size) > srv_dict_size_limit ) { |
2008 | 467 | prev_table = UT_LIST_GET_PREV(table_LRU, table); | 467 | prev_table = UT_LIST_GET_PREV(table_LRU, table); |
2009 | 468 | 468 | ||
2010 | @@ -471,7 +471,7 @@ | |||
2011 | 471 | goto next_loop; | 471 | goto next_loop; |
2012 | 472 | 472 | ||
2013 | 473 | cached_foreign_tables = 0; | 473 | cached_foreign_tables = 0; |
2015 | 474 | @@ -4367,6 +4368,12 @@ | 474 | @@ -4377,6 +4378,12 @@ |
2016 | 475 | heap = mem_heap_create(1000); | 475 | heap = mem_heap_create(1000); |
2017 | 476 | 476 | ||
2018 | 477 | while (index) { | 477 | while (index) { |
2019 | @@ -484,7 +484,7 @@ | |||
2020 | 484 | size = btr_get_size(index, BTR_TOTAL_SIZE); | 484 | size = btr_get_size(index, BTR_TOTAL_SIZE); |
2021 | 485 | 485 | ||
2022 | 486 | index->stat_index_size = size; | 486 | index->stat_index_size = size; |
2024 | 487 | @@ -4514,6 +4521,12 @@ | 487 | @@ -4524,6 +4531,12 @@ |
2025 | 488 | heap = mem_heap_create(1000); | 488 | heap = mem_heap_create(1000); |
2026 | 489 | 489 | ||
2027 | 490 | while (index) { | 490 | while (index) { |
2028 | @@ -497,7 +497,7 @@ | |||
2029 | 497 | /*===========================================*/ | 497 | /*===========================================*/ |
2030 | 498 | { | 498 | { |
2031 | 499 | dict_table_t* sys_stats; | 499 | dict_table_t* sys_stats; |
2033 | 500 | @@ -4706,6 +4719,13 @@ | 500 | @@ -4716,6 +4729,13 @@ |
2034 | 501 | || (srv_force_recovery < SRV_FORCE_NO_LOG_REDO | 501 | || (srv_force_recovery < SRV_FORCE_NO_LOG_REDO |
2035 | 502 | && dict_index_is_clust(index)))) { | 502 | && dict_index_is_clust(index)))) { |
2036 | 503 | ulint size; | 503 | ulint size; |
2037 | @@ -511,7 +511,7 @@ | |||
2038 | 511 | size = btr_get_size(index, BTR_TOTAL_SIZE); | 511 | size = btr_get_size(index, BTR_TOTAL_SIZE); |
2039 | 512 | 512 | ||
2040 | 513 | index->stat_index_size = size; | 513 | index->stat_index_size = size; |
2042 | 514 | @@ -5685,4 +5705,42 @@ | 514 | @@ -5695,4 +5715,42 @@ |
2043 | 515 | 515 | ||
2044 | 516 | index->type |= DICT_CORRUPT; | 516 | index->type |= DICT_CORRUPT; |
2045 | 517 | } | 517 | } |
2046 | @@ -584,7 +584,7 @@ | |||
2047 | 584 | UT_LIST_ADD_LAST(space_list, fil_system->space_list, space); | 584 | UT_LIST_ADD_LAST(space_list, fil_system->space_list, space); |
2048 | 585 | 585 | ||
2049 | 586 | mutex_exit(&fil_system->mutex); | 586 | mutex_exit(&fil_system->mutex); |
2051 | 587 | @@ -5277,6 +5280,34 @@ | 587 | @@ -5285,6 +5288,34 @@ |
2052 | 588 | ut_a(byte_offset % OS_FILE_LOG_BLOCK_SIZE == 0); | 588 | ut_a(byte_offset % OS_FILE_LOG_BLOCK_SIZE == 0); |
2053 | 589 | ut_a((len % OS_FILE_LOG_BLOCK_SIZE) == 0); | 589 | ut_a((len % OS_FILE_LOG_BLOCK_SIZE) == 0); |
2054 | 590 | 590 | ||
2055 | @@ -619,7 +619,7 @@ | |||
2056 | 619 | #ifdef UNIV_HOTBACKUP | 619 | #ifdef UNIV_HOTBACKUP |
2057 | 620 | /* In ibbackup do normal i/o, not aio */ | 620 | /* In ibbackup do normal i/o, not aio */ |
2058 | 621 | if (type == OS_FILE_READ) { | 621 | if (type == OS_FILE_READ) { |
2060 | 622 | @@ -5291,6 +5322,8 @@ | 622 | @@ -5299,6 +5330,8 @@ |
2061 | 623 | ret = os_aio(type, mode | wake_later, node->name, node->handle, buf, | 623 | ret = os_aio(type, mode | wake_later, node->name, node->handle, buf, |
2062 | 624 | offset_low, offset_high, len, node, message, trx); | 624 | offset_low, offset_high, len, node, message, trx); |
2063 | 625 | #endif | 625 | #endif |
2064 | @@ -628,7 +628,7 @@ | |||
2065 | 628 | ut_a(ret); | 628 | ut_a(ret); |
2066 | 629 | 629 | ||
2067 | 630 | if (mode == OS_AIO_SYNC) { | 630 | if (mode == OS_AIO_SYNC) { |
2069 | 631 | @@ -5791,3 +5824,46 @@ | 631 | @@ -5799,3 +5832,46 @@ |
2070 | 632 | return 0; | 632 | return 0; |
2071 | 633 | } | 633 | } |
2072 | 634 | } | 634 | } |
2073 | @@ -677,7 +677,7 @@ | |||
2074 | 677 | + | 677 | + |
2075 | 678 | --- a/storage/innobase/fsp/fsp0fsp.c | 678 | --- a/storage/innobase/fsp/fsp0fsp.c |
2076 | 679 | +++ b/storage/innobase/fsp/fsp0fsp.c | 679 | +++ b/storage/innobase/fsp/fsp0fsp.c |
2078 | 680 | @@ -369,6 +369,12 @@ | 680 | @@ -308,6 +308,12 @@ |
2079 | 681 | ut_ad(id || !zip_size); | 681 | ut_ad(id || !zip_size); |
2080 | 682 | 682 | ||
2081 | 683 | block = buf_page_get(id, zip_size, 0, RW_X_LATCH, mtr); | 683 | block = buf_page_get(id, zip_size, 0, RW_X_LATCH, mtr); |
2082 | @@ -690,7 +690,7 @@ | |||
2083 | 690 | header = FSP_HEADER_OFFSET + buf_block_get_frame(block); | 690 | header = FSP_HEADER_OFFSET + buf_block_get_frame(block); |
2084 | 691 | buf_block_dbg_add_level(block, SYNC_FSP_PAGE); | 691 | buf_block_dbg_add_level(block, SYNC_FSP_PAGE); |
2085 | 692 | 692 | ||
2087 | 693 | @@ -787,6 +793,12 @@ | 693 | @@ -726,6 +732,12 @@ |
2088 | 694 | fsp_header_t* sp_header; | 694 | fsp_header_t* sp_header; |
2089 | 695 | 695 | ||
2090 | 696 | block = buf_page_get(space, zip_size, 0, RW_X_LATCH, mtr); | 696 | block = buf_page_get(space, zip_size, 0, RW_X_LATCH, mtr); |
2091 | @@ -703,7 +703,7 @@ | |||
2092 | 703 | buf_block_dbg_add_level(block, SYNC_FSP_PAGE); | 703 | buf_block_dbg_add_level(block, SYNC_FSP_PAGE); |
2093 | 704 | 704 | ||
2094 | 705 | sp_header = FSP_HEADER_OFFSET + buf_block_get_frame(block); | 705 | sp_header = FSP_HEADER_OFFSET + buf_block_get_frame(block); |
2096 | 706 | @@ -1866,6 +1878,11 @@ | 706 | @@ -1805,6 +1817,11 @@ |
2097 | 707 | { | 707 | { |
2098 | 708 | fseg_inode_t* inode; | 708 | fseg_inode_t* inode; |
2099 | 709 | 709 | ||
2100 | @@ -715,7 +715,7 @@ | |||
2101 | 715 | for (; i < FSP_SEG_INODES_PER_PAGE(zip_size); i++) { | 715 | for (; i < FSP_SEG_INODES_PER_PAGE(zip_size); i++) { |
2102 | 716 | 716 | ||
2103 | 717 | inode = fsp_seg_inode_page_get_nth_inode( | 717 | inode = fsp_seg_inode_page_get_nth_inode( |
2105 | 718 | @@ -1979,6 +1996,11 @@ | 718 | @@ -1918,6 +1935,11 @@ |
2106 | 719 | 719 | ||
2107 | 720 | page = buf_block_get_frame(block); | 720 | page = buf_block_get_frame(block); |
2108 | 721 | 721 | ||
2109 | @@ -727,7 +727,7 @@ | |||
2110 | 727 | n = fsp_seg_inode_page_find_free(page, 0, zip_size, mtr); | 727 | n = fsp_seg_inode_page_find_free(page, 0, zip_size, mtr); |
2111 | 728 | 728 | ||
2112 | 729 | ut_a(n != ULINT_UNDEFINED); | 729 | ut_a(n != ULINT_UNDEFINED); |
2114 | 730 | @@ -2072,6 +2094,11 @@ | 730 | @@ -2011,6 +2033,11 @@ |
2115 | 731 | 731 | ||
2116 | 732 | inode = fut_get_ptr(space, zip_size, inode_addr, RW_X_LATCH, mtr); | 732 | inode = fut_get_ptr(space, zip_size, inode_addr, RW_X_LATCH, mtr); |
2117 | 733 | 733 | ||
2118 | @@ -739,7 +739,7 @@ | |||
2119 | 739 | if (UNIV_UNLIKELY(!mach_read_from_8(inode + FSEG_ID))) { | 739 | if (UNIV_UNLIKELY(!mach_read_from_8(inode + FSEG_ID))) { |
2120 | 740 | 740 | ||
2121 | 741 | inode = NULL; | 741 | inode = NULL; |
2123 | 742 | @@ -2098,7 +2125,7 @@ | 742 | @@ -2037,7 +2064,7 @@ |
2124 | 743 | { | 743 | { |
2125 | 744 | fseg_inode_t* inode | 744 | fseg_inode_t* inode |
2126 | 745 | = fseg_inode_try_get(header, space, zip_size, mtr); | 745 | = fseg_inode_try_get(header, space, zip_size, mtr); |
2127 | @@ -748,7 +748,7 @@ | |||
2128 | 748 | return(inode); | 748 | return(inode); |
2129 | 749 | } | 749 | } |
2130 | 750 | 750 | ||
2132 | 751 | @@ -3304,6 +3331,11 @@ | 751 | @@ -3243,6 +3270,11 @@ |
2133 | 752 | 752 | ||
2134 | 753 | descr = xdes_get_descriptor(space, zip_size, page, mtr); | 753 | descr = xdes_get_descriptor(space, zip_size, page, mtr); |
2135 | 754 | 754 | ||
2136 | @@ -760,7 +760,7 @@ | |||
2137 | 760 | ut_a(descr); | 760 | ut_a(descr); |
2138 | 761 | if (xdes_get_bit(descr, XDES_FREE_BIT, page % FSP_EXTENT_SIZE, mtr)) { | 761 | if (xdes_get_bit(descr, XDES_FREE_BIT, page % FSP_EXTENT_SIZE, mtr)) { |
2139 | 762 | fputs("InnoDB: Dump of the tablespace extent descriptor: ", | 762 | fputs("InnoDB: Dump of the tablespace extent descriptor: ", |
2141 | 763 | @@ -3551,6 +3583,11 @@ | 763 | @@ -3490,6 +3522,11 @@ |
2142 | 764 | 764 | ||
2143 | 765 | descr = xdes_get_descriptor(space, zip_size, header_page, mtr); | 765 | descr = xdes_get_descriptor(space, zip_size, header_page, mtr); |
2144 | 766 | 766 | ||
2145 | @@ -772,7 +772,7 @@ | |||
2146 | 772 | /* Check that the header resides on a page which has not been | 772 | /* Check that the header resides on a page which has not been |
2147 | 773 | freed yet */ | 773 | freed yet */ |
2148 | 774 | 774 | ||
2150 | 775 | @@ -3635,6 +3672,12 @@ | 775 | @@ -3574,6 +3611,12 @@ |
2151 | 776 | 776 | ||
2152 | 777 | inode = fseg_inode_get(header, space, zip_size, mtr); | 777 | inode = fseg_inode_get(header, space, zip_size, mtr); |
2153 | 778 | 778 | ||
2154 | @@ -908,7 +908,7 @@ | |||
2155 | 908 | switch (ret) { | 908 | switch (ret) { |
2156 | 909 | case DB_SUCCESS: | 909 | case DB_SUCCESS: |
2157 | 910 | error = 0; | 910 | error = 0; |
2159 | 911 | @@ -6137,6 +6188,10 @@ | 911 | @@ -6136,6 +6187,10 @@ |
2160 | 912 | { | 912 | { |
2161 | 913 | DBUG_ENTER("change_active_index"); | 913 | DBUG_ENTER("change_active_index"); |
2162 | 914 | 914 | ||
2163 | @@ -919,7 +919,7 @@ | |||
2164 | 919 | ut_ad(user_thd == ha_thd()); | 919 | ut_ad(user_thd == ha_thd()); |
2165 | 920 | ut_a(prebuilt->trx == thd_to_trx(user_thd)); | 920 | ut_a(prebuilt->trx == thd_to_trx(user_thd)); |
2166 | 921 | 921 | ||
2168 | 922 | @@ -6250,6 +6305,10 @@ | 922 | @@ -6249,6 +6304,10 @@ |
2169 | 923 | 923 | ||
2170 | 924 | DBUG_ENTER("general_fetch"); | 924 | DBUG_ENTER("general_fetch"); |
2171 | 925 | 925 | ||
2172 | @@ -930,7 +930,7 @@ | |||
2173 | 930 | ut_a(prebuilt->trx == thd_to_trx(user_thd)); | 930 | ut_a(prebuilt->trx == thd_to_trx(user_thd)); |
2174 | 931 | 931 | ||
2175 | 932 | innodb_srv_conc_enter_innodb(prebuilt->trx); | 932 | innodb_srv_conc_enter_innodb(prebuilt->trx); |
2177 | 933 | @@ -6259,6 +6318,10 @@ | 933 | @@ -6258,6 +6317,10 @@ |
2178 | 934 | 934 | ||
2179 | 935 | innodb_srv_conc_exit_innodb(prebuilt->trx); | 935 | innodb_srv_conc_exit_innodb(prebuilt->trx); |
2180 | 936 | 936 | ||
2181 | @@ -941,7 +941,7 @@ | |||
2182 | 941 | switch (ret) { | 941 | switch (ret) { |
2183 | 942 | case DB_SUCCESS: | 942 | case DB_SUCCESS: |
2184 | 943 | error = 0; | 943 | error = 0; |
2186 | 944 | @@ -7525,10 +7588,18 @@ | 944 | @@ -7524,10 +7587,18 @@ |
2187 | 945 | 945 | ||
2188 | 946 | update_thd(ha_thd()); | 946 | update_thd(ha_thd()); |
2189 | 947 | 947 | ||
2190 | @@ -960,7 +960,7 @@ | |||
2191 | 960 | error = convert_error_code_to_mysql(error, prebuilt->table->flags, | 960 | error = convert_error_code_to_mysql(error, prebuilt->table->flags, |
2192 | 961 | NULL); | 961 | NULL); |
2193 | 962 | 962 | ||
2195 | 963 | @@ -8040,6 +8111,16 @@ | 963 | @@ -8039,6 +8110,16 @@ |
2196 | 964 | return(ranges + (double) rows / (double) total_rows * time_for_scan); | 964 | return(ranges + (double) rows / (double) total_rows * time_for_scan); |
2197 | 965 | } | 965 | } |
2198 | 966 | 966 | ||
2199 | @@ -977,7 +977,7 @@ | |||
2200 | 977 | /*********************************************************************//** | 977 | /*********************************************************************//** |
2201 | 978 | Calculates the key number used inside MySQL for an Innobase index. We will | 978 | Calculates the key number used inside MySQL for an Innobase index. We will |
2202 | 979 | first check the "index translation table" for a match of the index to get | 979 | first check the "index translation table" for a match of the index to get |
2204 | 980 | @@ -8217,7 +8298,7 @@ | 980 | @@ -8216,7 +8297,7 @@ |
2205 | 981 | ib_table = prebuilt->table; | 981 | ib_table = prebuilt->table; |
2206 | 982 | 982 | ||
2207 | 983 | if (flag & HA_STATUS_TIME) { | 983 | if (flag & HA_STATUS_TIME) { |
2208 | @@ -986,7 +986,7 @@ | |||
2209 | 986 | /* In sql_show we call with this flag: update | 986 | /* In sql_show we call with this flag: update |
2210 | 987 | then statistics so that they are up-to-date */ | 987 | then statistics so that they are up-to-date */ |
2211 | 988 | 988 | ||
2213 | 989 | @@ -8517,10 +8598,18 @@ | 989 | @@ -8516,10 +8597,18 @@ |
2214 | 990 | THD* thd, /*!< in: connection thread handle */ | 990 | THD* thd, /*!< in: connection thread handle */ |
2215 | 991 | HA_CHECK_OPT* check_opt) /*!< in: currently ignored */ | 991 | HA_CHECK_OPT* check_opt) /*!< in: currently ignored */ |
2216 | 992 | { | 992 | { |
2217 | @@ -1005,7 +1005,7 @@ | |||
2218 | 1005 | return(0); | 1005 | return(0); |
2219 | 1006 | } | 1006 | } |
2220 | 1007 | 1007 | ||
2222 | 1008 | @@ -8756,6 +8845,10 @@ | 1008 | @@ -8755,6 +8844,10 @@ |
2223 | 1009 | my_error(ER_QUERY_INTERRUPTED, MYF(0)); | 1009 | my_error(ER_QUERY_INTERRUPTED, MYF(0)); |
2224 | 1010 | } | 1010 | } |
2225 | 1011 | 1011 | ||
2226 | @@ -1016,7 +1016,7 @@ | |||
2227 | 1016 | DBUG_RETURN(is_ok ? HA_ADMIN_OK : HA_ADMIN_CORRUPT); | 1016 | DBUG_RETURN(is_ok ? HA_ADMIN_OK : HA_ADMIN_CORRUPT); |
2228 | 1017 | } | 1017 | } |
2229 | 1018 | 1018 | ||
2231 | 1019 | @@ -9526,6 +9619,10 @@ | 1019 | @@ -9525,6 +9618,10 @@ |
2232 | 1020 | 1020 | ||
2233 | 1021 | update_thd(thd); | 1021 | update_thd(thd); |
2234 | 1022 | 1022 | ||
2235 | @@ -1027,7 +1027,7 @@ | |||
2236 | 1027 | if (prebuilt->table->ibd_file_missing && !thd_tablespace_op(thd)) { | 1027 | if (prebuilt->table->ibd_file_missing && !thd_tablespace_op(thd)) { |
2237 | 1028 | ut_print_timestamp(stderr); | 1028 | ut_print_timestamp(stderr); |
2238 | 1029 | fprintf(stderr, | 1029 | fprintf(stderr, |
2240 | 1030 | @@ -11990,6 +12087,26 @@ | 1030 | @@ -11989,6 +12086,26 @@ |
2241 | 1031 | "dump file (if present). Disabled by default.", | 1031 | "dump file (if present). Disabled by default.", |
2242 | 1032 | NULL, NULL, FALSE); | 1032 | NULL, NULL, FALSE); |
2243 | 1033 | 1033 | ||
2244 | @@ -1054,7 +1054,7 @@ | |||
2245 | 1054 | static struct st_mysql_sys_var* innobase_system_variables[]= { | 1054 | static struct st_mysql_sys_var* innobase_system_variables[]= { |
2246 | 1055 | MYSQL_SYSVAR(additional_mem_pool_size), | 1055 | MYSQL_SYSVAR(additional_mem_pool_size), |
2247 | 1056 | MYSQL_SYSVAR(autoextend_increment), | 1056 | MYSQL_SYSVAR(autoextend_increment), |
2249 | 1057 | @@ -12083,6 +12200,7 @@ | 1057 | @@ -12082,6 +12199,7 @@ |
2250 | 1058 | #ifdef UNIV_DEBUG | 1058 | #ifdef UNIV_DEBUG |
2251 | 1059 | MYSQL_SYSVAR(flush_checkpoint_debug), | 1059 | MYSQL_SYSVAR(flush_checkpoint_debug), |
2252 | 1060 | #endif | 1060 | #endif |
2253 | @@ -1104,7 +1104,7 @@ | |||
2254 | 1104 | block, index != NULL && dict_index_is_ibuf(index) | 1104 | block, index != NULL && dict_index_is_ibuf(index) |
2255 | 1105 | --- a/storage/innobase/include/buf0buf.h | 1105 | --- a/storage/innobase/include/buf0buf.h |
2256 | 1106 | +++ b/storage/innobase/include/buf0buf.h | 1106 | +++ b/storage/innobase/include/buf0buf.h |
2258 | 1107 | @@ -1003,7 +1003,7 @@ | 1107 | @@ -1023,7 +1023,7 @@ |
2259 | 1108 | const buf_block_t* block) /*!< in: pointer to the control block */ | 1108 | const buf_block_t* block) /*!< in: pointer to the control block */ |
2260 | 1109 | __attribute__((pure)); | 1109 | __attribute__((pure)); |
2261 | 1110 | #else /* UNIV_DEBUG */ | 1110 | #else /* UNIV_DEBUG */ |
2262 | @@ -1113,7 +1113,7 @@ | |||
2263 | 1113 | #endif /* UNIV_DEBUG */ | 1113 | #endif /* UNIV_DEBUG */ |
2264 | 1114 | /*********************************************************************//** | 1114 | /*********************************************************************//** |
2265 | 1115 | Gets the space id of a block. | 1115 | Gets the space id of a block. |
2267 | 1116 | @@ -1450,6 +1450,7 @@ | 1116 | @@ -1470,6 +1470,7 @@ |
2268 | 1117 | 0 if the block was never accessed | 1117 | 0 if the block was never accessed |
2269 | 1118 | in the buffer pool */ | 1118 | in the buffer pool */ |
2270 | 1119 | /* @} */ | 1119 | /* @} */ |
2271 | @@ -1132,7 +1132,7 @@ | |||
2272 | 1132 | /*********************************************************************//** | 1132 | /*********************************************************************//** |
2273 | 1133 | Gets the current size of buffer buf_pool in bytes. | 1133 | Gets the current size of buffer buf_pool in bytes. |
2274 | 1134 | @return size in bytes */ | 1134 | @return size in bytes */ |
2276 | 1135 | @@ -637,6 +637,12 @@ | 1135 | @@ -681,6 +681,12 @@ |
2277 | 1136 | /*================*/ | 1136 | /*================*/ |
2278 | 1137 | const buf_block_t* block) /*!< in: pointer to the control block */ | 1137 | const buf_block_t* block) /*!< in: pointer to the control block */ |
2279 | 1138 | { | 1138 | { |
2280 | @@ -1175,7 +1175,7 @@ | |||
2281 | 1175 | #ifdef UNIV_DEBUG | 1175 | #ifdef UNIV_DEBUG |
2282 | 1176 | --- a/storage/innobase/include/fil0fil.h | 1176 | --- a/storage/innobase/include/fil0fil.h |
2283 | 1177 | +++ b/storage/innobase/include/fil0fil.h | 1177 | +++ b/storage/innobase/include/fil0fil.h |
2285 | 1178 | @@ -754,6 +754,19 @@ | 1178 | @@ -759,6 +759,19 @@ |
2286 | 1179 | fil_system_hash_nodes(void); | 1179 | fil_system_hash_nodes(void); |
2287 | 1180 | /*========================*/ | 1180 | /*========================*/ |
2288 | 1181 | 1181 | ||
2289 | @@ -1359,7 +1359,7 @@ | |||
2290 | 1359 | /*-------------------------------------------*/ | 1359 | /*-------------------------------------------*/ |
2291 | 1360 | --- a/storage/innobase/srv/srv0start.c | 1360 | --- a/storage/innobase/srv/srv0start.c |
2292 | 1361 | +++ b/storage/innobase/srv/srv0start.c | 1361 | +++ b/storage/innobase/srv/srv0start.c |
2294 | 1362 | @@ -2155,6 +2155,13 @@ | 1362 | @@ -2175,6 +2175,13 @@ |
2295 | 1363 | 1363 | ||
2296 | 1364 | os_fast_mutex_free(&srv_os_test_mutex); | 1364 | os_fast_mutex_free(&srv_os_test_mutex); |
2297 | 1365 | 1365 | ||
2298 | 1366 | 1366 | ||
2299 | === modified file 'patches/innodb_recovery_patches.patch' | |||
2300 | --- patches/innodb_recovery_patches.patch 2011-12-27 15:32:16 +0000 | |||
2301 | +++ patches/innodb_recovery_patches.patch 2012-02-06 05:02:26 +0000 | |||
2302 | @@ -124,7 +124,7 @@ | |||
2303 | 124 | srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite; | 124 | srv_use_doublewrite_buf = (ibool) innobase_use_doublewrite; |
2304 | 125 | srv_use_checksums = (ibool) innobase_use_checksums; | 125 | srv_use_checksums = (ibool) innobase_use_checksums; |
2305 | 126 | 126 | ||
2307 | 127 | @@ -11391,6 +11394,11 @@ | 127 | @@ -11390,6 +11393,11 @@ |
2308 | 128 | "The common part for InnoDB table spaces.", | 128 | "The common part for InnoDB table spaces.", |
2309 | 129 | NULL, NULL, NULL); | 129 | NULL, NULL, NULL); |
2310 | 130 | 130 | ||
2311 | @@ -136,7 +136,7 @@ | |||
2312 | 136 | static MYSQL_SYSVAR_BOOL(recovery_update_relay_log, innobase_overwrite_relay_log_info, | 136 | static MYSQL_SYSVAR_BOOL(recovery_update_relay_log, innobase_overwrite_relay_log_info, |
2313 | 137 | PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY, | 137 | PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY, |
2314 | 138 | "During InnoDB crash recovery on slave overwrite relay-log.info " | 138 | "During InnoDB crash recovery on slave overwrite relay-log.info " |
2316 | 139 | @@ -11879,6 +11887,7 @@ | 139 | @@ -11918,6 +11926,7 @@ |
2317 | 140 | MYSQL_SYSVAR(data_file_path), | 140 | MYSQL_SYSVAR(data_file_path), |
2318 | 141 | MYSQL_SYSVAR(data_home_dir), | 141 | MYSQL_SYSVAR(data_home_dir), |
2319 | 142 | MYSQL_SYSVAR(doublewrite), | 142 | MYSQL_SYSVAR(doublewrite), |
2320 | 143 | 143 | ||
2321 | === modified file 'patches/innodb_separate_doublewrite.patch' | |||
2322 | --- patches/innodb_separate_doublewrite.patch 2011-12-27 15:32:16 +0000 | |||
2323 | +++ patches/innodb_separate_doublewrite.patch 2012-02-06 05:02:26 +0000 | |||
2324 | @@ -7,7 +7,7 @@ | |||
2325 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
2326 | 8 | --- a/storage/innobase/buf/buf0buf.c | 8 | --- a/storage/innobase/buf/buf0buf.c |
2327 | 9 | +++ b/storage/innobase/buf/buf0buf.c | 9 | +++ b/storage/innobase/buf/buf0buf.c |
2329 | 10 | @@ -3805,7 +3805,8 @@ | 10 | @@ -3807,7 +3807,8 @@ |
2330 | 11 | read_space_id = mach_read_from_4( | 11 | read_space_id = mach_read_from_4( |
2331 | 12 | frame + FIL_PAGE_ARCH_LOG_NO_OR_SPACE_ID); | 12 | frame + FIL_PAGE_ARCH_LOG_NO_OR_SPACE_ID); |
2332 | 13 | 13 | ||
2333 | @@ -262,7 +262,7 @@ | |||
2334 | 262 | if (err != DB_SUCCESS) { | 262 | if (err != DB_SUCCESS) { |
2335 | 263 | 263 | ||
2336 | 264 | return(err); | 264 | return(err); |
2338 | 265 | @@ -4168,7 +4178,7 @@ | 265 | @@ -4176,7 +4186,7 @@ |
2339 | 266 | } | 266 | } |
2340 | 267 | 267 | ||
2341 | 268 | #ifndef UNIV_HOTBACKUP | 268 | #ifndef UNIV_HOTBACKUP |
2342 | @@ -271,7 +271,7 @@ | |||
2343 | 271 | fprintf(stderr, | 271 | fprintf(stderr, |
2344 | 272 | "InnoDB: Error: tablespace id %lu in file %s" | 272 | "InnoDB: Error: tablespace id %lu in file %s" |
2345 | 273 | " is not sensible\n", | 273 | " is not sensible\n", |
2347 | 274 | @@ -4177,7 +4187,7 @@ | 274 | @@ -4185,7 +4195,7 @@ |
2348 | 275 | goto func_exit; | 275 | goto func_exit; |
2349 | 276 | } | 276 | } |
2350 | 277 | #else | 277 | #else |
2351 | @@ -280,7 +280,7 @@ | |||
2352 | 280 | char* new_path; | 280 | char* new_path; |
2353 | 281 | 281 | ||
2354 | 282 | fprintf(stderr, | 282 | fprintf(stderr, |
2356 | 283 | @@ -4998,7 +5008,7 @@ | 283 | @@ -5006,7 +5016,7 @@ |
2357 | 284 | } | 284 | } |
2358 | 285 | 285 | ||
2359 | 286 | if (node->n_pending == 0 && space->purpose == FIL_TABLESPACE | 286 | if (node->n_pending == 0 && space->purpose == FIL_TABLESPACE |
2360 | @@ -289,7 +289,7 @@ | |||
2361 | 289 | /* The node is in the LRU list, remove it */ | 289 | /* The node is in the LRU list, remove it */ |
2362 | 290 | 290 | ||
2363 | 291 | ut_a(UT_LIST_GET_LEN(system->LRU) > 0); | 291 | ut_a(UT_LIST_GET_LEN(system->LRU) > 0); |
2365 | 292 | @@ -5044,7 +5054,7 @@ | 292 | @@ -5052,7 +5062,7 @@ |
2366 | 293 | } | 293 | } |
2367 | 294 | 294 | ||
2368 | 295 | if (node->n_pending == 0 && node->space->purpose == FIL_TABLESPACE | 295 | if (node->n_pending == 0 && node->space->purpose == FIL_TABLESPACE |
2369 | @@ -298,7 +298,7 @@ | |||
2370 | 298 | /* The node must be put back to the LRU list */ | 298 | /* The node must be put back to the LRU list */ |
2371 | 299 | UT_LIST_ADD_FIRST(LRU, system->LRU, node); | 299 | UT_LIST_ADD_FIRST(LRU, system->LRU, node); |
2372 | 300 | } | 300 | } |
2374 | 301 | @@ -5655,7 +5665,7 @@ | 301 | @@ -5663,7 +5673,7 @@ |
2375 | 302 | ut_a(fil_node->n_pending == 0); | 302 | ut_a(fil_node->n_pending == 0); |
2376 | 303 | ut_a(fil_node->open); | 303 | ut_a(fil_node->open); |
2377 | 304 | ut_a(fil_node->space->purpose == FIL_TABLESPACE); | 304 | ut_a(fil_node->space->purpose == FIL_TABLESPACE); |
2378 | @@ -316,9 +316,9 @@ | |||
2379 | 316 | - | 316 | - |
2380 | 317 | +#include "trx0sys.h" | 317 | +#include "trx0sys.h" |
2381 | 318 | 318 | ||
2385 | 319 | #define FSP_HEADER_OFFSET FIL_PAGE_DATA /* Offset of the space header | 319 | /* FILE SEGMENT INODE |
2386 | 320 | within a file page */ | 320 | ================== |
2387 | 321 | @@ -999,10 +999,10 @@ | 321 | @@ -938,10 +938,10 @@ |
2388 | 322 | flst_init(header + FSP_SEG_INODES_FREE, mtr); | 322 | flst_init(header + FSP_SEG_INODES_FREE, mtr); |
2389 | 323 | 323 | ||
2390 | 324 | mlog_write_ull(header + FSP_SEG_ID, 1, mtr); | 324 | mlog_write_ull(header + FSP_SEG_ID, 1, mtr); |
2391 | @@ -350,7 +350,7 @@ | |||
2392 | 350 | srv_use_sys_stats_table = (ibool) innobase_use_sys_stats_table; | 350 | srv_use_sys_stats_table = (ibool) innobase_use_sys_stats_table; |
2393 | 351 | 351 | ||
2394 | 352 | /* -------------- Log files ---------------------------*/ | 352 | /* -------------- Log files ---------------------------*/ |
2396 | 353 | @@ -11772,6 +11775,11 @@ | 353 | @@ -11771,6 +11774,11 @@ |
2397 | 354 | "Path to individual files and their sizes.", | 354 | "Path to individual files and their sizes.", |
2398 | 355 | NULL, NULL, NULL); | 355 | NULL, NULL, NULL); |
2399 | 356 | 356 | ||
2400 | @@ -362,7 +362,7 @@ | |||
2401 | 362 | static MYSQL_SYSVAR_LONG(autoinc_lock_mode, innobase_autoinc_lock_mode, | 362 | static MYSQL_SYSVAR_LONG(autoinc_lock_mode, innobase_autoinc_lock_mode, |
2402 | 363 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, | 363 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, |
2403 | 364 | "The AUTOINC lock modes supported by InnoDB: " | 364 | "The AUTOINC lock modes supported by InnoDB: " |
2405 | 365 | @@ -11951,6 +11959,7 @@ | 365 | @@ -11990,6 +11998,7 @@ |
2406 | 366 | MYSQL_SYSVAR(commit_concurrency), | 366 | MYSQL_SYSVAR(commit_concurrency), |
2407 | 367 | MYSQL_SYSVAR(concurrency_tickets), | 367 | MYSQL_SYSVAR(concurrency_tickets), |
2408 | 368 | MYSQL_SYSVAR(data_file_path), | 368 | MYSQL_SYSVAR(data_file_path), |
2409 | @@ -536,7 +536,7 @@ | |||
2410 | 536 | #ifdef UNIV_LOG_ARCHIVE | 536 | #ifdef UNIV_LOG_ARCHIVE |
2411 | 537 | ulint* min_arch_log_no,/*!< out: min of archived log | 537 | ulint* min_arch_log_no,/*!< out: min of archived log |
2412 | 538 | numbers in data files */ | 538 | numbers in data files */ |
2414 | 539 | @@ -747,6 +748,7 @@ | 539 | @@ -748,6 +749,7 @@ |
2415 | 540 | *sum_of_new_sizes = 0; | 540 | *sum_of_new_sizes = 0; |
2416 | 541 | 541 | ||
2417 | 542 | *create_new_db = FALSE; | 542 | *create_new_db = FALSE; |
2418 | @@ -544,7 +544,7 @@ | |||
2419 | 544 | 544 | ||
2420 | 545 | srv_normalize_path_for_win(srv_data_home); | 545 | srv_normalize_path_for_win(srv_data_home); |
2421 | 546 | 546 | ||
2423 | 547 | @@ -984,6 +986,142 @@ | 547 | @@ -1004,6 +1006,142 @@ |
2424 | 548 | srv_data_file_is_raw_partition[i] != 0); | 548 | srv_data_file_is_raw_partition[i] != 0); |
2425 | 549 | } | 549 | } |
2426 | 550 | 550 | ||
2427 | @@ -622,8 +622,8 @@ | |||
2428 | 622 | + (ulong) TRX_SYS_DOUBLEWRITE_BLOCK_SIZE * 9); | 622 | + (ulong) TRX_SYS_DOUBLEWRITE_BLOCK_SIZE * 9); |
2429 | 623 | + } | 623 | + } |
2430 | 624 | + | 624 | + |
2433 | 625 | + fil_read_flushed_lsn_and_arch_log_no( | 625 | + fil_read_first_page( |
2434 | 626 | + files[i], one_opened, | 626 | + files[i], one_opened, &flags, |
2435 | 627 | +#ifdef UNIV_LOG_ARCHIVE | 627 | +#ifdef UNIV_LOG_ARCHIVE |
2436 | 628 | + min_arch_log_no, max_arch_log_no, | 628 | + min_arch_log_no, max_arch_log_no, |
2437 | 629 | +#endif /* UNIV_LOG_ARCHIVE */ | 629 | +#endif /* UNIV_LOG_ARCHIVE */ |
2438 | @@ -687,7 +687,7 @@ | |||
2439 | 687 | return(DB_SUCCESS); | 687 | return(DB_SUCCESS); |
2440 | 688 | } | 688 | } |
2441 | 689 | 689 | ||
2443 | 690 | @@ -997,6 +1135,7 @@ | 690 | @@ -1017,6 +1155,7 @@ |
2444 | 691 | /*====================================*/ | 691 | /*====================================*/ |
2445 | 692 | { | 692 | { |
2446 | 693 | ibool create_new_db; | 693 | ibool create_new_db; |
2447 | @@ -695,7 +695,7 @@ | |||
2448 | 695 | ibool log_file_created; | 695 | ibool log_file_created; |
2449 | 696 | ibool log_created = FALSE; | 696 | ibool log_created = FALSE; |
2450 | 697 | ibool log_opened = FALSE; | 697 | ibool log_opened = FALSE; |
2452 | 698 | @@ -1462,6 +1601,7 @@ | 698 | @@ -1482,6 +1621,7 @@ |
2453 | 699 | } | 699 | } |
2454 | 700 | 700 | ||
2455 | 701 | err = open_or_create_data_files(&create_new_db, | 701 | err = open_or_create_data_files(&create_new_db, |
2456 | @@ -703,7 +703,7 @@ | |||
2457 | 703 | #ifdef UNIV_LOG_ARCHIVE | 703 | #ifdef UNIV_LOG_ARCHIVE |
2458 | 704 | &min_arch_log_no, &max_arch_log_no, | 704 | &min_arch_log_no, &max_arch_log_no, |
2459 | 705 | #endif /* UNIV_LOG_ARCHIVE */ | 705 | #endif /* UNIV_LOG_ARCHIVE */ |
2461 | 706 | @@ -1629,6 +1769,14 @@ | 706 | @@ -1649,6 +1789,14 @@ |
2462 | 707 | after the double write buffer has been created. */ | 707 | after the double write buffer has been created. */ |
2463 | 708 | trx_sys_create(); | 708 | trx_sys_create(); |
2464 | 709 | 709 | ||
2465 | @@ -718,7 +718,7 @@ | |||
2466 | 718 | dict_create(); | 718 | dict_create(); |
2467 | 719 | 719 | ||
2468 | 720 | srv_startup_is_before_trx_rollback_phase = FALSE; | 720 | srv_startup_is_before_trx_rollback_phase = FALSE; |
2470 | 721 | @@ -1662,6 +1810,13 @@ | 721 | @@ -1682,6 +1830,13 @@ |
2471 | 722 | recv_recovery_from_archive_finish(); | 722 | recv_recovery_from_archive_finish(); |
2472 | 723 | #endif /* UNIV_LOG_ARCHIVE */ | 723 | #endif /* UNIV_LOG_ARCHIVE */ |
2473 | 724 | } else { | 724 | } else { |
2474 | @@ -732,7 +732,7 @@ | |||
2475 | 732 | 732 | ||
2476 | 733 | /* Check if we support the max format that is stamped | 733 | /* Check if we support the max format that is stamped |
2477 | 734 | on the system tablespace. | 734 | on the system tablespace. |
2479 | 735 | @@ -1748,6 +1903,17 @@ | 735 | @@ -1768,6 +1923,17 @@ |
2480 | 736 | we have finished the recovery process so that the | 736 | we have finished the recovery process so that the |
2481 | 737 | image of TRX_SYS_PAGE_NO is not stale. */ | 737 | image of TRX_SYS_PAGE_NO is not stale. */ |
2482 | 738 | trx_sys_file_format_tag_init(); | 738 | trx_sys_file_format_tag_init(); |
2483 | 739 | 739 | ||
2484 | === modified file 'patches/innodb_show_lock_name.patch' | |||
2485 | --- patches/innodb_show_lock_name.patch 2011-12-27 15:32:16 +0000 | |||
2486 | +++ patches/innodb_show_lock_name.patch 2012-02-06 05:02:26 +0000 | |||
2487 | @@ -7,7 +7,7 @@ | |||
2488 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
2489 | 8 | --- a/storage/innobase/handler/ha_innodb.cc | 8 | --- a/storage/innobase/handler/ha_innodb.cc |
2490 | 9 | +++ b/storage/innobase/handler/ha_innodb.cc | 9 | +++ b/storage/innobase/handler/ha_innodb.cc |
2492 | 10 | @@ -9710,9 +9710,8 @@ | 10 | @@ -9709,9 +9709,8 @@ |
2493 | 11 | rw_lock_wait_time += mutex->lspent_time; | 11 | rw_lock_wait_time += mutex->lspent_time; |
2494 | 12 | } | 12 | } |
2495 | 13 | #else /* UNIV_DEBUG */ | 13 | #else /* UNIV_DEBUG */ |
2496 | @@ -19,7 +19,7 @@ | |||
2497 | 19 | buf2len= (uint) my_snprintf(buf2, sizeof(buf2), "os_waits=%lu", | 19 | buf2len= (uint) my_snprintf(buf2, sizeof(buf2), "os_waits=%lu", |
2498 | 20 | (ulong) mutex->count_os_wait); | 20 | (ulong) mutex->count_os_wait); |
2499 | 21 | 21 | ||
2501 | 22 | @@ -9727,10 +9726,8 @@ | 22 | @@ -9726,10 +9725,8 @@ |
2502 | 23 | 23 | ||
2503 | 24 | if (block_mutex) { | 24 | if (block_mutex) { |
2504 | 25 | buf1len = (uint) my_snprintf(buf1, sizeof buf1, | 25 | buf1len = (uint) my_snprintf(buf1, sizeof buf1, |
2505 | @@ -32,7 +32,7 @@ | |||
2506 | 32 | buf2len = (uint) my_snprintf(buf2, sizeof buf2, | 32 | buf2len = (uint) my_snprintf(buf2, sizeof buf2, |
2507 | 33 | "os_waits=%lu", | 33 | "os_waits=%lu", |
2508 | 34 | (ulong) block_mutex_oswait_count); | 34 | (ulong) block_mutex_oswait_count); |
2510 | 35 | @@ -9759,9 +9756,8 @@ | 35 | @@ -9758,9 +9755,8 @@ |
2511 | 36 | continue; | 36 | continue; |
2512 | 37 | } | 37 | } |
2513 | 38 | 38 | ||
2514 | @@ -44,7 +44,7 @@ | |||
2515 | 44 | buf2len = my_snprintf(buf2, sizeof buf2, "os_waits=%lu", | 44 | buf2len = my_snprintf(buf2, sizeof buf2, "os_waits=%lu", |
2516 | 45 | (ulong) lock->count_os_wait); | 45 | (ulong) lock->count_os_wait); |
2517 | 46 | 46 | ||
2519 | 47 | @@ -9775,10 +9771,8 @@ | 47 | @@ -9774,10 +9770,8 @@ |
2520 | 48 | 48 | ||
2521 | 49 | if (block_lock) { | 49 | if (block_lock) { |
2522 | 50 | buf1len = (uint) my_snprintf(buf1, sizeof buf1, | 50 | buf1len = (uint) my_snprintf(buf1, sizeof buf1, |
2523 | 51 | 51 | ||
2524 | === modified file 'patches/innodb_show_status.patch' | |||
2525 | --- patches/innodb_show_status.patch 2011-12-27 15:32:16 +0000 | |||
2526 | +++ patches/innodb_show_status.patch 2012-02-06 05:02:26 +0000 | |||
2527 | @@ -7,7 +7,7 @@ | |||
2528 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
2529 | 8 | --- a/storage/innobase/buf/buf0buf.c | 8 | --- a/storage/innobase/buf/buf0buf.c |
2530 | 9 | +++ b/storage/innobase/buf/buf0buf.c | 9 | +++ b/storage/innobase/buf/buf0buf.c |
2532 | 10 | @@ -4365,6 +4365,7 @@ | 10 | @@ -4372,6 +4372,7 @@ |
2533 | 11 | } | 11 | } |
2534 | 12 | 12 | ||
2535 | 13 | total_info->pool_size += pool_info->pool_size; | 13 | total_info->pool_size += pool_info->pool_size; |
2536 | @@ -15,7 +15,7 @@ | |||
2537 | 15 | total_info->lru_len += pool_info->lru_len; | 15 | total_info->lru_len += pool_info->lru_len; |
2538 | 16 | total_info->old_lru_len += pool_info->old_lru_len; | 16 | total_info->old_lru_len += pool_info->old_lru_len; |
2539 | 17 | total_info->free_list_len += pool_info->free_list_len; | 17 | total_info->free_list_len += pool_info->free_list_len; |
2541 | 18 | @@ -4430,6 +4431,8 @@ | 18 | @@ -4437,6 +4438,8 @@ |
2542 | 19 | 19 | ||
2543 | 20 | pool_info->pool_size = buf_pool->curr_size; | 20 | pool_info->pool_size = buf_pool->curr_size; |
2544 | 21 | 21 | ||
2545 | @@ -24,7 +24,7 @@ | |||
2546 | 24 | pool_info->lru_len = UT_LIST_GET_LEN(buf_pool->LRU); | 24 | pool_info->lru_len = UT_LIST_GET_LEN(buf_pool->LRU); |
2547 | 25 | 25 | ||
2548 | 26 | pool_info->old_lru_len = buf_pool->LRU_old_len; | 26 | pool_info->old_lru_len = buf_pool->LRU_old_len; |
2550 | 27 | @@ -4551,14 +4554,16 @@ | 27 | @@ -4558,14 +4561,16 @@ |
2551 | 28 | ut_ad(pool_info); | 28 | ut_ad(pool_info); |
2552 | 29 | 29 | ||
2553 | 30 | fprintf(file, | 30 | fprintf(file, |
2554 | @@ -59,7 +59,7 @@ | |||
2555 | 59 | 59 | ||
2556 | 60 | --- a/storage/innobase/fil/fil0fil.c | 60 | --- a/storage/innobase/fil/fil0fil.c |
2557 | 61 | +++ b/storage/innobase/fil/fil0fil.c | 61 | +++ b/storage/innobase/fil/fil0fil.c |
2559 | 62 | @@ -4889,3 +4889,30 @@ | 62 | @@ -4897,3 +4897,30 @@ |
2560 | 63 | 63 | ||
2561 | 64 | fil_system = NULL; | 64 | fil_system = NULL; |
2562 | 65 | } | 65 | } |
2563 | @@ -101,7 +101,7 @@ | |||
2564 | 101 | {"buffer_pool_pages_free", | 101 | {"buffer_pool_pages_free", |
2565 | 102 | (char*) &export_vars.innodb_buffer_pool_pages_free, SHOW_LONG}, | 102 | (char*) &export_vars.innodb_buffer_pool_pages_free, SHOW_LONG}, |
2566 | 103 | #ifdef UNIV_DEBUG | 103 | #ifdef UNIV_DEBUG |
2568 | 104 | @@ -11208,6 +11210,16 @@ | 104 | @@ -11207,6 +11209,16 @@ |
2569 | 105 | "Force InnoDB to not use next-key locking, to use only row-level locking.", | 105 | "Force InnoDB to not use next-key locking, to use only row-level locking.", |
2570 | 106 | NULL, NULL, FALSE); | 106 | NULL, NULL, FALSE); |
2571 | 107 | 107 | ||
2572 | @@ -118,7 +118,7 @@ | |||
2573 | 118 | #ifdef UNIV_LOG_ARCHIVE | 118 | #ifdef UNIV_LOG_ARCHIVE |
2574 | 119 | static MYSQL_SYSVAR_STR(log_arch_dir, innobase_log_arch_dir, | 119 | static MYSQL_SYSVAR_STR(log_arch_dir, innobase_log_arch_dir, |
2575 | 120 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, | 120 | PLUGIN_VAR_RQCMDARG | PLUGIN_VAR_READONLY, |
2577 | 121 | @@ -11395,7 +11407,7 @@ | 121 | @@ -11394,7 +11406,7 @@ |
2578 | 122 | 122 | ||
2579 | 123 | static MYSQL_SYSVAR_STR(version, innodb_version_str, | 123 | static MYSQL_SYSVAR_STR(version, innodb_version_str, |
2580 | 124 | PLUGIN_VAR_NOCMDOPT | PLUGIN_VAR_READONLY, | 124 | PLUGIN_VAR_NOCMDOPT | PLUGIN_VAR_READONLY, |
2581 | @@ -127,7 +127,7 @@ | |||
2582 | 127 | 127 | ||
2583 | 128 | static MYSQL_SYSVAR_BOOL(use_sys_malloc, srv_use_sys_malloc, | 128 | static MYSQL_SYSVAR_BOOL(use_sys_malloc, srv_use_sys_malloc, |
2584 | 129 | PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY, | 129 | PLUGIN_VAR_NOCMDARG | PLUGIN_VAR_READONLY, |
2586 | 130 | @@ -11495,6 +11507,8 @@ | 130 | @@ -11494,6 +11506,8 @@ |
2587 | 131 | MYSQL_SYSVAR(thread_concurrency), | 131 | MYSQL_SYSVAR(thread_concurrency), |
2588 | 132 | MYSQL_SYSVAR(thread_sleep_delay), | 132 | MYSQL_SYSVAR(thread_sleep_delay), |
2589 | 133 | MYSQL_SYSVAR(autoinc_lock_mode), | 133 | MYSQL_SYSVAR(autoinc_lock_mode), |
2590 | @@ -148,7 +148,7 @@ | |||
2591 | 148 | ulint free_list_len; /*!< Length of buf_pool->free list */ | 148 | ulint free_list_len; /*!< Length of buf_pool->free list */ |
2592 | 149 | --- a/storage/innobase/include/fil0fil.h | 149 | --- a/storage/innobase/include/fil0fil.h |
2593 | 150 | +++ b/storage/innobase/include/fil0fil.h | 150 | +++ b/storage/innobase/include/fil0fil.h |
2595 | 151 | @@ -726,6 +726,17 @@ | 151 | @@ -731,6 +731,17 @@ |
2596 | 152 | /*============================*/ | 152 | /*============================*/ |
2597 | 153 | ulint id); /*!< in: space id */ | 153 | ulint id); /*!< in: space id */ |
2598 | 154 | 154 | ||
2599 | 155 | 155 | ||
2600 | === modified file 'patches/innodb_show_status_extend.patch' | |||
2601 | --- patches/innodb_show_status_extend.patch 2011-12-27 15:32:16 +0000 | |||
2602 | +++ patches/innodb_show_status_extend.patch 2012-02-06 05:02:26 +0000 | |||
2603 | @@ -240,7 +240,7 @@ | |||
2604 | 240 | /** The lock system */ | 240 | /** The lock system */ |
2605 | 241 | --- a/storage/innobase/include/srv0srv.h | 241 | --- a/storage/innobase/include/srv0srv.h |
2606 | 242 | +++ b/storage/innobase/include/srv0srv.h | 242 | +++ b/storage/innobase/include/srv0srv.h |
2608 | 243 | @@ -739,6 +739,11 @@ | 243 | @@ -742,6 +742,11 @@ |
2609 | 244 | 244 | ||
2610 | 245 | /** Status variables to be passed to MySQL */ | 245 | /** Status variables to be passed to MySQL */ |
2611 | 246 | struct export_var_struct{ | 246 | struct export_var_struct{ |
2612 | @@ -252,7 +252,7 @@ | |||
2613 | 252 | ulint innodb_data_pending_reads; /*!< Pending reads */ | 252 | ulint innodb_data_pending_reads; /*!< Pending reads */ |
2614 | 253 | ulint innodb_data_pending_writes; /*!< Pending writes */ | 253 | ulint innodb_data_pending_writes; /*!< Pending writes */ |
2615 | 254 | ulint innodb_data_pending_fsyncs; /*!< Pending fsyncs */ | 254 | ulint innodb_data_pending_fsyncs; /*!< Pending fsyncs */ |
2617 | 255 | @@ -756,6 +761,9 @@ | 255 | @@ -759,6 +764,9 @@ |
2618 | 256 | #ifdef UNIV_DEBUG | 256 | #ifdef UNIV_DEBUG |
2619 | 257 | ulint innodb_buffer_pool_pages_latched; /*!< Latched pages */ | 257 | ulint innodb_buffer_pool_pages_latched; /*!< Latched pages */ |
2620 | 258 | #endif /* UNIV_DEBUG */ | 258 | #endif /* UNIV_DEBUG */ |
2621 | @@ -262,7 +262,7 @@ | |||
2622 | 262 | ulint innodb_buffer_pool_read_requests; /*!< buf_pool->stat.n_page_gets */ | 262 | ulint innodb_buffer_pool_read_requests; /*!< buf_pool->stat.n_page_gets */ |
2623 | 263 | ulint innodb_buffer_pool_reads; /*!< srv_buf_pool_reads */ | 263 | ulint innodb_buffer_pool_reads; /*!< srv_buf_pool_reads */ |
2624 | 264 | ulint innodb_buffer_pool_wait_free; /*!< srv_buf_pool_wait_free */ | 264 | ulint innodb_buffer_pool_wait_free; /*!< srv_buf_pool_wait_free */ |
2626 | 265 | @@ -765,13 +773,43 @@ | 265 | @@ -768,13 +776,43 @@ |
2627 | 266 | ulint innodb_buffer_pool_read_ahead_rnd;/*!< srv_read_ahead_rnd */ | 266 | ulint innodb_buffer_pool_read_ahead_rnd;/*!< srv_read_ahead_rnd */ |
2628 | 267 | ulint innodb_buffer_pool_read_ahead; /*!< srv_read_ahead */ | 267 | ulint innodb_buffer_pool_read_ahead; /*!< srv_read_ahead */ |
2629 | 268 | ulint innodb_buffer_pool_read_ahead_evicted;/*!< srv_read_ahead evicted*/ | 268 | ulint innodb_buffer_pool_read_ahead_evicted;/*!< srv_read_ahead evicted*/ |
2630 | @@ -306,7 +306,7 @@ | |||
2631 | 306 | ulint innodb_os_log_written; /*!< srv_os_log_written */ | 306 | ulint innodb_os_log_written; /*!< srv_os_log_written */ |
2632 | 307 | ulint innodb_os_log_fsyncs; /*!< fil_n_log_flushes */ | 307 | ulint innodb_os_log_fsyncs; /*!< fil_n_log_flushes */ |
2633 | 308 | ulint innodb_os_log_pending_writes; /*!< srv_os_log_pending_writes */ | 308 | ulint innodb_os_log_pending_writes; /*!< srv_os_log_pending_writes */ |
2635 | 309 | @@ -780,6 +818,8 @@ | 309 | @@ -783,6 +821,8 @@ |
2636 | 310 | ulint innodb_pages_created; /*!< buf_pool->stat.n_pages_created */ | 310 | ulint innodb_pages_created; /*!< buf_pool->stat.n_pages_created */ |
2637 | 311 | ulint innodb_pages_read; /*!< buf_pool->stat.n_pages_read */ | 311 | ulint innodb_pages_read; /*!< buf_pool->stat.n_pages_read */ |
2638 | 312 | ulint innodb_pages_written; /*!< buf_pool->stat.n_pages_written */ | 312 | ulint innodb_pages_written; /*!< buf_pool->stat.n_pages_written */ |
2639 | @@ -315,7 +315,7 @@ | |||
2640 | 315 | ulint innodb_row_lock_waits; /*!< srv_n_lock_wait_count */ | 315 | ulint innodb_row_lock_waits; /*!< srv_n_lock_wait_count */ |
2641 | 316 | ulint innodb_row_lock_current_waits; /*!< srv_n_lock_wait_current_count */ | 316 | ulint innodb_row_lock_current_waits; /*!< srv_n_lock_wait_current_count */ |
2642 | 317 | ib_int64_t innodb_row_lock_time; /*!< srv_n_lock_wait_time | 317 | ib_int64_t innodb_row_lock_time; /*!< srv_n_lock_wait_time |
2644 | 318 | @@ -789,11 +829,18 @@ | 318 | @@ -792,11 +832,18 @@ |
2645 | 319 | / srv_n_lock_wait_count */ | 319 | / srv_n_lock_wait_count */ |
2646 | 320 | ulint innodb_row_lock_time_max; /*!< srv_n_lock_max_wait_time | 320 | ulint innodb_row_lock_time_max; /*!< srv_n_lock_max_wait_time |
2647 | 321 | / 1000 */ | 321 | / 1000 */ |
2648 | @@ -383,7 +383,7 @@ | |||
2649 | 383 | } | 383 | } |
2650 | 384 | --- a/storage/innobase/srv/srv0srv.c | 384 | --- a/storage/innobase/srv/srv0srv.c |
2651 | 385 | +++ b/storage/innobase/srv/srv0srv.c | 385 | +++ b/storage/innobase/srv/srv0srv.c |
2653 | 386 | @@ -2259,12 +2259,49 @@ | 386 | @@ -2262,12 +2262,49 @@ |
2654 | 387 | ulint LRU_len; | 387 | ulint LRU_len; |
2655 | 388 | ulint free_len; | 388 | ulint free_len; |
2656 | 389 | ulint flush_list_len; | 389 | ulint flush_list_len; |
2657 | @@ -433,7 +433,7 @@ | |||
2658 | 433 | export_vars.innodb_data_pending_reads | 433 | export_vars.innodb_data_pending_reads |
2659 | 434 | = os_n_pending_reads; | 434 | = os_n_pending_reads; |
2660 | 435 | export_vars.innodb_data_pending_writes | 435 | export_vars.innodb_data_pending_writes |
2662 | 436 | @@ -2303,6 +2340,92 @@ | 436 | @@ -2306,6 +2343,92 @@ |
2663 | 437 | 437 | ||
2664 | 438 | export_vars.innodb_buffer_pool_pages_misc | 438 | export_vars.innodb_buffer_pool_pages_misc |
2665 | 439 | = buf_pool_get_n_pages() - LRU_len - free_len; | 439 | = buf_pool_get_n_pages() - LRU_len - free_len; |
2666 | 440 | 440 | ||
2667 | === modified file 'patches/innodb_show_sys_tables.patch' | |||
2668 | --- patches/innodb_show_sys_tables.patch 2011-12-27 15:32:16 +0000 | |||
2669 | +++ patches/innodb_show_sys_tables.patch 2012-02-06 05:02:26 +0000 | |||
2670 | @@ -39,7 +39,7 @@ | |||
2671 | 39 | Determine the flags of a table described in SYS_TABLES. | 39 | Determine the flags of a table described in SYS_TABLES. |
2672 | 40 | --- a/storage/innobase/handler/ha_innodb.cc | 40 | --- a/storage/innobase/handler/ha_innodb.cc |
2673 | 41 | +++ b/storage/innobase/handler/ha_innodb.cc | 41 | +++ b/storage/innobase/handler/ha_innodb.cc |
2675 | 42 | @@ -11908,7 +11908,14 @@ | 42 | @@ -11950,7 +11950,14 @@ |
2676 | 43 | i_s_innodb_cmp, | 43 | i_s_innodb_cmp, |
2677 | 44 | i_s_innodb_cmp_reset, | 44 | i_s_innodb_cmp_reset, |
2678 | 45 | i_s_innodb_cmpmem, | 45 | i_s_innodb_cmpmem, |
2679 | 46 | 46 | ||
2680 | === modified file 'patches/innodb_split_buf_pool_mutex.patch' | |||
2681 | --- patches/innodb_split_buf_pool_mutex.patch 2012-01-11 15:14:15 +0000 | |||
2682 | +++ patches/innodb_split_buf_pool_mutex.patch 2012-02-06 05:02:26 +0000 | |||
2683 | @@ -527,7 +527,7 @@ | |||
2684 | 527 | buf_pool_mutex_exit(buf_pool); | 527 | buf_pool_mutex_exit(buf_pool); |
2685 | 528 | 528 | ||
2686 | 529 | return(DB_SUCCESS); | 529 | return(DB_SUCCESS); |
2688 | 530 | @@ -1374,7 +1402,11 @@ | 530 | @@ -1376,7 +1404,11 @@ |
2689 | 531 | ulint fold; | 531 | ulint fold; |
2690 | 532 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 532 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
2691 | 533 | 533 | ||
2692 | @@ -540,7 +540,7 @@ | |||
2693 | 540 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); | 540 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); |
2694 | 541 | ut_a(buf_page_get_io_fix(bpage) == BUF_IO_NONE); | 541 | ut_a(buf_page_get_io_fix(bpage) == BUF_IO_NONE); |
2695 | 542 | ut_a(bpage->buf_fix_count == 0); | 542 | ut_a(bpage->buf_fix_count == 0); |
2697 | 543 | @@ -1485,21 +1517,32 @@ | 543 | @@ -1487,21 +1519,32 @@ |
2698 | 544 | buf_page_t* bpage; | 544 | buf_page_t* bpage; |
2699 | 545 | ulint i; | 545 | ulint i; |
2700 | 546 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 546 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2701 | @@ -574,7 +574,7 @@ | |||
2702 | 574 | for (i = 0; i < BUF_POOL_WATCH_SIZE; i++) { | 574 | for (i = 0; i < BUF_POOL_WATCH_SIZE; i++) { |
2703 | 575 | bpage = &buf_pool->watch[i]; | 575 | bpage = &buf_pool->watch[i]; |
2704 | 576 | 576 | ||
2706 | 577 | @@ -1523,10 +1566,12 @@ | 577 | @@ -1525,10 +1568,12 @@ |
2707 | 578 | bpage->space = space; | 578 | bpage->space = space; |
2708 | 579 | bpage->offset = offset; | 579 | bpage->offset = offset; |
2709 | 580 | bpage->buf_fix_count = 1; | 580 | bpage->buf_fix_count = 1; |
2710 | @@ -588,7 +588,7 @@ | |||
2711 | 588 | return(NULL); | 588 | return(NULL); |
2712 | 589 | case BUF_BLOCK_ZIP_PAGE: | 589 | case BUF_BLOCK_ZIP_PAGE: |
2713 | 590 | ut_ad(bpage->in_page_hash); | 590 | ut_ad(bpage->in_page_hash); |
2715 | 591 | @@ -1544,6 +1589,8 @@ | 591 | @@ -1546,6 +1591,8 @@ |
2716 | 592 | ut_error; | 592 | ut_error; |
2717 | 593 | 593 | ||
2718 | 594 | /* Fix compiler warning */ | 594 | /* Fix compiler warning */ |
2719 | @@ -597,7 +597,7 @@ | |||
2720 | 597 | return(NULL); | 597 | return(NULL); |
2721 | 598 | } | 598 | } |
2722 | 599 | 599 | ||
2724 | 600 | @@ -1561,7 +1608,11 @@ | 600 | @@ -1563,7 +1610,11 @@ |
2725 | 601 | space, offset) */ | 601 | space, offset) */ |
2726 | 602 | buf_page_t* watch) /*!< in/out: sentinel for watch */ | 602 | buf_page_t* watch) /*!< in/out: sentinel for watch */ |
2727 | 603 | { | 603 | { |
2728 | @@ -610,7 +610,7 @@ | |||
2729 | 610 | 610 | ||
2730 | 611 | HASH_DELETE(buf_page_t, hash, buf_pool->page_hash, fold, watch); | 611 | HASH_DELETE(buf_page_t, hash, buf_pool->page_hash, fold, watch); |
2731 | 612 | ut_d(watch->in_page_hash = FALSE); | 612 | ut_d(watch->in_page_hash = FALSE); |
2733 | 613 | @@ -1583,28 +1634,31 @@ | 613 | @@ -1585,28 +1636,31 @@ |
2734 | 614 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 614 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2735 | 615 | ulint fold = buf_page_address_fold(space, offset); | 615 | ulint fold = buf_page_address_fold(space, offset); |
2736 | 616 | 616 | ||
2737 | @@ -646,7 +646,7 @@ | |||
2738 | 646 | } | 646 | } |
2739 | 647 | 647 | ||
2740 | 648 | /****************************************************************//** | 648 | /****************************************************************//** |
2742 | 649 | @@ -1624,14 +1678,16 @@ | 649 | @@ -1626,14 +1680,16 @@ |
2743 | 650 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 650 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2744 | 651 | ulint fold = buf_page_address_fold(space, offset); | 651 | ulint fold = buf_page_address_fold(space, offset); |
2745 | 652 | 652 | ||
2746 | @@ -665,7 +665,7 @@ | |||
2747 | 665 | 665 | ||
2748 | 666 | return(ret); | 666 | return(ret); |
2749 | 667 | } | 667 | } |
2751 | 668 | @@ -1648,13 +1704,15 @@ | 668 | @@ -1650,13 +1706,15 @@ |
2752 | 669 | { | 669 | { |
2753 | 670 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 670 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
2754 | 671 | 671 | ||
2755 | @@ -683,7 +683,7 @@ | |||
2756 | 683 | } | 683 | } |
2757 | 684 | 684 | ||
2758 | 685 | /********************************************************************//** | 685 | /********************************************************************//** |
2760 | 686 | @@ -1678,14 +1736,20 @@ | 686 | @@ -1680,14 +1738,20 @@ |
2761 | 687 | ut_a(buf_page_in_file(bpage)); | 687 | ut_a(buf_page_in_file(bpage)); |
2762 | 688 | 688 | ||
2763 | 689 | if (buf_page_peek_if_too_old(bpage)) { | 689 | if (buf_page_peek_if_too_old(bpage)) { |
2764 | @@ -708,7 +708,7 @@ | |||
2765 | 708 | } | 708 | } |
2766 | 709 | } | 709 | } |
2767 | 710 | 710 | ||
2769 | 711 | @@ -1702,7 +1766,8 @@ | 711 | @@ -1704,7 +1768,8 @@ |
2770 | 712 | buf_block_t* block; | 712 | buf_block_t* block; |
2771 | 713 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 713 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2772 | 714 | 714 | ||
2773 | @@ -718,7 +718,7 @@ | |||
2774 | 718 | 718 | ||
2775 | 719 | block = (buf_block_t*) buf_page_hash_get(buf_pool, space, offset); | 719 | block = (buf_block_t*) buf_page_hash_get(buf_pool, space, offset); |
2776 | 720 | 720 | ||
2778 | 721 | @@ -1711,7 +1776,8 @@ | 721 | @@ -1713,7 +1778,8 @@ |
2779 | 722 | block->check_index_page_at_flush = FALSE; | 722 | block->check_index_page_at_flush = FALSE; |
2780 | 723 | } | 723 | } |
2781 | 724 | 724 | ||
2782 | @@ -728,7 +728,7 @@ | |||
2783 | 728 | } | 728 | } |
2784 | 729 | 729 | ||
2785 | 730 | #if defined UNIV_DEBUG_FILE_ACCESSES || defined UNIV_DEBUG | 730 | #if defined UNIV_DEBUG_FILE_ACCESSES || defined UNIV_DEBUG |
2787 | 731 | @@ -1731,7 +1797,8 @@ | 731 | @@ -1733,7 +1799,8 @@ |
2788 | 732 | buf_page_t* bpage; | 732 | buf_page_t* bpage; |
2789 | 733 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 733 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2790 | 734 | 734 | ||
2791 | @@ -738,7 +738,7 @@ | |||
2792 | 738 | 738 | ||
2793 | 739 | bpage = buf_page_hash_get(buf_pool, space, offset); | 739 | bpage = buf_page_hash_get(buf_pool, space, offset); |
2794 | 740 | 740 | ||
2796 | 741 | @@ -1742,7 +1809,8 @@ | 741 | @@ -1744,7 +1811,8 @@ |
2797 | 742 | bpage->file_page_was_freed = TRUE; | 742 | bpage->file_page_was_freed = TRUE; |
2798 | 743 | } | 743 | } |
2799 | 744 | 744 | ||
2800 | @@ -748,7 +748,7 @@ | |||
2801 | 748 | 748 | ||
2802 | 749 | return(bpage); | 749 | return(bpage); |
2803 | 750 | } | 750 | } |
2805 | 751 | @@ -1763,7 +1831,8 @@ | 751 | @@ -1765,7 +1833,8 @@ |
2806 | 752 | buf_page_t* bpage; | 752 | buf_page_t* bpage; |
2807 | 753 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 753 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2808 | 754 | 754 | ||
2809 | @@ -758,7 +758,7 @@ | |||
2810 | 758 | 758 | ||
2811 | 759 | bpage = buf_page_hash_get(buf_pool, space, offset); | 759 | bpage = buf_page_hash_get(buf_pool, space, offset); |
2812 | 760 | 760 | ||
2814 | 761 | @@ -1772,7 +1841,8 @@ | 761 | @@ -1774,7 +1843,8 @@ |
2815 | 762 | bpage->file_page_was_freed = FALSE; | 762 | bpage->file_page_was_freed = FALSE; |
2816 | 763 | } | 763 | } |
2817 | 764 | 764 | ||
2818 | @@ -768,7 +768,7 @@ | |||
2819 | 768 | 768 | ||
2820 | 769 | return(bpage); | 769 | return(bpage); |
2821 | 770 | } | 770 | } |
2823 | 771 | @@ -1804,8 +1874,9 @@ | 771 | @@ -1806,8 +1876,9 @@ |
2824 | 772 | buf_pool->stat.n_page_gets++; | 772 | buf_pool->stat.n_page_gets++; |
2825 | 773 | 773 | ||
2826 | 774 | for (;;) { | 774 | for (;;) { |
2827 | @@ -779,7 +779,7 @@ | |||
2828 | 779 | bpage = buf_page_hash_get(buf_pool, space, offset); | 779 | bpage = buf_page_hash_get(buf_pool, space, offset); |
2829 | 780 | if (bpage) { | 780 | if (bpage) { |
2830 | 781 | ut_ad(!buf_pool_watch_is_sentinel(buf_pool, bpage)); | 781 | ut_ad(!buf_pool_watch_is_sentinel(buf_pool, bpage)); |
2832 | 782 | @@ -1814,7 +1885,8 @@ | 782 | @@ -1816,7 +1887,8 @@ |
2833 | 783 | 783 | ||
2834 | 784 | /* Page not in buf_pool: needs to be read from file */ | 784 | /* Page not in buf_pool: needs to be read from file */ |
2835 | 785 | 785 | ||
2836 | @@ -789,7 +789,7 @@ | |||
2837 | 789 | 789 | ||
2838 | 790 | buf_read_page(space, zip_size, offset); | 790 | buf_read_page(space, zip_size, offset); |
2839 | 791 | 791 | ||
2841 | 792 | @@ -1826,10 +1898,15 @@ | 792 | @@ -1828,10 +1900,15 @@ |
2842 | 793 | if (UNIV_UNLIKELY(!bpage->zip.data)) { | 793 | if (UNIV_UNLIKELY(!bpage->zip.data)) { |
2843 | 794 | /* There is no compressed page. */ | 794 | /* There is no compressed page. */ |
2844 | 795 | err_exit: | 795 | err_exit: |
2845 | @@ -806,7 +806,7 @@ | |||
2846 | 806 | ut_ad(!buf_pool_watch_is_sentinel(buf_pool, bpage)); | 806 | ut_ad(!buf_pool_watch_is_sentinel(buf_pool, bpage)); |
2847 | 807 | 807 | ||
2848 | 808 | switch (buf_page_get_state(bpage)) { | 808 | switch (buf_page_get_state(bpage)) { |
2850 | 809 | @@ -1838,24 +1915,43 @@ | 809 | @@ -1840,24 +1917,43 @@ |
2851 | 810 | case BUF_BLOCK_MEMORY: | 810 | case BUF_BLOCK_MEMORY: |
2852 | 811 | case BUF_BLOCK_REMOVE_HASH: | 811 | case BUF_BLOCK_REMOVE_HASH: |
2853 | 812 | case BUF_BLOCK_ZIP_FREE: | 812 | case BUF_BLOCK_ZIP_FREE: |
2854 | @@ -855,7 +855,7 @@ | |||
2855 | 855 | buf_block_buf_fix_inc((buf_block_t*) bpage, | 855 | buf_block_buf_fix_inc((buf_block_t*) bpage, |
2856 | 856 | __FILE__, __LINE__); | 856 | __FILE__, __LINE__); |
2857 | 857 | goto got_block; | 857 | goto got_block; |
2859 | 858 | @@ -1868,7 +1964,7 @@ | 858 | @@ -1870,7 +1966,7 @@ |
2860 | 859 | must_read = buf_page_get_io_fix(bpage) == BUF_IO_READ; | 859 | must_read = buf_page_get_io_fix(bpage) == BUF_IO_READ; |
2861 | 860 | access_time = buf_page_is_accessed(bpage); | 860 | access_time = buf_page_is_accessed(bpage); |
2862 | 861 | 861 | ||
2863 | @@ -864,7 +864,7 @@ | |||
2864 | 864 | 864 | ||
2865 | 865 | mutex_exit(block_mutex); | 865 | mutex_exit(block_mutex); |
2866 | 866 | 866 | ||
2868 | 867 | @@ -2179,7 +2275,7 @@ | 867 | @@ -2181,7 +2277,7 @@ |
2869 | 868 | const buf_block_t* block) /*!< in: pointer to block, | 868 | const buf_block_t* block) /*!< in: pointer to block, |
2870 | 869 | not dereferenced */ | 869 | not dereferenced */ |
2871 | 870 | { | 870 | { |
2872 | @@ -873,7 +873,7 @@ | |||
2873 | 873 | 873 | ||
2874 | 874 | if (UNIV_UNLIKELY((((ulint) block) % sizeof *block) != 0)) { | 874 | if (UNIV_UNLIKELY((((ulint) block) % sizeof *block) != 0)) { |
2875 | 875 | /* The pointer should be aligned. */ | 875 | /* The pointer should be aligned. */ |
2877 | 876 | @@ -2215,6 +2311,7 @@ | 876 | @@ -2217,6 +2313,7 @@ |
2878 | 877 | ulint fix_type; | 877 | ulint fix_type; |
2879 | 878 | ibool must_read; | 878 | ibool must_read; |
2880 | 879 | ulint retries = 0; | 879 | ulint retries = 0; |
2881 | @@ -881,7 +881,7 @@ | |||
2882 | 881 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 881 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
2883 | 882 | 882 | ||
2884 | 883 | ut_ad(mtr); | 883 | ut_ad(mtr); |
2886 | 884 | @@ -2248,18 +2345,24 @@ | 884 | @@ -2250,18 +2347,24 @@ |
2887 | 885 | fold = buf_page_address_fold(space, offset); | 885 | fold = buf_page_address_fold(space, offset); |
2888 | 886 | loop: | 886 | loop: |
2889 | 887 | block = guess; | 887 | block = guess; |
2890 | @@ -908,7 +908,7 @@ | |||
2891 | 908 | block = guess = NULL; | 908 | block = guess = NULL; |
2892 | 909 | } else { | 909 | } else { |
2893 | 910 | ut_ad(!block->page.in_zip_hash); | 910 | ut_ad(!block->page.in_zip_hash); |
2895 | 911 | @@ -2268,12 +2371,19 @@ | 911 | @@ -2270,12 +2373,19 @@ |
2896 | 912 | } | 912 | } |
2897 | 913 | 913 | ||
2898 | 914 | if (block == NULL) { | 914 | if (block == NULL) { |
2899 | @@ -928,7 +928,7 @@ | |||
2900 | 928 | block = NULL; | 928 | block = NULL; |
2901 | 929 | } | 929 | } |
2902 | 930 | 930 | ||
2904 | 931 | @@ -2285,12 +2395,14 @@ | 931 | @@ -2287,12 +2397,14 @@ |
2905 | 932 | space, offset, fold); | 932 | space, offset, fold); |
2906 | 933 | 933 | ||
2907 | 934 | if (UNIV_LIKELY_NULL(block)) { | 934 | if (UNIV_LIKELY_NULL(block)) { |
2908 | @@ -945,7 +945,7 @@ | |||
2909 | 945 | 945 | ||
2910 | 946 | if (mode == BUF_GET_IF_IN_POOL | 946 | if (mode == BUF_GET_IF_IN_POOL |
2911 | 947 | || mode == BUF_PEEK_IF_IN_POOL | 947 | || mode == BUF_PEEK_IF_IN_POOL |
2913 | 948 | @@ -2343,7 +2455,8 @@ | 948 | @@ -2345,7 +2457,8 @@ |
2914 | 949 | /* The page is being read to buffer pool, | 949 | /* The page is being read to buffer pool, |
2915 | 950 | but we cannot wait around for the read to | 950 | but we cannot wait around for the read to |
2916 | 951 | complete. */ | 951 | complete. */ |
2917 | @@ -955,7 +955,7 @@ | |||
2918 | 955 | 955 | ||
2919 | 956 | return(NULL); | 956 | return(NULL); |
2920 | 957 | } | 957 | } |
2922 | 958 | @@ -2353,38 +2466,49 @@ | 958 | @@ -2355,38 +2468,49 @@ |
2923 | 959 | ibool success; | 959 | ibool success; |
2924 | 960 | 960 | ||
2925 | 961 | case BUF_BLOCK_FILE_PAGE: | 961 | case BUF_BLOCK_FILE_PAGE: |
2926 | @@ -1012,7 +1012,7 @@ | |||
2927 | 1012 | 1012 | ||
2928 | 1013 | { | 1013 | { |
2929 | 1014 | buf_page_t* hash_bpage; | 1014 | buf_page_t* hash_bpage; |
2931 | 1015 | @@ -2397,35 +2521,47 @@ | 1015 | @@ -2399,35 +2523,47 @@ |
2932 | 1016 | while buf_pool->mutex was released. | 1016 | while buf_pool->mutex was released. |
2933 | 1017 | Free the block that was allocated. */ | 1017 | Free the block that was allocated. */ |
2934 | 1018 | 1018 | ||
2935 | @@ -1066,7 +1066,7 @@ | |||
2936 | 1066 | buf_block_init_low(block); | 1066 | buf_block_init_low(block); |
2937 | 1067 | block->lock_hash_val = lock_rec_hash(space, offset); | 1067 | block->lock_hash_val = lock_rec_hash(space, offset); |
2938 | 1068 | 1068 | ||
2940 | 1069 | @@ -2435,7 +2571,7 @@ | 1069 | @@ -2437,7 +2573,7 @@ |
2941 | 1070 | if (buf_page_get_state(&block->page) | 1070 | if (buf_page_get_state(&block->page) |
2942 | 1071 | == BUF_BLOCK_ZIP_PAGE) { | 1071 | == BUF_BLOCK_ZIP_PAGE) { |
2943 | 1072 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 1072 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
2944 | @@ -1075,7 +1075,7 @@ | |||
2945 | 1075 | &block->page); | 1075 | &block->page); |
2946 | 1076 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ | 1076 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ |
2947 | 1077 | ut_ad(!block->page.in_flush_list); | 1077 | ut_ad(!block->page.in_flush_list); |
2949 | 1078 | @@ -2453,18 +2589,23 @@ | 1078 | @@ -2455,18 +2591,23 @@ |
2950 | 1079 | /* Insert at the front of unzip_LRU list */ | 1079 | /* Insert at the front of unzip_LRU list */ |
2951 | 1080 | buf_unzip_LRU_add_block(block, FALSE); | 1080 | buf_unzip_LRU_add_block(block, FALSE); |
2952 | 1081 | 1081 | ||
2953 | @@ -1101,7 +1101,7 @@ | |||
2954 | 1101 | buf_page_free_descriptor(bpage); | 1101 | buf_page_free_descriptor(bpage); |
2955 | 1102 | 1102 | ||
2956 | 1103 | /* Decompress the page and apply buffered operations | 1103 | /* Decompress the page and apply buffered operations |
2958 | 1104 | @@ -2478,12 +2619,15 @@ | 1104 | @@ -2480,12 +2621,15 @@ |
2959 | 1105 | } | 1105 | } |
2960 | 1106 | 1106 | ||
2961 | 1107 | /* Unfix and unlatch the block. */ | 1107 | /* Unfix and unlatch the block. */ |
2962 | @@ -1120,7 +1120,7 @@ | |||
2963 | 1120 | rw_lock_x_unlock(&block->lock); | 1120 | rw_lock_x_unlock(&block->lock); |
2964 | 1121 | 1121 | ||
2965 | 1122 | break; | 1122 | break; |
2967 | 1123 | @@ -2499,7 +2643,7 @@ | 1123 | @@ -2501,7 +2645,7 @@ |
2968 | 1124 | 1124 | ||
2969 | 1125 | ut_ad(buf_block_get_state(block) == BUF_BLOCK_FILE_PAGE); | 1125 | ut_ad(buf_block_get_state(block) == BUF_BLOCK_FILE_PAGE); |
2970 | 1126 | 1126 | ||
2971 | @@ -1129,7 +1129,7 @@ | |||
2972 | 1129 | #if UNIV_WORD_SIZE == 4 | 1129 | #if UNIV_WORD_SIZE == 4 |
2973 | 1130 | /* On 32-bit systems, there is no padding in buf_page_t. On | 1130 | /* On 32-bit systems, there is no padding in buf_page_t. On |
2974 | 1131 | other systems, Valgrind could complain about uninitialized pad | 1131 | other systems, Valgrind could complain about uninitialized pad |
2976 | 1132 | @@ -2512,8 +2656,8 @@ | 1132 | @@ -2514,8 +2658,8 @@ |
2977 | 1133 | /* Try to evict the block from the buffer pool, to use the | 1133 | /* Try to evict the block from the buffer pool, to use the |
2978 | 1134 | insert buffer (change buffer) as much as possible. */ | 1134 | insert buffer (change buffer) as much as possible. */ |
2979 | 1135 | 1135 | ||
2980 | @@ -1140,7 +1140,7 @@ | |||
2981 | 1140 | if (mode == BUF_GET_IF_IN_POOL_OR_WATCH) { | 1140 | if (mode == BUF_GET_IF_IN_POOL_OR_WATCH) { |
2982 | 1141 | /* Set the watch, as it would have | 1141 | /* Set the watch, as it would have |
2983 | 1142 | been set if the page were not in the | 1142 | been set if the page were not in the |
2985 | 1143 | @@ -2522,6 +2666,9 @@ | 1143 | @@ -2524,6 +2668,9 @@ |
2986 | 1144 | space, offset, fold); | 1144 | space, offset, fold); |
2987 | 1145 | 1145 | ||
2988 | 1146 | if (UNIV_LIKELY_NULL(block)) { | 1146 | if (UNIV_LIKELY_NULL(block)) { |
2989 | @@ -1150,7 +1150,7 @@ | |||
2990 | 1150 | 1150 | ||
2991 | 1151 | /* The page entered the buffer | 1151 | /* The page entered the buffer |
2992 | 1152 | pool for some reason. Try to | 1152 | pool for some reason. Try to |
2994 | 1153 | @@ -2529,7 +2676,7 @@ | 1153 | @@ -2531,7 +2678,7 @@ |
2995 | 1154 | goto got_block; | 1154 | goto got_block; |
2996 | 1155 | } | 1155 | } |
2997 | 1156 | } | 1156 | } |
2998 | @@ -1159,7 +1159,7 @@ | |||
2999 | 1159 | fprintf(stderr, | 1159 | fprintf(stderr, |
3000 | 1160 | "innodb_change_buffering_debug evict %u %u\n", | 1160 | "innodb_change_buffering_debug evict %u %u\n", |
3001 | 1161 | (unsigned) space, (unsigned) offset); | 1161 | (unsigned) space, (unsigned) offset); |
3003 | 1162 | @@ -2551,13 +2698,14 @@ | 1162 | @@ -2553,13 +2700,14 @@ |
3004 | 1163 | ut_a(mode == BUF_GET_POSSIBLY_FREED | 1163 | ut_a(mode == BUF_GET_POSSIBLY_FREED |
3005 | 1164 | || !block->page.file_page_was_freed); | 1164 | || !block->page.file_page_was_freed); |
3006 | 1165 | #endif | 1165 | #endif |
3007 | @@ -1176,7 +1176,7 @@ | |||
3008 | 1176 | 1176 | ||
3009 | 1177 | if (UNIV_LIKELY(mode != BUF_PEEK_IF_IN_POOL)) { | 1177 | if (UNIV_LIKELY(mode != BUF_PEEK_IF_IN_POOL)) { |
3010 | 1178 | buf_page_set_accessed_make_young(&block->page, access_time); | 1178 | buf_page_set_accessed_make_young(&block->page, access_time); |
3012 | 1179 | @@ -2790,9 +2938,11 @@ | 1179 | @@ -2792,9 +2940,11 @@ |
3013 | 1180 | buf_pool = buf_pool_from_block(block); | 1180 | buf_pool = buf_pool_from_block(block); |
3014 | 1181 | 1181 | ||
3015 | 1182 | if (mode == BUF_MAKE_YOUNG && buf_page_peek_if_too_old(&block->page)) { | 1182 | if (mode == BUF_MAKE_YOUNG && buf_page_peek_if_too_old(&block->page)) { |
3016 | @@ -1190,7 +1190,7 @@ | |||
3017 | 1190 | } else if (!buf_page_is_accessed(&block->page)) { | 1190 | } else if (!buf_page_is_accessed(&block->page)) { |
3018 | 1191 | /* Above, we do a dirty read on purpose, to avoid | 1191 | /* Above, we do a dirty read on purpose, to avoid |
3019 | 1192 | mutex contention. The field buf_page_t::access_time | 1192 | mutex contention. The field buf_page_t::access_time |
3021 | 1193 | @@ -2800,9 +2950,11 @@ | 1193 | @@ -2802,9 +2952,11 @@ |
3022 | 1194 | field must be protected by mutex, however. */ | 1194 | field must be protected by mutex, however. */ |
3023 | 1195 | ulint time_ms = ut_time_ms(); | 1195 | ulint time_ms = ut_time_ms(); |
3024 | 1196 | 1196 | ||
3025 | @@ -1204,7 +1204,7 @@ | |||
3026 | 1204 | } | 1204 | } |
3027 | 1205 | 1205 | ||
3028 | 1206 | ut_ad(!ibuf_inside(mtr) || mode == BUF_KEEP_OLD); | 1206 | ut_ad(!ibuf_inside(mtr) || mode == BUF_KEEP_OLD); |
3030 | 1207 | @@ -2869,18 +3021,21 @@ | 1207 | @@ -2871,18 +3023,21 @@ |
3031 | 1208 | ut_ad(mtr); | 1208 | ut_ad(mtr); |
3032 | 1209 | ut_ad(mtr->state == MTR_ACTIVE); | 1209 | ut_ad(mtr->state == MTR_ACTIVE); |
3033 | 1210 | 1210 | ||
3034 | @@ -1229,7 +1229,7 @@ | |||
3035 | 1229 | 1229 | ||
3036 | 1230 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 1230 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
3037 | 1231 | ut_a(buf_block_get_state(block) == BUF_BLOCK_FILE_PAGE); | 1231 | ut_a(buf_block_get_state(block) == BUF_BLOCK_FILE_PAGE); |
3039 | 1232 | @@ -2970,7 +3125,10 @@ | 1232 | @@ -2972,7 +3127,10 @@ |
3040 | 1233 | buf_page_t* hash_page; | 1233 | buf_page_t* hash_page; |
3041 | 1234 | 1234 | ||
3042 | 1235 | ut_ad(buf_pool == buf_pool_get(space, offset)); | 1235 | ut_ad(buf_pool == buf_pool_get(space, offset)); |
3043 | @@ -1241,7 +1241,7 @@ | |||
3044 | 1241 | ut_ad(mutex_own(&(block->mutex))); | 1241 | ut_ad(mutex_own(&(block->mutex))); |
3045 | 1242 | ut_a(buf_block_get_state(block) != BUF_BLOCK_FILE_PAGE); | 1242 | ut_a(buf_block_get_state(block) != BUF_BLOCK_FILE_PAGE); |
3046 | 1243 | 1243 | ||
3048 | 1244 | @@ -2999,11 +3157,14 @@ | 1244 | @@ -3001,11 +3159,14 @@ |
3049 | 1245 | if (UNIV_LIKELY(!hash_page)) { | 1245 | if (UNIV_LIKELY(!hash_page)) { |
3050 | 1246 | } else if (buf_pool_watch_is_sentinel(buf_pool, hash_page)) { | 1246 | } else if (buf_pool_watch_is_sentinel(buf_pool, hash_page)) { |
3051 | 1247 | /* Preserve the reference count. */ | 1247 | /* Preserve the reference count. */ |
3052 | @@ -1257,7 +1257,7 @@ | |||
3053 | 1257 | } else { | 1257 | } else { |
3054 | 1258 | fprintf(stderr, | 1258 | fprintf(stderr, |
3055 | 1259 | "InnoDB: Error: page %lu %lu already found" | 1259 | "InnoDB: Error: page %lu %lu already found" |
3057 | 1260 | @@ -3013,7 +3174,8 @@ | 1260 | @@ -3015,7 +3176,8 @@ |
3058 | 1261 | (const void*) hash_page, (const void*) block); | 1261 | (const void*) hash_page, (const void*) block); |
3059 | 1262 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 1262 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
3060 | 1263 | mutex_exit(&block->mutex); | 1263 | mutex_exit(&block->mutex); |
3061 | @@ -1267,7 +1267,7 @@ | |||
3062 | 1267 | buf_print(); | 1267 | buf_print(); |
3063 | 1268 | buf_LRU_print(); | 1268 | buf_LRU_print(); |
3064 | 1269 | buf_validate(); | 1269 | buf_validate(); |
3066 | 1270 | @@ -3096,7 +3258,9 @@ | 1270 | @@ -3098,7 +3260,9 @@ |
3067 | 1271 | 1271 | ||
3068 | 1272 | fold = buf_page_address_fold(space, offset); | 1272 | fold = buf_page_address_fold(space, offset); |
3069 | 1273 | 1273 | ||
3070 | @@ -1278,7 +1278,7 @@ | |||
3071 | 1278 | 1278 | ||
3072 | 1279 | watch_page = buf_page_hash_get_low(buf_pool, space, offset, fold); | 1279 | watch_page = buf_page_hash_get_low(buf_pool, space, offset, fold); |
3073 | 1280 | if (watch_page && !buf_pool_watch_is_sentinel(buf_pool, watch_page)) { | 1280 | if (watch_page && !buf_pool_watch_is_sentinel(buf_pool, watch_page)) { |
3075 | 1281 | @@ -3105,9 +3269,15 @@ | 1281 | @@ -3107,9 +3271,15 @@ |
3076 | 1282 | err_exit: | 1282 | err_exit: |
3077 | 1283 | if (block) { | 1283 | if (block) { |
3078 | 1284 | mutex_enter(&block->mutex); | 1284 | mutex_enter(&block->mutex); |
3079 | @@ -1295,7 +1295,7 @@ | |||
3080 | 1295 | 1295 | ||
3081 | 1296 | bpage = NULL; | 1296 | bpage = NULL; |
3082 | 1297 | goto func_exit; | 1297 | goto func_exit; |
3084 | 1298 | @@ -3130,6 +3300,8 @@ | 1298 | @@ -3132,6 +3302,8 @@ |
3085 | 1299 | 1299 | ||
3086 | 1300 | buf_page_init(buf_pool, space, offset, fold, block); | 1300 | buf_page_init(buf_pool, space, offset, fold, block); |
3087 | 1301 | 1301 | ||
3088 | @@ -1304,7 +1304,7 @@ | |||
3089 | 1304 | /* The block must be put to the LRU list, to the old blocks */ | 1304 | /* The block must be put to the LRU list, to the old blocks */ |
3090 | 1305 | buf_LRU_add_block(bpage, TRUE/* to old blocks */); | 1305 | buf_LRU_add_block(bpage, TRUE/* to old blocks */); |
3091 | 1306 | 1306 | ||
3093 | 1307 | @@ -3157,7 +3329,7 @@ | 1307 | @@ -3159,7 +3331,7 @@ |
3094 | 1308 | been added to buf_pool->LRU and | 1308 | been added to buf_pool->LRU and |
3095 | 1309 | buf_pool->page_hash. */ | 1309 | buf_pool->page_hash. */ |
3096 | 1310 | mutex_exit(&block->mutex); | 1310 | mutex_exit(&block->mutex); |
3097 | @@ -1313,7 +1313,7 @@ | |||
3098 | 1313 | mutex_enter(&block->mutex); | 1313 | mutex_enter(&block->mutex); |
3099 | 1314 | block->page.zip.data = data; | 1314 | block->page.zip.data = data; |
3100 | 1315 | 1315 | ||
3102 | 1316 | @@ -3170,13 +3342,14 @@ | 1316 | @@ -3172,13 +3344,14 @@ |
3103 | 1317 | buf_unzip_LRU_add_block(block, TRUE); | 1317 | buf_unzip_LRU_add_block(block, TRUE); |
3104 | 1318 | } | 1318 | } |
3105 | 1319 | 1319 | ||
3106 | @@ -1329,7 +1329,7 @@ | |||
3107 | 1329 | 1329 | ||
3108 | 1330 | /* If buf_buddy_alloc() allocated storage from the LRU list, | 1330 | /* If buf_buddy_alloc() allocated storage from the LRU list, |
3109 | 1331 | it released and reacquired buf_pool->mutex. Thus, we must | 1331 | it released and reacquired buf_pool->mutex. Thus, we must |
3111 | 1332 | @@ -3192,7 +3365,10 @@ | 1332 | @@ -3194,7 +3367,10 @@ |
3112 | 1333 | 1333 | ||
3113 | 1334 | /* The block was added by some other thread. */ | 1334 | /* The block was added by some other thread. */ |
3114 | 1335 | watch_page = NULL; | 1335 | watch_page = NULL; |
3115 | @@ -1341,7 +1341,7 @@ | |||
3116 | 1341 | 1341 | ||
3117 | 1342 | bpage = NULL; | 1342 | bpage = NULL; |
3118 | 1343 | goto func_exit; | 1343 | goto func_exit; |
3120 | 1344 | @@ -3240,20 +3416,26 @@ | 1344 | @@ -3242,20 +3418,26 @@ |
3121 | 1345 | HASH_INSERT(buf_page_t, hash, buf_pool->page_hash, fold, | 1345 | HASH_INSERT(buf_page_t, hash, buf_pool->page_hash, fold, |
3122 | 1346 | bpage); | 1346 | bpage); |
3123 | 1347 | 1347 | ||
3124 | @@ -1369,7 +1369,7 @@ | |||
3125 | 1369 | 1369 | ||
3126 | 1370 | if (mode == BUF_READ_IBUF_PAGES_ONLY) { | 1370 | if (mode == BUF_READ_IBUF_PAGES_ONLY) { |
3127 | 1371 | 1371 | ||
3129 | 1372 | @@ -3295,7 +3477,9 @@ | 1372 | @@ -3297,7 +3479,9 @@ |
3130 | 1373 | 1373 | ||
3131 | 1374 | fold = buf_page_address_fold(space, offset); | 1374 | fold = buf_page_address_fold(space, offset); |
3132 | 1375 | 1375 | ||
3133 | @@ -1380,7 +1380,7 @@ | |||
3134 | 1380 | 1380 | ||
3135 | 1381 | block = (buf_block_t*) buf_page_hash_get_low( | 1381 | block = (buf_block_t*) buf_page_hash_get_low( |
3136 | 1382 | buf_pool, space, offset, fold); | 1382 | buf_pool, space, offset, fold); |
3138 | 1383 | @@ -3311,7 +3495,9 @@ | 1383 | @@ -3313,7 +3497,9 @@ |
3139 | 1384 | #endif /* UNIV_DEBUG_FILE_ACCESSES || UNIV_DEBUG */ | 1384 | #endif /* UNIV_DEBUG_FILE_ACCESSES || UNIV_DEBUG */ |
3140 | 1385 | 1385 | ||
3141 | 1386 | /* Page can be found in buf_pool */ | 1386 | /* Page can be found in buf_pool */ |
3142 | @@ -1391,7 +1391,7 @@ | |||
3143 | 1391 | 1391 | ||
3144 | 1392 | buf_block_free(free_block); | 1392 | buf_block_free(free_block); |
3145 | 1393 | 1393 | ||
3147 | 1394 | @@ -3333,6 +3519,7 @@ | 1394 | @@ -3335,6 +3521,7 @@ |
3148 | 1395 | mutex_enter(&block->mutex); | 1395 | mutex_enter(&block->mutex); |
3149 | 1396 | 1396 | ||
3150 | 1397 | buf_page_init(buf_pool, space, offset, fold, block); | 1397 | buf_page_init(buf_pool, space, offset, fold, block); |
3151 | @@ -1399,7 +1399,7 @@ | |||
3152 | 1399 | 1399 | ||
3153 | 1400 | /* The block must be put to the LRU list */ | 1400 | /* The block must be put to the LRU list */ |
3154 | 1401 | buf_LRU_add_block(&block->page, FALSE); | 1401 | buf_LRU_add_block(&block->page, FALSE); |
3156 | 1402 | @@ -3359,7 +3546,7 @@ | 1402 | @@ -3361,7 +3548,7 @@ |
3157 | 1403 | the reacquisition of buf_pool->mutex. We also must | 1403 | the reacquisition of buf_pool->mutex. We also must |
3158 | 1404 | defer this operation until after the block descriptor | 1404 | defer this operation until after the block descriptor |
3159 | 1405 | has been added to buf_pool->LRU and buf_pool->page_hash. */ | 1405 | has been added to buf_pool->LRU and buf_pool->page_hash. */ |
3160 | @@ -1408,7 +1408,7 @@ | |||
3161 | 1408 | mutex_enter(&block->mutex); | 1408 | mutex_enter(&block->mutex); |
3162 | 1409 | block->page.zip.data = data; | 1409 | block->page.zip.data = data; |
3163 | 1410 | 1410 | ||
3165 | 1411 | @@ -3377,7 +3564,8 @@ | 1411 | @@ -3379,7 +3566,8 @@ |
3166 | 1412 | 1412 | ||
3167 | 1413 | buf_page_set_accessed(&block->page, time_ms); | 1413 | buf_page_set_accessed(&block->page, time_ms); |
3168 | 1414 | 1414 | ||
3169 | @@ -1418,7 +1418,7 @@ | |||
3170 | 1418 | 1418 | ||
3171 | 1419 | mtr_memo_push(mtr, block, MTR_MEMO_BUF_FIX); | 1419 | mtr_memo_push(mtr, block, MTR_MEMO_BUF_FIX); |
3172 | 1420 | 1420 | ||
3174 | 1421 | @@ -3432,7 +3620,9 @@ | 1421 | @@ -3434,7 +3622,9 @@ |
3175 | 1422 | ibool ret = TRUE; | 1422 | ibool ret = TRUE; |
3176 | 1423 | 1423 | ||
3177 | 1424 | /* First unfix and release lock on the bpage */ | 1424 | /* First unfix and release lock on the bpage */ |
3178 | @@ -1429,7 +1429,7 @@ | |||
3179 | 1429 | mutex_enter(buf_page_get_mutex(bpage)); | 1429 | mutex_enter(buf_page_get_mutex(bpage)); |
3180 | 1430 | ut_ad(buf_page_get_io_fix(bpage) == BUF_IO_READ); | 1430 | ut_ad(buf_page_get_io_fix(bpage) == BUF_IO_READ); |
3181 | 1431 | ut_ad(bpage->buf_fix_count == 0); | 1431 | ut_ad(bpage->buf_fix_count == 0); |
3183 | 1432 | @@ -3453,11 +3643,15 @@ | 1432 | @@ -3455,11 +3645,15 @@ |
3184 | 1433 | ret = FALSE; | 1433 | ret = FALSE; |
3185 | 1434 | } | 1434 | } |
3186 | 1435 | 1435 | ||
3187 | @@ -1446,7 +1446,7 @@ | |||
3188 | 1446 | 1446 | ||
3189 | 1447 | return(ret); | 1447 | return(ret); |
3190 | 1448 | } | 1448 | } |
3192 | 1449 | @@ -3475,6 +3669,8 @@ | 1449 | @@ -3477,6 +3671,8 @@ |
3193 | 1450 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 1450 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
3194 | 1451 | const ibool uncompressed = (buf_page_get_state(bpage) | 1451 | const ibool uncompressed = (buf_page_get_state(bpage) |
3195 | 1452 | == BUF_BLOCK_FILE_PAGE); | 1452 | == BUF_BLOCK_FILE_PAGE); |
3196 | @@ -1455,7 +1455,7 @@ | |||
3197 | 1455 | 1455 | ||
3198 | 1456 | ut_a(buf_page_in_file(bpage)); | 1456 | ut_a(buf_page_in_file(bpage)); |
3199 | 1457 | 1457 | ||
3201 | 1458 | @@ -3617,8 +3813,26 @@ | 1458 | @@ -3619,8 +3815,26 @@ |
3202 | 1459 | } | 1459 | } |
3203 | 1460 | } | 1460 | } |
3204 | 1461 | 1461 | ||
3205 | @@ -1483,7 +1483,7 @@ | |||
3206 | 1483 | 1483 | ||
3207 | 1484 | #ifdef UNIV_IBUF_COUNT_DEBUG | 1484 | #ifdef UNIV_IBUF_COUNT_DEBUG |
3208 | 1485 | if (io_type == BUF_IO_WRITE || uncompressed) { | 1485 | if (io_type == BUF_IO_WRITE || uncompressed) { |
3210 | 1486 | @@ -3641,6 +3855,7 @@ | 1486 | @@ -3643,6 +3857,7 @@ |
3211 | 1487 | the x-latch to this OS thread: do not let this confuse you in | 1487 | the x-latch to this OS thread: do not let this confuse you in |
3212 | 1488 | debugging! */ | 1488 | debugging! */ |
3213 | 1489 | 1489 | ||
3214 | @@ -1491,7 +1491,7 @@ | |||
3215 | 1491 | ut_ad(buf_pool->n_pend_reads > 0); | 1491 | ut_ad(buf_pool->n_pend_reads > 0); |
3216 | 1492 | buf_pool->n_pend_reads--; | 1492 | buf_pool->n_pend_reads--; |
3217 | 1493 | buf_pool->stat.n_pages_read++; | 1493 | buf_pool->stat.n_pages_read++; |
3219 | 1494 | @@ -3658,6 +3873,9 @@ | 1494 | @@ -3660,6 +3875,9 @@ |
3220 | 1495 | 1495 | ||
3221 | 1496 | buf_flush_write_complete(bpage); | 1496 | buf_flush_write_complete(bpage); |
3222 | 1497 | 1497 | ||
3223 | @@ -1501,7 +1501,7 @@ | |||
3224 | 1501 | if (uncompressed) { | 1501 | if (uncompressed) { |
3225 | 1502 | rw_lock_s_unlock_gen(&((buf_block_t*) bpage)->lock, | 1502 | rw_lock_s_unlock_gen(&((buf_block_t*) bpage)->lock, |
3226 | 1503 | BUF_IO_WRITE); | 1503 | BUF_IO_WRITE); |
3228 | 1504 | @@ -3680,8 +3898,8 @@ | 1504 | @@ -3682,8 +3900,8 @@ |
3229 | 1505 | } | 1505 | } |
3230 | 1506 | #endif /* UNIV_DEBUG */ | 1506 | #endif /* UNIV_DEBUG */ |
3231 | 1507 | 1507 | ||
3232 | @@ -1511,7 +1511,7 @@ | |||
3233 | 1511 | } | 1511 | } |
3234 | 1512 | 1512 | ||
3235 | 1513 | /*********************************************************************//** | 1513 | /*********************************************************************//** |
3237 | 1514 | @@ -3698,7 +3916,9 @@ | 1514 | @@ -3700,7 +3918,9 @@ |
3238 | 1515 | 1515 | ||
3239 | 1516 | ut_ad(buf_pool); | 1516 | ut_ad(buf_pool); |
3240 | 1517 | 1517 | ||
3241 | @@ -1522,7 +1522,7 @@ | |||
3242 | 1522 | 1522 | ||
3243 | 1523 | chunk = buf_pool->chunks; | 1523 | chunk = buf_pool->chunks; |
3244 | 1524 | 1524 | ||
3246 | 1525 | @@ -3715,7 +3935,9 @@ | 1525 | @@ -3717,7 +3937,9 @@ |
3247 | 1526 | } | 1526 | } |
3248 | 1527 | } | 1527 | } |
3249 | 1528 | 1528 | ||
3250 | @@ -1533,7 +1533,7 @@ | |||
3251 | 1533 | 1533 | ||
3252 | 1534 | return(TRUE); | 1534 | return(TRUE); |
3253 | 1535 | } | 1535 | } |
3255 | 1536 | @@ -3763,7 +3985,8 @@ | 1536 | @@ -3765,7 +3987,8 @@ |
3256 | 1537 | freed = buf_LRU_search_and_free_block(buf_pool, 100); | 1537 | freed = buf_LRU_search_and_free_block(buf_pool, 100); |
3257 | 1538 | } | 1538 | } |
3258 | 1539 | 1539 | ||
3259 | @@ -1543,7 +1543,7 @@ | |||
3260 | 1543 | 1543 | ||
3261 | 1544 | ut_ad(UT_LIST_GET_LEN(buf_pool->LRU) == 0); | 1544 | ut_ad(UT_LIST_GET_LEN(buf_pool->LRU) == 0); |
3262 | 1545 | ut_ad(UT_LIST_GET_LEN(buf_pool->unzip_LRU) == 0); | 1545 | ut_ad(UT_LIST_GET_LEN(buf_pool->unzip_LRU) == 0); |
3264 | 1546 | @@ -3776,7 +3999,8 @@ | 1546 | @@ -3778,7 +4001,8 @@ |
3265 | 1547 | memset(&buf_pool->stat, 0x00, sizeof(buf_pool->stat)); | 1547 | memset(&buf_pool->stat, 0x00, sizeof(buf_pool->stat)); |
3266 | 1548 | buf_refresh_io_stats(buf_pool); | 1548 | buf_refresh_io_stats(buf_pool); |
3267 | 1549 | 1549 | ||
3268 | @@ -1553,7 +1553,7 @@ | |||
3269 | 1553 | } | 1553 | } |
3270 | 1554 | 1554 | ||
3271 | 1555 | /*********************************************************************//** | 1555 | /*********************************************************************//** |
3273 | 1556 | @@ -3818,7 +4042,10 @@ | 1556 | @@ -3820,7 +4044,10 @@ |
3274 | 1557 | 1557 | ||
3275 | 1558 | ut_ad(buf_pool); | 1558 | ut_ad(buf_pool); |
3276 | 1559 | 1559 | ||
3277 | @@ -1565,7 +1565,7 @@ | |||
3278 | 1565 | 1565 | ||
3279 | 1566 | chunk = buf_pool->chunks; | 1566 | chunk = buf_pool->chunks; |
3280 | 1567 | 1567 | ||
3282 | 1568 | @@ -3913,7 +4140,7 @@ | 1568 | @@ -3918,7 +4145,7 @@ |
3283 | 1569 | /* Check clean compressed-only blocks. */ | 1569 | /* Check clean compressed-only blocks. */ |
3284 | 1570 | 1570 | ||
3285 | 1571 | for (b = UT_LIST_GET_FIRST(buf_pool->zip_clean); b; | 1571 | for (b = UT_LIST_GET_FIRST(buf_pool->zip_clean); b; |
3286 | @@ -1574,7 +1574,7 @@ | |||
3287 | 1574 | ut_a(buf_page_get_state(b) == BUF_BLOCK_ZIP_PAGE); | 1574 | ut_a(buf_page_get_state(b) == BUF_BLOCK_ZIP_PAGE); |
3288 | 1575 | switch (buf_page_get_io_fix(b)) { | 1575 | switch (buf_page_get_io_fix(b)) { |
3289 | 1576 | case BUF_IO_NONE: | 1576 | case BUF_IO_NONE: |
3291 | 1577 | @@ -3944,7 +4171,7 @@ | 1577 | @@ -3950,7 +4177,7 @@ |
3292 | 1578 | 1578 | ||
3293 | 1579 | buf_flush_list_mutex_enter(buf_pool); | 1579 | buf_flush_list_mutex_enter(buf_pool); |
3294 | 1580 | for (b = UT_LIST_GET_FIRST(buf_pool->flush_list); b; | 1580 | for (b = UT_LIST_GET_FIRST(buf_pool->flush_list); b; |
3295 | @@ -1583,7 +1583,7 @@ | |||
3296 | 1583 | ut_ad(b->in_flush_list); | 1583 | ut_ad(b->in_flush_list); |
3297 | 1584 | ut_a(b->oldest_modification); | 1584 | ut_a(b->oldest_modification); |
3298 | 1585 | n_flush++; | 1585 | n_flush++; |
3300 | 1586 | @@ -4003,6 +4230,8 @@ | 1586 | @@ -4010,6 +4237,8 @@ |
3301 | 1587 | } | 1587 | } |
3302 | 1588 | 1588 | ||
3303 | 1589 | ut_a(UT_LIST_GET_LEN(buf_pool->LRU) == n_lru); | 1589 | ut_a(UT_LIST_GET_LEN(buf_pool->LRU) == n_lru); |
3304 | @@ -1592,7 +1592,7 @@ | |||
3305 | 1592 | if (UT_LIST_GET_LEN(buf_pool->free) != n_free) { | 1592 | if (UT_LIST_GET_LEN(buf_pool->free) != n_free) { |
3306 | 1593 | fprintf(stderr, "Free list len %lu, free blocks %lu\n", | 1593 | fprintf(stderr, "Free list len %lu, free blocks %lu\n", |
3307 | 1594 | (ulong) UT_LIST_GET_LEN(buf_pool->free), | 1594 | (ulong) UT_LIST_GET_LEN(buf_pool->free), |
3309 | 1595 | @@ -4013,8 +4242,11 @@ | 1595 | @@ -4020,8 +4249,11 @@ |
3310 | 1596 | ut_a(buf_pool->n_flush[BUF_FLUSH_SINGLE_PAGE] == n_single_flush); | 1596 | ut_a(buf_pool->n_flush[BUF_FLUSH_SINGLE_PAGE] == n_single_flush); |
3311 | 1597 | ut_a(buf_pool->n_flush[BUF_FLUSH_LIST] == n_list_flush); | 1597 | ut_a(buf_pool->n_flush[BUF_FLUSH_LIST] == n_list_flush); |
3312 | 1598 | ut_a(buf_pool->n_flush[BUF_FLUSH_LRU] == n_lru_flush); | 1598 | ut_a(buf_pool->n_flush[BUF_FLUSH_LRU] == n_lru_flush); |
3313 | @@ -1605,7 +1605,7 @@ | |||
3314 | 1605 | 1605 | ||
3315 | 1606 | ut_a(buf_LRU_validate()); | 1606 | ut_a(buf_LRU_validate()); |
3316 | 1607 | ut_a(buf_flush_validate(buf_pool)); | 1607 | ut_a(buf_flush_validate(buf_pool)); |
3318 | 1608 | @@ -4070,7 +4302,9 @@ | 1608 | @@ -4077,7 +4309,9 @@ |
3319 | 1609 | index_ids = mem_alloc(size * sizeof *index_ids); | 1609 | index_ids = mem_alloc(size * sizeof *index_ids); |
3320 | 1610 | counts = mem_alloc(sizeof(ulint) * size); | 1610 | counts = mem_alloc(sizeof(ulint) * size); |
3321 | 1611 | 1611 | ||
3322 | @@ -1616,7 +1616,7 @@ | |||
3323 | 1616 | buf_flush_list_mutex_enter(buf_pool); | 1616 | buf_flush_list_mutex_enter(buf_pool); |
3324 | 1617 | 1617 | ||
3325 | 1618 | fprintf(stderr, | 1618 | fprintf(stderr, |
3327 | 1619 | @@ -4139,7 +4373,9 @@ | 1619 | @@ -4146,7 +4380,9 @@ |
3328 | 1620 | } | 1620 | } |
3329 | 1621 | } | 1621 | } |
3330 | 1622 | 1622 | ||
3331 | @@ -1627,7 +1627,7 @@ | |||
3332 | 1627 | 1627 | ||
3333 | 1628 | for (i = 0; i < n_found; i++) { | 1628 | for (i = 0; i < n_found; i++) { |
3334 | 1629 | index = dict_index_get_if_in_cache(index_ids[i]); | 1629 | index = dict_index_get_if_in_cache(index_ids[i]); |
3336 | 1630 | @@ -4196,7 +4432,7 @@ | 1630 | @@ -4203,7 +4439,7 @@ |
3337 | 1631 | buf_chunk_t* chunk; | 1631 | buf_chunk_t* chunk; |
3338 | 1632 | ulint fixed_pages_number = 0; | 1632 | ulint fixed_pages_number = 0; |
3339 | 1633 | 1633 | ||
3340 | @@ -1636,7 +1636,7 @@ | |||
3341 | 1636 | 1636 | ||
3342 | 1637 | chunk = buf_pool->chunks; | 1637 | chunk = buf_pool->chunks; |
3343 | 1638 | 1638 | ||
3345 | 1639 | @@ -4230,7 +4466,7 @@ | 1639 | @@ -4237,7 +4473,7 @@ |
3346 | 1640 | /* Traverse the lists of clean and dirty compressed-only blocks. */ | 1640 | /* Traverse the lists of clean and dirty compressed-only blocks. */ |
3347 | 1641 | 1641 | ||
3348 | 1642 | for (b = UT_LIST_GET_FIRST(buf_pool->zip_clean); b; | 1642 | for (b = UT_LIST_GET_FIRST(buf_pool->zip_clean); b; |
3349 | @@ -1645,7 +1645,7 @@ | |||
3350 | 1645 | ut_a(buf_page_get_state(b) == BUF_BLOCK_ZIP_PAGE); | 1645 | ut_a(buf_page_get_state(b) == BUF_BLOCK_ZIP_PAGE); |
3351 | 1646 | ut_a(buf_page_get_io_fix(b) != BUF_IO_WRITE); | 1646 | ut_a(buf_page_get_io_fix(b) != BUF_IO_WRITE); |
3352 | 1647 | 1647 | ||
3354 | 1648 | @@ -4242,7 +4478,7 @@ | 1648 | @@ -4249,7 +4485,7 @@ |
3355 | 1649 | 1649 | ||
3356 | 1650 | buf_flush_list_mutex_enter(buf_pool); | 1650 | buf_flush_list_mutex_enter(buf_pool); |
3357 | 1651 | for (b = UT_LIST_GET_FIRST(buf_pool->flush_list); b; | 1651 | for (b = UT_LIST_GET_FIRST(buf_pool->flush_list); b; |
3358 | @@ -1654,7 +1654,7 @@ | |||
3359 | 1654 | ut_ad(b->in_flush_list); | 1654 | ut_ad(b->in_flush_list); |
3360 | 1655 | 1655 | ||
3361 | 1656 | switch (buf_page_get_state(b)) { | 1656 | switch (buf_page_get_state(b)) { |
3363 | 1657 | @@ -4268,7 +4504,7 @@ | 1657 | @@ -4275,7 +4511,7 @@ |
3364 | 1658 | 1658 | ||
3365 | 1659 | buf_flush_list_mutex_exit(buf_pool); | 1659 | buf_flush_list_mutex_exit(buf_pool); |
3366 | 1660 | mutex_exit(&buf_pool->zip_mutex); | 1660 | mutex_exit(&buf_pool->zip_mutex); |
3367 | @@ -1663,7 +1663,7 @@ | |||
3368 | 1663 | 1663 | ||
3369 | 1664 | return(fixed_pages_number); | 1664 | return(fixed_pages_number); |
3370 | 1665 | } | 1665 | } |
3372 | 1666 | @@ -4426,6 +4662,8 @@ | 1666 | @@ -4433,6 +4669,8 @@ |
3373 | 1667 | /* Find appropriate pool_info to store stats for this buffer pool */ | 1667 | /* Find appropriate pool_info to store stats for this buffer pool */ |
3374 | 1668 | pool_info = &all_pool_info[pool_id]; | 1668 | pool_info = &all_pool_info[pool_id]; |
3375 | 1669 | 1669 | ||
3376 | @@ -1672,7 +1672,7 @@ | |||
3377 | 1672 | buf_pool_mutex_enter(buf_pool); | 1672 | buf_pool_mutex_enter(buf_pool); |
3378 | 1673 | buf_flush_list_mutex_enter(buf_pool); | 1673 | buf_flush_list_mutex_enter(buf_pool); |
3379 | 1674 | 1674 | ||
3381 | 1675 | @@ -4541,6 +4779,8 @@ | 1675 | @@ -4548,6 +4786,8 @@ |
3382 | 1676 | pool_info->unzip_cur = buf_LRU_stat_cur.unzip; | 1676 | pool_info->unzip_cur = buf_LRU_stat_cur.unzip; |
3383 | 1677 | 1677 | ||
3384 | 1678 | buf_refresh_io_stats(buf_pool); | 1678 | buf_refresh_io_stats(buf_pool); |
3385 | @@ -1681,7 +1681,7 @@ | |||
3386 | 1681 | buf_pool_mutex_exit(buf_pool); | 1681 | buf_pool_mutex_exit(buf_pool); |
3387 | 1682 | } | 1682 | } |
3388 | 1683 | 1683 | ||
3390 | 1684 | @@ -4785,11 +5025,13 @@ | 1684 | @@ -4792,11 +5032,13 @@ |
3391 | 1685 | { | 1685 | { |
3392 | 1686 | ulint len; | 1686 | ulint len; |
3393 | 1687 | 1687 | ||
3394 | @@ -2127,7 +2127,7 @@ | |||
3395 | 2127 | } | 2127 | } |
3396 | 2128 | --- a/storage/innobase/buf/buf0lru.c | 2128 | --- a/storage/innobase/buf/buf0lru.c |
3397 | 2129 | +++ b/storage/innobase/buf/buf0lru.c | 2129 | +++ b/storage/innobase/buf/buf0lru.c |
3399 | 2130 | @@ -143,8 +143,9 @@ | 2130 | @@ -147,8 +147,9 @@ |
3400 | 2131 | void | 2131 | void |
3401 | 2132 | buf_LRU_block_free_hashed_page( | 2132 | buf_LRU_block_free_hashed_page( |
3402 | 2133 | /*===========================*/ | 2133 | /*===========================*/ |
3403 | @@ -2138,7 +2138,7 @@ | |||
3404 | 2138 | 2138 | ||
3405 | 2139 | /******************************************************************//** | 2139 | /******************************************************************//** |
3406 | 2140 | Determines if the unzip_LRU list should be used for evicting a victim | 2140 | Determines if the unzip_LRU list should be used for evicting a victim |
3408 | 2141 | @@ -154,15 +155,20 @@ | 2141 | @@ -158,15 +159,20 @@ |
3409 | 2142 | ibool | 2142 | ibool |
3410 | 2143 | buf_LRU_evict_from_unzip_LRU( | 2143 | buf_LRU_evict_from_unzip_LRU( |
3411 | 2144 | /*=========================*/ | 2144 | /*=========================*/ |
3412 | @@ -2161,7 +2161,7 @@ | |||
3413 | 2161 | return(FALSE); | 2161 | return(FALSE); |
3414 | 2162 | } | 2162 | } |
3415 | 2163 | 2163 | ||
3417 | 2164 | @@ -171,14 +177,20 @@ | 2164 | @@ -175,14 +181,20 @@ |
3418 | 2165 | decompressed pages in the buffer pool. */ | 2165 | decompressed pages in the buffer pool. */ |
3419 | 2166 | if (UT_LIST_GET_LEN(buf_pool->unzip_LRU) | 2166 | if (UT_LIST_GET_LEN(buf_pool->unzip_LRU) |
3420 | 2167 | <= UT_LIST_GET_LEN(buf_pool->LRU) / 10) { | 2167 | <= UT_LIST_GET_LEN(buf_pool->LRU) / 10) { |
3421 | @@ -2182,9 +2182,9 @@ | |||
3422 | 2182 | 2182 | ||
3423 | 2183 | /* Calculate the average over past intervals, and add the values | 2183 | /* Calculate the average over past intervals, and add the values |
3424 | 2184 | of the current interval. */ | 2184 | of the current interval. */ |
3426 | 2185 | @@ -246,18 +258,25 @@ | 2185 | @@ -250,18 +262,25 @@ |
3427 | 2186 | page_arr = ut_malloc( | 2186 | page_arr = ut_malloc( |
3429 | 2187 | sizeof(ulint) * BUF_LRU_DROP_SEARCH_HASH_SIZE); | 2187 | sizeof(ulint) * BUF_LRU_DROP_SEARCH_SIZE); |
3430 | 2188 | 2188 | ||
3431 | 2189 | - buf_pool_mutex_enter(buf_pool); | 2189 | - buf_pool_mutex_enter(buf_pool); |
3432 | 2190 | + //buf_pool_mutex_enter(buf_pool); | 2190 | + //buf_pool_mutex_enter(buf_pool); |
3433 | @@ -2209,7 +2209,7 @@ | |||
3434 | 2209 | ut_a(buf_page_in_file(bpage)); | 2209 | ut_a(buf_page_in_file(bpage)); |
3435 | 2210 | 2210 | ||
3436 | 2211 | if (buf_page_get_state(bpage) != BUF_BLOCK_FILE_PAGE | 2211 | if (buf_page_get_state(bpage) != BUF_BLOCK_FILE_PAGE |
3438 | 2212 | @@ -266,23 +285,27 @@ | 2212 | @@ -270,24 +289,30 @@ |
3439 | 2213 | /* Compressed pages are never hashed. | 2213 | /* Compressed pages are never hashed. |
3440 | 2214 | Skip blocks of other tablespaces. | 2214 | Skip blocks of other tablespaces. |
3441 | 2215 | Skip I/O-fixed blocks (to be dealt with later). */ | 2215 | Skip I/O-fixed blocks (to be dealt with later). */ |
3442 | @@ -2234,12 +2234,15 @@ | |||
3443 | 2234 | /* Store the page number so that we can drop the hash | 2234 | /* Store the page number so that we can drop the hash |
3444 | 2235 | index in a batch later. */ | 2235 | index in a batch later. */ |
3445 | 2236 | page_arr[num_entries] = bpage->offset; | 2236 | page_arr[num_entries] = bpage->offset; |
3446 | 2237 | + | ||
3447 | 2237 | + mutex_exit(block_mutex); | 2238 | + mutex_exit(block_mutex); |
3448 | 2238 | + | 2239 | + |
3450 | 2239 | ut_a(num_entries < BUF_LRU_DROP_SEARCH_HASH_SIZE); | 2240 | ut_a(num_entries < BUF_LRU_DROP_SEARCH_SIZE); |
3451 | 2241 | + | ||
3452 | 2240 | ++num_entries; | 2242 | ++num_entries; |
3453 | 2241 | 2243 | ||
3455 | 2242 | @@ -292,14 +315,16 @@ | 2244 | if (num_entries < BUF_LRU_DROP_SEARCH_SIZE) { |
3456 | 2245 | @@ -296,14 +321,16 @@ | ||
3457 | 2243 | 2246 | ||
3458 | 2244 | /* Array full. We release the buf_pool->mutex to obey | 2247 | /* Array full. We release the buf_pool->mutex to obey |
3459 | 2245 | the latching order. */ | 2248 | the latching order. */ |
3460 | @@ -2258,7 +2261,7 @@ | |||
3461 | 2258 | 2261 | ||
3462 | 2259 | /* Note that we released the buf_pool mutex above | 2262 | /* Note that we released the buf_pool mutex above |
3463 | 2260 | after reading the prev_bpage during processing of a | 2263 | after reading the prev_bpage during processing of a |
3465 | 2261 | @@ -317,13 +342,23 @@ | 2264 | @@ -321,13 +348,23 @@ |
3466 | 2262 | /* If, however, bpage has been removed from LRU list | 2265 | /* If, however, bpage has been removed from LRU list |
3467 | 2263 | to the free list then we should restart the scan. | 2266 | to the free list then we should restart the scan. |
3468 | 2264 | bpage->state is protected by buf_pool mutex. */ | 2267 | bpage->state is protected by buf_pool mutex. */ |
3469 | @@ -2283,67 +2286,73 @@ | |||
3470 | 2283 | 2286 | ||
3471 | 2284 | /* Drop any remaining batch of search hashed pages. */ | 2287 | /* Drop any remaining batch of search hashed pages. */ |
3472 | 2285 | buf_LRU_drop_page_hash_batch(id, zip_size, page_arr, num_entries); | 2288 | buf_LRU_drop_page_hash_batch(id, zip_size, page_arr, num_entries); |
3475 | 2286 | @@ -345,7 +380,9 @@ | 2289 | @@ -351,7 +388,9 @@ |
3476 | 2287 | ibool all_freed; | 2290 | ulint i; |
3477 | 2288 | 2291 | ||
3478 | 2289 | scan_again: | 2292 | scan_again: |
3479 | 2290 | - buf_pool_mutex_enter(buf_pool); | 2293 | - buf_pool_mutex_enter(buf_pool); |
3480 | 2291 | + //buf_pool_mutex_enter(buf_pool); | 2294 | + //buf_pool_mutex_enter(buf_pool); |
3481 | 2292 | + mutex_enter(&buf_pool->LRU_list_mutex); | 2295 | + mutex_enter(&buf_pool->LRU_list_mutex); |
3482 | 2293 | + rw_lock_x_lock(&buf_pool->page_hash_latch); | 2296 | + rw_lock_x_lock(&buf_pool->page_hash_latch); |
3483 | 2297 | buf_flush_list_mutex_enter(buf_pool); | ||
3484 | 2294 | 2298 | ||
3485 | 2295 | all_freed = TRUE; | 2299 | all_freed = TRUE; |
3522 | 2296 | 2300 | @@ -364,7 +403,7 @@ | |
3523 | 2297 | @@ -375,8 +412,15 @@ | 2301 | |
3524 | 2298 | all_freed = FALSE; | 2302 | ut_a(buf_page_in_file(bpage)); |
3525 | 2299 | goto next_page; | 2303 | |
3526 | 2300 | } else { | 2304 | - prev_bpage = UT_LIST_GET_PREV(list, bpage); |
3527 | 2301 | - block_mutex = buf_page_get_mutex(bpage); | 2305 | + prev_bpage = UT_LIST_GET_PREV(flush_list, bpage); |
3528 | 2302 | - mutex_enter(block_mutex); | 2306 | |
3529 | 2303 | + block_mutex = buf_page_get_mutex_enter(bpage); | 2307 | /* bpage->space and bpage->io_fix are protected by |
3530 | 2304 | + | 2308 | buf_pool->mutex and block_mutex. It is safe to check |
3531 | 2305 | + if (!block_mutex) { | 2309 | @@ -388,8 +427,14 @@ |
3532 | 2306 | + /* It may be impossible case... | 2310 | will stay in the flush_list because buf_flush_remove() |
3533 | 2307 | + Something wrong, so will be scan_again */ | 2311 | needs buf_pool->mutex as well. */ |
3534 | 2308 | + | 2312 | buf_flush_list_mutex_exit(buf_pool); |
3535 | 2309 | + all_freed = FALSE; | 2313 | - block_mutex = buf_page_get_mutex(bpage); |
3536 | 2310 | + goto next_page; | 2314 | - mutex_enter(block_mutex); |
3537 | 2311 | + } | 2315 | + block_mutex = buf_page_get_mutex_enter(bpage); |
3538 | 2312 | 2316 | + | |
3539 | 2313 | if (bpage->buf_fix_count > 0) { | 2317 | + if (!block_mutex) { |
3540 | 2314 | 2318 | + /* It may be impossible case... | |
3541 | 2315 | @@ -409,7 +453,9 @@ | 2319 | + Something wrong, so will be scan_again */ |
3542 | 2316 | ulint page_no; | 2320 | + all_freed = FALSE; |
3543 | 2317 | ulint zip_size; | 2321 | + goto next_page; |
3544 | 2318 | 2322 | + } | |
3545 | 2319 | - buf_pool_mutex_exit(buf_pool); | 2323 | |
3546 | 2320 | + //buf_pool_mutex_exit(buf_pool); | 2324 | if (bpage->buf_fix_count > 0) { |
3511 | 2321 | + mutex_exit(&buf_pool->LRU_list_mutex); | ||
3512 | 2322 | + rw_lock_x_unlock(&buf_pool->page_hash_latch); | ||
3513 | 2323 | |||
3514 | 2324 | zip_size = buf_page_get_zip_size(bpage); | ||
3515 | 2325 | page_no = buf_page_get_page_no(bpage); | ||
3516 | 2326 | @@ -433,7 +479,7 @@ | ||
3517 | 2327 | |||
3518 | 2328 | if (buf_LRU_block_remove_hashed_page(bpage, TRUE) | ||
3519 | 2329 | != BUF_BLOCK_ZIP_FREE) { | ||
3520 | 2330 | - buf_LRU_block_free_hashed_page((buf_block_t*) bpage); | ||
3521 | 2331 | + buf_LRU_block_free_hashed_page((buf_block_t*) bpage, TRUE); | ||
3547 | 2332 | mutex_exit(block_mutex); | 2325 | mutex_exit(block_mutex); |
3552 | 2333 | } else { | 2326 | @@ -440,9 +485,15 @@ |
3553 | 2334 | /* The block_mutex should have been released | 2327 | mutex_exit(block_mutex); |
3554 | 2335 | @@ -446,7 +492,9 @@ | 2328 | |
3555 | 2336 | bpage = prev_bpage; | 2329 | /* Now it is safe to release the buf_pool->mutex. */ |
3556 | 2330 | - buf_pool_mutex_exit(buf_pool); | ||
3557 | 2331 | + //buf_pool_mutex_exit(buf_pool); | ||
3558 | 2332 | + mutex_exit(&buf_pool->LRU_list_mutex); | ||
3559 | 2333 | + rw_lock_x_unlock(&buf_pool->page_hash_latch); | ||
3560 | 2334 | + | ||
3561 | 2335 | os_thread_yield(); | ||
3562 | 2336 | - buf_pool_mutex_enter(buf_pool); | ||
3563 | 2337 | + //buf_pool_mutex_enter(buf_pool); | ||
3564 | 2338 | + mutex_enter(&buf_pool->LRU_list_mutex); | ||
3565 | 2339 | + rw_lock_x_lock(&buf_pool->page_hash_latch); | ||
3566 | 2340 | + | ||
3567 | 2341 | |||
3568 | 2342 | mutex_enter(block_mutex); | ||
3569 | 2343 | buf_page_unset_sticky(bpage); | ||
3570 | 2344 | @@ -454,7 +505,9 @@ | ||
3571 | 2345 | i = 0; | ||
3572 | 2337 | } | 2346 | } |
3573 | 2338 | 2347 | ||
3574 | 2339 | - buf_pool_mutex_exit(buf_pool); | 2348 | - buf_pool_mutex_exit(buf_pool); |
3576 | 2340 | + //buf_pool_mutex_exit(buf_pool); | 2349 | +// buf_pool_mutex_exit(buf_pool); |
3577 | 2341 | + mutex_exit(&buf_pool->LRU_list_mutex); | 2350 | + mutex_exit(&buf_pool->LRU_list_mutex); |
3578 | 2342 | + rw_lock_x_unlock(&buf_pool->page_hash_latch); | 2351 | + rw_lock_x_unlock(&buf_pool->page_hash_latch); |
3579 | 2352 | buf_flush_list_mutex_exit(buf_pool); | ||
3580 | 2343 | 2353 | ||
3584 | 2344 | if (!all_freed) { | 2354 | ut_ad(buf_flush_validate(buf_pool)); |
3585 | 2345 | os_thread_sleep(20000); | 2355 | @@ -504,7 +557,9 @@ |
3583 | 2346 | @@ -493,7 +541,9 @@ | ||
3586 | 2347 | buf_page_t* b; | 2356 | buf_page_t* b; |
3587 | 2348 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 2357 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
3588 | 2349 | 2358 | ||
3589 | @@ -2354,7 +2363,7 @@ | |||
3590 | 2354 | ut_ad(buf_page_get_state(bpage) == BUF_BLOCK_ZIP_PAGE); | 2363 | ut_ad(buf_page_get_state(bpage) == BUF_BLOCK_ZIP_PAGE); |
3591 | 2355 | 2364 | ||
3592 | 2356 | /* Find the first successor of bpage in the LRU list | 2365 | /* Find the first successor of bpage in the LRU list |
3594 | 2357 | @@ -501,17 +551,17 @@ | 2366 | @@ -512,17 +567,17 @@ |
3595 | 2358 | b = bpage; | 2367 | b = bpage; |
3596 | 2359 | do { | 2368 | do { |
3597 | 2360 | b = UT_LIST_GET_NEXT(LRU, b); | 2369 | b = UT_LIST_GET_NEXT(LRU, b); |
3598 | @@ -2376,7 +2385,7 @@ | |||
3599 | 2376 | } | 2385 | } |
3600 | 2377 | } | 2386 | } |
3601 | 2378 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ | 2387 | #endif /* UNIV_DEBUG || UNIV_BUF_DEBUG */ |
3603 | 2379 | @@ -525,18 +575,19 @@ | 2388 | @@ -536,18 +591,19 @@ |
3604 | 2380 | buf_LRU_free_from_unzip_LRU_list( | 2389 | buf_LRU_free_from_unzip_LRU_list( |
3605 | 2381 | /*=============================*/ | 2390 | /*=============================*/ |
3606 | 2382 | buf_pool_t* buf_pool, /*!< in: buffer pool instance */ | 2391 | buf_pool_t* buf_pool, /*!< in: buffer pool instance */ |
3607 | @@ -2398,7 +2407,7 @@ | |||
3608 | 2398 | 2407 | ||
3609 | 2399 | /* Theoratically it should be much easier to find a victim | 2408 | /* Theoratically it should be much easier to find a victim |
3610 | 2400 | from unzip_LRU as we can choose even a dirty block (as we'll | 2409 | from unzip_LRU as we can choose even a dirty block (as we'll |
3612 | 2401 | @@ -546,7 +597,7 @@ | 2410 | @@ -557,7 +613,7 @@ |
3613 | 2402 | if we have done five iterations so far. */ | 2411 | if we have done five iterations so far. */ |
3614 | 2403 | 2412 | ||
3615 | 2404 | if (UNIV_UNLIKELY(n_iterations >= 5) | 2413 | if (UNIV_UNLIKELY(n_iterations >= 5) |
3616 | @@ -2407,7 +2416,7 @@ | |||
3617 | 2407 | 2416 | ||
3618 | 2408 | return(FALSE); | 2417 | return(FALSE); |
3619 | 2409 | } | 2418 | } |
3621 | 2410 | @@ -554,18 +605,25 @@ | 2419 | @@ -565,18 +621,25 @@ |
3622 | 2411 | distance = 100 + (n_iterations | 2420 | distance = 100 + (n_iterations |
3623 | 2412 | * UT_LIST_GET_LEN(buf_pool->unzip_LRU)) / 5; | 2421 | * UT_LIST_GET_LEN(buf_pool->unzip_LRU)) / 5; |
3624 | 2413 | 2422 | ||
3625 | @@ -2435,7 +2444,7 @@ | |||
3626 | 2435 | mutex_exit(&block->mutex); | 2444 | mutex_exit(&block->mutex); |
3627 | 2436 | 2445 | ||
3628 | 2437 | if (freed) { | 2446 | if (freed) { |
3630 | 2438 | @@ -584,35 +642,46 @@ | 2447 | @@ -595,35 +658,46 @@ |
3631 | 2439 | buf_LRU_free_from_common_LRU_list( | 2448 | buf_LRU_free_from_common_LRU_list( |
3632 | 2440 | /*==============================*/ | 2449 | /*==============================*/ |
3633 | 2441 | buf_pool_t* buf_pool, | 2450 | buf_pool_t* buf_pool, |
3634 | @@ -2487,7 +2496,7 @@ | |||
3635 | 2487 | mutex_exit(block_mutex); | 2496 | mutex_exit(block_mutex); |
3636 | 2488 | 2497 | ||
3637 | 2489 | if (freed) { | 2498 | if (freed) { |
3639 | 2490 | @@ -649,16 +718,23 @@ | 2499 | @@ -660,16 +734,23 @@ |
3640 | 2491 | n_iterations / 5 of the unzip_LRU list. */ | 2500 | n_iterations / 5 of the unzip_LRU list. */ |
3641 | 2492 | { | 2501 | { |
3642 | 2493 | ibool freed = FALSE; | 2502 | ibool freed = FALSE; |
3643 | @@ -2496,12 +2505,12 @@ | |||
3644 | 2496 | - buf_pool_mutex_enter(buf_pool); | 2505 | - buf_pool_mutex_enter(buf_pool); |
3645 | 2497 | + if (UT_LIST_GET_LEN(buf_pool->unzip_LRU)) | 2506 | + if (UT_LIST_GET_LEN(buf_pool->unzip_LRU)) |
3646 | 2498 | + have_LRU_mutex = TRUE; | 2507 | + have_LRU_mutex = TRUE; |
3647 | 2508 | + | ||
3648 | 2509 | + //buf_pool_mutex_enter(buf_pool); | ||
3649 | 2510 | + if (have_LRU_mutex) | ||
3650 | 2511 | + mutex_enter(&buf_pool->LRU_list_mutex); | ||
3651 | 2499 | 2512 | ||
3652 | 2500 | - freed = buf_LRU_free_from_unzip_LRU_list(buf_pool, n_iterations); | 2513 | - freed = buf_LRU_free_from_unzip_LRU_list(buf_pool, n_iterations); |
3653 | 2501 | + //buf_pool_mutex_enter(buf_pool); | ||
3654 | 2502 | + if (have_LRU_mutex) | ||
3655 | 2503 | + mutex_enter(&buf_pool->LRU_list_mutex); | ||
3656 | 2504 | + | ||
3657 | 2505 | + freed = buf_LRU_free_from_unzip_LRU_list(buf_pool, n_iterations, have_LRU_mutex); | 2514 | + freed = buf_LRU_free_from_unzip_LRU_list(buf_pool, n_iterations, have_LRU_mutex); |
3658 | 2506 | 2515 | ||
3659 | 2507 | if (!freed) { | 2516 | if (!freed) { |
3660 | @@ -2514,7 +2523,7 @@ | |||
3661 | 2514 | if (!freed) { | 2523 | if (!freed) { |
3662 | 2515 | buf_pool->LRU_flush_ended = 0; | 2524 | buf_pool->LRU_flush_ended = 0; |
3663 | 2516 | } else if (buf_pool->LRU_flush_ended > 0) { | 2525 | } else if (buf_pool->LRU_flush_ended > 0) { |
3665 | 2517 | @@ -666,6 +742,8 @@ | 2526 | @@ -677,6 +758,8 @@ |
3666 | 2518 | } | 2527 | } |
3667 | 2519 | 2528 | ||
3668 | 2520 | buf_pool_mutex_exit(buf_pool); | 2529 | buf_pool_mutex_exit(buf_pool); |
3669 | @@ -2523,7 +2532,7 @@ | |||
3670 | 2523 | 2532 | ||
3671 | 2524 | return(freed); | 2533 | return(freed); |
3672 | 2525 | } | 2534 | } |
3674 | 2526 | @@ -726,7 +804,9 @@ | 2535 | @@ -737,7 +820,9 @@ |
3675 | 2527 | 2536 | ||
3676 | 2528 | buf_pool = buf_pool_from_array(i); | 2537 | buf_pool = buf_pool_from_array(i); |
3677 | 2529 | 2538 | ||
3678 | @@ -2534,7 +2543,7 @@ | |||
3679 | 2534 | 2543 | ||
3680 | 2535 | if (!recv_recovery_on | 2544 | if (!recv_recovery_on |
3681 | 2536 | && UT_LIST_GET_LEN(buf_pool->free) | 2545 | && UT_LIST_GET_LEN(buf_pool->free) |
3683 | 2537 | @@ -736,7 +816,9 @@ | 2546 | @@ -747,7 +832,9 @@ |
3684 | 2538 | ret = TRUE; | 2547 | ret = TRUE; |
3685 | 2539 | } | 2548 | } |
3686 | 2540 | 2549 | ||
3687 | @@ -2545,7 +2554,7 @@ | |||
3688 | 2545 | } | 2554 | } |
3689 | 2546 | 2555 | ||
3690 | 2547 | return(ret); | 2556 | return(ret); |
3692 | 2548 | @@ -754,9 +836,10 @@ | 2557 | @@ -765,9 +852,10 @@ |
3693 | 2549 | { | 2558 | { |
3694 | 2550 | buf_block_t* block; | 2559 | buf_block_t* block; |
3695 | 2551 | 2560 | ||
3696 | @@ -2558,7 +2567,7 @@ | |||
3697 | 2558 | 2567 | ||
3698 | 2559 | if (block) { | 2568 | if (block) { |
3699 | 2560 | 2569 | ||
3701 | 2561 | @@ -765,7 +848,9 @@ | 2570 | @@ -776,7 +864,9 @@ |
3702 | 2562 | ut_ad(!block->page.in_flush_list); | 2571 | ut_ad(!block->page.in_flush_list); |
3703 | 2563 | ut_ad(!block->page.in_LRU_list); | 2572 | ut_ad(!block->page.in_LRU_list); |
3704 | 2564 | ut_a(!buf_page_in_file(&block->page)); | 2573 | ut_a(!buf_page_in_file(&block->page)); |
3705 | @@ -2569,7 +2578,7 @@ | |||
3706 | 2569 | 2578 | ||
3707 | 2570 | mutex_enter(&block->mutex); | 2579 | mutex_enter(&block->mutex); |
3708 | 2571 | 2580 | ||
3710 | 2572 | @@ -775,6 +860,8 @@ | 2581 | @@ -786,6 +876,8 @@ |
3711 | 2573 | ut_ad(buf_pool_from_block(block) == buf_pool); | 2582 | ut_ad(buf_pool_from_block(block) == buf_pool); |
3712 | 2574 | 2583 | ||
3713 | 2575 | mutex_exit(&block->mutex); | 2584 | mutex_exit(&block->mutex); |
3714 | @@ -2578,7 +2587,7 @@ | |||
3715 | 2578 | } | 2587 | } |
3716 | 2579 | 2588 | ||
3717 | 2580 | return(block); | 2589 | return(block); |
3719 | 2581 | @@ -797,7 +884,7 @@ | 2590 | @@ -808,7 +900,7 @@ |
3720 | 2582 | ibool mon_value_was = FALSE; | 2591 | ibool mon_value_was = FALSE; |
3721 | 2583 | ibool started_monitor = FALSE; | 2592 | ibool started_monitor = FALSE; |
3722 | 2584 | loop: | 2593 | loop: |
3723 | @@ -2587,7 +2596,7 @@ | |||
3724 | 2587 | 2596 | ||
3725 | 2588 | if (!recv_recovery_on && UT_LIST_GET_LEN(buf_pool->free) | 2597 | if (!recv_recovery_on && UT_LIST_GET_LEN(buf_pool->free) |
3726 | 2589 | + UT_LIST_GET_LEN(buf_pool->LRU) < buf_pool->curr_size / 20) { | 2598 | + UT_LIST_GET_LEN(buf_pool->LRU) < buf_pool->curr_size / 20) { |
3728 | 2590 | @@ -865,7 +952,7 @@ | 2599 | @@ -876,7 +968,7 @@ |
3729 | 2591 | 2600 | ||
3730 | 2592 | /* If there is a block in the free list, take it */ | 2601 | /* If there is a block in the free list, take it */ |
3731 | 2593 | block = buf_LRU_get_free_only(buf_pool); | 2602 | block = buf_LRU_get_free_only(buf_pool); |
3732 | @@ -2596,7 +2605,7 @@ | |||
3733 | 2596 | 2605 | ||
3734 | 2597 | if (block) { | 2606 | if (block) { |
3735 | 2598 | ut_ad(buf_pool_from_block(block) == buf_pool); | 2607 | ut_ad(buf_pool_from_block(block) == buf_pool); |
3737 | 2599 | @@ -965,7 +1052,8 @@ | 2608 | @@ -976,7 +1068,8 @@ |
3738 | 2600 | ulint new_len; | 2609 | ulint new_len; |
3739 | 2601 | 2610 | ||
3740 | 2602 | ut_a(buf_pool->LRU_old); | 2611 | ut_a(buf_pool->LRU_old); |
3741 | @@ -2606,7 +2615,7 @@ | |||
3742 | 2606 | ut_ad(buf_pool->LRU_old_ratio >= BUF_LRU_OLD_RATIO_MIN); | 2615 | ut_ad(buf_pool->LRU_old_ratio >= BUF_LRU_OLD_RATIO_MIN); |
3743 | 2607 | ut_ad(buf_pool->LRU_old_ratio <= BUF_LRU_OLD_RATIO_MAX); | 2616 | ut_ad(buf_pool->LRU_old_ratio <= BUF_LRU_OLD_RATIO_MAX); |
3744 | 2608 | #if BUF_LRU_OLD_RATIO_MIN * BUF_LRU_OLD_MIN_LEN <= BUF_LRU_OLD_RATIO_DIV * (BUF_LRU_OLD_TOLERANCE + 5) | 2617 | #if BUF_LRU_OLD_RATIO_MIN * BUF_LRU_OLD_MIN_LEN <= BUF_LRU_OLD_RATIO_DIV * (BUF_LRU_OLD_TOLERANCE + 5) |
3746 | 2609 | @@ -1031,7 +1119,8 @@ | 2618 | @@ -1042,7 +1135,8 @@ |
3747 | 2610 | { | 2619 | { |
3748 | 2611 | buf_page_t* bpage; | 2620 | buf_page_t* bpage; |
3749 | 2612 | 2621 | ||
3750 | @@ -2616,7 +2625,7 @@ | |||
3751 | 2616 | ut_a(UT_LIST_GET_LEN(buf_pool->LRU) == BUF_LRU_OLD_MIN_LEN); | 2625 | ut_a(UT_LIST_GET_LEN(buf_pool->LRU) == BUF_LRU_OLD_MIN_LEN); |
3752 | 2617 | 2626 | ||
3753 | 2618 | /* We first initialize all blocks in the LRU list as old and then use | 2627 | /* We first initialize all blocks in the LRU list as old and then use |
3755 | 2619 | @@ -1066,13 +1155,14 @@ | 2628 | @@ -1077,13 +1171,14 @@ |
3756 | 2620 | ut_ad(buf_pool); | 2629 | ut_ad(buf_pool); |
3757 | 2621 | ut_ad(bpage); | 2630 | ut_ad(bpage); |
3758 | 2622 | ut_ad(buf_page_in_file(bpage)); | 2631 | ut_ad(buf_page_in_file(bpage)); |
3759 | @@ -2633,7 +2642,7 @@ | |||
3760 | 2633 | 2642 | ||
3761 | 2634 | UT_LIST_REMOVE(unzip_LRU, buf_pool->unzip_LRU, block); | 2643 | UT_LIST_REMOVE(unzip_LRU, buf_pool->unzip_LRU, block); |
3762 | 2635 | } | 2644 | } |
3764 | 2636 | @@ -1090,7 +1180,8 @@ | 2645 | @@ -1101,7 +1196,8 @@ |
3765 | 2637 | 2646 | ||
3766 | 2638 | ut_ad(buf_pool); | 2647 | ut_ad(buf_pool); |
3767 | 2639 | ut_ad(bpage); | 2648 | ut_ad(bpage); |
3768 | @@ -2643,7 +2652,7 @@ | |||
3769 | 2643 | 2652 | ||
3770 | 2644 | ut_a(buf_page_in_file(bpage)); | 2653 | ut_a(buf_page_in_file(bpage)); |
3771 | 2645 | 2654 | ||
3773 | 2646 | @@ -1167,12 +1258,13 @@ | 2655 | @@ -1178,12 +1274,13 @@ |
3774 | 2647 | 2656 | ||
3775 | 2648 | ut_ad(buf_pool); | 2657 | ut_ad(buf_pool); |
3776 | 2649 | ut_ad(block); | 2658 | ut_ad(block); |
3777 | @@ -2659,7 +2668,7 @@ | |||
3778 | 2659 | 2668 | ||
3779 | 2660 | if (old) { | 2669 | if (old) { |
3780 | 2661 | UT_LIST_ADD_LAST(unzip_LRU, buf_pool->unzip_LRU, block); | 2670 | UT_LIST_ADD_LAST(unzip_LRU, buf_pool->unzip_LRU, block); |
3782 | 2662 | @@ -1193,7 +1285,8 @@ | 2671 | @@ -1204,7 +1301,8 @@ |
3783 | 2663 | 2672 | ||
3784 | 2664 | ut_ad(buf_pool); | 2673 | ut_ad(buf_pool); |
3785 | 2665 | ut_ad(bpage); | 2674 | ut_ad(bpage); |
3786 | @@ -2669,7 +2678,7 @@ | |||
3787 | 2669 | 2678 | ||
3788 | 2670 | ut_a(buf_page_in_file(bpage)); | 2679 | ut_a(buf_page_in_file(bpage)); |
3789 | 2671 | 2680 | ||
3791 | 2672 | @@ -1244,7 +1337,8 @@ | 2681 | @@ -1255,7 +1353,8 @@ |
3792 | 2673 | 2682 | ||
3793 | 2674 | ut_ad(buf_pool); | 2683 | ut_ad(buf_pool); |
3794 | 2675 | ut_ad(bpage); | 2684 | ut_ad(bpage); |
3795 | @@ -2679,7 +2688,7 @@ | |||
3796 | 2679 | 2688 | ||
3797 | 2680 | ut_a(buf_page_in_file(bpage)); | 2689 | ut_a(buf_page_in_file(bpage)); |
3798 | 2681 | ut_ad(!bpage->in_LRU_list); | 2690 | ut_ad(!bpage->in_LRU_list); |
3800 | 2682 | @@ -1323,7 +1417,8 @@ | 2691 | @@ -1334,7 +1433,8 @@ |
3801 | 2683 | { | 2692 | { |
3802 | 2684 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 2693 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
3803 | 2685 | 2694 | ||
3804 | @@ -2689,7 +2698,7 @@ | |||
3805 | 2689 | 2698 | ||
3806 | 2690 | if (bpage->old) { | 2699 | if (bpage->old) { |
3807 | 2691 | buf_pool->stat.n_pages_made_young++; | 2700 | buf_pool->stat.n_pages_made_young++; |
3809 | 2692 | @@ -1362,17 +1457,18 @@ | 2701 | @@ -1373,17 +1473,18 @@ |
3810 | 2693 | buf_LRU_free_block( | 2702 | buf_LRU_free_block( |
3811 | 2694 | /*===============*/ | 2703 | /*===============*/ |
3812 | 2695 | buf_page_t* bpage, /*!< in: block to be freed */ | 2704 | buf_page_t* bpage, /*!< in: block to be freed */ |
3813 | @@ -2711,7 +2720,7 @@ | |||
3814 | 2711 | ut_ad(!bpage->in_flush_list == !bpage->oldest_modification); | 2720 | ut_ad(!bpage->in_flush_list == !bpage->oldest_modification); |
3815 | 2712 | #if UNIV_WORD_SIZE == 4 | 2721 | #if UNIV_WORD_SIZE == 4 |
3816 | 2713 | /* On 32-bit systems, there is no padding in buf_page_t. On | 2722 | /* On 32-bit systems, there is no padding in buf_page_t. On |
3818 | 2714 | @@ -1381,7 +1477,7 @@ | 2723 | @@ -1392,7 +1493,7 @@ |
3819 | 2715 | UNIV_MEM_ASSERT_RW(bpage, sizeof *bpage); | 2724 | UNIV_MEM_ASSERT_RW(bpage, sizeof *bpage); |
3820 | 2716 | #endif | 2725 | #endif |
3821 | 2717 | 2726 | ||
3822 | @@ -2720,7 +2729,7 @@ | |||
3823 | 2720 | 2729 | ||
3824 | 2721 | /* Do not free buffer-fixed or I/O-fixed blocks. */ | 2730 | /* Do not free buffer-fixed or I/O-fixed blocks. */ |
3825 | 2722 | return(FALSE); | 2731 | return(FALSE); |
3827 | 2723 | @@ -1415,7 +1511,7 @@ | 2732 | @@ -1426,7 +1527,7 @@ |
3828 | 2724 | alloc: | 2733 | alloc: |
3829 | 2725 | b = buf_page_alloc_descriptor(); | 2734 | b = buf_page_alloc_descriptor(); |
3830 | 2726 | ut_a(b); | 2735 | ut_a(b); |
3831 | @@ -2729,7 +2738,7 @@ | |||
3832 | 2729 | } | 2738 | } |
3833 | 2730 | 2739 | ||
3834 | 2731 | #ifdef UNIV_DEBUG | 2740 | #ifdef UNIV_DEBUG |
3836 | 2732 | @@ -1426,6 +1522,39 @@ | 2741 | @@ -1437,6 +1538,39 @@ |
3837 | 2733 | } | 2742 | } |
3838 | 2734 | #endif /* UNIV_DEBUG */ | 2743 | #endif /* UNIV_DEBUG */ |
3839 | 2735 | 2744 | ||
3840 | @@ -2769,7 +2778,7 @@ | |||
3841 | 2769 | if (buf_LRU_block_remove_hashed_page(bpage, zip) | 2778 | if (buf_LRU_block_remove_hashed_page(bpage, zip) |
3842 | 2770 | != BUF_BLOCK_ZIP_FREE) { | 2779 | != BUF_BLOCK_ZIP_FREE) { |
3843 | 2771 | ut_a(bpage->buf_fix_count == 0); | 2780 | ut_a(bpage->buf_fix_count == 0); |
3845 | 2772 | @@ -1442,6 +1571,10 @@ | 2781 | @@ -1453,6 +1587,10 @@ |
3846 | 2773 | 2782 | ||
3847 | 2774 | ut_a(!hash_b); | 2783 | ut_a(!hash_b); |
3848 | 2775 | 2784 | ||
3849 | @@ -2780,7 +2789,7 @@ | |||
3850 | 2780 | b->state = b->oldest_modification | 2789 | b->state = b->oldest_modification |
3851 | 2781 | ? BUF_BLOCK_ZIP_DIRTY | 2790 | ? BUF_BLOCK_ZIP_DIRTY |
3852 | 2782 | : BUF_BLOCK_ZIP_PAGE; | 2791 | : BUF_BLOCK_ZIP_PAGE; |
3854 | 2783 | @@ -1517,6 +1650,7 @@ | 2792 | @@ -1528,6 +1666,7 @@ |
3855 | 2784 | buf_LRU_add_block_low(b, buf_page_is_old(b)); | 2793 | buf_LRU_add_block_low(b, buf_page_is_old(b)); |
3856 | 2785 | } | 2794 | } |
3857 | 2786 | 2795 | ||
3858 | @@ -2788,11 +2797,13 @@ | |||
3859 | 2788 | if (b->state == BUF_BLOCK_ZIP_PAGE) { | 2797 | if (b->state == BUF_BLOCK_ZIP_PAGE) { |
3860 | 2789 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 2798 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
3861 | 2790 | buf_LRU_insert_zip_clean(b); | 2799 | buf_LRU_insert_zip_clean(b); |
3863 | 2791 | @@ -1534,9 +1668,12 @@ | 2800 | @@ -1543,12 +1682,13 @@ |
3864 | 2801 | /* Prevent buf_page_get_gen() from | ||
3865 | 2802 | decompressing the block while we release | ||
3866 | 2792 | buf_pool->mutex and block_mutex. */ | 2803 | buf_pool->mutex and block_mutex. */ |
3870 | 2793 | b->buf_fix_count++; | 2804 | - mutex_enter(&buf_pool->zip_mutex); |
3871 | 2794 | b->io_fix = BUF_IO_READ; | 2805 | buf_page_set_sticky(b); |
3872 | 2795 | + mutex_exit(&buf_pool->zip_mutex); | 2806 | mutex_exit(&buf_pool->zip_mutex); |
3873 | 2796 | } | 2807 | } |
3874 | 2797 | 2808 | ||
3875 | 2798 | - buf_pool_mutex_exit(buf_pool); | 2809 | - buf_pool_mutex_exit(buf_pool); |
3876 | @@ -2802,7 +2813,7 @@ | |||
3877 | 2802 | mutex_exit(block_mutex); | 2813 | mutex_exit(block_mutex); |
3878 | 2803 | 2814 | ||
3879 | 2804 | /* Remove possible adaptive hash index on the page. | 2815 | /* Remove possible adaptive hash index on the page. |
3881 | 2805 | @@ -1568,7 +1705,9 @@ | 2816 | @@ -1580,7 +1720,9 @@ |
3882 | 2806 | : BUF_NO_CHECKSUM_MAGIC); | 2817 | : BUF_NO_CHECKSUM_MAGIC); |
3883 | 2807 | } | 2818 | } |
3884 | 2808 | 2819 | ||
3885 | @@ -2813,7 +2824,7 @@ | |||
3886 | 2813 | mutex_enter(block_mutex); | 2824 | mutex_enter(block_mutex); |
3887 | 2814 | 2825 | ||
3888 | 2815 | if (b) { | 2826 | if (b) { |
3890 | 2816 | @@ -1578,13 +1717,17 @@ | 2827 | @@ -1589,13 +1731,17 @@ |
3891 | 2817 | mutex_exit(&buf_pool->zip_mutex); | 2828 | mutex_exit(&buf_pool->zip_mutex); |
3892 | 2818 | } | 2829 | } |
3893 | 2819 | 2830 | ||
3894 | @@ -2832,7 +2843,7 @@ | |||
3895 | 2832 | } | 2843 | } |
3896 | 2833 | 2844 | ||
3897 | 2834 | return(TRUE); | 2845 | return(TRUE); |
3899 | 2835 | @@ -1596,13 +1739,14 @@ | 2846 | @@ -1607,13 +1753,14 @@ |
3900 | 2836 | void | 2847 | void |
3901 | 2837 | buf_LRU_block_free_non_file_page( | 2848 | buf_LRU_block_free_non_file_page( |
3902 | 2838 | /*=============================*/ | 2849 | /*=============================*/ |
3903 | @@ -2849,7 +2860,7 @@ | |||
3904 | 2849 | ut_ad(mutex_own(&block->mutex)); | 2860 | ut_ad(mutex_own(&block->mutex)); |
3905 | 2850 | 2861 | ||
3906 | 2851 | switch (buf_block_get_state(block)) { | 2862 | switch (buf_block_get_state(block)) { |
3908 | 2852 | @@ -1636,18 +1780,21 @@ | 2863 | @@ -1647,18 +1794,21 @@ |
3909 | 2853 | if (data) { | 2864 | if (data) { |
3910 | 2854 | block->page.zip.data = NULL; | 2865 | block->page.zip.data = NULL; |
3911 | 2855 | mutex_exit(&block->mutex); | 2866 | mutex_exit(&block->mutex); |
3912 | @@ -2875,7 +2886,7 @@ | |||
3913 | 2875 | 2886 | ||
3914 | 2876 | UNIV_MEM_ASSERT_AND_FREE(block->frame, UNIV_PAGE_SIZE); | 2887 | UNIV_MEM_ASSERT_AND_FREE(block->frame, UNIV_PAGE_SIZE); |
3915 | 2877 | } | 2888 | } |
3917 | 2878 | @@ -1677,7 +1824,11 @@ | 2889 | @@ -1688,7 +1838,11 @@ |
3918 | 2879 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 2890 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
3919 | 2880 | 2891 | ||
3920 | 2881 | ut_ad(bpage); | 2892 | ut_ad(bpage); |
3921 | @@ -2888,7 +2899,7 @@ | |||
3922 | 2888 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); | 2899 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); |
3923 | 2889 | 2900 | ||
3924 | 2890 | ut_a(buf_page_get_io_fix(bpage) == BUF_IO_NONE); | 2901 | ut_a(buf_page_get_io_fix(bpage) == BUF_IO_NONE); |
3926 | 2891 | @@ -1785,7 +1936,9 @@ | 2902 | @@ -1796,7 +1950,9 @@ |
3927 | 2892 | 2903 | ||
3928 | 2893 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 2904 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
3929 | 2894 | mutex_exit(buf_page_get_mutex(bpage)); | 2905 | mutex_exit(buf_page_get_mutex(bpage)); |
3930 | @@ -2899,7 +2910,7 @@ | |||
3931 | 2899 | buf_print(); | 2910 | buf_print(); |
3932 | 2900 | buf_LRU_print(); | 2911 | buf_LRU_print(); |
3933 | 2901 | buf_validate(); | 2912 | buf_validate(); |
3935 | 2902 | @@ -1807,17 +1960,17 @@ | 2913 | @@ -1818,17 +1974,17 @@ |
3936 | 2903 | ut_a(buf_page_get_zip_size(bpage)); | 2914 | ut_a(buf_page_get_zip_size(bpage)); |
3937 | 2904 | 2915 | ||
3938 | 2905 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG | 2916 | #if defined UNIV_DEBUG || defined UNIV_BUF_DEBUG |
3939 | @@ -2921,7 +2932,7 @@ | |||
3940 | 2921 | buf_page_free_descriptor(bpage); | 2932 | buf_page_free_descriptor(bpage); |
3941 | 2922 | return(BUF_BLOCK_ZIP_FREE); | 2933 | return(BUF_BLOCK_ZIP_FREE); |
3942 | 2923 | 2934 | ||
3944 | 2924 | @@ -1839,13 +1992,13 @@ | 2935 | @@ -1850,13 +2006,13 @@ |
3945 | 2925 | ut_ad(!bpage->in_flush_list); | 2936 | ut_ad(!bpage->in_flush_list); |
3946 | 2926 | ut_ad(!bpage->in_LRU_list); | 2937 | ut_ad(!bpage->in_LRU_list); |
3947 | 2927 | mutex_exit(&((buf_block_t*) bpage)->mutex); | 2938 | mutex_exit(&((buf_block_t*) bpage)->mutex); |
3948 | @@ -2938,7 +2949,7 @@ | |||
3949 | 2938 | mutex_enter(&((buf_block_t*) bpage)->mutex); | 2949 | mutex_enter(&((buf_block_t*) bpage)->mutex); |
3950 | 2939 | page_zip_set_size(&bpage->zip, 0); | 2950 | page_zip_set_size(&bpage->zip, 0); |
3951 | 2940 | } | 2951 | } |
3953 | 2941 | @@ -1871,18 +2024,19 @@ | 2952 | @@ -1882,18 +2038,19 @@ |
3954 | 2942 | void | 2953 | void |
3955 | 2943 | buf_LRU_block_free_hashed_page( | 2954 | buf_LRU_block_free_hashed_page( |
3956 | 2944 | /*===========================*/ | 2955 | /*===========================*/ |
3957 | @@ -2962,7 +2973,7 @@ | |||
3958 | 2962 | } | 2973 | } |
3959 | 2963 | 2974 | ||
3960 | 2964 | /******************************************************************//** | 2975 | /******************************************************************//** |
3962 | 2965 | @@ -1897,7 +2051,7 @@ | 2976 | @@ -1908,7 +2065,7 @@ |
3963 | 2966 | { | 2977 | { |
3964 | 2967 | if (buf_LRU_block_remove_hashed_page(bpage, TRUE) | 2978 | if (buf_LRU_block_remove_hashed_page(bpage, TRUE) |
3965 | 2968 | != BUF_BLOCK_ZIP_FREE) { | 2979 | != BUF_BLOCK_ZIP_FREE) { |
3966 | @@ -2971,7 +2982,7 @@ | |||
3967 | 2971 | } | 2982 | } |
3968 | 2972 | } | 2983 | } |
3969 | 2973 | 2984 | ||
3971 | 2974 | @@ -1925,7 +2079,8 @@ | 2985 | @@ -1936,7 +2093,8 @@ |
3972 | 2975 | } | 2986 | } |
3973 | 2976 | 2987 | ||
3974 | 2977 | if (adjust) { | 2988 | if (adjust) { |
3975 | @@ -2981,7 +2992,7 @@ | |||
3976 | 2981 | 2992 | ||
3977 | 2982 | if (ratio != buf_pool->LRU_old_ratio) { | 2993 | if (ratio != buf_pool->LRU_old_ratio) { |
3978 | 2983 | buf_pool->LRU_old_ratio = ratio; | 2994 | buf_pool->LRU_old_ratio = ratio; |
3980 | 2984 | @@ -1937,7 +2092,8 @@ | 2995 | @@ -1948,7 +2106,8 @@ |
3981 | 2985 | } | 2996 | } |
3982 | 2986 | } | 2997 | } |
3983 | 2987 | 2998 | ||
3984 | @@ -2991,7 +3002,7 @@ | |||
3985 | 2991 | } else { | 3002 | } else { |
3986 | 2992 | buf_pool->LRU_old_ratio = ratio; | 3003 | buf_pool->LRU_old_ratio = ratio; |
3987 | 2993 | } | 3004 | } |
3989 | 2994 | @@ -2042,7 +2198,8 @@ | 3005 | @@ -2053,7 +2212,8 @@ |
3990 | 2995 | ulint new_len; | 3006 | ulint new_len; |
3991 | 2996 | 3007 | ||
3992 | 2997 | ut_ad(buf_pool); | 3008 | ut_ad(buf_pool); |
3993 | @@ -3001,7 +3012,7 @@ | |||
3994 | 3001 | 3012 | ||
3995 | 3002 | if (UT_LIST_GET_LEN(buf_pool->LRU) >= BUF_LRU_OLD_MIN_LEN) { | 3013 | if (UT_LIST_GET_LEN(buf_pool->LRU) >= BUF_LRU_OLD_MIN_LEN) { |
3996 | 3003 | 3014 | ||
3998 | 3004 | @@ -2103,16 +2260,22 @@ | 3015 | @@ -2114,16 +2274,22 @@ |
3999 | 3005 | 3016 | ||
4000 | 3006 | ut_a(buf_pool->LRU_old_len == old_len); | 3017 | ut_a(buf_pool->LRU_old_len == old_len); |
4001 | 3007 | 3018 | ||
4002 | @@ -3026,7 +3037,7 @@ | |||
4003 | 3026 | UT_LIST_VALIDATE(unzip_LRU, buf_block_t, buf_pool->unzip_LRU, | 3037 | UT_LIST_VALIDATE(unzip_LRU, buf_block_t, buf_pool->unzip_LRU, |
4004 | 3027 | ut_ad(ut_list_node_313->in_unzip_LRU_list | 3038 | ut_ad(ut_list_node_313->in_unzip_LRU_list |
4005 | 3028 | && ut_list_node_313->page.in_LRU_list)); | 3039 | && ut_list_node_313->page.in_LRU_list)); |
4007 | 3029 | @@ -2126,7 +2289,8 @@ | 3040 | @@ -2137,7 +2303,8 @@ |
4008 | 3030 | ut_a(buf_page_belongs_to_unzip_LRU(&block->page)); | 3041 | ut_a(buf_page_belongs_to_unzip_LRU(&block->page)); |
4009 | 3031 | } | 3042 | } |
4010 | 3032 | 3043 | ||
4011 | @@ -3036,7 +3047,7 @@ | |||
4012 | 3036 | } | 3047 | } |
4013 | 3037 | 3048 | ||
4014 | 3038 | /**********************************************************************//** | 3049 | /**********************************************************************//** |
4016 | 3039 | @@ -2162,7 +2326,8 @@ | 3050 | @@ -2173,7 +2340,8 @@ |
4017 | 3040 | const buf_page_t* bpage; | 3051 | const buf_page_t* bpage; |
4018 | 3041 | 3052 | ||
4019 | 3042 | ut_ad(buf_pool); | 3053 | ut_ad(buf_pool); |
4020 | @@ -3046,7 +3057,7 @@ | |||
4021 | 3046 | 3057 | ||
4022 | 3047 | bpage = UT_LIST_GET_FIRST(buf_pool->LRU); | 3058 | bpage = UT_LIST_GET_FIRST(buf_pool->LRU); |
4023 | 3048 | 3059 | ||
4025 | 3049 | @@ -2219,7 +2384,8 @@ | 3060 | @@ -2230,7 +2398,8 @@ |
4026 | 3050 | bpage = UT_LIST_GET_NEXT(LRU, bpage); | 3061 | bpage = UT_LIST_GET_NEXT(LRU, bpage); |
4027 | 3051 | } | 3062 | } |
4028 | 3052 | 3063 | ||
4029 | @@ -3312,7 +3323,7 @@ | |||
4030 | 3312 | /*********************************************************************//** | 3323 | /*********************************************************************//** |
4031 | 3313 | Get the flush type of a page. | 3324 | Get the flush type of a page. |
4032 | 3314 | @return flush type */ | 3325 | @return flush type */ |
4034 | 3315 | @@ -1332,7 +1355,7 @@ | 3326 | @@ -1352,7 +1375,7 @@ |
4035 | 3316 | All these are protected by buf_pool->mutex. */ | 3327 | All these are protected by buf_pool->mutex. */ |
4036 | 3317 | /* @{ */ | 3328 | /* @{ */ |
4037 | 3318 | 3329 | ||
4038 | @@ -3321,7 +3332,7 @@ | |||
4039 | 3321 | /*!< based on state, this is a | 3332 | /*!< based on state, this is a |
4040 | 3322 | list node, protected either by | 3333 | list node, protected either by |
4041 | 3323 | buf_pool->mutex or by | 3334 | buf_pool->mutex or by |
4043 | 3324 | @@ -1360,6 +1383,10 @@ | 3335 | @@ -1380,6 +1403,10 @@ |
4044 | 3325 | BUF_BLOCK_REMOVE_HASH or | 3336 | BUF_BLOCK_REMOVE_HASH or |
4045 | 3326 | BUF_BLOCK_READY_IN_USE. */ | 3337 | BUF_BLOCK_READY_IN_USE. */ |
4046 | 3327 | 3338 | ||
4047 | @@ -3332,7 +3343,7 @@ | |||
4048 | 3332 | #ifdef UNIV_DEBUG | 3343 | #ifdef UNIV_DEBUG |
4049 | 3333 | ibool in_flush_list; /*!< TRUE if in buf_pool->flush_list; | 3344 | ibool in_flush_list; /*!< TRUE if in buf_pool->flush_list; |
4050 | 3334 | when buf_pool->flush_list_mutex is | 3345 | when buf_pool->flush_list_mutex is |
4052 | 3335 | @@ -1452,11 +1479,11 @@ | 3346 | @@ -1472,11 +1499,11 @@ |
4053 | 3336 | a block is in the unzip_LRU list | 3347 | a block is in the unzip_LRU list |
4054 | 3337 | if page.state == BUF_BLOCK_FILE_PAGE | 3348 | if page.state == BUF_BLOCK_FILE_PAGE |
4055 | 3338 | and page.zip.data != NULL */ | 3349 | and page.zip.data != NULL */ |
4056 | @@ -3346,7 +3357,7 @@ | |||
4057 | 3346 | mutex_t mutex; /*!< mutex protecting this block: | 3357 | mutex_t mutex; /*!< mutex protecting this block: |
4058 | 3347 | state (also protected by the buffer | 3358 | state (also protected by the buffer |
4059 | 3348 | pool mutex), io_fix, buf_fix_count, | 3359 | pool mutex), io_fix, buf_fix_count, |
4061 | 3349 | @@ -1636,6 +1663,11 @@ | 3360 | @@ -1656,6 +1683,11 @@ |
4062 | 3350 | pool instance, protects compressed | 3361 | pool instance, protects compressed |
4063 | 3351 | only pages (of type buf_page_t, not | 3362 | only pages (of type buf_page_t, not |
4064 | 3352 | buf_block_t */ | 3363 | buf_block_t */ |
4065 | @@ -3358,7 +3369,7 @@ | |||
4066 | 3358 | ulint instance_no; /*!< Array index of this buffer | 3369 | ulint instance_no; /*!< Array index of this buffer |
4067 | 3359 | pool instance */ | 3370 | pool instance */ |
4068 | 3360 | ulint old_pool_size; /*!< Old pool size in bytes */ | 3371 | ulint old_pool_size; /*!< Old pool size in bytes */ |
4070 | 3361 | @@ -1789,8 +1821,8 @@ | 3372 | @@ -1809,8 +1841,8 @@ |
4071 | 3362 | /** Test if a buffer pool mutex is owned. */ | 3373 | /** Test if a buffer pool mutex is owned. */ |
4072 | 3363 | #define buf_pool_mutex_own(b) mutex_own(&b->mutex) | 3374 | #define buf_pool_mutex_own(b) mutex_own(&b->mutex) |
4073 | 3364 | /** Acquire a buffer pool mutex. */ | 3375 | /** Acquire a buffer pool mutex. */ |
4074 | @@ -3426,7 +3437,7 @@ | |||
4075 | 3426 | /*********************************************************************//** | 3437 | /*********************************************************************//** |
4076 | 3427 | Get the flush type of a page. | 3438 | Get the flush type of a page. |
4077 | 3428 | @return flush type */ | 3439 | @return flush type */ |
4079 | 3429 | @@ -443,8 +472,8 @@ | 3440 | @@ -444,8 +473,8 @@ |
4080 | 3430 | enum buf_io_fix io_fix) /*!< in: io_fix state */ | 3441 | enum buf_io_fix io_fix) /*!< in: io_fix state */ |
4081 | 3431 | { | 3442 | { |
4082 | 3432 | #ifdef UNIV_DEBUG | 3443 | #ifdef UNIV_DEBUG |
4083 | @@ -3437,7 +3448,25 @@ | |||
4084 | 3437 | #endif | 3448 | #endif |
4085 | 3438 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); | 3449 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); |
4086 | 3439 | 3450 | ||
4088 | 3440 | @@ -474,14 +503,14 @@ | 3451 | @@ -482,7 +511,7 @@ |
4089 | 3452 | { | ||
4090 | 3453 | #ifdef UNIV_DEBUG | ||
4091 | 3454 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | ||
4092 | 3455 | - ut_ad(buf_pool_mutex_own(buf_pool)); | ||
4093 | 3456 | + ut_ad(mutex_own(&buf_pool->LRU_list_mutex)); | ||
4094 | 3457 | #endif | ||
4095 | 3458 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); | ||
4096 | 3459 | ut_ad(buf_page_get_io_fix(bpage) == BUF_IO_NONE); | ||
4097 | 3460 | @@ -500,7 +529,7 @@ | ||
4098 | 3461 | { | ||
4099 | 3462 | #ifdef UNIV_DEBUG | ||
4100 | 3463 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | ||
4101 | 3464 | - ut_ad(buf_pool_mutex_own(buf_pool)); | ||
4102 | 3465 | + ut_ad(mutex_own(&buf_pool->LRU_list_mutex)); | ||
4103 | 3466 | #endif | ||
4104 | 3467 | ut_ad(mutex_own(buf_page_get_mutex(bpage))); | ||
4105 | 3468 | ut_ad(buf_page_get_io_fix(bpage) == BUF_IO_PIN); | ||
4106 | 3469 | @@ -518,14 +547,14 @@ | ||
4107 | 3441 | const buf_page_t* bpage) /*!< control block being relocated */ | 3470 | const buf_page_t* bpage) /*!< control block being relocated */ |
4108 | 3442 | { | 3471 | { |
4109 | 3443 | #ifdef UNIV_DEBUG | 3472 | #ifdef UNIV_DEBUG |
4110 | @@ -3456,7 +3485,7 @@ | |||
4111 | 3456 | && bpage->buf_fix_count == 0); | 3485 | && bpage->buf_fix_count == 0); |
4112 | 3457 | } | 3486 | } |
4113 | 3458 | 3487 | ||
4115 | 3459 | @@ -495,8 +524,8 @@ | 3488 | @@ -539,8 +568,8 @@ |
4116 | 3460 | const buf_page_t* bpage) /*!< in: control block */ | 3489 | const buf_page_t* bpage) /*!< in: control block */ |
4117 | 3461 | { | 3490 | { |
4118 | 3462 | #ifdef UNIV_DEBUG | 3491 | #ifdef UNIV_DEBUG |
4119 | @@ -3467,7 +3496,7 @@ | |||
4120 | 3467 | #endif | 3496 | #endif |
4121 | 3468 | ut_ad(buf_page_in_file(bpage)); | 3497 | ut_ad(buf_page_in_file(bpage)); |
4122 | 3469 | 3498 | ||
4124 | 3470 | @@ -516,7 +545,8 @@ | 3499 | @@ -560,7 +589,8 @@ |
4125 | 3471 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); | 3500 | buf_pool_t* buf_pool = buf_pool_from_bpage(bpage); |
4126 | 3472 | #endif /* UNIV_DEBUG */ | 3501 | #endif /* UNIV_DEBUG */ |
4127 | 3473 | ut_a(buf_page_in_file(bpage)); | 3502 | ut_a(buf_page_in_file(bpage)); |
4128 | @@ -3477,7 +3506,7 @@ | |||
4129 | 3477 | ut_ad(bpage->in_LRU_list); | 3506 | ut_ad(bpage->in_LRU_list); |
4130 | 3478 | 3507 | ||
4131 | 3479 | #ifdef UNIV_LRU_DEBUG | 3508 | #ifdef UNIV_LRU_DEBUG |
4133 | 3480 | @@ -563,9 +593,10 @@ | 3509 | @@ -607,9 +637,10 @@ |
4134 | 3481 | ulint time_ms) /*!< in: ut_time_ms() */ | 3510 | ulint time_ms) /*!< in: ut_time_ms() */ |
4135 | 3482 | { | 3511 | { |
4136 | 3483 | #ifdef UNIV_DEBUG | 3512 | #ifdef UNIV_DEBUG |
4137 | @@ -3490,7 +3519,7 @@ | |||
4138 | 3490 | ut_a(buf_page_in_file(bpage)); | 3519 | ut_a(buf_page_in_file(bpage)); |
4139 | 3491 | 3520 | ||
4140 | 3492 | if (!bpage->access_time) { | 3521 | if (!bpage->access_time) { |
4142 | 3493 | @@ -808,19 +839,19 @@ | 3522 | @@ -852,19 +883,19 @@ |
4143 | 3494 | /*===========*/ | 3523 | /*===========*/ |
4144 | 3495 | buf_block_t* block) /*!< in, own: block to be freed */ | 3524 | buf_block_t* block) /*!< in, own: block to be freed */ |
4145 | 3496 | { | 3525 | { |
4146 | @@ -3514,7 +3543,7 @@ | |||
4147 | 3514 | } | 3543 | } |
4148 | 3515 | #endif /* !UNIV_HOTBACKUP */ | 3544 | #endif /* !UNIV_HOTBACKUP */ |
4149 | 3516 | 3545 | ||
4151 | 3517 | @@ -868,17 +899,17 @@ | 3546 | @@ -912,17 +943,17 @@ |
4152 | 3518 | page frame */ | 3547 | page frame */ |
4153 | 3519 | { | 3548 | { |
4154 | 3520 | ib_uint64_t lsn; | 3549 | ib_uint64_t lsn; |
4155 | @@ -3537,7 +3566,7 @@ | |||
4156 | 3537 | 3566 | ||
4157 | 3538 | return(lsn); | 3567 | return(lsn); |
4158 | 3539 | } | 3568 | } |
4160 | 3540 | @@ -896,7 +927,7 @@ | 3569 | @@ -940,7 +971,7 @@ |
4161 | 3541 | #ifdef UNIV_SYNC_DEBUG | 3570 | #ifdef UNIV_SYNC_DEBUG |
4162 | 3542 | buf_pool_t* buf_pool = buf_pool_from_bpage((buf_page_t*)block); | 3571 | buf_pool_t* buf_pool = buf_pool_from_bpage((buf_page_t*)block); |
4163 | 3543 | 3572 | ||
4164 | @@ -3546,7 +3575,7 @@ | |||
4165 | 3546 | && (block->page.buf_fix_count == 0)) | 3575 | && (block->page.buf_fix_count == 0)) |
4166 | 3547 | || rw_lock_own(&(block->lock), RW_LOCK_EXCLUSIVE)); | 3576 | || rw_lock_own(&(block->lock), RW_LOCK_EXCLUSIVE)); |
4167 | 3548 | #endif /* UNIV_SYNC_DEBUG */ | 3577 | #endif /* UNIV_SYNC_DEBUG */ |
4169 | 3549 | @@ -1026,7 +1057,11 @@ | 3578 | @@ -1070,7 +1101,11 @@ |
4170 | 3550 | buf_page_t* bpage; | 3579 | buf_page_t* bpage; |
4171 | 3551 | 3580 | ||
4172 | 3552 | ut_ad(buf_pool); | 3581 | ut_ad(buf_pool); |
4173 | @@ -3559,7 +3588,7 @@ | |||
4174 | 3559 | ut_ad(fold == buf_page_address_fold(space, offset)); | 3588 | ut_ad(fold == buf_page_address_fold(space, offset)); |
4175 | 3560 | 3589 | ||
4176 | 3561 | /* Look for the page in the hash table */ | 3590 | /* Look for the page in the hash table */ |
4178 | 3562 | @@ -1111,11 +1146,13 @@ | 3591 | @@ -1155,11 +1190,13 @@ |
4179 | 3563 | const buf_page_t* bpage; | 3592 | const buf_page_t* bpage; |
4180 | 3564 | buf_pool_t* buf_pool = buf_pool_get(space, offset); | 3593 | buf_pool_t* buf_pool = buf_pool_get(space, offset); |
4181 | 3565 | 3594 | ||
4182 | @@ -3575,7 +3604,7 @@ | |||
4183 | 3575 | 3604 | ||
4184 | 3576 | return(bpage != NULL); | 3605 | return(bpage != NULL); |
4185 | 3577 | } | 3606 | } |
4187 | 3578 | @@ -1243,4 +1280,38 @@ | 3607 | @@ -1287,4 +1324,38 @@ |
4188 | 3579 | buf_pool_mutex_exit(buf_pool); | 3608 | buf_pool_mutex_exit(buf_pool); |
4189 | 3580 | } | 3609 | } |
4190 | 3581 | } | 3610 | } |
4191 | 3582 | 3611 | ||
4192 | === modified file 'patches/innodb_stats.patch' | |||
4193 | --- patches/innodb_stats.patch 2011-12-27 15:32:16 +0000 | |||
4194 | +++ patches/innodb_stats.patch 2012-02-06 05:02:26 +0000 | |||
4195 | @@ -278,10 +278,16 @@ | |||
4196 | 278 | } | 278 | } |
4197 | 279 | 279 | ||
4198 | 280 | if (node->state == INDEX_CREATE_INDEX_TREE) { | 280 | if (node->state == INDEX_CREATE_INDEX_TREE) { |
4201 | 281 | @@ -1183,6 +1322,66 @@ | 281 | @@ -1177,6 +1316,66 @@ |
4202 | 282 | } | 282 | return(NULL); |
4203 | 283 | } | ||
4204 | 283 | 284 | ||
4206 | 284 | /****************************************************************//** | 285 | + thr->run_node = que_node_get_parent(node); |
4207 | 286 | + | ||
4208 | 287 | + return(thr); | ||
4209 | 288 | +} | ||
4210 | 289 | + | ||
4211 | 290 | +/****************************************************************//** | ||
4212 | 285 | +*/ | 291 | +*/ |
4213 | 286 | +UNIV_INTERN | 292 | +UNIV_INTERN |
4214 | 287 | +que_thr_t* | 293 | +que_thr_t* |
4215 | @@ -336,15 +342,9 @@ | |||
4216 | 336 | + return(NULL); | 342 | + return(NULL); |
4217 | 337 | + } | 343 | + } |
4218 | 338 | + | 344 | + |
4228 | 339 | + thr->run_node = que_node_get_parent(node); | 345 | thr->run_node = que_node_get_parent(node); |
4229 | 340 | + | 346 | |
4230 | 341 | + return(thr); | 347 | return(thr); |
4222 | 342 | +} | ||
4223 | 343 | + | ||
4224 | 344 | +/****************************************************************//** | ||
4225 | 345 | Creates the foreign key constraints system tables inside InnoDB | ||
4226 | 346 | at database creation or database start if they are not found or are | ||
4227 | 347 | not of the right form. | ||
4231 | 348 | --- a/storage/innobase/dict/dict0dict.c | 348 | --- a/storage/innobase/dict/dict0dict.c |
4232 | 349 | +++ b/storage/innobase/dict/dict0dict.c | 349 | +++ b/storage/innobase/dict/dict0dict.c |
4233 | 350 | @@ -755,7 +755,7 @@ | 350 | @@ -755,7 +755,7 @@ |
4234 | @@ -356,7 +356,7 @@ | |||
4235 | 356 | } | 356 | } |
4236 | 357 | 357 | ||
4237 | 358 | return(table); | 358 | return(table); |
4239 | 359 | @@ -4344,6 +4344,295 @@ | 359 | @@ -4354,6 +4354,295 @@ |
4240 | 360 | } | 360 | } |
4241 | 361 | 361 | ||
4242 | 362 | /*********************************************************************//** | 362 | /*********************************************************************//** |
4243 | @@ -652,7 +652,7 @@ | |||
4244 | 652 | Calculates new estimates for table and index statistics. The statistics | 652 | Calculates new estimates for table and index statistics. The statistics |
4245 | 653 | are used in query optimization. */ | 653 | are used in query optimization. */ |
4246 | 654 | UNIV_INTERN | 654 | UNIV_INTERN |
4248 | 655 | @@ -4351,10 +4640,11 @@ | 655 | @@ -4361,10 +4650,11 @@ |
4249 | 656 | dict_update_statistics( | 656 | dict_update_statistics( |
4250 | 657 | /*===================*/ | 657 | /*===================*/ |
4251 | 658 | dict_table_t* table, /*!< in/out: table */ | 658 | dict_table_t* table, /*!< in/out: table */ |
4252 | @@ -665,7 +665,7 @@ | |||
4253 | 665 | { | 665 | { |
4254 | 666 | dict_index_t* index; | 666 | dict_index_t* index; |
4255 | 667 | ulint sum_of_index_sizes = 0; | 667 | ulint sum_of_index_sizes = 0; |
4257 | 668 | @@ -4371,6 +4661,27 @@ | 668 | @@ -4381,6 +4671,27 @@ |
4258 | 669 | return; | 669 | return; |
4259 | 670 | } | 670 | } |
4260 | 671 | 671 | ||
4261 | @@ -693,7 +693,7 @@ | |||
4262 | 693 | /* Find out the sizes of the indexes and how many different values | 693 | /* Find out the sizes of the indexes and how many different values |
4263 | 694 | for the key they approximately have */ | 694 | for the key they approximately have */ |
4264 | 695 | 695 | ||
4266 | 696 | @@ -4435,6 +4746,11 @@ | 696 | @@ -4445,6 +4756,11 @@ |
4267 | 697 | index = dict_table_get_next_index(index); | 697 | index = dict_table_get_next_index(index); |
4268 | 698 | } while (index); | 698 | } while (index); |
4269 | 699 | 699 | ||
4270 | @@ -705,7 +705,7 @@ | |||
4271 | 705 | index = dict_table_get_first_index(table); | 705 | index = dict_table_get_first_index(table); |
4272 | 706 | 706 | ||
4273 | 707 | table->stat_n_rows = index->stat_n_diff_key_vals[ | 707 | table->stat_n_rows = index->stat_n_diff_key_vals[ |
4275 | 708 | @@ -4452,6 +4768,78 @@ | 708 | @@ -4462,6 +4778,78 @@ |
4276 | 709 | dict_table_stats_unlock(table, RW_X_LATCH); | 709 | dict_table_stats_unlock(table, RW_X_LATCH); |
4277 | 710 | } | 710 | } |
4278 | 711 | 711 | ||
4279 | @@ -784,7 +784,7 @@ | |||
4280 | 784 | /**********************************************************************//** | 784 | /**********************************************************************//** |
4281 | 785 | Prints info of a foreign key constraint. */ | 785 | Prints info of a foreign key constraint. */ |
4282 | 786 | static | 786 | static |
4284 | 787 | @@ -4529,7 +4917,8 @@ | 787 | @@ -4539,7 +4927,8 @@ |
4285 | 788 | 788 | ||
4286 | 789 | ut_ad(mutex_own(&(dict_sys->mutex))); | 789 | ut_ad(mutex_own(&(dict_sys->mutex))); |
4287 | 790 | 790 | ||
4288 | @@ -961,7 +961,7 @@ | |||
4289 | 961 | break; | 961 | break; |
4290 | 962 | case DB_RECORD_NOT_FOUND: | 962 | case DB_RECORD_NOT_FOUND: |
4291 | 963 | error = HA_ERR_KEY_NOT_FOUND; | 963 | error = HA_ERR_KEY_NOT_FOUND; |
4293 | 964 | @@ -6197,6 +6217,11 @@ | 964 | @@ -6196,6 +6216,11 @@ |
4294 | 965 | case DB_SUCCESS: | 965 | case DB_SUCCESS: |
4295 | 966 | error = 0; | 966 | error = 0; |
4296 | 967 | table->status = 0; | 967 | table->status = 0; |
4297 | @@ -973,7 +973,7 @@ | |||
4298 | 973 | break; | 973 | break; |
4299 | 974 | case DB_RECORD_NOT_FOUND: | 974 | case DB_RECORD_NOT_FOUND: |
4300 | 975 | error = HA_ERR_END_OF_FILE; | 975 | error = HA_ERR_END_OF_FILE; |
4302 | 976 | @@ -8150,11 +8175,35 @@ | 976 | @@ -8149,11 +8174,35 @@ |
4303 | 977 | /* In sql_show we call with this flag: update | 977 | /* In sql_show we call with this flag: update |
4304 | 978 | then statistics so that they are up-to-date */ | 978 | then statistics so that they are up-to-date */ |
4305 | 979 | 979 | ||
4306 | @@ -1010,7 +1010,7 @@ | |||
4307 | 1010 | 1010 | ||
4308 | 1011 | prebuilt->trx->op_info = "returning various info to MySQL"; | 1011 | prebuilt->trx->op_info = "returning various info to MySQL"; |
4309 | 1012 | } | 1012 | } |
4311 | 1013 | @@ -8239,7 +8288,7 @@ | 1013 | @@ -8238,7 +8287,7 @@ |
4312 | 1014 | are asked by MySQL to avoid locking. Another reason to | 1014 | are asked by MySQL to avoid locking. Another reason to |
4313 | 1015 | avoid the call is that it uses quite a lot of CPU. | 1015 | avoid the call is that it uses quite a lot of CPU. |
4314 | 1016 | See Bug#38185. */ | 1016 | See Bug#38185. */ |
4315 | @@ -1019,7 +1019,7 @@ | |||
4316 | 1019 | || !(flag & HA_STATUS_VARIABLE_EXTRA)) { | 1019 | || !(flag & HA_STATUS_VARIABLE_EXTRA)) { |
4317 | 1020 | /* We do not update delete_length if no | 1020 | /* We do not update delete_length if no |
4318 | 1021 | locking is requested so the "old" value can | 1021 | locking is requested so the "old" value can |
4320 | 1022 | @@ -11512,6 +11561,26 @@ | 1022 | @@ -11511,6 +11560,26 @@ |
4321 | 1023 | "The number of index pages to sample when calculating statistics (default 8)", | 1023 | "The number of index pages to sample when calculating statistics (default 8)", |
4322 | 1024 | NULL, NULL, 8, 1, ~0ULL, 0); | 1024 | NULL, NULL, 8, 1, ~0ULL, 0); |
4323 | 1025 | 1025 | ||
4324 | @@ -1046,7 +1046,7 @@ | |||
4325 | 1046 | static MYSQL_SYSVAR_BOOL(adaptive_hash_index, btr_search_enabled, | 1046 | static MYSQL_SYSVAR_BOOL(adaptive_hash_index, btr_search_enabled, |
4326 | 1047 | PLUGIN_VAR_OPCMDARG, | 1047 | PLUGIN_VAR_OPCMDARG, |
4327 | 1048 | "Enable InnoDB adaptive hash index (enabled by default). " | 1048 | "Enable InnoDB adaptive hash index (enabled by default). " |
4329 | 1049 | @@ -11844,6 +11913,9 @@ | 1049 | @@ -11883,6 +11952,9 @@ |
4330 | 1050 | MYSQL_SYSVAR(recovery_update_relay_log), | 1050 | MYSQL_SYSVAR(recovery_update_relay_log), |
4331 | 1051 | MYSQL_SYSVAR(rollback_on_timeout), | 1051 | MYSQL_SYSVAR(rollback_on_timeout), |
4332 | 1052 | MYSQL_SYSVAR(stats_on_metadata), | 1052 | MYSQL_SYSVAR(stats_on_metadata), |
4333 | @@ -1056,7 +1056,7 @@ | |||
4334 | 1056 | MYSQL_SYSVAR(stats_sample_pages), | 1056 | MYSQL_SYSVAR(stats_sample_pages), |
4335 | 1057 | MYSQL_SYSVAR(adaptive_hash_index), | 1057 | MYSQL_SYSVAR(adaptive_hash_index), |
4336 | 1058 | MYSQL_SYSVAR(stats_method), | 1058 | MYSQL_SYSVAR(stats_method), |
4338 | 1059 | @@ -11915,7 +11987,10 @@ | 1059 | @@ -11957,7 +12029,10 @@ |
4339 | 1060 | i_s_innodb_sys_columns, | 1060 | i_s_innodb_sys_columns, |
4340 | 1061 | i_s_innodb_sys_fields, | 1061 | i_s_innodb_sys_fields, |
4341 | 1062 | i_s_innodb_sys_foreign, | 1062 | i_s_innodb_sys_foreign, |
4342 | 1063 | 1063 | ||
4343 | === modified file 'patches/innodb_thread_concurrency_timer_based.patch' | |||
4344 | --- patches/innodb_thread_concurrency_timer_based.patch 2011-12-27 15:32:16 +0000 | |||
4345 | +++ patches/innodb_thread_concurrency_timer_based.patch 2012-02-06 05:02:26 +0000 | |||
4346 | @@ -25,7 +25,7 @@ | |||
4347 | 25 | #ifdef UNIV_LOG_ARCHIVE | 25 | #ifdef UNIV_LOG_ARCHIVE |
4348 | 26 | srv_log_archive_on = (ulint) innobase_log_archive; | 26 | srv_log_archive_on = (ulint) innobase_log_archive; |
4349 | 27 | #endif /* UNIV_LOG_ARCHIVE */ | 27 | #endif /* UNIV_LOG_ARCHIVE */ |
4351 | 28 | @@ -11602,6 +11606,12 @@ | 28 | @@ -11601,6 +11605,12 @@ |
4352 | 29 | "Maximum delay between polling for a spin lock (6 by default)", | 29 | "Maximum delay between polling for a spin lock (6 by default)", |
4353 | 30 | NULL, NULL, 6L, 0L, ~0L, 0); | 30 | NULL, NULL, 6L, 0L, ~0L, 0); |
4354 | 31 | 31 | ||
4355 | @@ -38,7 +38,7 @@ | |||
4356 | 38 | static MYSQL_SYSVAR_ULONG(thread_concurrency, srv_thread_concurrency, | 38 | static MYSQL_SYSVAR_ULONG(thread_concurrency, srv_thread_concurrency, |
4357 | 39 | PLUGIN_VAR_RQCMDARG, | 39 | PLUGIN_VAR_RQCMDARG, |
4358 | 40 | "Helps in performance tuning in heavily concurrent environments. Sets the maximum number of threads allowed inside InnoDB. Value 0 will disable the thread throttling.", | 40 | "Helps in performance tuning in heavily concurrent environments. Sets the maximum number of threads allowed inside InnoDB. Value 0 will disable the thread throttling.", |
4360 | 41 | @@ -11820,6 +11830,7 @@ | 41 | @@ -11859,6 +11869,7 @@ |
4361 | 42 | MYSQL_SYSVAR(spin_wait_delay), | 42 | MYSQL_SYSVAR(spin_wait_delay), |
4362 | 43 | MYSQL_SYSVAR(table_locks), | 43 | MYSQL_SYSVAR(table_locks), |
4363 | 44 | MYSQL_SYSVAR(thread_concurrency), | 44 | MYSQL_SYSVAR(thread_concurrency), |
4364 | @@ -67,7 +67,7 @@ | |||
4365 | 67 | UNIV_INTERN ulong srv_thread_concurrency = 0; | 67 | UNIV_INTERN ulong srv_thread_concurrency = 0; |
4366 | 68 | 68 | ||
4367 | 69 | /* this mutex protects srv_conc data structures */ | 69 | /* this mutex protects srv_conc data structures */ |
4369 | 70 | @@ -1145,6 +1146,75 @@ | 70 | @@ -1148,6 +1149,75 @@ |
4370 | 71 | /*********************************************************************//** | 71 | /*********************************************************************//** |
4371 | 72 | Puts an OS thread to wait if there are too many concurrent threads | 72 | Puts an OS thread to wait if there are too many concurrent threads |
4372 | 73 | (>= srv_thread_concurrency) inside InnoDB. The threads wait in a FIFO queue. */ | 73 | (>= srv_thread_concurrency) inside InnoDB. The threads wait in a FIFO queue. */ |
4373 | @@ -143,7 +143,7 @@ | |||
4374 | 143 | UNIV_INTERN | 143 | UNIV_INTERN |
4375 | 144 | void | 144 | void |
4376 | 145 | srv_conc_enter_innodb( | 145 | srv_conc_enter_innodb( |
4378 | 146 | @@ -1179,6 +1249,13 @@ | 146 | @@ -1182,6 +1252,13 @@ |
4379 | 147 | return; | 147 | return; |
4380 | 148 | } | 148 | } |
4381 | 149 | 149 | ||
4382 | @@ -157,7 +157,7 @@ | |||
4383 | 157 | os_fast_mutex_lock(&srv_conc_mutex); | 157 | os_fast_mutex_lock(&srv_conc_mutex); |
4384 | 158 | retry: | 158 | retry: |
4385 | 159 | if (trx->declared_to_be_inside_innodb) { | 159 | if (trx->declared_to_be_inside_innodb) { |
4387 | 160 | @@ -1332,6 +1409,14 @@ | 160 | @@ -1335,6 +1412,14 @@ |
4388 | 161 | } | 161 | } |
4389 | 162 | 162 | ||
4390 | 163 | ut_ad(srv_conc_n_threads >= 0); | 163 | ut_ad(srv_conc_n_threads >= 0); |
4391 | @@ -172,7 +172,7 @@ | |||
4392 | 172 | 172 | ||
4393 | 173 | os_fast_mutex_lock(&srv_conc_mutex); | 173 | os_fast_mutex_lock(&srv_conc_mutex); |
4394 | 174 | 174 | ||
4396 | 175 | @@ -1365,6 +1450,13 @@ | 175 | @@ -1368,6 +1453,13 @@ |
4397 | 176 | return; | 176 | return; |
4398 | 177 | } | 177 | } |
4399 | 178 | 178 | ||
4400 | 179 | 179 | ||
4401 | === modified file 'patches/log_connection_error.patch' | |||
4402 | --- patches/log_connection_error.patch 2011-09-07 14:00:24 +0000 | |||
4403 | +++ patches/log_connection_error.patch 2012-02-06 05:02:26 +0000 | |||
4404 | @@ -16,7 +16,7 @@ | |||
4405 | 16 | +Comment= | 16 | +Comment= |
4406 | 17 | --- a/sql/mysqld.cc | 17 | --- a/sql/mysqld.cc |
4407 | 18 | +++ b/sql/mysqld.cc | 18 | +++ b/sql/mysqld.cc |
4409 | 19 | @@ -5098,6 +5098,10 @@ | 19 | @@ -4959,6 +4959,10 @@ |
4410 | 20 | 20 | ||
4411 | 21 | DBUG_PRINT("error",("Too many connections")); | 21 | DBUG_PRINT("error",("Too many connections")); |
4412 | 22 | close_connection(thd, ER_CON_COUNT_ERROR); | 22 | close_connection(thd, ER_CON_COUNT_ERROR); |
4413 | @@ -27,7 +27,7 @@ | |||
4414 | 27 | delete thd; | 27 | delete thd; |
4415 | 28 | DBUG_VOID_RETURN; | 28 | DBUG_VOID_RETURN; |
4416 | 29 | } | 29 | } |
4418 | 30 | @@ -5481,6 +5485,10 @@ | 30 | @@ -5342,6 +5346,10 @@ |
4419 | 31 | if (!(thd->net.vio= vio_new_win32pipe(hConnectedPipe)) || | 31 | if (!(thd->net.vio= vio_new_win32pipe(hConnectedPipe)) || |
4420 | 32 | my_net_init(&thd->net, thd->net.vio)) | 32 | my_net_init(&thd->net, thd->net.vio)) |
4421 | 33 | { | 33 | { |
4422 | @@ -38,7 +38,7 @@ | |||
4423 | 38 | close_connection(thd, ER_OUT_OF_RESOURCES); | 38 | close_connection(thd, ER_OUT_OF_RESOURCES); |
4424 | 39 | delete thd; | 39 | delete thd; |
4425 | 40 | continue; | 40 | continue; |
4427 | 41 | @@ -5676,6 +5684,10 @@ | 41 | @@ -5537,6 +5545,10 @@ |
4428 | 42 | event_conn_closed)) || | 42 | event_conn_closed)) || |
4429 | 43 | my_net_init(&thd->net, thd->net.vio)) | 43 | my_net_init(&thd->net, thd->net.vio)) |
4430 | 44 | { | 44 | { |
4431 | 45 | 45 | ||
4432 | === modified file 'patches/log_warnings_suppress.patch' | |||
4433 | --- patches/log_warnings_suppress.patch 2011-12-27 15:32:16 +0000 | |||
4434 | +++ patches/log_warnings_suppress.patch 2012-02-06 05:02:26 +0000 | |||
4435 | @@ -19,7 +19,7 @@ | |||
4436 | 19 | +2011-02-21 rename patch log_warning_silence.patch to log_warnings_suppress.patch. Also rename variable "log_warning_silence" to "log_warning_suppress". | 19 | +2011-02-21 rename patch log_warning_silence.patch to log_warnings_suppress.patch. Also rename variable "log_warning_silence" to "log_warning_suppress". |
4437 | 20 | --- a/sql/mysqld.cc | 20 | --- a/sql/mysqld.cc |
4438 | 21 | +++ b/sql/mysqld.cc | 21 | +++ b/sql/mysqld.cc |
4440 | 22 | @@ -628,6 +628,8 @@ | 22 | @@ -632,6 +632,8 @@ |
4441 | 23 | SHOW_COMP_OPTION have_crypt, have_compress; | 23 | SHOW_COMP_OPTION have_crypt, have_compress; |
4442 | 24 | SHOW_COMP_OPTION have_profiling; | 24 | SHOW_COMP_OPTION have_profiling; |
4443 | 25 | 25 | ||
4444 | @@ -30,7 +30,7 @@ | |||
4445 | 30 | pthread_key(MEM_ROOT**,THR_MALLOC); | 30 | pthread_key(MEM_ROOT**,THR_MALLOC); |
4446 | 31 | --- a/sql/mysqld.h | 31 | --- a/sql/mysqld.h |
4447 | 32 | +++ b/sql/mysqld.h | 32 | +++ b/sql/mysqld.h |
4449 | 33 | @@ -228,6 +228,8 @@ | 33 | @@ -229,6 +229,8 @@ |
4450 | 34 | extern TYPELIB thread_handling_typelib; | 34 | extern TYPELIB thread_handling_typelib; |
4451 | 35 | extern my_decimal decimal_zero; | 35 | extern my_decimal decimal_zero; |
4452 | 36 | 36 | ||
4453 | @@ -41,7 +41,7 @@ | |||
4454 | 41 | using my_pthread_setspecific_ptr()/my_thread_getspecific_ptr(). | 41 | using my_pthread_setspecific_ptr()/my_thread_getspecific_ptr(). |
4455 | 42 | --- a/sql/sql_class.cc | 42 | --- a/sql/sql_class.cc |
4456 | 43 | +++ b/sql/sql_class.cc | 43 | +++ b/sql/sql_class.cc |
4458 | 44 | @@ -5024,7 +5024,7 @@ | 44 | @@ -5029,7 +5029,7 @@ |
4459 | 45 | ER_BINLOG_UNSAFE_STATEMENT, | 45 | ER_BINLOG_UNSAFE_STATEMENT, |
4460 | 46 | ER(ER_BINLOG_UNSAFE_STATEMENT), | 46 | ER(ER_BINLOG_UNSAFE_STATEMENT), |
4461 | 47 | ER(LEX::binlog_stmt_unsafe_errcode[unsafe_type])); | 47 | ER(LEX::binlog_stmt_unsafe_errcode[unsafe_type])); |
4462 | @@ -62,7 +62,7 @@ | |||
4463 | 62 | SLAVE_EXEC_MODE_LAST_BIT}; | 62 | SLAVE_EXEC_MODE_LAST_BIT}; |
4464 | 63 | --- a/sql/sys_vars.cc | 63 | --- a/sql/sys_vars.cc |
4465 | 64 | +++ b/sql/sys_vars.cc | 64 | +++ b/sql/sys_vars.cc |
4467 | 65 | @@ -1499,6 +1499,15 @@ | 65 | @@ -1572,6 +1572,15 @@ |
4468 | 66 | READ_ONLY GLOBAL_VAR(mysqld_port), CMD_LINE(REQUIRED_ARG, 'P'), | 66 | READ_ONLY GLOBAL_VAR(mysqld_port), CMD_LINE(REQUIRED_ARG, 'P'), |
4469 | 67 | VALID_RANGE(0, UINT_MAX32), DEFAULT(0), BLOCK_SIZE(1)); | 67 | VALID_RANGE(0, UINT_MAX32), DEFAULT(0), BLOCK_SIZE(1)); |
4470 | 68 | 68 | ||
4471 | 69 | 69 | ||
4472 | === modified file 'patches/mysql-test.diff' | |||
4473 | --- patches/mysql-test.diff 2012-01-10 11:28:15 +0000 | |||
4474 | +++ patches/mysql-test.diff 2012-02-06 05:02:26 +0000 | |||
4475 | @@ -1823,7 +1823,3 @@ | |||
4476 | 1823 | @@ -0,0 +1,2 @@ | 1823 | @@ -0,0 +1,2 @@ |
4477 | 1824 | +--source include/have_nodebug.inc | 1824 | +--source include/have_nodebug.inc |
4478 | 1825 | +--source include/percona_server_variables.inc | 1825 | +--source include/percona_server_variables.inc |
4479 | 1826 | --- a/mysql-test/suite/innodb/t/innodb_cmp_drop_table-master.opt | ||
4480 | 1827 | +++ /dev/null | ||
4481 | 1828 | @@ -1 +0,0 @@ | ||
4482 | 1829 | ---innodb-buffer-pool-size=8M | ||
4483 | 1830 | 1826 | ||
4484 | === modified file 'patches/optimizer_fix.patch' | |||
4485 | --- patches/optimizer_fix.patch 2011-12-27 15:32:16 +0000 | |||
4486 | +++ patches/optimizer_fix.patch 2012-02-06 05:02:26 +0000 | |||
4487 | @@ -18,7 +18,7 @@ | |||
4488 | 18 | +Ported to 5.1.42 | 18 | +Ported to 5.1.42 |
4489 | 19 | --- a/sql/mysqld.cc | 19 | --- a/sql/mysqld.cc |
4490 | 20 | +++ b/sql/mysqld.cc | 20 | +++ b/sql/mysqld.cc |
4492 | 21 | @@ -430,6 +430,7 @@ | 21 | @@ -434,6 +434,7 @@ |
4493 | 22 | MYSQL_PLUGIN_IMPORT uint opt_debug_sync_timeout= 0; | 22 | MYSQL_PLUGIN_IMPORT uint opt_debug_sync_timeout= 0; |
4494 | 23 | #endif /* defined(ENABLED_DEBUG_SYNC) */ | 23 | #endif /* defined(ENABLED_DEBUG_SYNC) */ |
4495 | 24 | my_bool opt_old_style_user_limits= 0, trust_function_creators= 0; | 24 | my_bool opt_old_style_user_limits= 0, trust_function_creators= 0; |
4496 | @@ -138,7 +138,7 @@ | |||
4497 | 138 | DBUG_RETURN(HA_POS_ERROR); /* This shouldn't happend */ | 138 | DBUG_RETURN(HA_POS_ERROR); /* This shouldn't happend */ |
4498 | 139 | --- a/sql/sys_vars.cc | 139 | --- a/sql/sys_vars.cc |
4499 | 140 | +++ b/sql/sys_vars.cc | 140 | +++ b/sql/sys_vars.cc |
4501 | 141 | @@ -2186,6 +2186,12 @@ | 141 | @@ -2259,6 +2259,12 @@ |
4502 | 142 | VALID_RANGE(1, IF_WIN(INT_MAX32/1000, LONG_TIMEOUT)), | 142 | VALID_RANGE(1, IF_WIN(INT_MAX32/1000, LONG_TIMEOUT)), |
4503 | 143 | DEFAULT(NET_WAIT_TIMEOUT), BLOCK_SIZE(1)); | 143 | DEFAULT(NET_WAIT_TIMEOUT), BLOCK_SIZE(1)); |
4504 | 144 | 144 | ||
4505 | 145 | 145 | ||
4506 | === modified file 'patches/processlist_row_stats.patch' | |||
4507 | --- patches/processlist_row_stats.patch 2011-12-27 15:32:16 +0000 | |||
4508 | +++ patches/processlist_row_stats.patch 2012-02-06 05:02:26 +0000 | |||
4509 | @@ -7,7 +7,7 @@ | |||
4510 | 7 | # should be done or reviewed by the maintainer! | 7 | # should be done or reviewed by the maintainer! |
4511 | 8 | --- a/sql/sql_class.cc | 8 | --- a/sql/sql_class.cc |
4512 | 9 | +++ b/sql/sql_class.cc | 9 | +++ b/sql/sql_class.cc |
4514 | 10 | @@ -2419,6 +2419,7 @@ | 10 | @@ -2424,6 +2424,7 @@ |
4515 | 11 | 11 | ||
4516 | 12 | thd->sent_row_count++; | 12 | thd->sent_row_count++; |
4517 | 13 | thd->sent_row_count_2++; | 13 | thd->sent_row_count_2++; |
4518 | 14 | 14 | ||
4519 | === modified file 'patches/query_cache_enhance.patch' | |||
4520 | --- patches/query_cache_enhance.patch 2011-12-27 15:32:16 +0000 | |||
4521 | +++ patches/query_cache_enhance.patch 2012-02-06 05:02:26 +0000 | |||
4522 | @@ -25,7 +25,7 @@ | |||
4523 | 25 | +2010-11 - Ported to 5.5 | 25 | +2010-11 - Ported to 5.5 |
4524 | 26 | --- a/sql/mysqld.cc | 26 | --- a/sql/mysqld.cc |
4525 | 27 | +++ b/sql/mysqld.cc | 27 | +++ b/sql/mysqld.cc |
4527 | 28 | @@ -904,6 +904,7 @@ | 28 | @@ -909,6 +909,7 @@ |
4528 | 29 | #endif | 29 | #endif |
4529 | 30 | #ifdef HAVE_QUERY_CACHE | 30 | #ifdef HAVE_QUERY_CACHE |
4530 | 31 | ulong query_cache_min_res_unit= QUERY_CACHE_MIN_RESULT_DATA_SIZE; | 31 | ulong query_cache_min_res_unit= QUERY_CACHE_MIN_RESULT_DATA_SIZE; |
4531 | @@ -719,7 +719,7 @@ | |||
4532 | 719 | NET net; // client connection descriptor | 719 | NET net; // client connection descriptor |
4533 | 720 | --- a/sql/sys_vars.cc | 720 | --- a/sql/sys_vars.cc |
4534 | 721 | +++ b/sql/sys_vars.cc | 721 | +++ b/sql/sys_vars.cc |
4536 | 722 | @@ -1815,6 +1815,11 @@ | 722 | @@ -1888,6 +1888,11 @@ |
4537 | 723 | NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), | 723 | NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), |
4538 | 724 | ON_UPDATE(fix_query_cache_size)); | 724 | ON_UPDATE(fix_query_cache_size)); |
4539 | 725 | 725 | ||
4540 | 726 | 726 | ||
4541 | === modified file 'patches/response_time_distribution.patch' | |||
4542 | --- patches/response_time_distribution.patch 2011-12-27 15:32:16 +0000 | |||
4543 | +++ patches/response_time_distribution.patch 2012-02-06 05:02:26 +0000 | |||
4544 | @@ -2886,7 +2886,7 @@ | |||
4545 | 2886 | +2010-09-15 add column 'total' | 2886 | +2010-09-15 add column 'total' |
4546 | 2887 | --- a/sql/CMakeLists.txt | 2887 | --- a/sql/CMakeLists.txt |
4547 | 2888 | +++ b/sql/CMakeLists.txt | 2888 | +++ b/sql/CMakeLists.txt |
4549 | 2889 | @@ -51,7 +51,7 @@ | 2889 | @@ -52,7 +52,7 @@ |
4550 | 2890 | message.h mf_iocache.cc my_decimal.cc ../sql-common/my_time.c | 2890 | message.h mf_iocache.cc my_decimal.cc ../sql-common/my_time.c |
4551 | 2891 | mysqld.cc net_serv.cc keycaches.cc | 2891 | mysqld.cc net_serv.cc keycaches.cc |
4552 | 2892 | ../sql-common/client_plugin.c | 2892 | ../sql-common/client_plugin.c |
4553 | @@ -2895,7 +2895,7 @@ | |||
4554 | 2895 | ../sql-common/pack.c parse_file.cc password.c procedure.cc | 2895 | ../sql-common/pack.c parse_file.cc password.c procedure.cc |
4555 | 2896 | protocol.cc records.cc repl_failsafe.cc rpl_filter.cc set_var.cc | 2896 | protocol.cc records.cc repl_failsafe.cc rpl_filter.cc set_var.cc |
4556 | 2897 | slave.cc sp.cc sp_cache.cc sp_head.cc sp_pcontext.cc | 2897 | slave.cc sp.cc sp_cache.cc sp_head.cc sp_pcontext.cc |
4558 | 2898 | @@ -59,7 +59,7 @@ | 2898 | @@ -60,7 +60,7 @@ |
4559 | 2899 | sql_cache.cc sql_class.cc sql_client.cc sql_crypt.cc sql_crypt.h | 2899 | sql_cache.cc sql_class.cc sql_client.cc sql_crypt.cc sql_crypt.h |
4560 | 2900 | sql_cursor.cc sql_db.cc sql_delete.cc sql_derived.cc sql_do.cc | 2900 | sql_cursor.cc sql_db.cc sql_delete.cc sql_derived.cc sql_do.cc |
4561 | 2901 | sql_error.cc sql_handler.cc sql_help.cc sql_insert.cc sql_lex.cc | 2901 | sql_error.cc sql_handler.cc sql_help.cc sql_insert.cc sql_lex.cc |
4562 | @@ -2935,7 +2935,7 @@ | |||
4563 | 2935 | #ifdef WITH_PERFSCHEMA_STORAGE_ENGINE | 2935 | #ifdef WITH_PERFSCHEMA_STORAGE_ENGINE |
4564 | 2936 | #include "../storage/perfschema/pfs_server.h" | 2936 | #include "../storage/perfschema/pfs_server.h" |
4565 | 2937 | #endif /* WITH_PERFSCHEMA_STORAGE_ENGINE */ | 2937 | #endif /* WITH_PERFSCHEMA_STORAGE_ENGINE */ |
4567 | 2938 | @@ -611,7 +613,7 @@ | 2938 | @@ -615,7 +617,7 @@ |
4568 | 2939 | MY_LOCALE *my_default_lc_messages; | 2939 | MY_LOCALE *my_default_lc_messages; |
4569 | 2940 | MY_LOCALE *my_default_lc_time_names; | 2940 | MY_LOCALE *my_default_lc_time_names; |
4570 | 2941 | 2941 | ||
4571 | @@ -2944,7 +2944,7 @@ | |||
4572 | 2944 | SHOW_COMP_OPTION have_geometry, have_rtree_keys; | 2944 | SHOW_COMP_OPTION have_geometry, have_rtree_keys; |
4573 | 2945 | SHOW_COMP_OPTION have_crypt, have_compress; | 2945 | SHOW_COMP_OPTION have_crypt, have_compress; |
4574 | 2946 | SHOW_COMP_OPTION have_profiling; | 2946 | SHOW_COMP_OPTION have_profiling; |
4576 | 2947 | @@ -912,6 +914,10 @@ | 2947 | @@ -917,6 +919,10 @@ |
4577 | 2948 | my_bool opt_enable_shared_memory; | 2948 | my_bool opt_enable_shared_memory; |
4578 | 2949 | HANDLE smem_event_connect_request= 0; | 2949 | HANDLE smem_event_connect_request= 0; |
4579 | 2950 | #endif | 2950 | #endif |
4580 | @@ -2955,7 +2955,7 @@ | |||
4581 | 2955 | 2955 | ||
4582 | 2956 | my_bool opt_use_ssl = 0; | 2956 | my_bool opt_use_ssl = 0; |
4583 | 2957 | char *opt_ssl_ca= NULL, *opt_ssl_capath= NULL, *opt_ssl_cert= NULL, | 2957 | char *opt_ssl_ca= NULL, *opt_ssl_capath= NULL, *opt_ssl_cert= NULL, |
4585 | 2958 | @@ -1483,6 +1489,9 @@ | 2958 | @@ -1488,6 +1494,9 @@ |
4586 | 2959 | my_free(opt_bin_logname); | 2959 | my_free(opt_bin_logname); |
4587 | 2960 | bitmap_free(&temp_pool); | 2960 | bitmap_free(&temp_pool); |
4588 | 2961 | free_max_user_conn(); | 2961 | free_max_user_conn(); |
4589 | @@ -2965,7 +2965,7 @@ | |||
4590 | 2965 | #ifdef HAVE_REPLICATION | 2965 | #ifdef HAVE_REPLICATION |
4591 | 2966 | end_slave_list(); | 2966 | end_slave_list(); |
4592 | 2967 | #endif | 2967 | #endif |
4594 | 2968 | @@ -4010,6 +4019,9 @@ | 2968 | @@ -3860,6 +3869,9 @@ |
4595 | 2969 | if (!DEFAULT_ERRMSGS[0][0]) | 2969 | if (!DEFAULT_ERRMSGS[0][0]) |
4596 | 2970 | unireg_abort(1); | 2970 | unireg_abort(1); |
4597 | 2971 | 2971 | ||
4598 | @@ -2975,7 +2975,7 @@ | |||
4599 | 2975 | /* We have to initialize the storage engines before CSV logging */ | 2975 | /* We have to initialize the storage engines before CSV logging */ |
4600 | 2976 | if (ha_init()) | 2976 | if (ha_init()) |
4601 | 2977 | { | 2977 | { |
4603 | 2978 | @@ -6905,6 +6917,11 @@ | 2978 | @@ -6773,6 +6785,11 @@ |
4604 | 2979 | #else | 2979 | #else |
4605 | 2980 | have_query_cache=SHOW_OPTION_NO; | 2980 | have_query_cache=SHOW_OPTION_NO; |
4606 | 2981 | #endif | 2981 | #endif |
4607 | @@ -3374,7 +3374,7 @@ | |||
4608 | 3374 | +#endif // QUERY_RESPONSE_TIME_H | 3374 | +#endif // QUERY_RESPONSE_TIME_H |
4609 | 3375 | --- a/sql/set_var.h | 3375 | --- a/sql/set_var.h |
4610 | 3376 | +++ b/sql/set_var.h | 3376 | +++ b/sql/set_var.h |
4612 | 3377 | @@ -293,6 +293,7 @@ | 3377 | @@ -294,6 +294,7 @@ |
4613 | 3378 | 3378 | ||
4614 | 3379 | extern SHOW_COMP_OPTION have_ssl, have_symlink, have_dlopen; | 3379 | extern SHOW_COMP_OPTION have_ssl, have_symlink, have_dlopen; |
4615 | 3380 | extern SHOW_COMP_OPTION have_query_cache; | 3380 | extern SHOW_COMP_OPTION have_query_cache; |
4616 | @@ -3486,7 +3486,7 @@ | |||
4617 | 3486 | %token QUICK | 3486 | %token QUICK |
4618 | 3487 | %token RANGE_SYM /* SQL-2003-R */ | 3487 | %token RANGE_SYM /* SQL-2003-R */ |
4619 | 3488 | %token READS_SYM /* SQL-2003-R */ | 3488 | %token READS_SYM /* SQL-2003-R */ |
4621 | 3489 | @@ -11100,6 +11101,15 @@ | 3489 | @@ -11105,6 +11106,15 @@ |
4622 | 3490 | { | 3490 | { |
4623 | 3491 | Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT; | 3491 | Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT; |
4624 | 3492 | } | 3492 | } |
4625 | @@ -3502,7 +3502,7 @@ | |||
4626 | 3502 | | CREATE PROCEDURE_SYM sp_name | 3502 | | CREATE PROCEDURE_SYM sp_name |
4627 | 3503 | { | 3503 | { |
4628 | 3504 | LEX *lex= Lex; | 3504 | LEX *lex= Lex; |
4630 | 3505 | @@ -11339,6 +11349,12 @@ | 3505 | @@ -11344,6 +11354,12 @@ |
4631 | 3506 | Lex->type|= REFRESH_SLAVE; | 3506 | Lex->type|= REFRESH_SLAVE; |
4632 | 3507 | Lex->reset_slave_info.all= false; | 3507 | Lex->reset_slave_info.all= false; |
4633 | 3508 | } | 3508 | } |
4634 | @@ -3515,7 +3515,7 @@ | |||
4635 | 3515 | | MASTER_SYM | 3515 | | MASTER_SYM |
4636 | 3516 | { Lex->type|= REFRESH_MASTER; } | 3516 | { Lex->type|= REFRESH_MASTER; } |
4637 | 3517 | | DES_KEY_FILE | 3517 | | DES_KEY_FILE |
4639 | 3518 | @@ -12646,6 +12662,7 @@ | 3518 | @@ -12651,6 +12667,7 @@ |
4640 | 3519 | | PROXY_SYM {} | 3519 | | PROXY_SYM {} |
4641 | 3520 | | QUARTER_SYM {} | 3520 | | QUARTER_SYM {} |
4642 | 3521 | | QUERY_SYM {} | 3521 | | QUERY_SYM {} |
4643 | @@ -3525,15 +3525,15 @@ | |||
4644 | 3525 | | REBUILD_SYM {} | 3525 | | REBUILD_SYM {} |
4645 | 3526 | --- a/sql/sys_vars.cc | 3526 | --- a/sql/sys_vars.cc |
4646 | 3527 | +++ b/sql/sys_vars.cc | 3527 | +++ b/sql/sys_vars.cc |
4650 | 3528 | @@ -49,6 +49,7 @@ | 3528 | @@ -51,6 +51,7 @@ |
4651 | 3529 | #include "../storage/perfschema/pfs_server.h" | 3529 | |
4652 | 3530 | #endif /* WITH_PERFSCHEMA_STORAGE_ENGINE */ | 3530 | TYPELIB bool_typelib={ array_elements(bool_values)-1, "", bool_values, 0 }; |
4653 | 3531 | 3531 | ||
4654 | 3532 | +#include "query_response_time.h" | 3532 | +#include "query_response_time.h" |
4655 | 3533 | /* | 3533 | /* |
4656 | 3534 | This forward declaration is needed because including sql_base.h | 3534 | This forward declaration is needed because including sql_base.h |
4657 | 3535 | causes further includes. [TODO] Eliminate this forward declaration | 3535 | causes further includes. [TODO] Eliminate this forward declaration |
4659 | 3536 | @@ -1866,6 +1867,26 @@ | 3536 | @@ -1939,6 +1940,26 @@ |
4660 | 3537 | DEFAULT(FALSE)); | 3537 | DEFAULT(FALSE)); |
4661 | 3538 | #endif /* HAVE_QUERY_CACHE */ | 3538 | #endif /* HAVE_QUERY_CACHE */ |
4662 | 3539 | 3539 | ||
4663 | 3540 | 3540 | ||
4664 | === modified file 'patches/show_slave_status_nolock.patch' | |||
4665 | --- patches/show_slave_status_nolock.patch 2011-12-13 13:49:04 +0000 | |||
4666 | +++ patches/show_slave_status_nolock.patch 2012-02-06 05:02:26 +0000 | |||
4667 | @@ -26,7 +26,7 @@ | |||
4668 | 26 | { "NVARCHAR", SYM(NVARCHAR_SYM)}, | 26 | { "NVARCHAR", SYM(NVARCHAR_SYM)}, |
4669 | 27 | --- a/sql/mysqld.cc | 27 | --- a/sql/mysqld.cc |
4670 | 28 | +++ b/sql/mysqld.cc | 28 | +++ b/sql/mysqld.cc |
4672 | 29 | @@ -3121,6 +3121,7 @@ | 29 | @@ -2971,6 +2971,7 @@ |
4673 | 30 | {"show_relaylog_events", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_RELAYLOG_EVENTS]), SHOW_LONG_STATUS}, | 30 | {"show_relaylog_events", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_RELAYLOG_EVENTS]), SHOW_LONG_STATUS}, |
4674 | 31 | {"show_slave_hosts", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_SLAVE_HOSTS]), SHOW_LONG_STATUS}, | 31 | {"show_slave_hosts", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_SLAVE_HOSTS]), SHOW_LONG_STATUS}, |
4675 | 32 | {"show_slave_status", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_SLAVE_STAT]), SHOW_LONG_STATUS}, | 32 | {"show_slave_status", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_SLAVE_STAT]), SHOW_LONG_STATUS}, |
4676 | @@ -105,7 +105,7 @@ | |||
4677 | 105 | %token STDDEV_SAMP_SYM /* SQL-2003-N */ | 105 | %token STDDEV_SAMP_SYM /* SQL-2003-N */ |
4678 | 106 | %token STD_SYM | 106 | %token STD_SYM |
4679 | 107 | %token STOP_SYM | 107 | %token STOP_SYM |
4681 | 108 | @@ -11106,6 +11107,11 @@ | 108 | @@ -11111,6 +11112,11 @@ |
4682 | 109 | { | 109 | { |
4683 | 110 | Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT; | 110 | Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT; |
4684 | 111 | } | 111 | } |
4685 | 112 | 112 | ||
4686 | === modified file 'patches/show_temp.patch' | |||
4687 | --- patches/show_temp.patch 2011-12-27 15:32:16 +0000 | |||
4688 | +++ patches/show_temp.patch 2012-02-06 05:02:26 +0000 | |||
4689 | @@ -25,7 +25,7 @@ | |||
4690 | 25 | SCH_VARIABLES, | 25 | SCH_VARIABLES, |
4691 | 26 | --- a/sql/mysqld.cc | 26 | --- a/sql/mysqld.cc |
4692 | 27 | +++ b/sql/mysqld.cc | 27 | +++ b/sql/mysqld.cc |
4694 | 28 | @@ -3101,6 +3101,7 @@ | 28 | @@ -2951,6 +2951,7 @@ |
4695 | 29 | {"show_storage_engines", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_STORAGE_ENGINES]), SHOW_LONG_STATUS}, | 29 | {"show_storage_engines", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_STORAGE_ENGINES]), SHOW_LONG_STATUS}, |
4696 | 30 | {"show_table_status", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_TABLE_STATUS]), SHOW_LONG_STATUS}, | 30 | {"show_table_status", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_TABLE_STATUS]), SHOW_LONG_STATUS}, |
4697 | 31 | {"show_tables", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_TABLES]), SHOW_LONG_STATUS}, | 31 | {"show_tables", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_TABLES]), SHOW_LONG_STATUS}, |
4698 | @@ -33,7 +33,7 @@ | |||
4699 | 33 | {"show_triggers", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_TRIGGERS]), SHOW_LONG_STATUS}, | 33 | {"show_triggers", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_TRIGGERS]), SHOW_LONG_STATUS}, |
4700 | 34 | {"show_variables", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_VARIABLES]), SHOW_LONG_STATUS}, | 34 | {"show_variables", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_VARIABLES]), SHOW_LONG_STATUS}, |
4701 | 35 | {"show_warnings", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_WARNS]), SHOW_LONG_STATUS}, | 35 | {"show_warnings", (char*) offsetof(STATUS_VAR, com_stat[(uint) SQLCOM_SHOW_WARNS]), SHOW_LONG_STATUS}, |
4703 | 36 | @@ -7802,6 +7803,7 @@ | 36 | @@ -7670,6 +7671,7 @@ |
4704 | 37 | PSI_mutex_key key_LOCK_des_key_file; | 37 | PSI_mutex_key key_LOCK_des_key_file; |
4705 | 38 | #endif /* HAVE_OPENSSL */ | 38 | #endif /* HAVE_OPENSSL */ |
4706 | 39 | 39 | ||
4707 | @@ -41,7 +41,7 @@ | |||
4708 | 41 | PSI_mutex_key key_BINLOG_LOCK_index, key_BINLOG_LOCK_prep_xids, | 41 | PSI_mutex_key key_BINLOG_LOCK_index, key_BINLOG_LOCK_prep_xids, |
4709 | 42 | key_delayed_insert_mutex, key_hash_filo_lock, key_LOCK_active_mi, | 42 | key_delayed_insert_mutex, key_hash_filo_lock, key_LOCK_active_mi, |
4710 | 43 | key_LOCK_connection_count, key_LOCK_crypt, key_LOCK_delayed_create, | 43 | key_LOCK_connection_count, key_LOCK_crypt, key_LOCK_delayed_create, |
4712 | 44 | @@ -7855,6 +7857,7 @@ | 44 | @@ -7723,6 +7725,7 @@ |
4713 | 45 | { &key_LOCK_system_variables_hash, "LOCK_system_variables_hash", PSI_FLAG_GLOBAL}, | 45 | { &key_LOCK_system_variables_hash, "LOCK_system_variables_hash", PSI_FLAG_GLOBAL}, |
4714 | 46 | { &key_LOCK_table_share, "LOCK_table_share", PSI_FLAG_GLOBAL}, | 46 | { &key_LOCK_table_share, "LOCK_table_share", PSI_FLAG_GLOBAL}, |
4715 | 47 | { &key_LOCK_thd_data, "THD::LOCK_thd_data", 0}, | 47 | { &key_LOCK_thd_data, "THD::LOCK_thd_data", 0}, |
4716 | @@ -387,7 +387,7 @@ | |||
4717 | 387 | OPEN_TRIGGER_ONLY|OPTIMIZE_I_S_TABLE}, | 387 | OPEN_TRIGGER_ONLY|OPTIMIZE_I_S_TABLE}, |
4718 | 388 | --- a/sql/sql_yacc.yy | 388 | --- a/sql/sql_yacc.yy |
4719 | 389 | +++ b/sql/sql_yacc.yy | 389 | +++ b/sql/sql_yacc.yy |
4721 | 390 | @@ -10893,6 +10893,15 @@ | 390 | @@ -10898,6 +10898,15 @@ |
4722 | 391 | if (prepare_schema_table(YYTHD, lex, 0, SCH_TABLE_NAMES)) | 391 | if (prepare_schema_table(YYTHD, lex, 0, SCH_TABLE_NAMES)) |
4723 | 392 | MYSQL_YYABORT; | 392 | MYSQL_YYABORT; |
4724 | 393 | } | 393 | } |
4725 | @@ -405,7 +405,7 @@ | |||
4726 | 405 | LEX *lex= Lex; | 405 | LEX *lex= Lex; |
4727 | 406 | --- a/sql/mysqld.h | 406 | --- a/sql/mysqld.h |
4728 | 407 | +++ b/sql/mysqld.h | 407 | +++ b/sql/mysqld.h |
4730 | 408 | @@ -233,6 +233,7 @@ | 408 | @@ -234,6 +234,7 @@ |
4731 | 409 | extern PSI_mutex_key key_LOCK_des_key_file; | 409 | extern PSI_mutex_key key_LOCK_des_key_file; |
4732 | 410 | #endif | 410 | #endif |
4733 | 411 | 411 | ||
4734 | 412 | 412 | ||
4735 | === modified file 'patches/slow_extended.patch' | |||
4736 | --- patches/slow_extended.patch 2011-12-27 15:32:16 +0000 | |||
4737 | +++ patches/slow_extended.patch 2012-02-06 05:02:26 +0000 | |||
4738 | @@ -411,7 +411,7 @@ | |||
4739 | 411 | ulonglong lock_utime, bool is_command, | 411 | ulonglong lock_utime, bool is_command, |
4740 | 412 | --- a/sql/mysqld.cc | 412 | --- a/sql/mysqld.cc |
4741 | 413 | +++ b/sql/mysqld.cc | 413 | +++ b/sql/mysqld.cc |
4743 | 414 | @@ -421,6 +421,10 @@ | 414 | @@ -425,6 +425,10 @@ |
4744 | 415 | char* opt_secure_file_priv; | 415 | char* opt_secure_file_priv; |
4745 | 416 | my_bool opt_log_slow_admin_statements= 0; | 416 | my_bool opt_log_slow_admin_statements= 0; |
4746 | 417 | my_bool opt_log_slow_slave_statements= 0; | 417 | my_bool opt_log_slow_slave_statements= 0; |
4747 | @@ -422,7 +422,7 @@ | |||
4748 | 422 | my_bool lower_case_file_system= 0; | 422 | my_bool lower_case_file_system= 0; |
4749 | 423 | my_bool opt_large_pages= 0; | 423 | my_bool opt_large_pages= 0; |
4750 | 424 | my_bool opt_super_large_pages= 0; | 424 | my_bool opt_super_large_pages= 0; |
4752 | 425 | @@ -5892,14 +5896,10 @@ | 425 | @@ -5753,14 +5757,10 @@ |
4753 | 426 | "Don't log extra information to update and slow-query logs.", | 426 | "Don't log extra information to update and slow-query logs.", |
4754 | 427 | &opt_short_log_format, &opt_short_log_format, | 427 | &opt_short_log_format, &opt_short_log_format, |
4755 | 428 | 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, | 428 | 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, |
4756 | @@ -439,7 +439,7 @@ | |||
4757 | 439 | {"log-slow-queries", OPT_SLOW_QUERY_LOG, | 439 | {"log-slow-queries", OPT_SLOW_QUERY_LOG, |
4758 | 440 | "Log slow queries to a table or log file. Defaults logging to table " | 440 | "Log slow queries to a table or log file. Defaults logging to table " |
4759 | 441 | "mysql.slow_log or hostname-slow.log if --log-output=file is used. " | 441 | "mysql.slow_log or hostname-slow.log if --log-output=file is used. " |
4761 | 442 | @@ -7288,6 +7288,10 @@ | 442 | @@ -7156,6 +7156,10 @@ |
4762 | 443 | 443 | ||
4763 | 444 | C_MODE_END | 444 | C_MODE_END |
4764 | 445 | 445 | ||
4765 | @@ -450,7 +450,7 @@ | |||
4766 | 450 | /** | 450 | /** |
4767 | 451 | Get server options from the command line, | 451 | Get server options from the command line, |
4768 | 452 | and perform related server initializations. | 452 | and perform related server initializations. |
4770 | 453 | @@ -7437,6 +7441,8 @@ | 453 | @@ -7305,6 +7309,8 @@ |
4771 | 454 | global_system_variables.long_query_time= (ulonglong) | 454 | global_system_variables.long_query_time= (ulonglong) |
4772 | 455 | (global_system_variables.long_query_time_double * 1e6); | 455 | (global_system_variables.long_query_time_double * 1e6); |
4773 | 456 | 456 | ||
4774 | @@ -569,7 +569,7 @@ | |||
4775 | 569 | } | 569 | } |
4776 | 570 | 570 | ||
4777 | 571 | 571 | ||
4779 | 572 | @@ -3682,8 +3717,6 @@ | 572 | @@ -3687,8 +3722,6 @@ |
4780 | 573 | backup->in_sub_stmt= in_sub_stmt; | 573 | backup->in_sub_stmt= in_sub_stmt; |
4781 | 574 | backup->enable_slow_log= enable_slow_log; | 574 | backup->enable_slow_log= enable_slow_log; |
4782 | 575 | backup->limit_found_rows= limit_found_rows; | 575 | backup->limit_found_rows= limit_found_rows; |
4783 | @@ -578,7 +578,7 @@ | |||
4784 | 578 | backup->cuted_fields= cuted_fields; | 578 | backup->cuted_fields= cuted_fields; |
4785 | 579 | backup->client_capabilities= client_capabilities; | 579 | backup->client_capabilities= client_capabilities; |
4786 | 580 | backup->savepoints= transaction.savepoints; | 580 | backup->savepoints= transaction.savepoints; |
4788 | 581 | @@ -3691,6 +3724,7 @@ | 581 | @@ -3696,6 +3729,7 @@ |
4789 | 582 | first_successful_insert_id_in_prev_stmt; | 582 | first_successful_insert_id_in_prev_stmt; |
4790 | 583 | backup->first_successful_insert_id_in_cur_stmt= | 583 | backup->first_successful_insert_id_in_cur_stmt= |
4791 | 584 | first_successful_insert_id_in_cur_stmt; | 584 | first_successful_insert_id_in_cur_stmt; |
4792 | @@ -586,7 +586,7 @@ | |||
4793 | 586 | 586 | ||
4794 | 587 | if ((!lex->requires_prelocking() || is_update_query(lex->sql_command)) && | 587 | if ((!lex->requires_prelocking() || is_update_query(lex->sql_command)) && |
4795 | 588 | !is_current_stmt_binlog_format_row()) | 588 | !is_current_stmt_binlog_format_row()) |
4797 | 589 | @@ -3706,13 +3740,74 @@ | 589 | @@ -3711,13 +3745,74 @@ |
4798 | 590 | /* Disable result sets */ | 590 | /* Disable result sets */ |
4799 | 591 | client_capabilities &= ~CLIENT_MULTI_RESULTS; | 591 | client_capabilities &= ~CLIENT_MULTI_RESULTS; |
4800 | 592 | in_sub_stmt|= new_state; | 592 | in_sub_stmt|= new_state; |
4801 | @@ -663,7 +663,7 @@ | |||
4802 | 663 | 663 | ||
4803 | 664 | void THD::restore_sub_statement_state(Sub_statement_state *backup) | 664 | void THD::restore_sub_statement_state(Sub_statement_state *backup) |
4804 | 665 | { | 665 | { |
4806 | 666 | @@ -3753,7 +3848,6 @@ | 666 | @@ -3758,7 +3853,6 @@ |
4807 | 667 | first_successful_insert_id_in_cur_stmt= | 667 | first_successful_insert_id_in_cur_stmt= |
4808 | 668 | backup->first_successful_insert_id_in_cur_stmt; | 668 | backup->first_successful_insert_id_in_cur_stmt; |
4809 | 669 | limit_found_rows= backup->limit_found_rows; | 669 | limit_found_rows= backup->limit_found_rows; |
4810 | @@ -671,7 +671,7 @@ | |||
4811 | 671 | client_capabilities= backup->client_capabilities; | 671 | client_capabilities= backup->client_capabilities; |
4812 | 672 | /* | 672 | /* |
4813 | 673 | If we've left sub-statement mode, reset the fatal error flag. | 673 | If we've left sub-statement mode, reset the fatal error flag. |
4815 | 674 | @@ -3771,8 +3865,8 @@ | 674 | @@ -3776,8 +3870,8 @@ |
4816 | 675 | The following is added to the old values as we are interested in the | 675 | The following is added to the old values as we are interested in the |
4817 | 676 | total complexity of the query | 676 | total complexity of the query |
4818 | 677 | */ | 677 | */ |
4819 | @@ -1072,7 +1072,7 @@ | |||
4820 | 1072 | { | 1072 | { |
4821 | 1073 | --- a/sql/sys_vars.cc | 1073 | --- a/sql/sys_vars.cc |
4822 | 1074 | +++ b/sql/sys_vars.cc | 1074 | +++ b/sql/sys_vars.cc |
4824 | 1075 | @@ -972,6 +972,29 @@ | 1075 | @@ -1045,6 +1045,29 @@ |
4825 | 1076 | NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), | 1076 | NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), |
4826 | 1077 | ON_UPDATE(update_cached_long_query_time)); | 1077 | ON_UPDATE(update_cached_long_query_time)); |
4827 | 1078 | 1078 | ||
4828 | @@ -1102,7 +1102,7 @@ | |||
4829 | 1102 | static bool fix_low_prio_updates(sys_var *self, THD *thd, enum_var_type type) | 1102 | static bool fix_low_prio_updates(sys_var *self, THD *thd, enum_var_type type) |
4830 | 1103 | { | 1103 | { |
4831 | 1104 | if (type == OPT_SESSION) | 1104 | if (type == OPT_SESSION) |
4833 | 1105 | @@ -2904,6 +2927,123 @@ | 1105 | @@ -2977,6 +3000,123 @@ |
4834 | 1106 | DEFAULT(FALSE), NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), | 1106 | DEFAULT(FALSE), NO_MUTEX_GUARD, NOT_IN_BINLOG, ON_CHECK(0), |
4835 | 1107 | ON_UPDATE(fix_log_state)); | 1107 | ON_UPDATE(fix_log_state)); |
4836 | 1108 | 1108 | ||
4837 | 1109 | 1109 | ||
4838 | === modified file 'patches/sql_no_fcache.patch' | |||
4839 | --- patches/sql_no_fcache.patch 2011-12-13 13:49:04 +0000 | |||
4840 | +++ patches/sql_no_fcache.patch 2012-02-06 05:02:26 +0000 | |||
4841 | @@ -139,7 +139,7 @@ | |||
4842 | 139 | { "SQL_TSI_SECOND", SYM(SECOND_SYM)}, | 139 | { "SQL_TSI_SECOND", SYM(SECOND_SYM)}, |
4843 | 140 | --- a/sql/mysqld.h | 140 | --- a/sql/mysqld.h |
4844 | 141 | +++ b/sql/mysqld.h | 141 | +++ b/sql/mysqld.h |
4846 | 142 | @@ -194,6 +194,8 @@ | 142 | @@ -195,6 +195,8 @@ |
4847 | 143 | extern char language[FN_REFLEN]; | 143 | extern char language[FN_REFLEN]; |
4848 | 144 | extern "C" MYSQL_PLUGIN_IMPORT ulong server_id; | 144 | extern "C" MYSQL_PLUGIN_IMPORT ulong server_id; |
4849 | 145 | extern ulong concurrency; | 145 | extern ulong concurrency; |
4850 | @@ -162,7 +162,7 @@ | |||
4851 | 162 | 162 | ||
4852 | 163 | #include <thr_alarm.h> | 163 | #include <thr_alarm.h> |
4853 | 164 | #include <ft_global.h> | 164 | #include <ft_global.h> |
4855 | 165 | @@ -487,6 +492,11 @@ | 165 | @@ -491,6 +496,11 @@ |
4856 | 166 | ulong binlog_cache_use= 0, binlog_cache_disk_use= 0; | 166 | ulong binlog_cache_use= 0, binlog_cache_disk_use= 0; |
4857 | 167 | ulong binlog_stmt_cache_use= 0, binlog_stmt_cache_disk_use= 0; | 167 | ulong binlog_stmt_cache_use= 0, binlog_stmt_cache_disk_use= 0; |
4858 | 168 | ulong max_connections, max_connect_errors; | 168 | ulong max_connections, max_connect_errors; |
4859 | @@ -174,7 +174,7 @@ | |||
4860 | 174 | /* | 174 | /* |
4861 | 175 | Maximum length of parameter value which can be set through | 175 | Maximum length of parameter value which can be set through |
4862 | 176 | mysql_send_long_data() call. | 176 | mysql_send_long_data() call. |
4864 | 177 | @@ -4252,6 +4262,97 @@ | 177 | @@ -4102,6 +4112,97 @@ |
4865 | 178 | #define decrement_handler_count() | 178 | #define decrement_handler_count() |
4866 | 179 | #endif /* defined(_WIN32) || defined(HAVE_SMEM) */ | 179 | #endif /* defined(_WIN32) || defined(HAVE_SMEM) */ |
4867 | 180 | 180 | ||
4868 | @@ -272,7 +272,7 @@ | |||
4869 | 272 | 272 | ||
4870 | 273 | #ifndef EMBEDDED_LIBRARY | 273 | #ifndef EMBEDDED_LIBRARY |
4871 | 274 | #ifndef DBUG_OFF | 274 | #ifndef DBUG_OFF |
4873 | 275 | @@ -4510,6 +4611,10 @@ | 275 | @@ -4363,6 +4464,10 @@ |
4874 | 276 | test_lc_time_sz(); | 276 | test_lc_time_sz(); |
4875 | 277 | #endif | 277 | #endif |
4876 | 278 | 278 | ||
4877 | @@ -283,7 +283,7 @@ | |||
4878 | 283 | /* | 283 | /* |
4879 | 284 | We have enough space for fiddling with the argv, continue | 284 | We have enough space for fiddling with the argv, continue |
4880 | 285 | */ | 285 | */ |
4882 | 286 | @@ -4713,6 +4818,10 @@ | 286 | @@ -4574,6 +4679,10 @@ |
4883 | 287 | } | 287 | } |
4884 | 288 | #endif | 288 | #endif |
4885 | 289 | clean_up(1); | 289 | clean_up(1); |
4886 | @@ -294,7 +294,7 @@ | |||
4887 | 294 | mysqld_exit(0); | 294 | mysqld_exit(0); |
4888 | 295 | } | 295 | } |
4889 | 296 | 296 | ||
4891 | 297 | @@ -6553,6 +6662,7 @@ | 297 | @@ -6421,6 +6530,7 @@ |
4892 | 298 | {"Delayed_errors", (char*) &delayed_insert_errors, SHOW_LONG}, | 298 | {"Delayed_errors", (char*) &delayed_insert_errors, SHOW_LONG}, |
4893 | 299 | {"Delayed_insert_threads", (char*) &delayed_insert_threads, SHOW_LONG_NOFLUSH}, | 299 | {"Delayed_insert_threads", (char*) &delayed_insert_threads, SHOW_LONG_NOFLUSH}, |
4894 | 300 | {"Delayed_writes", (char*) &delayed_insert_writes, SHOW_LONG}, | 300 | {"Delayed_writes", (char*) &delayed_insert_writes, SHOW_LONG}, |
4895 | @@ -314,7 +314,7 @@ | |||
4896 | 314 | lex->leaf_tables_insert= 0; | 314 | lex->leaf_tables_insert= 0; |
4897 | 315 | --- a/sql/sql_lex.h | 315 | --- a/sql/sql_lex.h |
4898 | 316 | +++ b/sql/sql_lex.h | 316 | +++ b/sql/sql_lex.h |
4900 | 317 | @@ -2345,6 +2345,7 @@ | 317 | @@ -2346,6 +2346,7 @@ |
4901 | 318 | 318 | ||
4902 | 319 | enum enum_yes_no_unknown tx_chain, tx_release; | 319 | enum enum_yes_no_unknown tx_chain, tx_release; |
4903 | 320 | bool safe_to_cache_query; | 320 | bool safe_to_cache_query; |
4904 | @@ -378,7 +378,7 @@ | |||
4905 | 378 | %token SQL_SMALL_RESULT | 378 | %token SQL_SMALL_RESULT |
4906 | 379 | %token SQL_SYM /* SQL-2003-R */ | 379 | %token SQL_SYM /* SQL-2003-R */ |
4907 | 380 | %token SQL_THREAD | 380 | %token SQL_THREAD |
4909 | 381 | @@ -7357,6 +7358,10 @@ | 381 | @@ -7362,6 +7363,10 @@ |
4910 | 382 | Lex->select_lex.sql_cache= SELECT_LEX::SQL_NO_CACHE; | 382 | Lex->select_lex.sql_cache= SELECT_LEX::SQL_NO_CACHE; |
4911 | 383 | } | 383 | } |
4912 | 384 | } | 384 | } |
4913 | 385 | 385 | ||
4914 | === modified file 'patches/subunit.patch' | |||
4915 | --- patches/subunit.patch 2012-01-10 07:01:07 +0000 | |||
4916 | +++ patches/subunit.patch 2012-02-06 05:02:26 +0000 | |||
4917 | @@ -189,7 +189,7 @@ | |||
4918 | 189 | 189 | ||
4919 | 190 | require "lib/mtr_process.pl"; | 190 | require "lib/mtr_process.pl"; |
4920 | 191 | require "lib/mtr_io.pl"; | 191 | require "lib/mtr_io.pl"; |
4922 | 192 | @@ -291,6 +292,7 @@ | 192 | @@ -292,6 +293,7 @@ |
4923 | 193 | my $opt_valgrind_path; | 193 | my $opt_valgrind_path; |
4924 | 194 | my $valgrind_reports= 0; | 194 | my $valgrind_reports= 0; |
4925 | 195 | my $opt_callgrind; | 195 | my $opt_callgrind; |
4926 | @@ -197,7 +197,7 @@ | |||
4927 | 197 | my %mysqld_logs; | 197 | my %mysqld_logs; |
4928 | 198 | my $opt_debug_sync_timeout= 300; # Default timeout for WAIT_FOR actions. | 198 | my $opt_debug_sync_timeout= 300; # Default timeout for WAIT_FOR actions. |
4929 | 199 | 199 | ||
4931 | 200 | @@ -630,6 +632,7 @@ | 200 | @@ -631,6 +633,7 @@ |
4932 | 201 | 201 | ||
4933 | 202 | # Report test status | 202 | # Report test status |
4934 | 203 | mtr_report_test($result); | 203 | mtr_report_test($result); |
4935 | @@ -205,7 +205,7 @@ | |||
4936 | 205 | 205 | ||
4937 | 206 | if ( $result->is_failed() ) { | 206 | if ( $result->is_failed() ) { |
4938 | 207 | 207 | ||
4940 | 208 | @@ -1142,6 +1145,7 @@ | 208 | @@ -1144,6 +1147,7 @@ |
4941 | 209 | 'valgrind-option=s' => \@valgrind_args, | 209 | 'valgrind-option=s' => \@valgrind_args, |
4942 | 210 | 'valgrind-path=s' => \$opt_valgrind_path, | 210 | 'valgrind-path=s' => \$opt_valgrind_path, |
4943 | 211 | 'callgrind' => \$opt_callgrind, | 211 | 'callgrind' => \$opt_callgrind, |
4944 | @@ -213,7 +213,7 @@ | |||
4945 | 213 | 'debug-sync-timeout=i' => \$opt_debug_sync_timeout, | 213 | 'debug-sync-timeout=i' => \$opt_debug_sync_timeout, |
4946 | 214 | 214 | ||
4947 | 215 | # Directories | 215 | # Directories |
4949 | 216 | @@ -1703,11 +1707,18 @@ | 216 | @@ -1705,11 +1709,18 @@ |
4950 | 217 | unless @valgrind_args; | 217 | unless @valgrind_args; |
4951 | 218 | } | 218 | } |
4952 | 219 | 219 | ||
4953 | @@ -233,7 +233,7 @@ | |||
4954 | 233 | 233 | ||
4955 | 234 | # Don't add --quiet; you will loose the summary reports. | 234 | # Don't add --quiet; you will loose the summary reports. |
4956 | 235 | 235 | ||
4958 | 236 | @@ -5796,6 +5807,10 @@ | 236 | @@ -5831,6 +5842,10 @@ |
4959 | 237 | mtr_add_arg($args, "--tool=callgrind"); | 237 | mtr_add_arg($args, "--tool=callgrind"); |
4960 | 238 | mtr_add_arg($args, "--base=$opt_vardir/log"); | 238 | mtr_add_arg($args, "--base=$opt_vardir/log"); |
4961 | 239 | } | 239 | } |
4962 | 240 | 240 | ||
4963 | === modified file 'patches/userstat.patch' | |||
4964 | --- patches/userstat.patch 2011-12-27 15:32:16 +0000 | |||
4965 | +++ patches/userstat.patch 2012-02-06 05:02:26 +0000 | |||
4966 | @@ -363,7 +363,7 @@ | |||
4967 | 363 | /* | 363 | /* |
4968 | 364 | Log error with all enabled log event handlers | 364 | Log error with all enabled log event handlers |
4969 | 365 | 365 | ||
4971 | 366 | @@ -5026,6 +5033,8 @@ | 366 | @@ -5062,6 +5069,8 @@ |
4972 | 367 | thd->first_successful_insert_id_in_prev_stmt_for_binlog); | 367 | thd->first_successful_insert_id_in_prev_stmt_for_binlog); |
4973 | 368 | if (e.write(file)) | 368 | if (e.write(file)) |
4974 | 369 | goto err; | 369 | goto err; |
4975 | @@ -372,7 +372,7 @@ | |||
4976 | 372 | } | 372 | } |
4977 | 373 | if (thd->auto_inc_intervals_in_cur_stmt_for_binlog.nb_elements() > 0) | 373 | if (thd->auto_inc_intervals_in_cur_stmt_for_binlog.nb_elements() > 0) |
4978 | 374 | { | 374 | { |
4980 | 375 | @@ -5037,12 +5046,16 @@ | 375 | @@ -5073,12 +5082,16 @@ |
4981 | 376 | minimum()); | 376 | minimum()); |
4982 | 377 | if (e.write(file)) | 377 | if (e.write(file)) |
4983 | 378 | goto err; | 378 | goto err; |
4984 | @@ -389,7 +389,7 @@ | |||
4985 | 389 | } | 389 | } |
4986 | 390 | if (thd->user_var_events.elements) | 390 | if (thd->user_var_events.elements) |
4987 | 391 | { | 391 | { |
4989 | 392 | @@ -5065,6 +5078,8 @@ | 392 | @@ -5101,6 +5114,8 @@ |
4990 | 393 | flags); | 393 | flags); |
4991 | 394 | if (e.write(file)) | 394 | if (e.write(file)) |
4992 | 395 | goto err; | 395 | goto err; |
4993 | @@ -398,7 +398,7 @@ | |||
4994 | 398 | } | 398 | } |
4995 | 399 | } | 399 | } |
4996 | 400 | } | 400 | } |
4998 | 401 | @@ -5076,6 +5091,8 @@ | 401 | @@ -5112,6 +5127,8 @@ |
4999 | 402 | if (event_info->write(file) || | 402 | if (event_info->write(file) || |
5000 | 403 | DBUG_EVALUATE_IF("injecting_fault_writing", 1, 0)) | 403 | DBUG_EVALUATE_IF("injecting_fault_writing", 1, 0)) |
The diff has been truncated for viewing.