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
d7cbb0f9
Commit
d7cbb0f9
authored
Apr 17, 2013
by
Leif Walsh
Committed by
Yoni Fogel
Apr 17, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
refs #5386 add comments
git-svn-id:
file:///svn/toku/tokudb@46954
c7de825b-a66e-492c-adef-691d508d4ae1
parent
735ecd21
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
ft/cachetable.cc
ft/cachetable.cc
+6
-4
No files found.
ft/cachetable.cc
View file @
d7cbb0f9
...
...
@@ -1397,7 +1397,8 @@ static void checkpoint_pair_and_dependent_pairs(
// on output, the pair's mutex is not held.
// if true, we must try again, and pair is not pinned
// if false, we succeeded, the pair is pinned
// NOTE: On entry and exit, the read list lock is held.
// NOTE: On entry, the read list lock may be held (and have_read_list_lock must be set accordingly).
// On exit, the read list lock is held.
static
bool
try_pin_pair
(
PAIR
p
,
CACHETABLE
ct
,
...
...
@@ -1426,6 +1427,7 @@ static bool try_pin_pair(
nb_mutex_lock
(
&
p
->
value_nb_mutex
,
&
p
->
mutex
);
pair_touch
(
p
);
pair_unlock
(
p
);
// reacquire the read list lock here, we hold it for the rest of the function.
if
(
reacquire_lock
)
{
ct
->
list
.
read_list_lock
();
}
...
...
@@ -1542,8 +1544,8 @@ int toku_cachetable_get_and_pin_with_dep_pairs_batched (
PAIR
p
=
ct
->
list
.
find_pair
(
cachefile
,
key
,
fullhash
);
if
(
p
)
{
pair_lock
(
p
);
// on entry, holds p->mutex
,
// on exit, does not hold p->mutex
// on entry, holds p->mutex
and read list lock
// on exit, does not hold p->mutex
, holds read list lock
bool
try_again
=
try_pin_pair
(
p
,
ct
,
...
...
@@ -1585,7 +1587,7 @@ int toku_cachetable_get_and_pin_with_dep_pairs_batched (
// we will gain the read_list_lock again before exiting try_pin_pair
// on entry, holds p->mutex,
// on exit, does not hold p->mutex
// on exit, does not hold p->mutex
, holds read list lock
bool
try_again
=
try_pin_pair
(
p
,
ct
,
...
...
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