Merge lp:~percona-dev/percona-server/no-warnings into lp:percona-server/release-5.1.54-12
- no-warnings
- Merge into 5.1.54
Status: | Superseded |
---|---|
Proposed branch: | lp:~percona-dev/percona-server/no-warnings |
Merge into: | lp:percona-server/release-5.1.54-12 |
Diff against target: |
965 lines (+181/-122) 20 files modified
bug59486.patch (+15/-0) error_pad.patch (+2/-2) innodb_buffer_pool_shm.patch (+4/-3) innodb_extend_slow.patch (+4/-17) innodb_fast_shutdown.patch (+7/-1) innodb_files_extend.patch (+12/-0) innodb_fix_misc.patch (+8/-0) innodb_io_patches.patch (+36/-34) innodb_lru_dump_restore.patch (+6/-23) innodb_pass_corrupt_table.patch (+3/-3) innodb_purge_thread.patch (+5/-5) innodb_separate_doublewrite.patch (+12/-4) innodb_show_lock_name.patch (+15/-6) innodb_split_buf_pool_mutex.patch (+35/-5) innodb_stats.patch (+1/-1) response-time-distribution.patch (+2/-2) series (+1/-0) show_patches.patch (+1/-1) sql_no_fcache.patch (+3/-1) userstat.patch (+9/-14) |
To merge this branch: | bzr merge lp:~percona-dev/percona-server/no-warnings |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Yasufumi Kinoshita (community) | Needs Fixing | ||
Percona developers | Pending | ||
Review via email: mp+46356@code.launchpad.net |
This proposal has been superseded by a proposal from 2011-02-01.
Commit message
Description of the change
Yasufumi Kinoshita (yasufumi-kinoshita) : | # |
Yasufumi Kinoshita (yasufumi-kinoshita) wrote : | # |
Yasufumi Kinoshita (yasufumi-kinoshita) : | # |
Yasufumi Kinoshita (yasufumi-kinoshita) wrote : | # |
Does force decreasing warnings really increase the stability?
It may increase bugs.
Alexey Kopytov (akopytov) wrote : | # |
Yasufumi,
Thanks for your review.
> Hmm?
>
> 382 -+ lint n_flush;
> 383 -+ lint blocks_sum, new_blocks_sum, flushed_blocks_sum;
> 384 ++ ulint n_flush;
> 385 ++ ulint blocks_sum;
> 386 ++ ulint new_blocks_sum;
> 387 ++ ulint flushed_blocks_sum;
>
> after the change,
>
> n_flush = blocks_sum * (lsn - lsn_old) / log_sys-
> if (flushed_blocks_sum > n_pages_
> n_flush -= (flushed_blocks_sum - n_pages_
> }
>
> is changed?
>
> n_flush can be minus logically.
Good catch! I have fixed that.
Alexey Kopytov (akopytov) wrote : | # |
> Does force decreasing warnings really increase the stability?
Yes, it does increase the code quality. Quite often a compiler warning indicates a real problem/bug in the code. But if you have many warnings, it will go unnoticed. The only way to make sure all warnings are addressed by developers is to fix all existing warnings and make sure no new ones are introduced.
Upstream MySQL development has done a huge work to remove warnings. As a part of that work, --with-debug=full now builds -Werror to make sure no new warnings are introduced. That, however, prevented Percona Server to be built with -Werror.
> It may increase bugs.
I don't see any possible scenarios where a removing compiler warning would directly lead to new bugs.
Can you elaborate on that?
Yasufumi Kinoshita (yasufumi-kinoshita) wrote : | # |
I mean it should be done by the person who know the code well.
In this case, you may break logic of the exist code.
Simple decrement of the warning without knowledge may cause broken code.
If you don't change the sign of the types, it works fine 100% as intended by me.
I always aware all workloads all over the world.
Even if it is very rare case, I should be consider.
So, the warning decrement activity should be done by the author ideally,
if you still insist it should be done.
Alexey Kopytov (akopytov) wrote : | # |
Yasufumi,
As long as I am able to build Percona Server with -Werror, I'm happy. If you think you can fix that yourself, that's fine, just let me know when you are going to do that.
Yasufumi Kinoshita (yasufumi-kinoshita) wrote : | # |
Alexey,
I used "-Wall -Wpointer-arith" and confirmed their safeness. (added "-Wpointer-arith" in this half of year.)
Why don't you explain the merit to reduce the warnings (not only confirm them)
for the code based on objective facts and logic....?
And I think you should never get mysqld with "-Werror" at many of distributions...
I always get warnings from basic mysql code with my options.
And the older GCC 4.1.? (CentOS5.5) always print warning about atomic-builtin of gcc...
Does removing "-Wall -Wpointer-arith" and using "-Werror" increase quality of code?
Or, should I also need to build with "-Werror" without "-Wall -Wpointer-arith" for each development and for your happiness?
I am happy, if the possibility to contort or break our codes are eliminated.
It seemed for me that you introduced the possibility only for your preference.
Thanks.
Preview Diff
1 | === added file 'bug59486.patch' |
2 | --- bug59486.patch 1970-01-01 00:00:00 +0000 |
3 | +++ bug59486.patch 2011-01-17 07:35:09 +0000 |
4 | @@ -0,0 +1,15 @@ |
5 | +# name : bug59486.patch |
6 | +# maintainer : Alexey |
7 | +# |
8 | +diff -ruN a/storage/innodb_plugin/mtr/mtr0log.c b/storage/innodb_plugin/mtr/mtr0log.c |
9 | +--- a/storage/innodb_plugin/mtr/mtr0log.c 2011-01-14 00:00:48.000000000 +0300 |
10 | ++++ b/storage/innodb_plugin/mtr/mtr0log.c 2011-01-14 00:01:21.000000000 +0300 |
11 | +@@ -408,7 +408,7 @@ |
12 | + ptr += 2; |
13 | + |
14 | + if (UNIV_UNLIKELY(offset >= UNIV_PAGE_SIZE) |
15 | +- || UNIV_UNLIKELY(len + offset) > UNIV_PAGE_SIZE) { |
16 | ++ || UNIV_UNLIKELY(len + offset > UNIV_PAGE_SIZE)) { |
17 | + recv_sys->found_corrupt_log = TRUE; |
18 | + |
19 | + return(NULL); |
20 | |
21 | === modified file 'error_pad.patch' |
22 | --- error_pad.patch 2010-10-19 00:20:32 +0000 |
23 | +++ error_pad.patch 2011-01-17 07:35:09 +0000 |
24 | @@ -61,7 +61,7 @@ |
25 | - goto err; |
26 | + int padd_to= tmp_error->d_code; |
27 | + char* padd_message= tmp->text; |
28 | -+ while ((row_nr+er_offset) < padd_to) |
29 | ++ while ((int) row_nr + er_offset < padd_to) |
30 | + { |
31 | + if (copy_rows(to, padd_message,row_nr,start_pos)) |
32 | + { |
33 | @@ -177,7 +177,7 @@ |
34 | + fprintf(stderr, "Failed to parse the error padd string '%s' '%s' (d_code doesn't parse)!\n",er_name,str); |
35 | + DBUG_RETURN(0); |
36 | + } |
37 | -+ if (d_code < (er_offset + er_count)) |
38 | ++ if (d_code < (uint) er_offset + er_count) |
39 | + { |
40 | + fprintf(stderr, "Error to padding less current error number!\n"); |
41 | + DBUG_RETURN(0); |
42 | |
43 | === modified file 'innodb_buffer_pool_shm.patch' |
44 | --- innodb_buffer_pool_shm.patch 2010-12-16 11:35:26 +0000 |
45 | +++ innodb_buffer_pool_shm.patch 2011-01-17 07:35:09 +0000 |
46 | @@ -299,7 +299,7 @@ |
47 | |
48 | /* Subtract the space needed for block descriptors. */ |
49 | { |
50 | -@@ -810,6 +1044,98 @@ |
51 | +@@ -810,6 +1044,99 @@ |
52 | chunk->size = size; |
53 | } |
54 | |
55 | @@ -335,8 +335,9 @@ |
56 | + "InnoDB: Logical offset (blocks) : %ld (%#lx)\n", |
57 | + (byte*)chunk->mem + shm_info->frame_offset, |
58 | + chunk->blocks[0].frame, frame, |
59 | -+ phys_offset, phys_offset, logi_offset, logi_offset, |
60 | -+ blocks_offset, blocks_offset); |
61 | ++ (long) phys_offset, (ulong) phys_offset, |
62 | ++ (long) logi_offset, (ulong) logi_offset, |
63 | ++ (long) blocks_offset, (ulong) blocks_offset); |
64 | + } else { |
65 | + fprintf(stderr, |
66 | + "InnoDB: Buffer pool in the shared memory segment can be used as it is.\n"); |
67 | |
68 | === modified file 'innodb_extend_slow.patch' |
69 | --- innodb_extend_slow.patch 2010-12-16 11:35:26 +0000 |
70 | +++ innodb_extend_slow.patch 2011-01-17 07:35:09 +0000 |
71 | @@ -37,9 +37,9 @@ |
72 | + block->page.offset, DPAH_SIZE << 3); |
73 | + block_hash_byte = block_hash >> 3; |
74 | + block_hash_offset = (byte) block_hash & 0x07; |
75 | -+ if (block_hash_byte < 0 || block_hash_byte >= DPAH_SIZE) |
76 | ++ if (block_hash_byte >= DPAH_SIZE) |
77 | + fprintf(stderr, "!!! block_hash_byte = %lu block_hash_offset = %d !!!\n", block_hash_byte, block_hash_offset); |
78 | -+ if (block_hash_offset < 0 || block_hash_offset > 7) |
79 | ++ if (block_hash_offset > 7) |
80 | + fprintf(stderr, "!!! block_hash_byte = %lu block_hash_offset = %d !!!\n", block_hash_byte, block_hash_offset); |
81 | + if ((trx->distinct_page_access_hash[block_hash_byte] & ((byte) 0x01 << block_hash_offset)) == 0) |
82 | + trx->distinct_page_access++; |
83 | @@ -766,16 +766,6 @@ |
84 | |
85 | if ((ulint)ret == n) { |
86 | |
87 | -@@ -3356,7 +3390,8 @@ |
88 | - offset */ |
89 | - ulint offset_high, /*!< in: most significant 32 bits of |
90 | - offset */ |
91 | -- ulint len) /*!< in: length of the block to read or write */ |
92 | -+ ulint len, /*!< in: length of the block to read or write */ |
93 | -+ trx_t* trx) |
94 | - { |
95 | - os_aio_slot_t* slot; |
96 | - ulint i; |
97 | @@ -3642,10 +3677,11 @@ |
98 | (can be used to identify a completed |
99 | aio operation); ignored if mode is |
100 | @@ -800,7 +790,7 @@ |
101 | } |
102 | |
103 | ut_a(type == OS_FILE_WRITE); |
104 | -@@ -3721,8 +3757,13 @@ |
105 | +@@ -3721,6 +3756,11 @@ |
106 | ut_error; |
107 | } |
108 | |
109 | @@ -810,11 +800,8 @@ |
110 | + trx->io_read += n; |
111 | + } |
112 | slot = os_aio_array_reserve_slot(type, array, message1, message2, file, |
113 | -- name, buf, offset, offset_high, n); |
114 | -+ name, buf, offset, offset_high, n, trx); |
115 | + name, buf, offset, offset_high, n); |
116 | if (type == OS_FILE_READ) { |
117 | - if (os_aio_use_native_aio) { |
118 | - #ifdef WIN_ASYNC_IO |
119 | diff -ruN a/storage/innodb_plugin/srv/srv0srv.c b/storage/innodb_plugin/srv/srv0srv.c |
120 | --- a/storage/innodb_plugin/srv/srv0srv.c 2010-08-27 16:27:30.233022109 +0900 |
121 | +++ b/storage/innodb_plugin/srv/srv0srv.c 2010-08-27 16:30:47.384058509 +0900 |
122 | |
123 | === modified file 'innodb_fast_shutdown.patch' |
124 | --- innodb_fast_shutdown.patch 2010-12-13 11:43:12 +0000 |
125 | +++ innodb_fast_shutdown.patch 2011-01-17 07:35:09 +0000 |
126 | @@ -11,6 +11,7 @@ |
127 | # suite. |
128 | # |
129 | # The patch also implements os_event_wait_time() for POSIX systems. |
130 | +diff -ruN /dev/null b/COPYING.innodb_fast_shutdown |
131 | --- /dev/null 1970-01-01 00:00:00.000000000 +0000 |
132 | +++ b/COPYING.innodb_fast_shutdown 2010-11-16 21:37:51.000000000 +0300 |
133 | @@ -0,0 +1,10 @@ |
134 | @@ -24,6 +25,7 @@ |
135 | + * Neither the name of the author nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. |
136 | + |
137 | +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
138 | +diff -ruN a/storage/innodb_plugin/include/os0sync.h b/storage/innodb_plugin/include/os0sync.h |
139 | --- a/storage/innodb_plugin/include/os0sync.h 2010-11-16 21:33:00.000000000 +0300 |
140 | +++ b/storage/innodb_plugin/include/os0sync.h 2010-11-16 21:34:06.000000000 +0300 |
141 | @@ -189,14 +189,14 @@ |
142 | @@ -43,6 +45,7 @@ |
143 | OS_SYNC_INFINITE_TIME */ |
144 | #ifdef __WIN__ |
145 | /**********************************************************//** |
146 | +diff -ruN a/storage/innodb_plugin/include/srv0srv.h b/storage/innodb_plugin/include/srv0srv.h |
147 | --- a/storage/innodb_plugin/include/srv0srv.h 2010-11-16 21:33:00.000000000 +0300 |
148 | +++ b/storage/innodb_plugin/include/srv0srv.h 2010-11-16 21:34:06.000000000 +0300 |
149 | @@ -57,6 +57,9 @@ |
150 | @@ -55,6 +58,7 @@ |
151 | /* If the last data file is auto-extended, we add this many pages to it |
152 | at a time */ |
153 | #define SRV_AUTO_EXTEND_INCREMENT \ |
154 | +diff -ruN a/storage/innodb_plugin/log/log0log.c b/storage/innodb_plugin/log/log0log.c |
155 | --- a/storage/innodb_plugin/log/log0log.c 2010-11-16 21:33:00.000000000 +0300 |
156 | +++ b/storage/innodb_plugin/log/log0log.c 2010-11-16 21:34:06.000000000 +0300 |
157 | @@ -3103,6 +3103,7 @@ |
158 | @@ -65,6 +69,7 @@ |
159 | loop: |
160 | os_thread_sleep(100000); |
161 | |
162 | +diff -ruN a/storage/innodb_plugin/os/os0sync.c b/storage/innodb_plugin/os/os0sync.c |
163 | --- a/storage/innodb_plugin/os/os0sync.c 2010-11-16 21:33:00.000000000 +0300 |
164 | +++ b/storage/innodb_plugin/os/os0sync.c 2010-11-16 21:34:06.000000000 +0300 |
165 | @@ -31,6 +31,9 @@ |
166 | @@ -157,6 +162,7 @@ |
167 | #endif |
168 | } |
169 | |
170 | +diff -ruN a/storage/innodb_plugin/srv/srv0srv.c b/storage/innodb_plugin/srv/srv0srv.c |
171 | --- a/storage/innodb_plugin/srv/srv0srv.c 2010-11-16 21:33:00.000000000 +0300 |
172 | +++ b/storage/innodb_plugin/srv/srv0srv.c 2010-11-16 21:34:06.000000000 +0300 |
173 | @@ -707,6 +707,8 @@ |
174 | @@ -221,7 +227,7 @@ |
175 | srv_main_sleeps++; |
176 | |
177 | /* |
178 | -@@ -3476,9 +3479,10 @@ |
179 | +@@ -3478,9 +3481,10 @@ |
180 | mutex_exit(&kernel_mutex); |
181 | |
182 | sleep_ms = 10; |
183 | |
184 | === modified file 'innodb_files_extend.patch' |
185 | --- innodb_files_extend.patch 2010-12-16 11:35:26 +0000 |
186 | +++ innodb_files_extend.patch 2011-01-17 07:35:09 +0000 |
187 | @@ -540,3 +540,15 @@ |
188 | fprintf(stderr, |
189 | "InnoDB: Error: file size must be < 4 GB" |
190 | " with this MySQL binary\n" |
191 | +diff -ruN a/storage/innodb_plugin/include/fsp0types.h b/storage/innodb_plugin/include/fsp0types.h |
192 | +--- a/storage/innodb_plugin/include/fsp0types.h 2010-11-29 13:38:03.000000000 +0300 |
193 | ++++ b/storage/innodb_plugin/include/fsp0types.h 2011-01-13 22:22:36.000000000 +0300 |
194 | +@@ -42,7 +42,7 @@ |
195 | + /* @} */ |
196 | + |
197 | + /** File space extent size (one megabyte) in pages */ |
198 | +-#define FSP_EXTENT_SIZE (1 << (20 - UNIV_PAGE_SIZE_SHIFT)) |
199 | ++#define FSP_EXTENT_SIZE (1UL << (20 - UNIV_PAGE_SIZE_SHIFT)) |
200 | + |
201 | + /** On a page of any file segment, data may be put starting from this |
202 | + offset */ |
203 | |
204 | === modified file 'innodb_fix_misc.patch' |
205 | --- innodb_fix_misc.patch 2010-12-20 21:54:44 +0000 |
206 | +++ innodb_fix_misc.patch 2011-01-17 07:35:09 +0000 |
207 | @@ -54,6 +54,14 @@ |
208 | diff -ruN a/storage/innodb_plugin/row/row0mysql.c b/storage/innodb_plugin/row/row0mysql.c |
209 | --- a/storage/innodb_plugin/row/row0mysql.c 2010-07-20 16:33:04.097866666 +0900 |
210 | +++ b/storage/innodb_plugin/row/row0mysql.c 2010-07-20 16:33:53.995828763 +0900 |
211 | +@@ -51,6 +51,7 @@ |
212 | + #include "btr0sea.h" |
213 | + #include "fil0fil.h" |
214 | + #include "ibuf0ibuf.h" |
215 | ++#include "ha_prototypes.h" |
216 | + |
217 | + /** Provide optional 4.x backwards compatibility for 5.0 and above */ |
218 | + UNIV_INTERN ibool row_rollback_on_timeout = FALSE; |
219 | @@ -1135,6 +1135,13 @@ |
220 | |
221 | thr = que_fork_get_first_thr(prebuilt->ins_graph); |
222 | |
223 | === modified file 'innodb_io_patches.patch' |
224 | --- innodb_io_patches.patch 2010-12-16 11:35:26 +0000 |
225 | +++ innodb_io_patches.patch 2011-01-17 07:35:09 +0000 |
226 | @@ -6,8 +6,8 @@ |
227 | # Any small change to this file in the main branch |
228 | # should be done or reviewed by the maintainer! |
229 | diff -ruN a/storage/innodb_plugin/buf/buf0flu.c b/storage/innodb_plugin/buf/buf0flu.c |
230 | ---- a/storage/innodb_plugin/buf/buf0flu.c 2010-08-04 02:24:19.000000000 +0900 |
231 | -+++ b/storage/innodb_plugin/buf/buf0flu.c 2010-08-27 15:52:29.282007496 +0900 |
232 | +--- a/storage/innodb_plugin/buf/buf0flu.c 2011-01-15 00:07:59.000000000 +0300 |
233 | ++++ b/storage/innodb_plugin/buf/buf0flu.c 2011-01-15 01:18:32.000000000 +0300 |
234 | @@ -1238,8 +1238,9 @@ |
235 | /*====================*/ |
236 | ulint space, /*!< in: space id */ |
237 | @@ -38,8 +38,8 @@ |
238 | buf_pool_mutex_enter(); |
239 | goto flush_next; |
240 | diff -ruN a/storage/innodb_plugin/buf/buf0rea.c b/storage/innodb_plugin/buf/buf0rea.c |
241 | ---- a/storage/innodb_plugin/buf/buf0rea.c 2010-08-04 02:24:19.000000000 +0900 |
242 | -+++ b/storage/innodb_plugin/buf/buf0rea.c 2010-08-27 15:52:29.282007496 +0900 |
243 | +--- a/storage/innodb_plugin/buf/buf0rea.c 2011-01-15 00:07:59.000000000 +0300 |
244 | ++++ b/storage/innodb_plugin/buf/buf0rea.c 2011-01-15 01:18:32.000000000 +0300 |
245 | @@ -254,6 +254,10 @@ |
246 | = BUF_READ_AHEAD_LINEAR_AREA; |
247 | ulint threshold; |
248 | @@ -52,8 +52,8 @@ |
249 | /* No read-ahead to avoid thread deadlocks */ |
250 | return(0); |
251 | diff -ruN a/storage/innodb_plugin/handler/ha_innodb.cc b/storage/innodb_plugin/handler/ha_innodb.cc |
252 | ---- a/storage/innodb_plugin/handler/ha_innodb.cc 2010-08-27 15:52:14.318058668 +0900 |
253 | -+++ b/storage/innodb_plugin/handler/ha_innodb.cc 2010-08-27 15:52:29.291123270 +0900 |
254 | +--- a/storage/innodb_plugin/handler/ha_innodb.cc 2011-01-15 00:09:04.000000000 +0300 |
255 | ++++ b/storage/innodb_plugin/handler/ha_innodb.cc 2011-01-15 01:18:32.000000000 +0300 |
256 | @@ -313,6 +313,12 @@ |
257 | "Timeout in seconds an InnoDB transaction may wait for a lock before being rolled back. Values above 100000000 disable the timeout.", |
258 | NULL, NULL, 50, 1, 1024 * 1024 * 1024, 0); |
259 | @@ -235,8 +235,8 @@ |
260 | MYSQL_SYSVAR(change_buffering), |
261 | #if defined UNIV_DEBUG || defined UNIV_IBUF_DEBUG |
262 | diff -ruN a/storage/innodb_plugin/handler/innodb_patch_info.h b/storage/innodb_plugin/handler/innodb_patch_info.h |
263 | ---- a/storage/innodb_plugin/handler/innodb_patch_info.h 2010-08-27 15:52:14.323071350 +0900 |
264 | -+++ b/storage/innodb_plugin/handler/innodb_patch_info.h 2010-08-27 15:52:29.296058625 +0900 |
265 | +--- a/storage/innodb_plugin/handler/innodb_patch_info.h 2011-01-15 00:09:04.000000000 +0300 |
266 | ++++ b/storage/innodb_plugin/handler/innodb_patch_info.h 2011-01-15 01:18:32.000000000 +0300 |
267 | @@ -25,5 +25,6 @@ |
268 | }innodb_enhancements[] = { |
269 | {"xtradb_show_enhancements","I_S.XTRADB_ENHANCEMENTS","","http://www.percona.com/docs/wiki/percona-xtradb"}, |
270 | @@ -245,8 +245,8 @@ |
271 | {NULL, NULL, NULL, NULL} |
272 | }; |
273 | diff -ruN a/storage/innodb_plugin/ibuf/ibuf0ibuf.c b/storage/innodb_plugin/ibuf/ibuf0ibuf.c |
274 | ---- a/storage/innodb_plugin/ibuf/ibuf0ibuf.c 2010-08-04 02:24:19.000000000 +0900 |
275 | -+++ b/storage/innodb_plugin/ibuf/ibuf0ibuf.c 2010-08-27 15:52:29.299059959 +0900 |
276 | +--- a/storage/innodb_plugin/ibuf/ibuf0ibuf.c 2011-01-15 00:07:59.000000000 +0300 |
277 | ++++ b/storage/innodb_plugin/ibuf/ibuf0ibuf.c 2011-01-15 01:18:31.000000000 +0300 |
278 | @@ -464,8 +464,10 @@ |
279 | grow in size, as the references on the upper levels of the tree can |
280 | change */ |
281 | @@ -275,8 +275,8 @@ |
282 | sync = FALSE; |
283 | |
284 | diff -ruN a/storage/innodb_plugin/include/buf0rea.h b/storage/innodb_plugin/include/buf0rea.h |
285 | ---- a/storage/innodb_plugin/include/buf0rea.h 2010-08-04 02:24:19.000000000 +0900 |
286 | -+++ b/storage/innodb_plugin/include/buf0rea.h 2010-08-27 15:52:29.301063286 +0900 |
287 | +--- a/storage/innodb_plugin/include/buf0rea.h 2011-01-15 00:07:59.000000000 +0300 |
288 | ++++ b/storage/innodb_plugin/include/buf0rea.h 2011-01-15 01:18:27.000000000 +0300 |
289 | @@ -124,8 +124,7 @@ |
290 | |
291 | /** The size in pages of the area which the read-ahead algorithms read if |
292 | @@ -288,8 +288,8 @@ |
293 | /** @name Modes used in read-ahead @{ */ |
294 | /** read only pages belonging to the insert buffer tree */ |
295 | diff -ruN a/storage/innodb_plugin/include/ha_prototypes.h b/storage/innodb_plugin/include/ha_prototypes.h |
296 | ---- a/storage/innodb_plugin/include/ha_prototypes.h 2010-08-04 02:24:20.000000000 +0900 |
297 | -+++ b/storage/innodb_plugin/include/ha_prototypes.h 2010-08-27 15:52:29.302093420 +0900 |
298 | +--- a/storage/innodb_plugin/include/ha_prototypes.h 2011-01-15 00:07:59.000000000 +0300 |
299 | ++++ b/storage/innodb_plugin/include/ha_prototypes.h 2011-01-15 00:09:04.000000000 +0300 |
300 | @@ -268,4 +268,12 @@ |
301 | void* thd); /*!< in: thread handle (THD*), or NULL to query |
302 | the global innodb_lock_wait_timeout */ |
303 | @@ -304,8 +304,8 @@ |
304 | + |
305 | #endif |
306 | diff -ruN a/storage/innodb_plugin/include/srv0srv.h b/storage/innodb_plugin/include/srv0srv.h |
307 | ---- a/storage/innodb_plugin/include/srv0srv.h 2010-08-27 15:52:14.326071475 +0900 |
308 | -+++ b/storage/innodb_plugin/include/srv0srv.h 2010-08-27 15:52:29.304059342 +0900 |
309 | +--- a/storage/innodb_plugin/include/srv0srv.h 2011-01-15 00:09:04.000000000 +0300 |
310 | ++++ b/storage/innodb_plugin/include/srv0srv.h 2011-01-15 01:18:32.000000000 +0300 |
311 | @@ -199,6 +199,16 @@ |
312 | extern ulong srv_max_purge_lag; |
313 | |
314 | @@ -335,8 +335,8 @@ |
315 | |
316 | /** Alternatives for file i/o in Windows */ |
317 | diff -ruN a/storage/innodb_plugin/include/trx0trx.h b/storage/innodb_plugin/include/trx0trx.h |
318 | ---- a/storage/innodb_plugin/include/trx0trx.h 2010-08-04 02:24:19.000000000 +0900 |
319 | -+++ b/storage/innodb_plugin/include/trx0trx.h 2010-08-27 15:52:29.305070921 +0900 |
320 | +--- a/storage/innodb_plugin/include/trx0trx.h 2011-01-15 00:07:59.000000000 +0300 |
321 | ++++ b/storage/innodb_plugin/include/trx0trx.h 2011-01-15 01:18:31.000000000 +0300 |
322 | @@ -497,6 +497,7 @@ |
323 | FALSE, one can save CPU time and about |
324 | 150 bytes in the undo log size as then |
325 | @@ -346,8 +346,8 @@ |
326 | prepare_commit mutex across |
327 | both phases. In that case, we |
328 | diff -ruN a/storage/innodb_plugin/log/log0log.c b/storage/innodb_plugin/log/log0log.c |
329 | ---- a/storage/innodb_plugin/log/log0log.c 2010-08-04 02:24:20.000000000 +0900 |
330 | -+++ b/storage/innodb_plugin/log/log0log.c 2010-08-27 15:52:29.309058924 +0900 |
331 | +--- a/storage/innodb_plugin/log/log0log.c 2011-01-15 00:07:59.000000000 +0300 |
332 | ++++ b/storage/innodb_plugin/log/log0log.c 2011-01-15 01:18:28.000000000 +0300 |
333 | @@ -347,6 +347,33 @@ |
334 | } |
335 | |
336 | @@ -469,8 +469,8 @@ |
337 | |
338 | time_elapsed = 0.001 + difftime(current_time, |
339 | diff -ruN a/storage/innodb_plugin/log/log0recv.c b/storage/innodb_plugin/log/log0recv.c |
340 | ---- a/storage/innodb_plugin/log/log0recv.c 2010-08-04 02:24:20.000000000 +0900 |
341 | -+++ b/storage/innodb_plugin/log/log0recv.c 2010-08-27 15:52:29.313058539 +0900 |
342 | +--- a/storage/innodb_plugin/log/log0recv.c 2011-01-15 00:07:59.000000000 +0300 |
343 | ++++ b/storage/innodb_plugin/log/log0recv.c 2011-01-15 01:18:29.000000000 +0300 |
344 | @@ -2893,9 +2893,12 @@ |
345 | ib_uint64_t archived_lsn; |
346 | #endif /* UNIV_LOG_ARCHIVE */ |
347 | @@ -486,8 +486,8 @@ |
348 | ut_ad(type != LOG_CHECKPOINT || limit_lsn == IB_ULONGLONG_MAX); |
349 | /** TRUE when recovering from a checkpoint */ |
350 | diff -ruN a/storage/innodb_plugin/os/os0file.c b/storage/innodb_plugin/os/os0file.c |
351 | ---- a/storage/innodb_plugin/os/os0file.c 2010-08-04 02:24:19.000000000 +0900 |
352 | -+++ b/storage/innodb_plugin/os/os0file.c 2010-08-27 15:52:29.318058185 +0900 |
353 | +--- a/storage/innodb_plugin/os/os0file.c 2011-01-15 00:07:59.000000000 +0300 |
354 | ++++ b/storage/innodb_plugin/os/os0file.c 2011-01-15 01:18:29.000000000 +0300 |
355 | @@ -91,6 +91,28 @@ |
356 | /** Flag: enable debug printout for asynchronous i/o */ |
357 | UNIV_INTERN ibool os_aio_print_debug = FALSE; |
358 | @@ -943,8 +943,8 @@ |
359 | *message1 = slot->message1; |
360 | *message2 = slot->message2; |
361 | diff -ruN a/storage/innodb_plugin/srv/srv0srv.c b/storage/innodb_plugin/srv/srv0srv.c |
362 | ---- a/storage/innodb_plugin/srv/srv0srv.c 2010-08-27 15:52:14.337059014 +0900 |
363 | -+++ b/storage/innodb_plugin/srv/srv0srv.c 2010-08-27 15:52:29.323059046 +0900 |
364 | +--- a/storage/innodb_plugin/srv/srv0srv.c 2011-01-15 00:09:04.000000000 +0300 |
365 | ++++ b/storage/innodb_plugin/srv/srv0srv.c 2011-01-15 01:18:32.000000000 +0300 |
366 | @@ -370,6 +370,17 @@ |
367 | |
368 | UNIV_INTERN ulong srv_replication_delay = 0; |
369 | @@ -1065,7 +1065,7 @@ |
370 | } else if (srv_adaptive_flushing) { |
371 | |
372 | /* Try to keep the rate of flushing of dirty |
373 | -@@ -2619,6 +2675,255 @@ |
374 | +@@ -2619,6 +2675,257 @@ |
375 | skip_sleep = TRUE; |
376 | } |
377 | } |
378 | @@ -1221,7 +1221,9 @@ |
379 | + |
380 | + if (prev_adaptive_checkpoint == 3) { |
381 | + lint n_flush; |
382 | -+ lint blocks_sum, new_blocks_sum, flushed_blocks_sum; |
383 | ++ ulint blocks_sum; |
384 | ++ ulint new_blocks_sum; |
385 | ++ ulint flushed_blocks_sum; |
386 | + |
387 | + blocks_sum = new_blocks_sum = flushed_blocks_sum = 0; |
388 | + |
389 | @@ -1321,7 +1323,7 @@ |
390 | } |
391 | |
392 | if (srv_activity_count == old_activity_count) { |
393 | -@@ -2667,7 +2972,7 @@ |
394 | +@@ -2667,7 +2974,7 @@ |
395 | even if the server were active */ |
396 | |
397 | srv_main_thread_op_info = "doing insert buffer merge"; |
398 | @@ -1330,7 +1332,7 @@ |
399 | |
400 | /* Flush logs if needed */ |
401 | srv_sync_log_buffer_in_background(); |
402 | -@@ -2792,7 +3097,7 @@ |
403 | +@@ -2792,7 +3099,7 @@ |
404 | buf_flush_batch below. Otherwise, the system favors |
405 | clean pages over cleanup throughput. */ |
406 | n_bytes_merged = ibuf_contract_for_n_pages(FALSE, |
407 | @@ -1340,8 +1342,8 @@ |
408 | |
409 | srv_main_thread_op_info = "reserving kernel mutex"; |
410 | diff -ruN a/storage/innodb_plugin/srv/srv0start.c b/storage/innodb_plugin/srv/srv0start.c |
411 | ---- a/storage/innodb_plugin/srv/srv0start.c 2010-08-04 02:24:20.000000000 +0900 |
412 | -+++ b/storage/innodb_plugin/srv/srv0start.c 2010-08-27 15:52:29.326058817 +0900 |
413 | +--- a/storage/innodb_plugin/srv/srv0start.c 2011-01-15 00:07:59.000000000 +0300 |
414 | ++++ b/storage/innodb_plugin/srv/srv0start.c 2011-01-15 01:18:32.000000000 +0300 |
415 | @@ -1135,7 +1135,12 @@ |
416 | break; |
417 | default: |
418 | @@ -1380,8 +1382,8 @@ |
419 | } else { |
420 | fprintf(stderr, |
421 | diff -ruN a/storage/innodb_plugin/trx/trx0trx.c b/storage/innodb_plugin/trx/trx0trx.c |
422 | ---- a/storage/innodb_plugin/trx/trx0trx.c 2010-08-04 02:24:20.000000000 +0900 |
423 | -+++ b/storage/innodb_plugin/trx/trx0trx.c 2010-08-27 15:52:29.329058408 +0900 |
424 | +--- a/storage/innodb_plugin/trx/trx0trx.c 2011-01-15 00:07:59.000000000 +0300 |
425 | ++++ b/storage/innodb_plugin/trx/trx0trx.c 2011-01-15 01:18:31.000000000 +0300 |
426 | @@ -109,6 +109,8 @@ |
427 | |
428 | trx->support_xa = TRUE; |
429 | |
430 | === modified file 'innodb_lru_dump_restore.patch' |
431 | --- innodb_lru_dump_restore.patch 2010-12-22 18:24:52 +0000 |
432 | +++ innodb_lru_dump_restore.patch 2011-01-17 07:35:09 +0000 |
433 | @@ -42,7 +42,7 @@ |
434 | diff -ruN a/storage/innodb_plugin/buf/buf0lru.c b/storage/innodb_plugin/buf/buf0lru.c |
435 | --- a/storage/innodb_plugin/buf/buf0lru.c 2010-08-27 16:13:11.070058073 +0900 |
436 | +++ b/storage/innodb_plugin/buf/buf0lru.c 2010-08-27 16:34:33.860400549 +0900 |
437 | -@@ -2122,6 +2122,278 @@ |
438 | +@@ -2122,6 +2122,277 @@ |
439 | memset(&buf_LRU_stat_cur, 0, sizeof buf_LRU_stat_cur); |
440 | } |
441 | |
442 | @@ -285,8 +285,7 @@ |
443 | + continue; |
444 | + } |
445 | + |
446 | -+ if (fil_area_is_exist(space_id, zip_size, page_no, 0, |
447 | -+ zip_size ? zip_size : UNIV_PAGE_SIZE)) { |
448 | ++ if (fil_area_is_exist(space_id, page_no)) { |
449 | + |
450 | + tablespace_version = fil_space_get_version(space_id); |
451 | + |
452 | @@ -336,7 +335,7 @@ |
453 | diff -ruN a/storage/innodb_plugin/fil/fil0fil.c b/storage/innodb_plugin/fil/fil0fil.c |
454 | --- a/storage/innodb_plugin/fil/fil0fil.c 2010-08-27 16:32:40.298411400 +0900 |
455 | +++ b/storage/innodb_plugin/fil/fil0fil.c 2010-08-27 16:34:33.868058362 +0900 |
456 | -@@ -4915,6 +4915,78 @@ |
457 | +@@ -4915,6 +4915,70 @@ |
458 | return(DB_SUCCESS); |
459 | } |
460 | |
461 | @@ -347,15 +346,7 @@ |
462 | +fil_area_is_exist( |
463 | +/*==============*/ |
464 | + ulint space_id, /*!< in: space id */ |
465 | -+ ulint zip_size, /*!< in: compressed page size in bytes; |
466 | -+ 0 for uncompressed pages */ |
467 | -+ ulint block_offset, /*!< in: offset in number of blocks */ |
468 | -+ ulint byte_offset, /*!< in: remainder of offset in bytes; in |
469 | -+ aio this must be divisible by the OS block |
470 | -+ size */ |
471 | -+ ulint len) /*!< in: how many bytes to read or write; this |
472 | -+ must not cross a file boundary; in aio this |
473 | -+ must be a block size multiple */ |
474 | ++ ulint block_offset) /*!< in: offset in number of blocks */ |
475 | +{ |
476 | + fil_space_t* space; |
477 | + fil_node_t* node; |
478 | @@ -563,7 +554,7 @@ |
479 | diff -ruN a/storage/innodb_plugin/include/fil0fil.h b/storage/innodb_plugin/include/fil0fil.h |
480 | --- a/storage/innodb_plugin/include/fil0fil.h 2010-08-27 16:32:40.315012507 +0900 |
481 | +++ b/storage/innodb_plugin/include/fil0fil.h 2010-08-27 16:34:33.878063455 +0900 |
482 | -@@ -643,6 +643,22 @@ |
483 | +@@ -643,6 +643,14 @@ |
484 | void* message, /*!< in: message for aio handler if non-sync |
485 | aio used, else ignored */ |
486 | trx_t* trx); |
487 | @@ -574,15 +565,7 @@ |
488 | +fil_area_is_exist( |
489 | +/*==============*/ |
490 | + ulint space_id, /*!< in: space id */ |
491 | -+ ulint zip_size, /*!< in: compressed page size in bytes; |
492 | -+ 0 for uncompressed pages */ |
493 | -+ ulint block_offset, /*!< in: offset in number of blocks */ |
494 | -+ ulint byte_offset, /*!< in: remainder of offset in bytes; in |
495 | -+ aio this must be divisible by the OS block |
496 | -+ size */ |
497 | -+ ulint len); /*!< in: how many bytes to read or write; this |
498 | -+ must not cross a file boundary; in aio this |
499 | -+ must be a block size multiple */ |
500 | ++ ulint block_offset); /*!< in: offset in number of blocks */ |
501 | /**********************************************************************//** |
502 | Waits for an aio operation to complete. This function is used to write the |
503 | handler for completed requests. The aio array of pending requests is divided |
504 | |
505 | === modified file 'innodb_pass_corrupt_table.patch' |
506 | --- innodb_pass_corrupt_table.patch 2010-12-16 11:35:26 +0000 |
507 | +++ innodb_pass_corrupt_table.patch 2011-01-17 07:35:09 +0000 |
508 | @@ -608,7 +608,7 @@ |
509 | ut_a(ret); |
510 | |
511 | if (mode == OS_AIO_SYNC) { |
512 | -@@ -5053,7 +5074,7 @@ |
513 | +@@ -5045,7 +5066,7 @@ |
514 | |
515 | if (fil_node->space->purpose == FIL_TABLESPACE) { |
516 | srv_set_io_thread_op_info(segment, "complete io for buf page"); |
517 | @@ -617,7 +617,7 @@ |
518 | } else { |
519 | srv_set_io_thread_op_info(segment, "complete io for log"); |
520 | log_io_complete(message); |
521 | -@@ -5407,3 +5428,46 @@ |
522 | +@@ -5399,3 +5420,46 @@ |
523 | return 0; |
524 | } |
525 | } |
526 | @@ -1184,7 +1184,7 @@ |
527 | diff -ruN a/storage/innodb_plugin/include/fil0fil.h b/storage/innodb_plugin/include/fil0fil.h |
528 | --- a/storage/innodb_plugin/include/fil0fil.h 2010-08-27 16:36:03.499987483 +0900 |
529 | +++ b/storage/innodb_plugin/include/fil0fil.h 2010-08-27 16:39:03.015021314 +0900 |
530 | -@@ -756,6 +756,19 @@ |
531 | +@@ -748,6 +748,19 @@ |
532 | fil_system_hash_nodes(void); |
533 | /*========================*/ |
534 | |
535 | |
536 | === modified file 'innodb_purge_thread.patch' |
537 | --- innodb_purge_thread.patch 2010-12-16 11:35:26 +0000 |
538 | +++ innodb_purge_thread.patch 2011-01-17 07:35:09 +0000 |
539 | @@ -166,7 +166,7 @@ |
540 | srv_n_threads_active[SRV_MASTER]++; |
541 | |
542 | mutex_exit(&kernel_mutex); |
543 | -@@ -3083,6 +3085,7 @@ |
544 | +@@ -3085,6 +3087,7 @@ |
545 | /* Flush logs if needed */ |
546 | srv_sync_log_buffer_in_background(); |
547 | |
548 | @@ -174,7 +174,7 @@ |
549 | /* We run a full purge every 10 seconds, even if the server |
550 | were active */ |
551 | do { |
552 | -@@ -3099,6 +3102,7 @@ |
553 | +@@ -3101,6 +3104,7 @@ |
554 | srv_sync_log_buffer_in_background(); |
555 | |
556 | } while (n_pages_purged); |
557 | @@ -182,7 +182,7 @@ |
558 | |
559 | srv_main_thread_op_info = "flushing buffer pool pages"; |
560 | |
561 | -@@ -3167,6 +3171,7 @@ |
562 | +@@ -3169,6 +3173,7 @@ |
563 | os_thread_sleep(100000); |
564 | } |
565 | |
566 | @@ -190,7 +190,7 @@ |
567 | srv_main_thread_op_info = "purging"; |
568 | |
569 | /* Run a full purge */ |
570 | -@@ -3183,6 +3188,7 @@ |
571 | +@@ -3185,6 +3190,7 @@ |
572 | srv_sync_log_buffer_in_background(); |
573 | |
574 | } while (n_pages_purged); |
575 | @@ -198,7 +198,7 @@ |
576 | |
577 | srv_main_thread_op_info = "reserving kernel mutex"; |
578 | |
579 | -@@ -3335,3 +3341,143 @@ |
580 | +@@ -3337,3 +3343,143 @@ |
581 | |
582 | OS_THREAD_DUMMY_RETURN; /* Not reached, avoid compiler warning */ |
583 | } |
584 | |
585 | === modified file 'innodb_separate_doublewrite.patch' |
586 | --- innodb_separate_doublewrite.patch 2010-12-16 11:35:26 +0000 |
587 | +++ innodb_separate_doublewrite.patch 2011-01-17 07:35:09 +0000 |
588 | @@ -67,7 +67,15 @@ |
589 | diff -ruN a/storage/innodb_plugin/dict/dict0load.c b/storage/innodb_plugin/dict/dict0load.c |
590 | --- a/storage/innodb_plugin/dict/dict0load.c 2010-08-27 16:22:04.223059346 +0900 |
591 | +++ b/storage/innodb_plugin/dict/dict0load.c 2010-08-27 16:37:55.363104692 +0900 |
592 | -@@ -396,7 +396,7 @@ |
593 | +@@ -40,6 +40,7 @@ |
594 | + #include "rem0cmp.h" |
595 | + #include "srv0start.h" |
596 | + #include "srv0srv.h" |
597 | ++#include "trx0sys.h" |
598 | + |
599 | + /****************************************************************//** |
600 | + Compare the name of an index column. |
601 | +@@ -396,7 +397,7 @@ |
602 | |
603 | mtr_commit(&mtr); |
604 | |
605 | @@ -76,7 +84,7 @@ |
606 | /* The system tablespace always exists. */ |
607 | } else if (in_crash_recovery) { |
608 | /* Check that the tablespace (the .ibd file) really |
609 | -@@ -904,7 +904,7 @@ |
610 | +@@ -904,7 +905,7 @@ |
611 | space = mach_read_from_4(field); |
612 | |
613 | /* Check if the tablespace exists and has the right name */ |
614 | @@ -85,7 +93,7 @@ |
615 | flags = dict_sys_tables_get_flags(rec); |
616 | |
617 | if (UNIV_UNLIKELY(flags == ULINT_UNDEFINED)) { |
618 | -@@ -957,7 +957,7 @@ |
619 | +@@ -957,7 +958,7 @@ |
620 | } |
621 | |
622 | /* See if the tablespace is available. */ |
623 | @@ -295,7 +303,7 @@ |
624 | /* The node must be put back to the LRU list */ |
625 | UT_LIST_ADD_FIRST(LRU, system->LRU, node); |
626 | } |
627 | -@@ -5271,7 +5281,7 @@ |
628 | +@@ -5263,7 +5273,7 @@ |
629 | ut_a(fil_node->n_pending == 0); |
630 | ut_a(fil_node->open); |
631 | ut_a(fil_node->space->purpose == FIL_TABLESPACE); |
632 | |
633 | === modified file 'innodb_show_lock_name.patch' |
634 | --- innodb_show_lock_name.patch 2010-12-16 11:35:26 +0000 |
635 | +++ innodb_show_lock_name.patch 2011-01-17 07:35:09 +0000 |
636 | @@ -192,26 +192,32 @@ |
637 | const char* cfile_name, /*!< in: file name where created */ |
638 | ulint cline) /*!< in: file line where created */ |
639 | { |
640 | -@@ -242,14 +242,15 @@ |
641 | +@@ -242,15 +242,18 @@ |
642 | #ifndef INNODB_RW_LOCKS_USE_ATOMICS |
643 | mutex_create(rw_lock_get_mutex(lock), SYNC_NO_ORDER_CHECK); |
644 | |
645 | - lock->mutex.cfile_name = cfile_name; |
646 | - lock->mutex.cline = cline; |
647 | +- |
648 | +- ut_d(lock->mutex.cmutex_name = cmutex_name); |
649 | ++#ifdef UNIV_DEBUG |
650 | + ut_d(lock->mutex.cfile_name = cfile_name); |
651 | + ut_d(lock->mutex.cline = cline); |
652 | - |
653 | -- ut_d(lock->mutex.cmutex_name = cmutex_name); |
654 | ++#else |
655 | ++ UT_NOT_USED(cfile_name); |
656 | ++ UT_NOT_USED(cline); |
657 | ++#endif |
658 | + lock->mutex.cmutex_name = cmutex_name; |
659 | ut_d(lock->mutex.mutex_type = 1); |
660 | #else /* INNODB_RW_LOCKS_USE_ATOMICS */ |
661 | - # ifdef UNIV_DEBUG |
662 | +-# ifdef UNIV_DEBUG |
663 | - UT_NOT_USED(cmutex_name); |
664 | +-# endif |
665 | + UT_NOT_USED(cfile_name); |
666 | + UT_NOT_USED(cline); |
667 | - # endif |
668 | #endif /* INNODB_RW_LOCKS_USE_ATOMICS */ |
669 | |
670 | + lock->lock_word = X_LOCK_DECR; |
671 | @@ -269,8 +270,7 @@ |
672 | |
673 | ut_d(lock->magic_n = RW_LOCK_MAGIC_N); |
674 | @@ -285,13 +291,16 @@ |
675 | # ifdef UNIV_SYNC_DEBUG |
676 | ulint level, /*!< in: level */ |
677 | # endif /* UNIV_SYNC_DEBUG */ |
678 | -@@ -263,11 +263,13 @@ |
679 | +@@ -263,11 +263,16 @@ |
680 | mutex->file_name = "not yet reserved"; |
681 | mutex->level = level; |
682 | #endif /* UNIV_SYNC_DEBUG */ |
683 | +#ifdef UNIV_DEBUG |
684 | mutex->cfile_name = cfile_name; |
685 | mutex->cline = cline; |
686 | ++#else |
687 | ++ UT_NOT_USED(cfile_name); |
688 | ++ UT_NOT_USED(cline); |
689 | +#endif /* UNIV_DEBUG */ |
690 | mutex->count_os_wait = 0; |
691 | -#ifdef UNIV_DEBUG |
692 | |
693 | === modified file 'innodb_split_buf_pool_mutex.patch' |
694 | --- innodb_split_buf_pool_mutex.patch 2010-12-16 11:35:26 +0000 |
695 | +++ innodb_split_buf_pool_mutex.patch 2011-01-17 07:35:09 +0000 |
696 | @@ -388,19 +388,33 @@ |
697 | ut_ad(!mutex_own(&buf_pool_zip_mutex)); |
698 | ut_ad(!ut_align_offset(src, size)); |
699 | ut_ad(!ut_align_offset(dst, size)); |
700 | -@@ -434,6 +476,12 @@ |
701 | +@@ -433,6 +475,14 @@ |
702 | + if (size >= PAGE_ZIP_MIN_SIZE) { |
703 | /* This is a compressed page. */ |
704 | mutex_t* mutex; |
705 | - |
706 | ++ ulint space; |
707 | ++ ulint page_no; |
708 | ++ |
709 | + if (!have_page_hash_mutex) { |
710 | + mutex_exit(&zip_free_mutex); |
711 | + mutex_enter(&LRU_list_mutex); |
712 | + rw_lock_x_lock(&page_hash_latch); |
713 | + } |
714 | -+ |
715 | + |
716 | /* The src block may be split into smaller blocks, |
717 | some of which may be free. Thus, the |
718 | - mach_read_from_4() calls below may attempt to read |
719 | +@@ -442,9 +492,9 @@ |
720 | + pool), so there is nothing wrong about this. The |
721 | + mach_read_from_4() calls here will only trigger bogus |
722 | + Valgrind memcheck warnings in UNIV_DEBUG_VALGRIND builds. */ |
723 | +- ulint space = mach_read_from_4( |
724 | ++ space = mach_read_from_4( |
725 | + (const byte*) src + FIL_PAGE_ARCH_LOG_NO_OR_SPACE_ID); |
726 | +- ulint page_no = mach_read_from_4( |
727 | ++ page_no = mach_read_from_4( |
728 | + (const byte*) src + FIL_PAGE_OFFSET); |
729 | + /* Suppress Valgrind warnings about conditional jump |
730 | + on uninitialized value. */ |
731 | @@ -458,6 +506,11 @@ |
732 | added to buf_pool->page_hash yet. Obviously, |
733 | it cannot be relocated. */ |
734 | @@ -3803,7 +3817,15 @@ |
735 | |
736 | return(bpage != NULL); |
737 | } |
738 | -@@ -1038,11 +1076,14 @@ |
739 | +@@ -1031,18 +1069,21 @@ |
740 | + buf_block_t* block, /*!< in: buffer block */ |
741 | + ulint rw_latch, /*!< in: RW_S_LATCH, RW_X_LATCH, |
742 | + RW_NO_LATCH */ |
743 | +- mtr_t* mtr) /*!< in: mtr */ |
744 | ++ mtr_t* mtr __attribute__((unused))) /*!< in: mtr */ |
745 | + { |
746 | + ut_ad(block); |
747 | + |
748 | ut_a(buf_block_get_state(block) == BUF_BLOCK_FILE_PAGE); |
749 | ut_a(block->page.buf_fix_count > 0); |
750 | |
751 | @@ -3975,6 +3997,14 @@ |
752 | diff -ruN a/storage/innodb_plugin/mtr/mtr0mtr.c b/storage/innodb_plugin/mtr/mtr0mtr.c |
753 | --- a/storage/innodb_plugin/mtr/mtr0mtr.c 2010-08-04 02:24:20.000000000 +0900 |
754 | +++ b/storage/innodb_plugin/mtr/mtr0mtr.c 2010-08-27 16:11:40.631020912 +0900 |
755 | +@@ -33,6 +33,7 @@ |
756 | + #include "page0types.h" |
757 | + #include "mtr0log.h" |
758 | + #include "log0log.h" |
759 | ++#include "buf0flu.h" |
760 | + |
761 | + #ifndef UNIV_HOTBACKUP |
762 | + # include "log0recv.h" |
763 | @@ -105,6 +105,38 @@ |
764 | } |
765 | } |
766 | |
767 | === modified file 'innodb_stats.patch' |
768 | --- innodb_stats.patch 2010-12-16 11:35:26 +0000 |
769 | +++ innodb_stats.patch 2011-01-17 07:35:09 +0000 |
770 | @@ -1134,7 +1134,7 @@ |
771 | table->status = 0; |
772 | +#ifdef EXTENDED_FOR_USERSTAT |
773 | + rows_read++; |
774 | -+ if (active_index >= 0 && active_index < MAX_KEY) |
775 | ++ if (active_index < MAX_KEY) |
776 | + index_rows_read[active_index]++; |
777 | +#endif |
778 | break; |
779 | |
780 | === modified file 'response-time-distribution.patch' |
781 | --- response-time-distribution.patch 2011-01-10 13:38:39 +0000 |
782 | +++ response-time-distribution.patch 2011-01-17 07:35:09 +0000 |
783 | @@ -369,7 +369,7 @@ |
784 | + buffer[string_positive_power_length]= '.'; |
785 | + ulonglong second= (value / MILLION); |
786 | + ulonglong microsecond= (value % MILLION); |
787 | -+ std::size_t result_length= snprintf(buffer,buffer_size,format,second,microsecond); |
788 | ++ int result_length= snprintf(buffer, buffer_size, format, second, microsecond); |
789 | + if(result_length < 0) |
790 | + { |
791 | + assert(sizeof(STRING_OVERFLOW) <= buffer_size); |
792 | @@ -514,7 +514,7 @@ |
793 | + DBUG_ENTER("fill_schema_query_response_time"); |
794 | + TABLE *table= static_cast<TABLE*>(tables->table); |
795 | + Field **fields= table->field; |
796 | -+ for(int i= 0, count= bound_count() + 1 /* with overflow */; count > i; ++i) |
797 | ++ for(uint i= 0, count= bound_count() + 1 /* with overflow */; count > i; ++i) |
798 | + { |
799 | + char time[TIME_STRING_BUFFER_LENGTH]; |
800 | + char total[TOTAL_STRING_BUFFER_LENGTH]; |
801 | |
802 | === modified file 'series' |
803 | --- series 2011-01-06 14:04:28 +0000 |
804 | +++ series 2011-01-17 07:35:09 +0000 |
805 | @@ -1,3 +1,4 @@ |
806 | +bug59486.patch |
807 | innodb_swap_builtin_plugin.patch |
808 | show_patches.patch |
809 | slow_extended.patch |
810 | |
811 | === modified file 'show_patches.patch' |
812 | --- show_patches.patch 2010-12-16 11:35:26 +0000 |
813 | +++ show_patches.patch 2011-01-17 07:35:09 +0000 |
814 | @@ -160,7 +160,7 @@ |
815 | + const char *comment; |
816 | +}patches[] = { |
817 | +$output |
818 | -+{NULL, NULL, NULL, NULL} |
819 | ++{NULL, NULL, NULL, NULL, NULL, NULL} |
820 | +}; |
821 | + |
822 | +HEADER |
823 | |
824 | === modified file 'sql_no_fcache.patch' |
825 | --- sql_no_fcache.patch 2010-12-17 19:06:49 +0000 |
826 | +++ sql_no_fcache.patch 2011-01-17 07:35:09 +0000 |
827 | @@ -358,11 +358,13 @@ |
828 | const char *join_type_str[]={ "UNKNOWN","system","const","eq_ref","ref", |
829 | "MAYBE_REF","ALL","range","index","fulltext", |
830 | "ref_or_null","unique_subquery","index_subquery", |
831 | -@@ -239,9 +245,18 @@ |
832 | +@@ -239,9 +245,20 @@ |
833 | ulong setup_tables_done_option) |
834 | { |
835 | bool res; |
836 | ++#if defined(__linux__) |
837 | + pid_t pid; |
838 | ++#endif |
839 | register SELECT_LEX *select_lex = &lex->select_lex; |
840 | DBUG_ENTER("handle_select"); |
841 | |
842 | |
843 | === modified file 'userstat.patch' |
844 | --- userstat.patch 2011-01-10 13:38:39 +0000 |
845 | +++ userstat.patch 2011-01-17 07:35:09 +0000 |
846 | @@ -1934,7 +1934,6 @@ |
847 | + double end_usecs = 0; |
848 | + /* cpu time */ |
849 | + int cputime_error = 0; |
850 | -+ struct timespec tp; |
851 | + double start_cpu_nsecs = 0; |
852 | + double end_cpu_nsecs = 0; |
853 | + |
854 | @@ -2066,7 +2065,7 @@ |
855 | /** |
856 | A result class used to send cursor rows using the binary protocol. |
857 | */ |
858 | -@@ -2103,8 +2106,32 @@ |
859 | +@@ -2103,8 +2106,31 @@ |
860 | /* First of all clear possible warnings from the previous command */ |
861 | mysql_reset_thd_for_next_command(thd); |
862 | |
863 | @@ -2077,7 +2076,6 @@ |
864 | + double end_usecs = 0; |
865 | + /* cpu time */ |
866 | + int cputime_error = 0; |
867 | -+ struct timespec tp; |
868 | + double start_cpu_nsecs = 0; |
869 | + double end_cpu_nsecs = 0; |
870 | + |
871 | @@ -2100,7 +2098,7 @@ |
872 | |
873 | if (thd->stmt_map.insert(thd, stmt)) |
874 | { |
875 | -@@ -2112,7 +2139,7 @@ |
876 | +@@ -2112,7 +2138,7 @@ |
877 | The error is set in the insert. The statement itself |
878 | will be also deleted there (this is how the hash works). |
879 | */ |
880 | @@ -2109,7 +2107,7 @@ |
881 | } |
882 | |
883 | /* Reset warnings from previous command */ |
884 | -@@ -2139,6 +2166,44 @@ |
885 | +@@ -2139,6 +2165,44 @@ |
886 | thd->protocol= save_protocol; |
887 | |
888 | /* check_prepared_statemnt sends the metadata packet in case of success */ |
889 | @@ -2154,7 +2152,7 @@ |
890 | DBUG_VOID_RETURN; |
891 | } |
892 | |
893 | -@@ -2489,12 +2554,36 @@ |
894 | +@@ -2489,12 +2553,35 @@ |
895 | /* First of all clear possible warnings from the previous command */ |
896 | mysql_reset_thd_for_next_command(thd); |
897 | |
898 | @@ -2165,7 +2163,6 @@ |
899 | + double end_usecs = 0; |
900 | + /* cpu time */ |
901 | + int cputime_error = 0; |
902 | -+ struct timespec tp; |
903 | + double start_cpu_nsecs = 0; |
904 | + double end_cpu_nsecs = 0; |
905 | + |
906 | @@ -2192,7 +2189,7 @@ |
907 | } |
908 | |
909 | #if defined(ENABLED_PROFILING) && defined(COMMUNITY_SERVER) |
910 | -@@ -2515,6 +2604,44 @@ |
911 | +@@ -2515,6 +2602,44 @@ |
912 | /* Close connection socket; for use with client testing (Bug#43560). */ |
913 | DBUG_EXECUTE_IF("close_conn_after_stmt_execute", vio_close(thd->net.vio);); |
914 | |
915 | @@ -2237,7 +2234,7 @@ |
916 | DBUG_VOID_RETURN; |
917 | |
918 | } |
919 | -@@ -2588,20 +2715,45 @@ |
920 | +@@ -2588,20 +2713,44 @@ |
921 | |
922 | /* First of all clear possible warnings from the previous command */ |
923 | mysql_reset_thd_for_next_command(thd); |
924 | @@ -2249,7 +2246,6 @@ |
925 | + double end_usecs = 0; |
926 | + /* cpu time */ |
927 | + int cputime_error = 0; |
928 | -+ struct timespec tp; |
929 | + double start_cpu_nsecs = 0; |
930 | + double end_cpu_nsecs = 0; |
931 | + |
932 | @@ -2285,7 +2281,7 @@ |
933 | } |
934 | |
935 | thd->stmt_arena= stmt; |
936 | -@@ -2625,6 +2777,44 @@ |
937 | +@@ -2625,6 +2774,44 @@ |
938 | thd->restore_backup_statement(stmt, &stmt_backup); |
939 | thd->stmt_arena= thd; |
940 | |
941 | @@ -2330,7 +2326,7 @@ |
942 | DBUG_VOID_RETURN; |
943 | } |
944 | |
945 | -@@ -2655,13 +2845,37 @@ |
946 | +@@ -2655,13 +2842,36 @@ |
947 | /* First of all clear possible warnings from the previous command */ |
948 | mysql_reset_thd_for_next_command(thd); |
949 | |
950 | @@ -2341,7 +2337,6 @@ |
951 | + double end_usecs = 0; |
952 | + /* cpu time */ |
953 | + int cputime_error = 0; |
954 | -+ struct timespec tp; |
955 | + double start_cpu_nsecs = 0; |
956 | + double end_cpu_nsecs = 0; |
957 | + |
958 | @@ -2369,7 +2364,7 @@ |
959 | } |
960 | |
961 | stmt->close_cursor(); |
962 | -@@ -2678,6 +2892,44 @@ |
963 | +@@ -2678,6 +2888,44 @@ |
964 | |
965 | my_ok(thd); |
966 |
Hmm?
382 -+ lint n_flush;
383 -+ lint blocks_sum, new_blocks_sum, flushed_blocks_sum;
384 ++ ulint n_flush;
385 ++ ulint blocks_sum;
386 ++ ulint new_blocks_sum;
387 ++ ulint flushed_blocks_sum;
after the change,
n_flush = blocks_sum * (lsn - lsn_old) / log_sys- >max_modified_ age_async; flushed_ prev) { flushed_ prev);
if (flushed_blocks_sum > n_pages_
n_flush -= (flushed_blocks_sum - n_pages_
}
is changed?
n_flush can be minus logically.