Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
code
PMem-based Data Structures
Commits
9b603496
Commit
9b603496
authored
Nov 12, 2019
by
Philipp Götze
Browse files
⚡
Use 'drain' instead of a transaction for preparing the benchmarks
parent
50f654e6
Pipeline
#277
failed with stages
in 7 minutes and 54 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/bench/trees/tree_get.cpp
View file @
9b603496
...
...
@@ -32,13 +32,14 @@ static void BM_TreeGet(benchmark::State &state) {
pop
=
pool
<
root
>::
create
(
path
,
LAYOUT
,
POOL_SIZE
);
transaction
::
run
(
pop
,
[
&
]
{
pop
.
root
()
->
tree
=
make_persistent
<
TreeType
>
();
});
});
insert
(
pop
.
root
()
->
tree
);
}
else
{
LOG
(
"Warning: "
<<
path
<<
" already exists"
);
pop
=
pool
<
root
>::
open
(
path
,
LAYOUT
);
hybridWrapper
.
recover
(
*
pop
.
root
()
->
tree
);
}
pop
.
drain
();
const
auto
tree
=
pop
.
root
()
->
tree
;
auto
&
treeRef
=
*
tree
;
...
...
src/bench/trees/tree_insert.cpp
View file @
9b603496
...
...
@@ -46,6 +46,7 @@ static void BM_TreeInsert(benchmark::State &state) {
pop
.
root
()
->
tree
=
make_persistent
<
TreeType
>
();
});
}
pop
.
drain
();
const
auto
tree
=
pop
.
root
()
->
tree
;
auto
&
treeRef
=
*
tree
;
...
...
src/bench/trees/tree_scan.cpp
View file @
9b603496
...
...
@@ -32,15 +32,14 @@ static void BM_TreeScan(benchmark::State &state) {
pop
=
pool
<
root
>::
create
(
path
,
LAYOUT
,
POOL_SIZE
);
transaction
::
run
(
pop
,
[
&
]
{
pop
.
root
()
->
tree
=
make_persistent
<
TreeType
>
();
insert
(
pop
.
root
()
->
tree
);
});
insert
(
pop
.
root
()
->
tree
);
}
else
{
LOG
(
"Warning: "
<<
path
<<
" already exists"
);
pop
=
pool
<
root
>::
open
(
path
,
LAYOUT
);
transaction
::
run
(
pop
,
[
&
]
{
hybridWrapper
.
recover
(
*
pop
.
root
()
->
tree
);
});
hybridWrapper
.
recover
(
*
pop
.
root
()
->
tree
);
}
pop
.
drain
();
///< wait for preparations to be persistent
auto
tree
=
pop
.
root
()
->
tree
;
auto
&
treeRef
=
*
tree
;
auto
node
=
treeRef
.
rootNode
;
...
...
src/bench/trees/tree_split.cpp
View file @
9b603496
...
...
@@ -46,6 +46,7 @@ static void BM_TreeSplit(benchmark::State &state) {
pop
.
root
()
->
tree
=
make_persistent
<
TreeType
>
();
});
}
pop
.
drain
();
auto
tree
=
pop
.
root
()
->
tree
;
auto
&
treeRef
=
*
tree
;
auto
&
leaf
=
treeRef
.
rootNode
.
leaf
;
...
...
src/bench/trees/tree_traverse.cpp
View file @
9b603496
...
...
@@ -32,13 +32,14 @@ static void BM_TreeTraverse(benchmark::State &state) {
pop
=
pool
<
root
>::
create
(
path
,
LAYOUT
,
POOL_SIZE
);
transaction
::
run
(
pop
,
[
&
]
{
pop
.
root
()
->
tree
=
make_persistent
<
TreeType
>
();
});
});
insert
(
pop
.
root
()
->
tree
);
}
else
{
LOG
(
"Warning: "
<<
path
<<
" already exists"
);
pop
=
pool
<
root
>::
open
(
path
,
LAYOUT
);
hybridWrapper
.
recover
(
*
pop
.
root
()
->
tree
);
}
pop
.
drain
();
auto
tree
=
pop
.
root
()
->
tree
;
auto
&
treeRef
=
*
tree
;
...
...
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