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
eafc4bef
Commit
eafc4bef
authored
Dec 13, 2010
by
Sergey Petrunya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MWL#121-125 DS-MRR improvements
- Address review feedback: change return type of RANGE_SEQ_IF::next()
parent
58b64600
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
21 additions
and
24 deletions
+21
-24
sql/handler.h
sql/handler.h
+3
-3
sql/multi_range_read.cc
sql/multi_range_read.cc
+6
-9
sql/opt_range.h
sql/opt_range.h
+2
-2
sql/opt_range_mrr.cc
sql/opt_range_mrr.cc
+4
-4
sql/sql_join_cache.cc
sql/sql_join_cache.cc
+6
-6
No files found.
sql/handler.h
View file @
eafc4bef
...
...
@@ -1197,10 +1197,10 @@ typedef struct st_range_seq_if
range OUT Information about the next range
RETURN
0
- Ok, the range structure filled with info about the next range
1
- No more ranges
FALSE
- Ok, the range structure filled with info about the next range
TRUE
- No more ranges
*/
uint
(
*
next
)
(
range_seq_t
seq
,
KEY_MULTI_RANGE
*
range
);
bool
(
*
next
)
(
range_seq_t
seq
,
KEY_MULTI_RANGE
*
range
);
/*
Check whether range_info orders to skip the next record
...
...
sql/multi_range_read.cc
View file @
eafc4bef
...
...
@@ -426,17 +426,14 @@ int Mrr_ordered_index_reader::refill_buffer(bool initial)
if
(
source_exhausted
)
DBUG_RETURN
(
HA_ERR_END_OF_FILE
);
//if (know_key_tuple_params)
{
buf_manager
->
reset_buffer_sizes
(
buf_manager
->
arg
);
key_buffer
->
reset
();
key_buffer
->
setup_writing
(
&
key_ptr
,
keypar
.
key_size_in_keybuf
,
is_mrr_assoc
?
(
uchar
**
)
&
range_info_ptr
:
NULL
,
sizeof
(
uchar
*
));
}
buf_manager
->
reset_buffer_sizes
(
buf_manager
->
arg
);
key_buffer
->
reset
();
key_buffer
->
setup_writing
(
&
key_ptr
,
keypar
.
key_size_in_keybuf
,
is_mrr_assoc
?
(
uchar
**
)
&
range_info_ptr
:
NULL
,
sizeof
(
uchar
*
));
while
(
key_buffer
->
can_write
()
&&
!
(
source_exhausted
=
(
bool
)
mrr_funcs
.
next
(
mrr_iter
,
&
cur_range
)))
!
(
source_exhausted
=
mrr_funcs
.
next
(
mrr_iter
,
&
cur_range
)))
{
DBUG_ASSERT
(
cur_range
.
range_flag
&
EQ_RANGE
);
...
...
sql/opt_range.h
View file @
eafc4bef
...
...
@@ -373,7 +373,7 @@ typedef struct st_quick_range_seq_ctx
}
QUICK_RANGE_SEQ_CTX
;
range_seq_t
quick_range_seq_init
(
void
*
init_param
,
uint
n_ranges
,
uint
flags
);
uint
quick_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
);
bool
quick_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
);
/*
...
...
@@ -461,7 +461,7 @@ private:
friend
class
QUICK_INDEX_MERGE_SELECT
;
friend
class
QUICK_ROR_INTERSECT_SELECT
;
friend
class
QUICK_GROUP_MIN_MAX_SELECT
;
friend
uint
quick_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
);
friend
bool
quick_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
);
friend
range_seq_t
quick_range_seq_init
(
void
*
init_param
,
uint
n_ranges
,
uint
flags
);
};
...
...
sql/opt_range_mrr.cc
View file @
eafc4bef
...
...
@@ -116,11 +116,11 @@ static void step_down_to(SEL_ARG_RANGE_SEQ *arg, SEL_ARG *key_tree)
- max_key_part
RETURN
0
Ok
1
No more ranges in the sequence
FALSE
Ok
TRUE
No more ranges in the sequence
*/
uint
sel_arg_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
bool
sel_arg_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
{
SEL_ARG
*
key_tree
;
SEL_ARG_RANGE_SEQ
*
seq
=
(
SEL_ARG_RANGE_SEQ
*
)
rseq
;
...
...
@@ -314,7 +314,7 @@ range_seq_t quick_range_seq_init(void *init_param, uint n_ranges, uint flags)
1 No more ranges in the sequence
*/
uint
quick_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
bool
quick_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
{
QUICK_RANGE_SEQ_CTX
*
ctx
=
(
QUICK_RANGE_SEQ_CTX
*
)
rseq
;
...
...
sql/sql_join_cache.cc
View file @
eafc4bef
...
...
@@ -3655,12 +3655,12 @@ range_seq_t bka_range_seq_init(void *init_param, uint n_ranges, uint flags)
This function are used only as a callback function.
RETURN VALUE
0
ok, the range structure filled with info about the next range/key
1
no more ranges
FALSE
ok, the range structure filled with info about the next range/key
TRUE
no more ranges
*/
static
uint
bka_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
bool
bka_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
{
DBUG_ENTER
(
"bka_range_seq_next"
);
JOIN_CACHE_BKA
*
cache
=
(
JOIN_CACHE_BKA
*
)
rseq
;
...
...
@@ -4130,12 +4130,12 @@ range_seq_t bkah_range_seq_init(void *init_param, uint n_ranges, uint flags)
This function are used only as a callback function.
RETURN VALUE
0
ok, the range structure filled with info about the next range/key
1
no more ranges
FALSE
ok, the range structure filled with info about the next range/key
TRUE
no more ranges
*/
static
uint
bkah_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
bool
bkah_range_seq_next
(
range_seq_t
rseq
,
KEY_MULTI_RANGE
*
range
)
{
DBUG_ENTER
(
"bkah_range_seq_next"
);
JOIN_CACHE_BKAH
*
cache
=
(
JOIN_CACHE_BKAH
*
)
rseq
;
...
...
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