]> git.pld-linux.org Git - packages/mysql.git/blob - innodb_show_lock_name.patch
- disable response-time-distribution patch on arch which has no atomic builtins even...
[packages/mysql.git] / innodb_show_lock_name.patch
1 # name       : innodb_show_lock_name.patch
2 # introduced : 11 or before
3 # maintainer : Yasufumi
4 #
5 #!!! notice !!!
6 # Any small change to this file in the main branch
7 # should be done or reviewed by the maintainer!
8 diff -ruN a/storage/innobase/handler/ha_innodb.cc b/storage/innobase/handler/ha_innodb.cc
9 --- a/storage/innobase/handler/ha_innodb.cc     2010-12-03 17:34:35.285040381 +0900
10 +++ b/storage/innobase/handler/ha_innodb.cc     2010-12-03 17:35:12.974975252 +0900
11 @@ -9575,8 +9575,8 @@
12                         rw_lock_wait_time += mutex->lspent_time;
13                 }
14  #else /* UNIV_DEBUG */
15 -               buf1len= (uint) my_snprintf(buf1, sizeof(buf1), "%s:%lu",
16 -                                    mutex->cfile_name, (ulong) mutex->cline);
17 +               buf1len= (uint) my_snprintf(buf1, sizeof(buf1), "%s",
18 +                                    mutex->cmutex_name);
19                 buf2len= (uint) my_snprintf(buf2, sizeof(buf2), "os_waits=%lu",
20                                      (ulong) mutex->count_os_wait);
21  
22 @@ -9591,9 +9591,8 @@
23  
24         if (block_mutex) {
25                 buf1len = (uint) my_snprintf(buf1, sizeof buf1,
26 -                                            "combined %s:%lu",
27 -                                            block_mutex->cfile_name,
28 -                                            (ulong) block_mutex->cline);
29 +                                            "combined %s",
30 +                                            block_mutex->cmutex_name);
31                 buf2len = (uint) my_snprintf(buf2, sizeof buf2,
32                                              "os_waits=%lu",
33                                              (ulong) block_mutex_oswait_count);
34 @@ -9622,8 +9621,8 @@
35                         continue;
36                 }
37  
38 -               buf1len = my_snprintf(buf1, sizeof buf1, "%s:%lu",
39 -                                    lock->cfile_name, (ulong) lock->cline);
40 +               buf1len = my_snprintf(buf1, sizeof buf1, "%s",
41 +                                    lock->lock_name);
42                 buf2len = my_snprintf(buf2, sizeof buf2, "os_waits=%lu",
43                                       (ulong) lock->count_os_wait);
44  
45 @@ -9637,9 +9636,8 @@
46  
47         if (block_lock) {
48                 buf1len = (uint) my_snprintf(buf1, sizeof buf1,
49 -                                            "combined %s:%lu",
50 -                                            block_lock->cfile_name,
51 -                                            (ulong) block_lock->cline);
52 +                                            "combined %s",
53 +                                            block_lock->lock_name);
54                 buf2len = (uint) my_snprintf(buf2, sizeof buf2,
55                                              "os_waits=%lu",
56                                              (ulong) block_lock_oswait_count);
57 diff -ruN a/storage/innobase/include/sync0rw.h b/storage/innobase/include/sync0rw.h
58 --- a/storage/innobase/include/sync0rw.h        2010-12-03 15:49:59.225953164 +0900
59 +++ b/storage/innobase/include/sync0rw.h        2010-12-03 17:35:12.978024458 +0900
60 @@ -138,14 +138,14 @@
61  # ifdef UNIV_DEBUG
62  #  ifdef UNIV_SYNC_DEBUG
63  #   define rw_lock_create(K, L, level)                         \
64 -       rw_lock_create_func((L), (level), #L, __FILE__, __LINE__)
65 +       rw_lock_create_func((L), (level), __FILE__, __LINE__, #L)
66  #  else        /* UNIV_SYNC_DEBUG */
67  #   define rw_lock_create(K, L, level)                         \
68 -       rw_lock_create_func((L), #L, __FILE__, __LINE__)
69 +       rw_lock_create_func((L), __FILE__, __LINE__, #L)
70  #  endif/* UNIV_SYNC_DEBUG */
71  # else /* UNIV_DEBUG */
72  #  define rw_lock_create(K, L, level)                          \
73 -       rw_lock_create_func((L), __FILE__, __LINE__)
74 +       rw_lock_create_func((L), #L)
75  # endif        /* UNIV_DEBUG */
76  
77  /**************************************************************//**
78 @@ -191,14 +191,14 @@
79  # ifdef UNIV_DEBUG
80  #  ifdef UNIV_SYNC_DEBUG
81  #   define rw_lock_create(K, L, level)                         \
82 -       pfs_rw_lock_create_func((K), (L), (level), #L, __FILE__, __LINE__)
83 +       pfs_rw_lock_create_func((K), (L), (level), __FILE__, __LINE__, #L)
84  #  else        /* UNIV_SYNC_DEBUG */
85  #   define rw_lock_create(K, L, level)                         \
86 -       pfs_rw_lock_create_func((K), (L), #L, __FILE__, __LINE__)
87 +       pfs_rw_lock_create_func((K), (L), __FILE__, __LINE__, #L)
88  #  endif/* UNIV_SYNC_DEBUG */
89  # else /* UNIV_DEBUG */
90  #  define rw_lock_create(K, L, level)                          \
91 -       pfs_rw_lock_create_func((K), (L), __FILE__, __LINE__)
92 +       pfs_rw_lock_create_func((K), (L), #L)
93  # endif        /* UNIV_DEBUG */
94  
95  /******************************************************************
96 @@ -256,10 +256,10 @@
97  # ifdef UNIV_SYNC_DEBUG
98         ulint           level,          /*!< in: level */
99  # endif /* UNIV_SYNC_DEBUG */
100 -       const char*     cmutex_name,    /*!< in: mutex name */
101 -#endif /* UNIV_DEBUG */
102         const char*     cfile_name,     /*!< in: file name where created */
103 -       ulint           cline);         /*!< in: file line where created */
104 +       ulint           cline,          /*!< in: file line where created */
105 +#endif /* UNIV_DEBUG */
106 +       const char*     cmutex_name);   /*!< in: mutex name */
107  /******************************************************************//**
108  Calling this function is obligatory only if the memory buffer containing
109  the rw-lock is freed. Removes an rw-lock object from the global list. The
110 @@ -611,7 +611,8 @@
111         struct PSI_rwlock *pfs_psi;/*!< The instrumentation hook */
112  #endif
113         ulint count_os_wait;    /*!< Count of os_waits. May not be accurate */
114 -       const char*     cfile_name;/*!< File name where lock created */
115 +       //const char*   cfile_name;/*!< File name where lock created */
116 +       const char*     lock_name;/*!< lock name */
117          /* last s-lock file/line is not guaranteed to be correct */
118         const char*     last_s_file_name;/*!< File name where last s-locked */
119         const char*     last_x_file_name;/*!< File name where last x-locked */
120 @@ -622,7 +623,7 @@
121                                 are at the start of this struct, thus we can
122                                 peek this field without causing much memory
123                                 bus traffic */
124 -       unsigned        cline:14;       /*!< Line where created */
125 +       //unsigned      cline:14;       /*!< Line where created */
126         unsigned        last_s_line:14; /*!< Line number where last time s-locked */
127         unsigned        last_x_line:14; /*!< Line number where last time x-locked */
128  #ifdef UNIV_DEBUG
129 @@ -692,10 +693,10 @@
130  # ifdef UNIV_SYNC_DEBUG
131         ulint           level,          /*!< in: level */
132  # endif /* UNIV_SYNC_DEBUG */
133 -       const char*     cmutex_name,    /*!< in: mutex name */
134 -#endif /* UNIV_DEBUG */
135         const char*     cfile_name,     /*!< in: file name where created */
136 -       ulint           cline);         /*!< in: file line where created */
137 +       ulint           cline,          /*!< in: file line where created */
138 +#endif /* UNIV_DEBUG */
139 +       const char*     cmutex_name);   /*!< in: mutex name */
140  
141  /******************************************************************//**
142  Performance schema instrumented wrap function for rw_lock_x_lock_func()
143 diff -ruN a/storage/innobase/include/sync0rw.ic b/storage/innobase/include/sync0rw.ic
144 --- a/storage/innobase/include/sync0rw.ic       2010-11-03 07:01:13.000000000 +0900
145 +++ b/storage/innobase/include/sync0rw.ic       2010-12-03 17:35:12.980024605 +0900
146 @@ -640,10 +640,10 @@
147  #  ifdef UNIV_SYNC_DEBUG
148         ulint           level,          /*!< in: level */
149  #  endif /* UNIV_SYNC_DEBUG */
150 -       const char*     cmutex_name,    /*!< in: mutex name */
151 -# endif /* UNIV_DEBUG */
152         const char*     cfile_name,     /*!< in: file name where created */
153 -       ulint           cline)          /*!< in: file line where created */
154 +       ulint           cline,          /*!< in: file line where created */
155 +# endif /* UNIV_DEBUG */
156 +       const char*     cmutex_name)    /*!< in: mutex name */
157  {
158         /* Initialize the rwlock for performance schema */
159         lock->pfs_psi = (PSI_server && PFS_IS_INSTRUMENTED(key))
160 @@ -656,10 +656,10 @@
161  #  ifdef UNIV_SYNC_DEBUG
162                             level,
163  #  endif /* UNIV_SYNC_DEBUG */
164 -                           cmutex_name,
165 -# endif /* UNIV_DEBUG */
166                             cfile_name,
167 -                           cline);
168 +                           cline,
169 +# endif /* UNIV_DEBUG */
170 +                           cmutex_name);
171  }
172  /******************************************************************//**
173  Performance schema instrumented wrap function for rw_lock_x_lock_func()
174 diff -ruN a/storage/innobase/include/sync0sync.h b/storage/innobase/include/sync0sync.h
175 --- a/storage/innobase/include/sync0sync.h      2010-12-03 15:49:59.227955503 +0900
176 +++ b/storage/innobase/include/sync0sync.h      2010-12-03 17:35:12.982023946 +0900
177 @@ -159,14 +159,14 @@
178  # ifdef UNIV_DEBUG
179  #  ifdef UNIV_SYNC_DEBUG
180  #   define mutex_create(K, M, level)                           \
181 -       pfs_mutex_create_func((K), (M), #M, (level), __FILE__, __LINE__)
182 +       pfs_mutex_create_func((K), (M), (level), __FILE__, __LINE__, #M)
183  #  else
184  #   define mutex_create(K, M, level)                           \
185 -       pfs_mutex_create_func((K), (M), #M, __FILE__, __LINE__)
186 +       pfs_mutex_create_func((K), (M), __FILE__, __LINE__, #M)
187  #  endif/* UNIV_SYNC_DEBUG */
188  # else
189  #  define mutex_create(K, M, level)                            \
190 -       pfs_mutex_create_func((K), (M), __FILE__, __LINE__)
191 +       pfs_mutex_create_func((K), (M), #M)
192  # endif        /* UNIV_DEBUG */
193  
194  # define mutex_enter(M)                                                \
195 @@ -186,14 +186,14 @@
196  # ifdef UNIV_DEBUG
197  #  ifdef UNIV_SYNC_DEBUG
198  #   define mutex_create(K, M, level)                   \
199 -       mutex_create_func((M), #M, (level), __FILE__, __LINE__)
200 +       mutex_create_func((M), (level), __FILE__, __LINE__, #M)
201  #  else /* UNIV_SYNC_DEBUG */
202  #   define mutex_create(K, M, level)                           \
203 -       mutex_create_func((M), #M, __FILE__, __LINE__)
204 +       mutex_create_func((M), __FILE__, __LINE__, #M)
205  #  endif /* UNIV_SYNC_DEBUG */
206  # else /* UNIV_DEBUG */
207  #  define mutex_create(K, M, level)                            \
208 -       mutex_create_func((M), __FILE__, __LINE__)
209 +       mutex_create_func((M), #M)
210  # endif        /* UNIV_DEBUG */
211  
212  # define mutex_enter(M)        mutex_enter_func((M), __FILE__, __LINE__)
213 @@ -218,13 +218,13 @@
214  /*==============*/
215         mutex_t*        mutex,          /*!< in: pointer to memory */
216  #ifdef UNIV_DEBUG
217 -       const char*     cmutex_name,    /*!< in: mutex name */
218  # ifdef UNIV_SYNC_DEBUG
219         ulint           level,          /*!< in: level */
220  # endif /* UNIV_SYNC_DEBUG */
221 -#endif /* UNIV_DEBUG */
222         const char*     cfile_name,     /*!< in: file name where created */
223 -       ulint           cline);         /*!< in: file line where created */
224 +       ulint           cline,          /*!< in: file line where created */
225 +#endif /* UNIV_DEBUG */
226 +       const char*     cmutex_name);   /*!< in: mutex name */
227  
228  /******************************************************************//**
229  NOTE! Use the corresponding macro mutex_free(), not directly this function!
230 @@ -292,13 +292,13 @@
231         PSI_mutex_key   key,            /*!< in: Performance Schema key */
232         mutex_t*        mutex,          /*!< in: pointer to memory */
233  # ifdef UNIV_DEBUG
234 -       const char*     cmutex_name,    /*!< in: mutex name */
235  #  ifdef UNIV_SYNC_DEBUG
236         ulint           level,          /*!< in: level */
237  #  endif /* UNIV_SYNC_DEBUG */
238 -# endif /* UNIV_DEBUG */
239         const char*     cfile_name,     /*!< in: file name where created */
240 -       ulint           cline);         /*!< in: file line where created */
241 +       ulint           cline,          /*!< in: file line where created */
242 +# endif /* UNIV_DEBUG */
243 +       const char*     cmutex_name);
244  /******************************************************************//**
245  NOTE! Please use the corresponding macro mutex_enter(), not directly
246  this function!
247 @@ -723,9 +723,9 @@
248         ulint   line;           /*!< Line where the mutex was locked */
249         ulint   level;          /*!< Level in the global latching order */
250  #endif /* UNIV_SYNC_DEBUG */
251 +#ifdef UNIV_DEBUG
252         const char*     cfile_name;/*!< File name where mutex created */
253         ulint           cline;  /*!< Line where created */
254 -#ifdef UNIV_DEBUG
255         os_thread_id_t thread_id; /*!< The thread id of the thread
256                                 which locked the mutex. */
257         ulint           magic_n;        /*!< MUTEX_MAGIC_N */
258 @@ -740,9 +740,9 @@
259         ulong           count_os_yield; /*!< count of os_wait */
260         ulonglong       lspent_time;    /*!< mutex os_wait timer msec */
261         ulonglong       lmax_spent_time;/*!< mutex os_wait timer msec */
262 -       const char*     cmutex_name;    /*!< mutex name */
263         ulint           mutex_type;     /*!< 0=usual mutex, 1=rw_lock mutex */
264  #endif /* UNIV_DEBUG */
265 +       const char*     cmutex_name;    /*!< mutex name */
266  #ifdef UNIV_PFS_MUTEX
267         struct PSI_mutex* pfs_psi;      /*!< The performance schema
268                                         instrumentation hook */
269 diff -ruN a/storage/innobase/include/sync0sync.ic b/storage/innobase/include/sync0sync.ic
270 --- a/storage/innobase/include/sync0sync.ic     2010-11-03 07:01:13.000000000 +0900
271 +++ b/storage/innobase/include/sync0sync.ic     2010-12-03 17:35:12.984024599 +0900
272 @@ -321,13 +321,13 @@
273         mysql_pfs_key_t key,            /*!< in: Performance Schema key */
274         mutex_t*        mutex,          /*!< in: pointer to memory */
275  # ifdef UNIV_DEBUG
276 -       const char*     cmutex_name,    /*!< in: mutex name */
277  #  ifdef UNIV_SYNC_DEBUG
278         ulint           level,          /*!< in: level */
279  #  endif /* UNIV_SYNC_DEBUG */
280 -# endif /* UNIV_DEBUG */
281         const char*     cfile_name,     /*!< in: file name where created */
282 -       ulint           cline)          /*!< in: file line where created */
283 +       ulint           cline,          /*!< in: file line where created */
284 +# endif /* UNIV_DEBUG */
285 +       const char*     cmutex_name)    /*!< in: mutex name */
286  {
287         mutex->pfs_psi = (PSI_server && PFS_IS_INSTRUMENTED(key))
288                                 ? PSI_server->init_mutex(key, mutex)
289 @@ -335,13 +335,13 @@
290  
291         mutex_create_func(mutex,
292  # ifdef UNIV_DEBUG
293 -                         cmutex_name,
294  #  ifdef UNIV_SYNC_DEBUG
295                           level,
296  #  endif /* UNIV_SYNC_DEBUG */
297 -# endif /* UNIV_DEBUG */
298                           cfile_name,
299 -                         cline);
300 +                         cline,
301 +# endif /* UNIV_DEBUG */
302 +                         cmutex_name);
303  }
304  /******************************************************************//**
305  NOTE! Please use the corresponding macro mutex_free(), not directly
306 diff -ruN a/storage/innobase/sync/sync0arr.c b/storage/innobase/sync/sync0arr.c
307 --- a/storage/innobase/sync/sync0arr.c  2010-12-03 15:09:51.304953409 +0900
308 +++ b/storage/innobase/sync/sync0arr.c  2010-12-03 17:35:12.985024561 +0900
309 @@ -488,12 +488,12 @@
310                 mutex = cell->old_wait_mutex;
311  
312                 fprintf(file,
313 -                       "Mutex at %p created file %s line %lu, lock var %lu\n"
314 +                       "Mutex at %p '%s', lock var %lu\n"
315  #ifdef UNIV_SYNC_DEBUG
316                         "Last time reserved in file %s line %lu, "
317  #endif /* UNIV_SYNC_DEBUG */
318                         "waiters flag %lu\n",
319 -                       (void*) mutex, mutex->cfile_name, (ulong) mutex->cline,
320 +                       (void*) mutex, mutex->cmutex_name,
321                         (ulong) mutex->lock_word,
322  #ifdef UNIV_SYNC_DEBUG
323                         mutex->file_name, (ulong) mutex->line,
324 @@ -511,9 +511,8 @@
325                 rwlock = cell->old_wait_rw_lock;
326  
327                 fprintf(file,
328 -                       " RW-latch at %p created in file %s line %lu\n",
329 -                       (void*) rwlock, rwlock->cfile_name,
330 -                       (ulong) rwlock->cline);
331 +                       " RW-latch at %p '%s'\n",
332 +                       (void*) rwlock, rwlock->lock_name);
333                 writer = rw_lock_get_writer(rwlock);
334                 if (writer != RW_LOCK_NOT_LOCKED) {
335                         fprintf(file,
336 diff -ruN a/storage/innobase/sync/sync0rw.c b/storage/innobase/sync/sync0rw.c
337 --- a/storage/innobase/sync/sync0rw.c   2010-11-03 07:01:13.000000000 +0900
338 +++ b/storage/innobase/sync/sync0rw.c   2010-12-03 17:35:12.987029059 +0900
339 @@ -241,10 +241,10 @@
340  # ifdef UNIV_SYNC_DEBUG
341         ulint           level,          /*!< in: level */
342  # endif /* UNIV_SYNC_DEBUG */
343 -       const char*     cmutex_name,    /*!< in: mutex name */
344 -#endif /* UNIV_DEBUG */
345         const char*     cfile_name,     /*!< in: file name where created */
346 -       ulint           cline)          /*!< in: file line where created */
347 +       ulint           cline,          /*!< in: file line where created */
348 +#endif /* UNIV_DEBUG */
349 +       const char*     cmutex_name)    /*!< in: mutex name */
350  {
351         /* If this is the very first time a synchronization object is
352         created, then the following call initializes the sync system. */
353 @@ -253,14 +253,15 @@
354         mutex_create(rw_lock_mutex_key, rw_lock_get_mutex(lock),
355                      SYNC_NO_ORDER_CHECK);
356  
357 -       lock->mutex.cfile_name = cfile_name;
358 -       lock->mutex.cline = cline;
359 +       ut_d(lock->mutex.cfile_name = cfile_name);
360 +       ut_d(lock->mutex.cline = cline);
361  
362 -       ut_d(lock->mutex.cmutex_name = cmutex_name);
363 +       lock->mutex.cmutex_name = cmutex_name;
364         ut_d(lock->mutex.mutex_type = 1);
365  #else /* INNODB_RW_LOCKS_USE_ATOMICS */
366  # ifdef UNIV_DEBUG
367 -       UT_NOT_USED(cmutex_name);
368 +       UT_NOT_USED(cfile_name);
369 +       UT_NOT_USED(cline);
370  # endif
371  #endif /* INNODB_RW_LOCKS_USE_ATOMICS */
372  
373 @@ -283,8 +284,7 @@
374  
375         ut_d(lock->magic_n = RW_LOCK_MAGIC_N);
376  
377 -       lock->cfile_name = cfile_name;
378 -       lock->cline = (unsigned int) cline;
379 +       lock->lock_name = cmutex_name;
380  
381         lock->count_os_wait = 0;
382         lock->last_s_file_name = "not yet reserved";
383 @@ -404,10 +404,10 @@
384         if (srv_print_latch_waits) {
385                 fprintf(stderr,
386                         "Thread %lu spin wait rw-s-lock at %p"
387 -                       " cfile %s cline %lu rnds %lu\n",
388 +                       " '%s' rnds %lu\n",
389                         (ulong) os_thread_pf(os_thread_get_curr_id()),
390                         (void*) lock,
391 -                       lock->cfile_name, (ulong) lock->cline, (ulong) i);
392 +                       lock->lock_name, (ulong) i);
393         }
394  
395         /* We try once again to obtain the lock */
396 @@ -440,10 +440,9 @@
397                 if (srv_print_latch_waits) {
398                         fprintf(stderr,
399                                 "Thread %lu OS wait rw-s-lock at %p"
400 -                               " cfile %s cline %lu\n",
401 +                               " '%s'\n",
402                                 os_thread_pf(os_thread_get_curr_id()),
403 -                               (void*) lock, lock->cfile_name,
404 -                               (ulong) lock->cline);
405 +                               (void*) lock, lock->lock_name);
406                 }
407  
408                 /* these stats may not be accurate */
409 @@ -662,9 +661,9 @@
410         if (srv_print_latch_waits) {
411                 fprintf(stderr,
412                         "Thread %lu spin wait rw-x-lock at %p"
413 -                       " cfile %s cline %lu rnds %lu\n",
414 +                       " '%s' rnds %lu\n",
415                         os_thread_pf(os_thread_get_curr_id()), (void*) lock,
416 -                       lock->cfile_name, (ulong) lock->cline, (ulong) i);
417 +                       lock->lock_name, (ulong) i);
418         }
419  
420         sync_array_reserve_cell(sync_primary_wait_array,
421 @@ -685,9 +684,9 @@
422         if (srv_print_latch_waits) {
423                 fprintf(stderr,
424                         "Thread %lu OS wait for rw-x-lock at %p"
425 -                       " cfile %s cline %lu\n",
426 +                       " '%s'\n",
427                         os_thread_pf(os_thread_get_curr_id()), (void*) lock,
428 -                       lock->cfile_name, (ulong) lock->cline);
429 +                       lock->lock_name);
430         }
431  
432         /* these stats may not be accurate */
433 diff -ruN a/storage/innobase/sync/sync0sync.c b/storage/innobase/sync/sync0sync.c
434 --- a/storage/innobase/sync/sync0sync.c 2010-12-03 15:49:59.233955565 +0900
435 +++ b/storage/innobase/sync/sync0sync.c 2010-12-03 17:35:12.989024400 +0900
436 @@ -269,13 +269,13 @@
437  /*==============*/
438         mutex_t*        mutex,          /*!< in: pointer to memory */
439  #ifdef UNIV_DEBUG
440 -       const char*     cmutex_name,    /*!< in: mutex name */
441  # ifdef UNIV_SYNC_DEBUG
442         ulint           level,          /*!< in: level */
443  # endif /* UNIV_SYNC_DEBUG */
444 -#endif /* UNIV_DEBUG */
445         const char*     cfile_name,     /*!< in: file name where created */
446 -       ulint           cline)          /*!< in: file line where created */
447 +       ulint           cline,          /*!< in: file line where created */
448 +#endif /* UNIV_DEBUG */
449 +       const char*     cmutex_name)    /*!< in: mutex name */
450  {
451  #if defined(HAVE_ATOMIC_BUILTINS)
452         mutex_reset_lock_word(mutex);
453 @@ -293,11 +293,13 @@
454         mutex->file_name = "not yet reserved";
455         mutex->level = level;
456  #endif /* UNIV_SYNC_DEBUG */
457 +#ifdef UNIV_DEBUG
458         mutex->cfile_name = cfile_name;
459         mutex->cline = cline;
460 +#endif /* UNIV_DEBUG */
461         mutex->count_os_wait = 0;
462 -#ifdef UNIV_DEBUG
463         mutex->cmutex_name=       cmutex_name;
464 +#ifdef UNIV_DEBUG
465         mutex->count_using=       0;
466         mutex->mutex_type=        0;
467         mutex->lspent_time=       0;
468 @@ -551,9 +553,9 @@
469  #ifdef UNIV_SRV_PRINT_LATCH_WAITS
470         fprintf(stderr,
471                 "Thread %lu spin wait mutex at %p"
472 -               " cfile %s cline %lu rnds %lu\n",
473 +               " '%s' rnds %lu\n",
474                 (ulong) os_thread_pf(os_thread_get_curr_id()), (void*) mutex,
475 -               mutex->cfile_name, (ulong) mutex->cline, (ulong) i);
476 +               mutex->cmutex_name, (ulong) i);
477  #endif
478  
479         mutex_spin_round_count += i;
480 @@ -628,9 +630,9 @@
481  
482  #ifdef UNIV_SRV_PRINT_LATCH_WAITS
483         fprintf(stderr,
484 -               "Thread %lu OS wait mutex at %p cfile %s cline %lu rnds %lu\n",
485 +               "Thread %lu OS wait mutex at %p '%s' rnds %lu\n",
486                 (ulong) os_thread_pf(os_thread_get_curr_id()), (void*) mutex,
487 -               mutex->cfile_name, (ulong) mutex->cline, (ulong) i);
488 +               mutex->cmutex_name, (ulong) i);
489  #endif
490  
491         mutex_os_wait_count++;
492 @@ -878,8 +880,8 @@
493  
494         if (mutex->magic_n == MUTEX_MAGIC_N) {
495                 fprintf(stderr,
496 -                       "Mutex created at %s %lu\n",
497 -                       mutex->cfile_name, (ulong) mutex->cline);
498 +                       "Mutex '%s'\n",
499 +                       mutex->cmutex_name);
500  
501                 if (mutex_get_lock_word(mutex) != 0) {
502                         ulint           line;
This page took 0.079409 seconds and 3 git commands to generate.