fixed trie benches
This commit is contained in:
parent
f19d044e7c
commit
45ee74868a
@ -54,7 +54,8 @@ fn trie_insertions_six_high(b: &mut Bencher) {
|
||||
|
||||
b.iter(||{
|
||||
let mut memdb = MemoryDB::new();
|
||||
let mut t = TrieDB::new(&mut memdb);
|
||||
let mut root = H256::new();
|
||||
let mut t = TrieDB::new(&mut memdb, &mut root);
|
||||
for i in d.iter() {
|
||||
t.insert(&i.0, &i.1);
|
||||
}
|
||||
@ -88,7 +89,8 @@ fn trie_insertions_six_mid(b: &mut Bencher) {
|
||||
}
|
||||
b.iter(||{
|
||||
let mut memdb = MemoryDB::new();
|
||||
let mut t = TrieDB::new(&mut memdb);
|
||||
let mut root = H256::new();
|
||||
let mut t = TrieDB::new(&mut memdb, &mut root);
|
||||
for i in d.iter() {
|
||||
t.insert(&i.0, &i.1);
|
||||
}
|
||||
@ -124,7 +126,8 @@ fn trie_insertions_random_mid(b: &mut Bencher) {
|
||||
|
||||
b.iter(||{
|
||||
let mut memdb = MemoryDB::new();
|
||||
let mut t = TrieDB::new(&mut memdb);
|
||||
let mut root = H256::new();
|
||||
let mut t = TrieDB::new(&mut memdb, &mut root);
|
||||
for i in d.iter() {
|
||||
t.insert(&i.0, &i.1);
|
||||
}
|
||||
@ -160,7 +163,8 @@ fn trie_insertions_six_low(b: &mut Bencher) {
|
||||
|
||||
b.iter(||{
|
||||
let mut memdb = MemoryDB::new();
|
||||
let mut t = TrieDB::new(&mut memdb);
|
||||
let mut root = H256::new();
|
||||
let mut t = TrieDB::new(&mut memdb, &mut root);
|
||||
for i in d.iter() {
|
||||
t.insert(&i.0, &i.1);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user