diff --git a/.gitignore b/.gitignore index d92073c0af4..3535f8cc0eb 100644 --- a/.gitignore +++ b/.gitignore @@ -221,6 +221,7 @@ storage/myisam/myisamlog storage/myisam/myisampack storage/myisam/rt_test storage/myisam/sp_test +storage/perfschema/pfs_config.h storage/rocksdb/ldb storage/rocksdb/myrocks_hotbackup storage/rocksdb/mysql_ldb diff --git a/include/my_pthread.h b/include/my_pthread.h index 41af69bb54d..0c67dc95765 100644 --- a/include/my_pthread.h +++ b/include/my_pthread.h @@ -116,7 +116,7 @@ int pthread_cancel(pthread_t thread); #define pthread_key_create(A,B) ((*A=TlsAlloc())==0xFFFFFFFF) #define pthread_key_delete(A) TlsFree(A) #define my_pthread_setspecific_ptr(T,V) (!TlsSetValue((T),(V))) -#define pthread_setspecific(A,B) (!TlsSetValue((A),(B))) +#define pthread_setspecific(A,B) (!TlsSetValue((A),(LPVOID)(B))) #define pthread_getspecific(A) (TlsGetValue(A)) #define my_pthread_getspecific(T,A) ((T) TlsGetValue(A)) #define my_pthread_getspecific_ptr(T,V) ((T) TlsGetValue(V)) diff --git a/include/mysql/psi/mysql_file.h b/include/mysql/psi/mysql_file.h index 533c440d4f9..761482d0165 100644 --- a/include/mysql/psi/mysql_file.h +++ b/include/mysql/psi/mysql_file.h @@ -540,7 +540,7 @@ inline_mysql_file_fgets( { char *result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -568,7 +568,7 @@ inline_mysql_file_fgetc( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -596,7 +596,7 @@ inline_mysql_file_fputs( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -626,7 +626,7 @@ inline_mysql_file_fputc( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -654,7 +654,7 @@ inline_mysql_file_fprintf(MYSQL_FILE *file, const char *format, ...) int result; va_list args; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -686,7 +686,7 @@ inline_mysql_file_vfprintf( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -714,7 +714,7 @@ inline_mysql_file_fflush( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -748,18 +748,15 @@ inline_mysql_file_fstat( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, filenr, PSI_FILE_FSTAT); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, filenr, PSI_FILE_FSTAT); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); - result= my_fstat(filenr, stat_area, flags); - PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); + result= my_fstat(filenr, stat_area, flags); + PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); + return result; } #endif @@ -776,18 +773,15 @@ inline_mysql_file_stat( { MY_STAT *result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_STAT, path, &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_STAT, path, &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); - result= my_stat(path, stat_area, flags); - PSI_FILE_CALL(end_file_open_wait)(locker, result); - return result; - } + PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); + result= my_stat(path, stat_area, flags); + PSI_FILE_CALL(end_file_open_wait)(locker, result); + return result; } #endif @@ -804,19 +798,16 @@ inline_mysql_file_chsize( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CHSIZE); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CHSIZE); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) newlength, src_file, - src_line); - result= my_chsize(file, newlength, filler, flags); - PSI_FILE_CALL(end_file_wait)(locker, (size_t) newlength); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) newlength, src_file, + src_line); + result= my_chsize(file, newlength, filler, flags); + PSI_FILE_CALL(end_file_wait)(locker, (size_t) newlength); + return result; } #endif @@ -837,24 +828,21 @@ inline_mysql_file_fopen( if (likely(that != NULL)) { #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_STREAM_OPEN, + filename, that); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_STREAM_OPEN, - filename, that); - if (likely(locker != NULL)) + PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); + that->m_file= my_fopen(filename, flags, myFlags); + that->m_psi= PSI_FILE_CALL(end_file_open_wait)(locker, that->m_file); + if (unlikely(that->m_file == NULL)) { - PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); - that->m_file= my_fopen(filename, flags, myFlags); - that->m_psi= PSI_FILE_CALL(end_file_open_wait)(locker, that->m_file); - if (unlikely(that->m_file == NULL)) - { - my_free(that); - return NULL; - } - return that; + my_free(that); + return NULL; } + return that; } #endif @@ -880,7 +868,7 @@ inline_mysql_file_fclose( if (likely(file != NULL)) { #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -912,7 +900,7 @@ inline_mysql_file_fread( { size_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -945,7 +933,7 @@ inline_mysql_file_fwrite( { size_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -978,7 +966,7 @@ inline_mysql_file_fseek( { my_off_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -1006,7 +994,7 @@ inline_mysql_file_ftell( { my_off_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + if (psi_likely(file->m_psi)) { struct PSI_file_locker *locker; PSI_file_locker_state state; @@ -1034,19 +1022,16 @@ inline_mysql_file_create( { File file; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_CREATE, filename, + &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_CREATE, filename, - &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); - file= my_create(filename, create_flags, access_flags, myFlags); - PSI_FILE_CALL(end_file_open_wait_and_bind_to_descriptor)(locker, file); - return file; - } + PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); + file= my_create(filename, create_flags, access_flags, myFlags); + PSI_FILE_CALL(end_file_open_wait_and_bind_to_descriptor)(locker, file); + return file; } #endif @@ -1067,7 +1052,7 @@ inline_mysql_file_create_temp( PSI_file_locker_state state; locker= PSI_FILE_CALL(get_thread_file_name_locker) (&state, key, PSI_FILE_CREATE, NULL, &locker); - if (likely(locker != NULL)) + if (psi_likely(locker != NULL)) { PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); /* The file name is generated by create_temp_file(). */ @@ -1090,19 +1075,16 @@ inline_mysql_file_open( { File file; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_OPEN, filename, + &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_OPEN, filename, - &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); - file= my_open(filename, flags, myFlags); - PSI_FILE_CALL(end_file_open_wait_and_bind_to_descriptor)(locker, file); - return file; - } + PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); + file= my_open(filename, flags, myFlags); + PSI_FILE_CALL(end_file_open_wait_and_bind_to_descriptor)(locker, file); + return file; } #endif @@ -1119,18 +1101,15 @@ inline_mysql_file_close( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CLOSE); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_CLOSE); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line); - result= my_close(file, flags); - PSI_FILE_CALL(end_file_close_wait)(locker, result); - return result; - } + PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line); + result= my_close(file, flags); + PSI_FILE_CALL(end_file_close_wait)(locker, result); + return result; } #endif @@ -1147,23 +1126,20 @@ inline_mysql_file_read( { size_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + size_t bytes_read; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_READ); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - size_t bytes_read; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_READ); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); - result= my_read(file, buffer, count, flags); - if (flags & (MY_NABP | MY_FNABP)) - bytes_read= (result == 0) ? count : 0; - else - bytes_read= (result != MY_FILE_ERROR) ? result : 0; - PSI_FILE_CALL(end_file_wait)(locker, bytes_read); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); + result= my_read(file, buffer, count, flags); + if (flags & (MY_NABP | MY_FNABP)) + bytes_read= (result == 0) ? count : 0; + else + bytes_read= (result != MY_FILE_ERROR) ? result : 0; + PSI_FILE_CALL(end_file_wait)(locker, bytes_read); + return result; } #endif @@ -1180,23 +1156,20 @@ inline_mysql_file_write( { size_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + size_t bytes_written; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_WRITE); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - size_t bytes_written; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_WRITE); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); - result= my_write(file, buffer, count, flags); - if (flags & (MY_NABP | MY_FNABP)) - bytes_written= (result == 0) ? count : 0; - else - bytes_written= (result != MY_FILE_ERROR) ? result : 0; - PSI_FILE_CALL(end_file_wait)(locker, bytes_written); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); + result= my_write(file, buffer, count, flags); + if (flags & (MY_NABP | MY_FNABP)) + bytes_written= (result == 0) ? count : 0; + else + bytes_written= (result != MY_FILE_ERROR) ? result : 0; + PSI_FILE_CALL(end_file_wait)(locker, bytes_written); + return result; } #endif @@ -1213,23 +1186,20 @@ inline_mysql_file_pread( { size_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + size_t bytes_read; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_READ); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - size_t bytes_read; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_READ); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); - result= my_pread(file, buffer, count, offset, flags); - if (flags & (MY_NABP | MY_FNABP)) - bytes_read= (result == 0) ? count : 0; - else - bytes_read= (result != MY_FILE_ERROR) ? result : 0; - PSI_FILE_CALL(end_file_wait)(locker, bytes_read); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); + result= my_pread(file, buffer, count, offset, flags); + if (flags & (MY_NABP | MY_FNABP)) + bytes_read= (result == 0) ? count : 0; + else + bytes_read= (result != MY_FILE_ERROR) ? result : 0; + PSI_FILE_CALL(end_file_wait)(locker, bytes_read); + return result; } #endif @@ -1246,23 +1216,20 @@ inline_mysql_file_pwrite( { size_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + size_t bytes_written; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_WRITE); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - size_t bytes_written; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_WRITE); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); - result= my_pwrite(file, buffer, count, offset, flags); - if (flags & (MY_NABP | MY_FNABP)) - bytes_written= (result == 0) ? count : 0; - else - bytes_written= (result != MY_FILE_ERROR) ? result : 0; - PSI_FILE_CALL(end_file_wait)(locker, bytes_written); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, count, src_file, src_line); + result= my_pwrite(file, buffer, count, offset, flags); + if (flags & (MY_NABP | MY_FNABP)) + bytes_written= (result == 0) ? count : 0; + else + bytes_written= (result != MY_FILE_ERROR) ? result : 0; + PSI_FILE_CALL(end_file_wait)(locker, bytes_written); + return result; } #endif @@ -1279,18 +1246,15 @@ inline_mysql_file_seek( { my_off_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_SEEK); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_SEEK); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); - result= my_seek(file, pos, whence, flags); - PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); + result= my_seek(file, pos, whence, flags); + PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); + return result; } #endif @@ -1307,18 +1271,15 @@ inline_mysql_file_tell( { my_off_t result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_TELL); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, file, PSI_FILE_TELL); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); - result= my_tell(file, flags); - PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); + result= my_tell(file, flags); + PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); + return result; } #endif @@ -1335,18 +1296,15 @@ inline_mysql_file_delete( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_DELETE, name, &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_DELETE, name, &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line); - result= my_delete(name, flags); - PSI_FILE_CALL(end_file_close_wait)(locker, result); - return result; - } + PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line); + result= my_delete(name, flags); + PSI_FILE_CALL(end_file_close_wait)(locker, result); + return result; } #endif @@ -1363,19 +1321,16 @@ inline_mysql_file_rename( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker) + (&state, key, PSI_FILE_RENAME, from, &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker) - (&state, key, PSI_FILE_RENAME, from, &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); - result= my_rename(from, to, flags); - PSI_FILE_CALL(end_file_rename_wait)(locker, from, to, result); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); + result= my_rename(from, to, flags); + PSI_FILE_CALL(end_file_rename_wait)(locker, from, to, result); + return result; } #endif @@ -1394,20 +1349,17 @@ inline_mysql_file_create_with_symlink( { File file; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_CREATE, filename, + &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_CREATE, filename, - &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); - file= my_create_with_symlink(linkname, filename, create_flags, access_flags, - flags); - PSI_FILE_CALL(end_file_open_wait_and_bind_to_descriptor)(locker, file); - return file; - } + PSI_FILE_CALL(start_file_open_wait)(locker, src_file, src_line); + file= my_create_with_symlink(linkname, filename, create_flags, access_flags, + flags); + PSI_FILE_CALL(end_file_open_wait_and_bind_to_descriptor)(locker, file); + return file; } #endif @@ -1428,19 +1380,16 @@ inline_mysql_file_delete_with_symlink( char buf[FN_REFLEN]; char *fullname= fn_format(buf, name, "", ext, MY_UNPACK_FILENAME | MY_APPEND_EXT); #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_DELETE, fullname, + &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker)(&state, key, PSI_FILE_DELETE, fullname, - &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line); - result= my_handler_delete_with_symlink(fullname, flags); - PSI_FILE_CALL(end_file_close_wait)(locker, result); - return result; - } + PSI_FILE_CALL(start_file_close_wait)(locker, src_file, src_line); + result= my_handler_delete_with_symlink(fullname, flags); + PSI_FILE_CALL(end_file_close_wait)(locker, result); + return result; } #endif @@ -1458,19 +1407,16 @@ inline_mysql_file_rename_with_symlink( { int result; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_name_locker) + (&state, key, PSI_FILE_RENAME, from, &locker); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_name_locker) - (&state, key, PSI_FILE_RENAME, from, &locker); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); - result= my_rename_with_symlink(from, to, flags); - PSI_FILE_CALL(end_file_rename_wait)(locker, from, to, result); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); + result= my_rename_with_symlink(from, to, flags); + PSI_FILE_CALL(end_file_rename_wait)(locker, from, to, result); + return result; } #endif @@ -1487,18 +1433,15 @@ inline_mysql_file_sync( { int result= 0; #ifdef HAVE_PSI_FILE_INTERFACE - if (psi_likely(pfs_enabled)) + struct PSI_file_locker *locker; + PSI_file_locker_state state; + locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, fd, PSI_FILE_SYNC); + if (psi_likely(locker != NULL)) { - struct PSI_file_locker *locker; - PSI_file_locker_state state; - locker= PSI_FILE_CALL(get_thread_file_descriptor_locker)(&state, fd, PSI_FILE_SYNC); - if (likely(locker != NULL)) - { - PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); - result= my_sync(fd, flags); - PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); - return result; - } + PSI_FILE_CALL(start_file_wait)(locker, (size_t) 0, src_file, src_line); + result= my_sync(fd, flags); + PSI_FILE_CALL(end_file_wait)(locker, (size_t) 0); + return result; } #endif diff --git a/include/mysql/psi/mysql_mdl.h b/include/mysql/psi/mysql_mdl.h index 0db0160c77d..20d6c94c57c 100644 --- a/include/mysql/psi/mysql_mdl.h +++ b/include/mysql/psi/mysql_mdl.h @@ -30,10 +30,25 @@ #include "mysql/psi/psi.h" +#ifdef HAVE_PSI_METADATA_INTERFACE + #ifndef PSI_METADATA_CALL #define PSI_METADATA_CALL(M) PSI_DYNAMIC_CALL(M) #endif +#define PSI_CALL_start_metadata_wait(A,B,C,D) PSI_METADATA_CALL(start_metadata_wait)(A,B,C,D) +#define PSI_CALL_end_metadata_wait(A,B) PSI_METADATA_CALL(end_metadata_wait)(A,B) +#define PSI_CALL_create_metadata_lock(A,B,C,D,E,F,G) PSI_METADATA_CALL(create_metadata_lock)(A,B,C,D,E,F,G) +#define PSI_CALL_set_metadata_lock_status(A,B) PSI_METADATA_CALL(set_metadata_lock_status)(A,B) +#define PSI_CALL_destroy_metadata_lock(A) PSI_METADATA_CALL(destroy_metadata_lock)(A) +#else +#define PSI_CALL_start_metadata_wait(A,B,C,D) 0 +#define PSI_CALL_end_metadata_wait(A,B) do { } while(0) +#define PSI_CALL_create_metadata_lock(A,B,C,D,E,F,G) 0 +#define PSI_CALL_set_metadata_lock_status(A,B) do {} while(0) +#define PSI_CALL_destroy_metadata_lock(A) do {} while(0) +#endif + /** @defgroup Thread_instrumentation Metadata Instrumentation @ingroup Instrumentation_interface diff --git a/include/mysql/psi/mysql_memory.h b/include/mysql/psi/mysql_memory.h index c491ef4570c..a79579c2e56 100644 --- a/include/mysql/psi/mysql_memory.h +++ b/include/mysql/psi/mysql_memory.h @@ -30,6 +30,18 @@ #include "mysql/psi/psi.h" +#ifdef HAVE_PSI_MEMORY_INTERFACE +#define PSI_CALL_memory_alloc(A1,A2,A3) PSI_MEMORY_CALL(memory_alloc)(A1,A2,A3) +#define PSI_CALL_memory_free(A1,A2,A3) PSI_MEMORY_CALL(memory_free)(A1,A2,A3) +#define PSI_CALL_memory_realloc(A1,A2,A3,A4) PSI_MEMORY_CALL(memory_realloc)(A1,A2,A3,A4) +#define PSI_CALL_register_memory(A1,A2,A3) PSI_MEMORY_CALL(register_memory)(A1,A2,A3) +#else +#define PSI_CALL_memory_alloc(A1,A2,A3) 0 +#define PSI_CALL_memory_free(A1,A2,A3) do { } while(0) +#define PSI_CALL_memory_realloc(A1,A2,A3,A4) 0 +#define PSI_CALL_register_memory(A1,A2,A3) do { } while(0) +#endif + #ifndef PSI_MEMORY_CALL #define PSI_MEMORY_CALL(M) PSI_DYNAMIC_CALL(M) #endif @@ -58,9 +70,7 @@ static inline void inline_mysql_memory_register( int count __attribute__((unused))) #endif { -#ifdef HAVE_PSI_MEMORY_INTERFACE - PSI_MEMORY_CALL(register_memory)(category, info, count); -#endif + PSI_CALL_register_memory(category, info, count); } /** @} (end of group Memory_instrumentation) */ diff --git a/include/mysql/psi/mysql_stage.h b/include/mysql/psi/mysql_stage.h index 9af5a7110df..732df6bd357 100644 --- a/include/mysql/psi/mysql_stage.h +++ b/include/mysql/psi/mysql_stage.h @@ -89,10 +89,10 @@ End the last stage */ #ifdef HAVE_PSI_STAGE_INTERFACE - #define mysql_end_stage \ - inline_mysql_end_stage + #define mysql_end_stage() \ + inline_mysql_end_stage() #else - #define mysql_end_stage \ + #define mysql_end_stage() \ do {} while (0) #endif diff --git a/include/mysql/psi/mysql_thread.h b/include/mysql/psi/mysql_thread.h index 071ea66e656..711520dba78 100644 --- a/include/mysql/psi/mysql_thread.h +++ b/include/mysql/psi/mysql_thread.h @@ -96,26 +96,32 @@ #define PSI_CALL_new_thread PSI_THREAD_CALL(new_thread) #define PSI_CALL_register_thread PSI_THREAD_CALL(register_thread) #define PSI_CALL_set_thread PSI_THREAD_CALL(set_thread) +#define PSI_CALL_set_thread_THD PSI_THREAD_CALL(set_thread_THD) #define PSI_CALL_set_thread_connect_attrs PSI_THREAD_CALL(set_thread_connect_attrs) #define PSI_CALL_set_thread_db PSI_THREAD_CALL(set_thread_db) #define PSI_CALL_set_thread_id PSI_THREAD_CALL(set_thread_id) +#define PSI_CALL_set_thread_os_id PSI_THREAD_CALL(set_thread_os_id) #define PSI_CALL_set_thread_info PSI_THREAD_CALL(set_thread_info) #define PSI_CALL_set_thread_start_time PSI_THREAD_CALL(set_thread_start_time) #define PSI_CALL_set_thread_account PSI_THREAD_CALL(set_thread_account) #define PSI_CALL_spawn_thread PSI_THREAD_CALL(spawn_thread) +#define PSI_CALL_set_connection_type PSI_THREAD_CALL(set_connection_type) #else #define PSI_CALL_delete_current_thread() do { } while(0) #define PSI_CALL_get_thread() NULL #define PSI_CALL_new_thread(A1,A2,A3) NULL #define PSI_CALL_register_thread(A1,A2,A3) do { } while(0) #define PSI_CALL_set_thread(A1) do { } while(0) +#define PSI_CALL_set_thread_THD(A1,A2) do { } while(0) #define PSI_CALL_set_thread_connect_attrs(A1,A2,A3) 0 #define PSI_CALL_set_thread_db(A1,A2) do { } while(0) #define PSI_CALL_set_thread_id(A1,A2) do { } while(0) +#define PSI_CALL_set_thread_os_id(A1) do { } while(0) #define PSI_CALL_set_thread_info(A1, A2) do { } while(0) #define PSI_CALL_set_thread_start_time(A1) do { } while(0) #define PSI_CALL_set_thread_account(A1, A2, A3, A4) do { } while(0) #define PSI_CALL_spawn_thread(A1, A2, A3, A4, A5) 0 +#define PSI_CALL_set_connection_type(A) do { } while(0) #endif diff --git a/include/mysql/psi/mysql_transaction.h b/include/mysql/psi/mysql_transaction.h index 41629395ee0..dab9cfee14f 100644 --- a/include/mysql/psi/mysql_transaction.h +++ b/include/mysql/psi/mysql_transaction.h @@ -45,7 +45,7 @@ inline_mysql_start_transaction(STATE, XID, TRXID, ISO, RO, AC, __FILE__, __LINE__) #else #define MYSQL_START_TRANSACTION(STATE, XID, TRXID, ISO, RO, AC) \ - do {} while (0) + 0 #endif #ifdef HAVE_PSI_TRANSACTION_INTERFACE @@ -109,7 +109,7 @@ inline_mysql_rollback_transaction(LOCKER) #else #define MYSQL_ROLLBACK_TRANSACTION(LOCKER) \ - NULL + do { } while(0) #endif #ifdef HAVE_PSI_TRANSACTION_INTERFACE @@ -117,7 +117,7 @@ inline_mysql_commit_transaction(LOCKER) #else #define MYSQL_COMMIT_TRANSACTION(LOCKER) \ - NULL + do { } while(0) #endif #ifdef HAVE_PSI_TRANSACTION_INTERFACE diff --git a/include/mysql/psi/psi.h b/include/mysql/psi/psi.h index 9400bebe5b0..3cc392fef67 100644 --- a/include/mysql/psi/psi.h +++ b/include/mysql/psi/psi.h @@ -23,10 +23,6 @@ #ifndef MYSQL_PERFORMANCE_SCHEMA_INTERFACE_H #define MYSQL_PERFORMANCE_SCHEMA_INTERFACE_H -#ifdef EMBEDDED_LIBRARY -#define DISABLE_ALL_PSI -#endif /* EMBEDDED_LIBRARY */ - #ifndef MY_GLOBAL_INCLUDED /* Make sure a .c or .cc file contains an include to my_global.h first. @@ -55,6 +51,12 @@ #include "psi_base.h" #include "psi_memory.h" +#ifdef _WIN32 +typedef struct thread_attr pthread_attr_t; +typedef DWORD pthread_t; +typedef DWORD pthread_key_t; +#endif + /* MAINTAINER: The following pattern: @@ -783,6 +785,7 @@ enum PSI_socket_operation }; typedef enum PSI_socket_operation PSI_socket_operation; +#endif /** Instrumented mutex key. To instrument a mutex, a mutex key must be obtained using @c register_mutex. @@ -819,10 +822,7 @@ typedef unsigned int PSI_thread_key; To instrument a file, a file key must be obtained using @c register_file. Using a zero key always disable the instrumentation. */ -#ifndef PSI_FILE_KEY_DEFINED typedef unsigned int PSI_file_key; -#define PSI_FILE_KEY_DEFINED -#endif /** Instrumented stage key. @@ -2967,7 +2967,7 @@ typedef struct PSI_sp_locker_state_v2 PSI_sp_locker_state; typedef struct PSI_metadata_locker_state_v2 PSI_metadata_locker_state; #endif -#else /* HAVE_PSI_INTERFACE */ +#ifndef HAVE_PSI_INTERFACE /** Dummy structure, used to declare PSI_server when no instrumentation @@ -3004,10 +3004,13 @@ struct PSI_stage_info_none with HAVE_PSI_INTERFACE. */ typedef struct PSI_stage_info_none PSI_stage_info; +typedef struct PSI_stage_info_none PSI_statement_info; +typedef struct PSI_stage_info_none PSI_sp_locker_state; +typedef struct PSI_stage_info_none PSI_metadata_locker_state; +typedef struct PSI_stage_info_none PSI_metadata_locker; #endif /* HAVE_PSI_INTERFACE */ -extern MYSQL_PLUGIN_IMPORT my_bool pfs_enabled; extern MYSQL_PLUGIN_IMPORT PSI *PSI_server; /* diff --git a/include/mysql/psi/psi_abi_v1.h.pp b/include/mysql/psi/psi_abi_v1.h.pp index 3d562b794f4..ec47f0d5253 100644 --- a/include/mysql/psi/psi_abi_v1.h.pp +++ b/include/mysql/psi/psi_abi_v1.h.pp @@ -851,6 +851,5 @@ typedef struct PSI_transaction_locker_state_v1 PSI_transaction_locker_state; typedef struct PSI_socket_locker_state_v1 PSI_socket_locker_state; typedef struct PSI_sp_locker_state_v1 PSI_sp_locker_state; typedef struct PSI_metadata_locker_state_v1 PSI_metadata_locker_state; -extern MYSQL_PLUGIN_IMPORT my_bool pfs_enabled; extern MYSQL_PLUGIN_IMPORT PSI *PSI_server; C_MODE_END diff --git a/include/mysql/psi/psi_abi_v2.h.pp b/include/mysql/psi/psi_abi_v2.h.pp index 47e81a2c6bc..a670e53a8b7 100644 --- a/include/mysql/psi/psi_abi_v2.h.pp +++ b/include/mysql/psi/psi_abi_v2.h.pp @@ -275,6 +275,5 @@ typedef struct PSI_transaction_locker_state_v2 PSI_transaction_locker_state; typedef struct PSI_socket_locker_state_v2 PSI_socket_locker_state; typedef struct PSI_sp_locker_state_v2 PSI_sp_locker_state; typedef struct PSI_metadata_locker_state_v2 PSI_metadata_locker_state; -extern MYSQL_PLUGIN_IMPORT my_bool pfs_enabled; extern MYSQL_PLUGIN_IMPORT PSI *PSI_server; C_MODE_END diff --git a/include/mysql/psi/psi_base.h b/include/mysql/psi/psi_base.h index 95f8d2101f0..f365e2625ee 100644 --- a/include/mysql/psi/psi_base.h +++ b/include/mysql/psi/psi_base.h @@ -28,6 +28,10 @@ #ifndef MYSQL_PSI_BASE_H #define MYSQL_PSI_BASE_H +#ifdef EMBEDDED_LIBRARY +#define DISABLE_ALL_PSI +#endif /* EMBEDDED_LIBRARY */ + #ifdef __cplusplus extern "C" { #endif diff --git a/include/mysql_com.h b/include/mysql_com.h index 2bfacdeec20..de9eb938f69 100644 --- a/include/mysql_com.h +++ b/include/mysql_com.h @@ -25,8 +25,10 @@ #define HOSTNAME_LENGTH 60 #define SYSTEM_CHARSET_MBMAXLEN 3 -#define NAME_CHAR_LEN 64U /* Field/table name length */ -#define USERNAME_CHAR_LENGTH 128U +#define NAME_CHAR_LEN 64 /* Field/table name length */ +#define USERNAME_CHAR_LENGTH 128 +#define USERNAME_CHAR_LENGTH_STR STRINGIFY_ARG(USERNAME_CHAR_LENGTH) + #define NAME_LEN (NAME_CHAR_LEN*SYSTEM_CHARSET_MBMAXLEN) #define USERNAME_LENGTH (USERNAME_CHAR_LENGTH*SYSTEM_CHARSET_MBMAXLEN) #define DEFINER_CHAR_LENGTH (USERNAME_CHAR_LENGTH + HOSTNAME_LENGTH + 1) diff --git a/include/pfs_file_provider.h b/include/pfs_file_provider.h index eae10e9c39e..3df999894fd 100644 --- a/include/pfs_file_provider.h +++ b/include/pfs_file_provider.h @@ -78,6 +78,9 @@ void pfs_start_file_close_wait_v1(PSI_file_locker *locker, void pfs_end_file_close_wait_v1(PSI_file_locker *locker, int rc); +void pfs_end_file_rename_wait_v1(PSI_file_locker *locker, const char *old_name, + const char *new_name, int rc); + C_MODE_END #endif /* EMBEDDED_LIBRARY */ diff --git a/mysql-test/include/default_mysqld.cnf b/mysql-test/include/default_mysqld.cnf index e85f3ffbde3..cccf72591cc 100644 --- a/mysql-test/include/default_mysqld.cnf +++ b/mysql-test/include/default_mysqld.cnf @@ -76,7 +76,13 @@ loose-performance-schema-max-cond-instances=1000 loose-performance-schema-max-file-instances=10000 loose-performance-schema-max-socket-instances=1000 loose-performance-schema-max-table-instances=500 +loose-performance-schema-max-table-lock-stat=500 +loose-performance-schema-max-index-stat=5000 loose-performance-schema-max-table-handles=1000 +loose-performance-schema-max-prepared-statements-instances=100 +loose-performance-schema-max-program-instances=5000 +loose-performance-schema-setup-actors-size=100 +loose-performance-schema-setup-objects-size=100 loose-performance-schema-events-waits-history-size=10 loose-performance-schema-events-waits-history-long-size=10000 @@ -84,8 +90,11 @@ loose-performance-schema-events-stages-history-size=10 loose-performance-schema-events-stages-history-long-size=1000 loose-performance-schema-events-statements-history-size=10 loose-performance-schema-events-statements-history-long-size=1000 +loose-performance-schema-events-transactions-history-size=10 +loose-performance-schema-events-transactions-history-long-size=1000 loose-performance-schema-max-thread-instances=200 loose-performance-schema-session-connect-attrs-size=2048 +loose-performance-schema-max-metadata-locks=10000 # Enable everything, for maximun code exposure during testing @@ -97,6 +106,9 @@ loose-performance-schema-consumer-events-stages-history-long=ON loose-performance-schema-consumer-events-statements-current=ON loose-performance-schema-consumer-events-statements-history=ON loose-performance-schema-consumer-events-statements-history-long=ON +loose-performance-schema-consumer-events-transactions-current=ON +loose-performance-schema-consumer-events-transactions-history=ON +loose-performance-schema-consumer-events-transactions-history-long=ON loose-performance-schema-consumer-events-waits-current=ON loose-performance-schema-consumer-events-waits-history=ON loose-performance-schema-consumer-events-waits-history-long=ON diff --git a/mysql-test/include/wait_for_sql_thread_read_all.inc b/mysql-test/include/wait_for_sql_thread_read_all.inc index ec5ecd0cb17..1bbb006f3a8 100644 --- a/mysql-test/include/wait_for_sql_thread_read_all.inc +++ b/mysql-test/include/wait_for_sql_thread_read_all.inc @@ -1,6 +1,6 @@ --let $show_statement = show all slaves status --let $field = Slave_SQL_State ---let $condition = = 'Slave has read all relay log; waiting for the slave I/O thread to update it' +--let $condition = = 'Slave has read all relay log; waiting for more updates' --let $wait_for_all = 1 --source include/wait_show_condition.inc diff --git a/mysql-test/main/mysqld--help.result b/mysql-test/main/mysqld--help.result index 20f40b94337..9c9b62662db 100644 --- a/mysql-test/main/mysqld--help.result +++ b/mysql-test/main/mysqld--help.result @@ -756,13 +756,21 @@ The following specify which files/extra groups are read (specified before remain --performance-schema-consumer-events-statements-current Default startup value for the events_statements_current consumer. - (Defaults to on; use --skip-performance-schema-consumer-events-statements-current to disable.) --performance-schema-consumer-events-statements-history Default startup value for the events_statements_history consumer. --performance-schema-consumer-events-statements-history-long Default startup value for the events_statements_history_long consumer. + --performance-schema-consumer-events-transactions-current + Default startup value for the events_transactions_current + consumer. + --performance-schema-consumer-events-transactions-history + Default startup value for the events_transactions_history + consumer. + --performance-schema-consumer-events-transactions-history-long + Default startup value for the + events_transactions_history_long consumer. --performance-schema-consumer-events-waits-current Default startup value for the events_waits_current consumer. @@ -798,6 +806,12 @@ The following specify which files/extra groups are read (specified before remain --performance-schema-events-statements-history-size=# Number of rows per thread in EVENTS_STATEMENTS_HISTORY. Use 0 to disable, -1 for automated sizing. + --performance-schema-events-transactions-history-long-size=# + Number of rows in EVENTS_TRANSACTIONS_HISTORY_LONG. Use 0 + to disable, -1 for automated sizing. + --performance-schema-events-transactions-history-size=# + Number of rows per thread in EVENTS_TRANSACTIONS_HISTORY. + Use 0 to disable, -1 for automated sizing. --performance-schema-events-waits-history-long-size=# Number of rows in EVENTS_WAITS_HISTORY_LONG. Use 0 to disable, -1 for automated sizing. @@ -825,11 +839,25 @@ The following specify which files/extra groups are read (specified before remain --performance-schema-max-file-instances=# Maximum number of instrumented files. Use 0 to disable, -1 for automated sizing. + --performance-schema-max-index-stat=# + Maximum number of index statistics for instrumented + tables. Use 0 to disable, -1 for automated scaling. + --performance-schema-max-memory-classes=# + Maximum number of memory pool instruments. + --performance-schema-max-metadata-locks=# + Maximum number of metadata locks. Use 0 to disable, -1 + for automated scaling. --performance-schema-max-mutex-classes=# Maximum number of mutex instruments. --performance-schema-max-mutex-instances=# Maximum number of instrumented MUTEX objects. Use 0 to disable, -1 for automated sizing. + --performance-schema-max-prepared-statements-instances=# + Maximum number of instrumented prepared statements. Use 0 + to disable, -1 for automated scaling. + --performance-schema-max-program-instances=# + Maximum number of instrumented programs. Use 0 to + disable, -1 for automated scaling. --performance-schema-max-rwlock-classes=# Maximum number of rwlock instruments. --performance-schema-max-rwlock-instances=# @@ -840,16 +868,23 @@ The following specify which files/extra groups are read (specified before remain --performance-schema-max-socket-instances=# Maximum number of opened instrumented sockets. Use 0 to disable, -1 for automated sizing. + --performance-schema-max-sql-text-length=# + Maximum length of displayed sql text. --performance-schema-max-stage-classes=# Maximum number of stage instruments. --performance-schema-max-statement-classes=# Maximum number of statement instruments. + --performance-schema-max-statement-stack=# + Number of rows per thread in EVENTS_STATEMENTS_CURRENT. --performance-schema-max-table-handles=# Maximum number of opened instrumented tables. Use 0 to disable, -1 for automated sizing. --performance-schema-max-table-instances=# Maximum number of instrumented tables. Use 0 to disable, -1 for automated sizing. + --performance-schema-max-table-lock-stat=# + Maximum number of lock statistics for instrumented + tables. Use 0 to disable, -1 for automated scaling. --performance-schema-max-thread-classes=# Maximum number of thread instruments. --performance-schema-max-thread-instances=# @@ -1613,9 +1648,12 @@ performance-schema-accounts-size -1 performance-schema-consumer-events-stages-current FALSE performance-schema-consumer-events-stages-history FALSE performance-schema-consumer-events-stages-history-long FALSE -performance-schema-consumer-events-statements-current TRUE +performance-schema-consumer-events-statements-current FALSE performance-schema-consumer-events-statements-history FALSE performance-schema-consumer-events-statements-history-long FALSE +performance-schema-consumer-events-transactions-current FALSE +performance-schema-consumer-events-transactions-history FALSE +performance-schema-consumer-events-transactions-history-long FALSE performance-schema-consumer-events-waits-current FALSE performance-schema-consumer-events-waits-history FALSE performance-schema-consumer-events-waits-history-long FALSE @@ -1627,6 +1665,8 @@ performance-schema-events-stages-history-long-size -1 performance-schema-events-stages-history-size -1 performance-schema-events-statements-history-long-size -1 performance-schema-events-statements-history-size -1 +performance-schema-events-transactions-history-long-size -1 +performance-schema-events-transactions-history-size -1 performance-schema-events-waits-history-long-size -1 performance-schema-events-waits-history-size -1 performance-schema-hosts-size -1 @@ -1634,24 +1674,32 @@ performance-schema-instrument performance-schema-max-cond-classes 90 performance-schema-max-cond-instances -1 performance-schema-max-digest-length 1024 -performance-schema-max-file-classes 50 +performance-schema-max-file-classes 80 performance-schema-max-file-handles 32768 performance-schema-max-file-instances -1 -performance-schema-max-mutex-classes 200 +performance-schema-max-index-stat -1 +performance-schema-max-memory-classes 320 +performance-schema-max-metadata-locks -1 +performance-schema-max-mutex-classes 210 performance-schema-max-mutex-instances -1 -performance-schema-max-rwlock-classes 40 +performance-schema-max-prepared-statements-instances -1 +performance-schema-max-program-instances -1 +performance-schema-max-rwlock-classes 50 performance-schema-max-rwlock-instances -1 performance-schema-max-socket-classes 10 performance-schema-max-socket-instances -1 +performance-schema-max-sql-text-length 1024 performance-schema-max-stage-classes 160 -performance-schema-max-statement-classes 202 +performance-schema-max-statement-classes 222 +performance-schema-max-statement-stack 10 performance-schema-max-table-handles -1 performance-schema-max-table-instances -1 +performance-schema-max-table-lock-stat -1 performance-schema-max-thread-classes 50 performance-schema-max-thread-instances -1 performance-schema-session-connect-attrs-size -1 -performance-schema-setup-actors-size 100 -performance-schema-setup-objects-size 100 +performance-schema-setup-actors-size -1 +performance-schema-setup-objects-size -1 performance-schema-users-size -1 port 3306 port-open-timeout 0 diff --git a/mysql-test/suite/funcs_1/r/processlist_priv_no_prot.result b/mysql-test/suite/funcs_1/r/processlist_priv_no_prot.result index f3f561fd479..c3fbc3a9137 100644 --- a/mysql-test/suite/funcs_1/r/processlist_priv_no_prot.result +++ b/mysql-test/suite/funcs_1/r/processlist_priv_no_prot.result @@ -45,7 +45,7 @@ PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( ) DEFAULT CHARSET=utf8 SHOW processlist; Id User Host db Command Time State Info Progress -ID root HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID root HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS SELECT * FROM processlist ORDER BY id; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID @@ -125,7 +125,7 @@ PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( ) DEFAULT CHARSET=utf8 SHOW processlist; Id User Host db Command Time State Info Progress -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM processlist ORDER BY id; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM processlist ORDER BY id TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM processlist ORDER BY id TID @@ -190,7 +190,7 @@ Grants for ddicttestuser1@localhost GRANT PROCESS ON *.* TO `ddicttestuser1`@`localhost` IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' SHOW processlist; Id User Host db Command Time State Info Progress -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -206,7 +206,7 @@ SHOW processlist; Id User Host db Command Time State Info Progress ID root HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -233,7 +233,7 @@ Id User Host db Command Time State Info Progress ID root HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -259,7 +259,7 @@ SHOW processlist; Id User Host db Command Time State Info Progress ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -303,7 +303,7 @@ Id User Host db Command Time State Info Progress ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -331,7 +331,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -390,7 +390,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser2 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser2 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser2 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -421,7 +421,7 @@ GRANT USAGE ON *.* TO `ddicttestuser2`@`localhost` IDENTIFIED BY PASSWORD '*22DA SHOW processlist; Id User Host db Command Time State Info Progress ID ddicttestuser2 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser2 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser2 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser2 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -452,7 +452,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -490,7 +490,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Query TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID diff --git a/mysql-test/suite/funcs_1/r/processlist_priv_ps.result b/mysql-test/suite/funcs_1/r/processlist_priv_ps.result index a68e62e4642..c23665cb2de 100644 --- a/mysql-test/suite/funcs_1/r/processlist_priv_ps.result +++ b/mysql-test/suite/funcs_1/r/processlist_priv_ps.result @@ -45,7 +45,7 @@ PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( ) DEFAULT CHARSET=utf8 SHOW processlist; Id User Host db Command Time State Info Progress -ID root HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID root HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS SELECT * FROM processlist ORDER BY id; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID @@ -125,7 +125,7 @@ PROCESSLIST CREATE TEMPORARY TABLE `PROCESSLIST` ( ) DEFAULT CHARSET=utf8 SHOW processlist; Id User Host db Command Time State Info Progress -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM processlist ORDER BY id; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM processlist ORDER BY id TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM processlist ORDER BY id TID @@ -190,7 +190,7 @@ Grants for ddicttestuser1@localhost GRANT PROCESS ON *.* TO `ddicttestuser1`@`localhost` IDENTIFIED BY PASSWORD '*22DA61451703738F203CDB9DB041ACBA1F4760B1' SHOW processlist; Id User Host db Command Time State Info Progress -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -206,7 +206,7 @@ SHOW processlist; Id User Host db Command Time State Info Progress ID root HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -233,7 +233,7 @@ Id User Host db Command Time State Info Progress ID root HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -259,7 +259,7 @@ SHOW processlist; Id User Host db Command Time State Info Progress ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -303,7 +303,7 @@ Id User Host db Command Time State Info Progress ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -331,7 +331,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -390,7 +390,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser2 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser2 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser2 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -421,7 +421,7 @@ GRANT USAGE ON *.* TO `ddicttestuser2`@`localhost` IDENTIFIED BY PASSWORD '*22DA SHOW processlist; Id User Host db Command Time State Info Progress ID ddicttestuser2 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser2 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser2 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser2 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -452,7 +452,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID @@ -490,7 +490,7 @@ ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS ID ddicttestuser1 HOST_NAME information_schema Sleep TIME NULL TIME_MS -ID ddicttestuser1 HOST_NAME information_schema Query TIME Init SHOW processlist TIME_MS +ID ddicttestuser1 HOST_NAME information_schema Query TIME starting SHOW processlist TIME_MS SELECT * FROM information_schema.processlist; ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_USED MAX_MEMORY_USED EXAMINED_ROWS QUERY_ID INFO_BINARY TID ID ddicttestuser1 HOST_NAME information_schema Execute TIME Filling schema table SELECT * FROM information_schema.processlist TIME_MS 0 0 0.000 MEMORY MAX_MEMORY ROWS QUERY_ID SELECT * FROM information_schema.processlist TID diff --git a/mysql-test/suite/funcs_1/r/processlist_val_no_prot.result b/mysql-test/suite/funcs_1/r/processlist_val_no_prot.result index ad109501f98..f99edef092f 100644 --- a/mysql-test/suite/funcs_1/r/processlist_val_no_prot.result +++ b/mysql-test/suite/funcs_1/r/processlist_val_no_prot.result @@ -39,7 +39,7 @@ ID USER HOST DB COMMAND TIME STATE INFO TIME_MS STAGE MAX_STAGE PROGRESS MEMORY_ root test Query