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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
b14adc39
Commit
b14adc39
authored
Mar 04, 2011
by
Mikael Ronstrom
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More review fixes
parent
5f24be65
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
19 additions
and
16 deletions
+19
-16
include/my_sys.h
include/my_sys.h
+2
-2
include/mysql/plugin_audit.h.pp
include/mysql/plugin_audit.h.pp
+2
-2
include/mysql/plugin_auth.h.pp
include/mysql/plugin_auth.h.pp
+2
-2
include/mysql/plugin_ftparser.h.pp
include/mysql/plugin_ftparser.h.pp
+2
-2
include/mysql/service_thd_wait.h
include/mysql/service_thd_wait.h
+2
-2
sql/item_func.cc
sql/item_func.cc
+4
-4
sql/mdl.cc
sql/mdl.cc
+2
-2
sql/scheduler.cc
sql/scheduler.cc
+3
-0
No files found.
include/my_sys.h
View file @
b14adc39
...
...
@@ -627,8 +627,8 @@ extern FILE *my_freopen(const char *path, const char *mode, FILE *stream);
extern
int
my_fclose
(
FILE
*
fd
,
myf
MyFlags
);
extern
File
my_fileno
(
FILE
*
fd
);
extern
int
my_chsize
(
File
fd
,
my_off_t
newlength
,
int
filler
,
myf
MyFlags
);
void
thr_set_sync_wait_callback
(
void
(
*
before_sync
)(
void
),
void
(
*
after_sync
)(
void
));
extern
void
thr_set_sync_wait_callback
(
void
(
*
before_sync
)(
void
),
void
(
*
after_sync
)(
void
));
extern
int
my_sync
(
File
fd
,
myf
my_flags
);
extern
int
my_sync_dir
(
const
char
*
dir_name
,
myf
my_flags
);
extern
int
my_sync_dir_by_file
(
const
char
*
file_name
,
myf
my_flags
);
...
...
include/mysql/plugin_audit.h.pp
View file @
b14adc39
...
...
@@ -46,10 +46,10 @@ typedef enum _thd_wait_type_e {
THD_WAIT_LAST
=
11
}
thd_wait_type
;
extern
struct
thd_wait_service_st
{
void
(
*
thd_wait_begin_func
)(
void
*
,
thd_wait_type
);
void
(
*
thd_wait_begin_func
)(
void
*
,
int
);
void
(
*
thd_wait_end_func
)(
void
*
);
}
*
thd_wait_service
;
void
thd_wait_begin
(
void
*
thd
,
thd_wait_type
wait_type
);
void
thd_wait_begin
(
void
*
thd
,
int
wait_type
);
void
thd_wait_end
(
void
*
thd
);
#include <mysql/service_thread_scheduler.h>
struct
scheduler_functions
;
...
...
include/mysql/plugin_auth.h.pp
View file @
b14adc39
...
...
@@ -46,10 +46,10 @@ typedef enum _thd_wait_type_e {
THD_WAIT_LAST
=
11
}
thd_wait_type
;
extern
struct
thd_wait_service_st
{
void
(
*
thd_wait_begin_func
)(
void
*
,
thd_wait_type
);
void
(
*
thd_wait_begin_func
)(
void
*
,
int
);
void
(
*
thd_wait_end_func
)(
void
*
);
}
*
thd_wait_service
;
void
thd_wait_begin
(
void
*
thd
,
thd_wait_type
wait_type
);
void
thd_wait_begin
(
void
*
thd
,
int
wait_type
);
void
thd_wait_end
(
void
*
thd
);
#include <mysql/service_thread_scheduler.h>
struct
scheduler_functions
;
...
...
include/mysql/plugin_ftparser.h.pp
View file @
b14adc39
...
...
@@ -46,10 +46,10 @@ typedef enum _thd_wait_type_e {
THD_WAIT_LAST
=
11
}
thd_wait_type
;
extern
struct
thd_wait_service_st
{
void
(
*
thd_wait_begin_func
)(
void
*
,
thd_wait_type
);
void
(
*
thd_wait_begin_func
)(
void
*
,
int
);
void
(
*
thd_wait_end_func
)(
void
*
);
}
*
thd_wait_service
;
void
thd_wait_begin
(
void
*
thd
,
thd_wait_type
wait_type
);
void
thd_wait_begin
(
void
*
thd
,
int
wait_type
);
void
thd_wait_end
(
void
*
thd
);
#include <mysql/service_thread_scheduler.h>
struct
scheduler_functions
;
...
...
include/mysql/service_thd_wait.h
View file @
b14adc39
...
...
@@ -78,7 +78,7 @@ typedef enum _thd_wait_type_e {
}
thd_wait_type
;
extern
struct
thd_wait_service_st
{
void
(
*
thd_wait_begin_func
)(
MYSQL_THD
,
thd_wait_type
);
void
(
*
thd_wait_begin_func
)(
MYSQL_THD
,
int
);
void
(
*
thd_wait_end_func
)(
MYSQL_THD
);
}
*
thd_wait_service
;
...
...
@@ -90,7 +90,7 @@ extern struct thd_wait_service_st {
#else
void
thd_wait_begin
(
MYSQL_THD
thd
,
thd_wait_type
wait_type
);
void
thd_wait_begin
(
MYSQL_THD
thd
,
int
wait_type
);
void
thd_wait_end
(
MYSQL_THD
thd
);
#endif
...
...
sql/item_func.cc
View file @
b14adc39
...
...
@@ -3877,12 +3877,11 @@ longlong Item_func_get_lock::val_int()
timed_cond
.
set_timeout
(
timeout
*
ULL
(
1000000000
));
error
=
0
;
thd_wait_begin
(
thd
,
THD_WAIT_USER_LOCK
);
while
(
ull
->
locked
&&
!
thd
->
killed
)
{
DBUG_PRINT
(
"info"
,
(
"waiting on lock"
));
thd_wait_begin
(
thd
,
THD_WAIT_USER_LOCK
);
error
=
timed_cond
.
wait
(
&
ull
->
cond
,
&
LOCK_user_locks
);
thd_wait_end
(
thd
);
if
(
error
==
ETIMEDOUT
||
error
==
ETIME
)
{
DBUG_PRINT
(
"info"
,
(
"lock wait timeout"
));
...
...
@@ -3890,6 +3889,7 @@ longlong Item_func_get_lock::val_int()
}
error
=
0
;
}
thd_wait_end
(
thd
);
if
(
ull
->
locked
)
{
...
...
@@ -4107,15 +4107,15 @@ longlong Item_func_sleep::val_int()
thd
->
mysys_var
->
current_cond
=
&
cond
;
error
=
0
;
thd_wait_begin
(
thd
,
THD_WAIT_SLEEP
);
while
(
!
thd
->
killed
)
{
thd_wait_begin
(
thd
,
THD_WAIT_SLEEP
);
error
=
timed_cond
.
wait
(
&
cond
,
&
LOCK_user_locks
);
thd_wait_end
(
thd
);
if
(
error
==
ETIMEDOUT
||
error
==
ETIME
)
break
;
error
=
0
;
}
thd_wait_end
(
thd
);
thd_proc_info
(
thd
,
0
);
mysql_mutex_unlock
(
&
LOCK_user_locks
);
mysql_mutex_lock
(
&
thd
->
mysys_var
->
mutex
);
...
...
sql/mdl.cc
View file @
b14adc39
...
...
@@ -975,14 +975,14 @@ MDL_wait::timed_wait(THD *thd, struct timespec *abs_timeout,
old_msg
=
thd_enter_cond
(
thd
,
&
m_COND_wait_status
,
&
m_LOCK_wait_status
,
wait_state_name
);
thd_wait_begin
(
thd
,
THD_WAIT_META_DATA_LOCK
);
while
(
!
m_wait_status
&&
!
thd_killed
(
thd
)
&&
wait_result
!=
ETIMEDOUT
&&
wait_result
!=
ETIME
)
{
thd_wait_begin
(
thd
,
THD_WAIT_META_DATA_LOCK
);
wait_result
=
mysql_cond_timedwait
(
&
m_COND_wait_status
,
&
m_LOCK_wait_status
,
abs_timeout
);
thd_wait_end
(
thd
);
}
thd_wait_end
(
thd
);
if
(
m_wait_status
==
EMPTY
)
{
...
...
sql/scheduler.cc
View file @
b14adc39
...
...
@@ -80,6 +80,8 @@ scheduler_functions *thread_scheduler= NULL;
*/
/**@{*/
extern
"C"
{
static
void
scheduler_wait_lock_begin
(
void
)
{
MYSQL_CALLBACK
(
thread_scheduler
,
thd_wait_begin
,
(
current_thd
,
THD_WAIT_TABLE_LOCK
));
...
...
@@ -97,6 +99,7 @@ static void scheduler_wait_sync_begin(void) {
static
void
scheduler_wait_sync_end
(
void
)
{
MYSQL_CALLBACK
(
thread_scheduler
,
thd_wait_end
,
(
current_thd
));
}
};
/**@}*/
/**
...
...
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