Bank::new_for_benches uses bench config (#25017)
This commit is contained in:
parent
7401bc0fa5
commit
df9a4a0c9d
|
@ -44,7 +44,7 @@ use {
|
|||
pub const ITER_BATCH_SIZE: usize = 1000;
|
||||
pub const BINS_DEFAULT: usize = 8192;
|
||||
pub const BINS_FOR_TESTING: usize = 2; // we want > 1, but each bin is a few disk files with a disk based index, so fewer is better
|
||||
pub const BINS_FOR_BENCHMARKS: usize = 2;
|
||||
pub const BINS_FOR_BENCHMARKS: usize = 8192;
|
||||
pub const FLUSH_THREADS_TESTING: usize = 1;
|
||||
pub const ACCOUNTS_INDEX_CONFIG_FOR_TESTING: AccountsIndexConfig = AccountsIndexConfig {
|
||||
bins: Some(BINS_FOR_TESTING),
|
||||
|
|
|
@ -1366,12 +1366,19 @@ impl Bank {
|
|||
}
|
||||
|
||||
pub fn new_for_benches(genesis_config: &GenesisConfig) -> Self {
|
||||
// this will diverge
|
||||
Self::new_for_tests(genesis_config)
|
||||
Self::new_with_paths_for_benches(
|
||||
genesis_config,
|
||||
Vec::new(),
|
||||
None,
|
||||
None,
|
||||
AccountSecondaryIndexes::default(),
|
||||
false,
|
||||
AccountShrinkThreshold::default(),
|
||||
false,
|
||||
)
|
||||
}
|
||||
|
||||
pub fn new_for_tests(genesis_config: &GenesisConfig) -> Self {
|
||||
// this will diverge
|
||||
Self::new_with_paths_for_tests(
|
||||
genesis_config,
|
||||
Vec::new(),
|
||||
|
|
Loading…
Reference in New Issue