Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
6acddd53
Commit
6acddd53
authored
Mar 21, 2020
by
Sergey Vojtovich
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
global_query_id: my_atomic to Atomic_counter
parent
62687801
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
5 deletions
+4
-5
sql/mysqld.cc
sql/mysqld.cc
+1
-1
sql/mysqld.h
sql/mysqld.h
+3
-4
No files found.
sql/mysqld.cc
View file @
6acddd53
...
...
@@ -483,7 +483,7 @@ ulonglong test_flags;
ulonglong
query_cache_size
=
0
;
ulong
query_cache_limit
=
0
;
ulong
executed_events
=
0
;
query_id_t
global_query_id
;
Atomic_counter
<
query_id_t
>
global_query_id
;
ulong
aborted_threads
,
aborted_connects
,
aborted_connects_preauth
;
ulong
delayed_insert_timeout
,
delayed_insert_limit
,
delayed_queue_size
;
ulong
delayed_insert_threads
,
delayed_insert_writes
,
delayed_rows_in_use
;
...
...
sql/mysqld.h
View file @
6acddd53
...
...
@@ -23,7 +23,6 @@
#include "sql_bitmap.h"
/* Bitmap */
#include "my_decimal.h"
/* my_decimal */
#include "mysql_com.h"
/* SERVER_VERSION_LENGTH */
#include "my_atomic.h"
#include "my_counter.h"
#include "mysql/psi/mysql_file.h"
/* MYSQL_FILE */
#include "mysql/psi/mysql_socket.h"
/* MYSQL_SOCKET */
...
...
@@ -763,17 +762,17 @@ enum enum_query_type
/* query_id */
extern
query_id_t
global_query_id
;
extern
Atomic_counter
<
query_id_t
>
global_query_id
;
/* increment query_id and return it. */
inline
__attribute__
((
warn_unused_result
))
query_id_t
next_query_id
()
{
return
my_atomic_add64_explicit
(
&
global_query_id
,
1
,
MY_MEMORY_ORDER_RELAXED
)
;
return
global_query_id
++
;
}
inline
query_id_t
get_query_id
()
{
return
my_atomic_load64_explicit
(
&
global_query_id
,
MY_MEMORY_ORDER_RELAXED
)
;
return
global_query_id
;
}
/* increment global_thread_id and return it. */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment