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
d9eca0e1
Commit
d9eca0e1
authored
21 years ago
by
monty@narttu.mysql.fi
Browse files
Options
Browse Files
Download
Plain Diff
Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into narttu.mysql.fi:/my/mysql-4.1
parents
5584d422
77311570
Branches unavailable
Tags unavailable
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
3 deletions
+1
-3
include/my_pthread.h
include/my_pthread.h
+1
-3
No files found.
include/my_pthread.h
View file @
d9eca0e1
...
@@ -669,8 +669,6 @@ extern pthread_t shutdown_th, main_th, signal_th;
...
@@ -669,8 +669,6 @@ extern pthread_t shutdown_th, main_th, signal_th;
#define thread_safe_increment(V,L) atomic_add(1,(atomic_t*) &V);
#define thread_safe_increment(V,L) atomic_add(1,(atomic_t*) &V);
#define thread_safe_add(V,C,L) atomic_add((C),(atomic_t*) &V);
#define thread_safe_add(V,C,L) atomic_add((C),(atomic_t*) &V);
#define thread_safe_sub(V,C,L) atomic_sub((C),(atomic_t*) &V);
#define thread_safe_sub(V,C,L) atomic_sub((C),(atomic_t*) &V);
#define statistic_increment(V,L) thread_safe_increment((V),(L))
#define statistic_add(V,C,L) thread_safe_add((V),(C),(L))
#else
#else
#define thread_safe_increment(V,L) \
#define thread_safe_increment(V,L) \
pthread_mutex_lock((L)); (V)++; pthread_mutex_unlock((L));
pthread_mutex_lock((L)); (V)++; pthread_mutex_unlock((L));
...
@@ -678,6 +676,7 @@ extern pthread_t shutdown_th, main_th, signal_th;
...
@@ -678,6 +676,7 @@ extern pthread_t shutdown_th, main_th, signal_th;
pthread_mutex_lock((L)); (V)+=(C); pthread_mutex_unlock((L));
pthread_mutex_lock((L)); (V)+=(C); pthread_mutex_unlock((L));
#define thread_safe_sub(V,C,L) \
#define thread_safe_sub(V,C,L) \
pthread_mutex_lock((L)); (V)-=(C); pthread_mutex_unlock((L));
pthread_mutex_lock((L)); (V)-=(C); pthread_mutex_unlock((L));
#endif
/* HAVE_ATOMIC_ADD */
#ifdef SAFE_STATISTICS
#ifdef SAFE_STATISTICS
#define statistic_increment(V,L) thread_safe_increment((V),(L))
#define statistic_increment(V,L) thread_safe_increment((V),(L))
#define statistic_add(V,C,L) thread_safe_add((V),(C),(L))
#define statistic_add(V,C,L) thread_safe_add((V),(C),(L))
...
@@ -685,7 +684,6 @@ extern pthread_t shutdown_th, main_th, signal_th;
...
@@ -685,7 +684,6 @@ extern pthread_t shutdown_th, main_th, signal_th;
#define statistic_increment(V,L) (V)++
#define statistic_increment(V,L) (V)++
#define statistic_add(V,C,L) (V)+=(C)
#define statistic_add(V,C,L) (V)+=(C)
#endif
/* SAFE_STATISTICS */
#endif
/* SAFE_STATISTICS */
#endif
/* HAVE_ATOMIC_ADD */
#endif
/* thread_safe_increment */
#endif
/* thread_safe_increment */
#ifdef __cplusplus
#ifdef __cplusplus
...
...
This diff is collapsed.
Click to expand 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