Boot hashbrown (#5505)

As of Rust 1.36.0, hashbrown now implements the HashMap in std (which
implements HashSet).

https://blog.rust-lang.org/2019/07/04/Rust-1.36.0.html#a-new-hashmapk,-v%3E-implementation
This commit is contained in:
Greg Fitzgerald
2019-08-12 16:46:49 -06:00
committed by GitHub
parent 687818aad6
commit a43922ccbf
11 changed files with 5 additions and 25 deletions

View File

@ -14,7 +14,6 @@ bv = { version = "0.11.0", features = ["serde"] }
byteorder = "1.3.2"
fnv = "1.0.6"
fs_extra = "1.1.0"
hashbrown = "0.5.0"
lazy_static = "1.3.0"
libc = "0.2.61"
libloading = "0.5.2"

View File

@ -6,8 +6,7 @@ use fnv::FnvHasher;
use solana_runtime::bloom::{Bloom, BloomHashIndex};
use solana_sdk::hash::{hash, Hash};
use solana_sdk::signature::Signature;
//use std::collections::HashSet;
use hashbrown::HashSet;
use std::collections::HashSet;
use std::hash::Hasher;
use test::Bencher;

View File

@ -7,7 +7,7 @@ type ForkList<T> = Vec<(Fork, T)>;
#[derive(Debug, Default)]
pub struct AccountsIndex<T> {
pub account_maps: hashbrown::HashMap<Pubkey, RwLock<ForkList<T>>>,
pub account_maps: HashMap<Pubkey, RwLock<ForkList<T>>>,
pub roots: HashSet<Fork>,