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
16b2b1ea
Commit
16b2b1ea
authored
Apr 08, 2017
by
Marko Mäkelä
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use page_is_leaf() where applicable
parent
ea414622
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
8 additions
and
8 deletions
+8
-8
storage/innobase/btr/btr0btr.cc
storage/innobase/btr/btr0btr.cc
+1
-1
storage/innobase/btr/btr0defragment.cc
storage/innobase/btr/btr0defragment.cc
+1
-1
storage/innobase/dict/dict0stats.cc
storage/innobase/dict/dict0stats.cc
+2
-2
storage/xtradb/btr/btr0btr.cc
storage/xtradb/btr/btr0btr.cc
+1
-1
storage/xtradb/btr/btr0defragment.cc
storage/xtradb/btr/btr0defragment.cc
+1
-1
storage/xtradb/dict/dict0stats.cc
storage/xtradb/dict/dict0stats.cc
+2
-2
No files found.
storage/innobase/btr/btr0btr.cc
View file @
16b2b1ea
...
@@ -3241,7 +3241,7 @@ btr_page_split_and_insert(
...
@@ -3241,7 +3241,7 @@ btr_page_split_and_insert(
btr_page_create
(
new_block
,
new_page_zip
,
cursor
->
index
,
btr_page_create
(
new_block
,
new_page_zip
,
cursor
->
index
,
btr_page_get_level
(
page
,
mtr
),
mtr
);
btr_page_get_level
(
page
,
mtr
),
mtr
);
/* Only record the leaf level page splits. */
/* Only record the leaf level page splits. */
if
(
btr_page_get_level
(
page
,
mtr
)
==
0
)
{
if
(
page_is_leaf
(
page
)
)
{
cursor
->
index
->
stat_defrag_n_page_split
++
;
cursor
->
index
->
stat_defrag_n_page_split
++
;
cursor
->
index
->
stat_defrag_modified_counter
++
;
cursor
->
index
->
stat_defrag_modified_counter
++
;
btr_defragment_save_defrag_stats_if_needed
(
cursor
->
index
);
btr_defragment_save_defrag_stats_if_needed
(
cursor
->
index
);
...
...
storage/innobase/btr/btr0defragment.cc
View file @
16b2b1ea
...
@@ -233,7 +233,7 @@ btr_defragment_add_index(
...
@@ -233,7 +233,7 @@ btr_defragment_add_index(
return
NULL
;
return
NULL
;
}
}
if
(
btr_page_get_level
(
page
,
&
mtr
)
==
0
)
{
if
(
page_is_leaf
(
page
)
)
{
// Index root is a leaf page, no need to defragment.
// Index root is a leaf page, no need to defragment.
mtr_commit
(
&
mtr
);
mtr_commit
(
&
mtr
);
return
NULL
;
return
NULL
;
...
...
storage/innobase/dict/dict0stats.cc
View file @
16b2b1ea
...
@@ -1576,7 +1576,7 @@ dict_stats_analyze_index_below_cur(
...
@@ -1576,7 +1576,7 @@ dict_stats_analyze_index_below_cur(
page
=
buf_block_get_frame
(
block
);
page
=
buf_block_get_frame
(
block
);
if
(
btr_page_get_level
(
page
,
mtr
)
==
0
)
{
if
(
page_is_leaf
(
page
)
)
{
/* leaf level */
/* leaf level */
break
;
break
;
}
}
...
@@ -1620,7 +1620,7 @@ dict_stats_analyze_index_below_cur(
...
@@ -1620,7 +1620,7 @@ dict_stats_analyze_index_below_cur(
}
}
/* make sure we got a leaf page as a result from the above loop */
/* make sure we got a leaf page as a result from the above loop */
ut_ad
(
btr_page_get_level
(
page
,
&
mtr
)
==
0
);
ut_ad
(
page_is_leaf
(
page
)
);
/* scan the leaf page and find the number of distinct keys,
/* scan the leaf page and find the number of distinct keys,
when looking only at the first n_prefix columns; also estimate
when looking only at the first n_prefix columns; also estimate
...
...
storage/xtradb/btr/btr0btr.cc
View file @
16b2b1ea
...
@@ -3277,7 +3277,7 @@ btr_page_split_and_insert(
...
@@ -3277,7 +3277,7 @@ btr_page_split_and_insert(
btr_page_create
(
new_block
,
new_page_zip
,
cursor
->
index
,
btr_page_create
(
new_block
,
new_page_zip
,
cursor
->
index
,
btr_page_get_level
(
page
,
mtr
),
mtr
);
btr_page_get_level
(
page
,
mtr
),
mtr
);
/* Only record the leaf level page splits. */
/* Only record the leaf level page splits. */
if
(
btr_page_get_level
(
page
,
mtr
)
==
0
)
{
if
(
page_is_leaf
(
page
)
)
{
cursor
->
index
->
stat_defrag_n_page_split
++
;
cursor
->
index
->
stat_defrag_n_page_split
++
;
cursor
->
index
->
stat_defrag_modified_counter
++
;
cursor
->
index
->
stat_defrag_modified_counter
++
;
btr_defragment_save_defrag_stats_if_needed
(
cursor
->
index
);
btr_defragment_save_defrag_stats_if_needed
(
cursor
->
index
);
...
...
storage/xtradb/btr/btr0defragment.cc
View file @
16b2b1ea
...
@@ -233,7 +233,7 @@ btr_defragment_add_index(
...
@@ -233,7 +233,7 @@ btr_defragment_add_index(
return
NULL
;
return
NULL
;
}
}
if
(
btr_page_get_level
(
page
,
&
mtr
)
==
0
)
{
if
(
page_is_leaf
(
page
)
)
{
// Index root is a leaf page, no need to defragment.
// Index root is a leaf page, no need to defragment.
mtr_commit
(
&
mtr
);
mtr_commit
(
&
mtr
);
return
NULL
;
return
NULL
;
...
...
storage/xtradb/dict/dict0stats.cc
View file @
16b2b1ea
...
@@ -1576,7 +1576,7 @@ dict_stats_analyze_index_below_cur(
...
@@ -1576,7 +1576,7 @@ dict_stats_analyze_index_below_cur(
page
=
buf_block_get_frame
(
block
);
page
=
buf_block_get_frame
(
block
);
if
(
btr_page_get_level
(
page
,
mtr
)
==
0
)
{
if
(
page_is_leaf
(
page
)
)
{
/* leaf level */
/* leaf level */
break
;
break
;
}
}
...
@@ -1620,7 +1620,7 @@ dict_stats_analyze_index_below_cur(
...
@@ -1620,7 +1620,7 @@ dict_stats_analyze_index_below_cur(
}
}
/* make sure we got a leaf page as a result from the above loop */
/* make sure we got a leaf page as a result from the above loop */
ut_ad
(
btr_page_get_level
(
page
,
&
mtr
)
==
0
);
ut_ad
(
page_is_leaf
(
page
)
);
/* scan the leaf page and find the number of distinct keys,
/* scan the leaf page and find the number of distinct keys,
when looking only at the first n_prefix columns; also estimate
when looking only at the first n_prefix columns; also estimate
...
...
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