test-validator: Add --max-compute-units flag (#24130)

* test-validator: Add `--max-compute-units` flag

* Add `RuntimeConfig` for tweaking runtime behavior

* Actually add the file

* Move RuntimeConfig to runtime
This commit is contained in:
Jon Cinque
2022-04-12 02:28:10 +02:00
committed by GitHub
parent 4fd184c131
commit 9b8850f99e
12 changed files with 106 additions and 29 deletions

View File

@ -44,6 +44,7 @@ mod pubkey_bins;
mod read_only_accounts_cache;
pub mod rent_collector;
mod rolling_bit_field;
pub mod runtime_config;
pub mod secondary_index;
pub mod serde_snapshot;
mod shared_buffer_reader;

View File

@ -0,0 +1,9 @@
use {solana_program_runtime::compute_budget::ComputeBudget, solana_sdk::clock::Slot};
/// Encapsulates flags that can be used to tweak the runtime behavior.
#[derive(Default, Clone)]
pub struct RuntimeConfig {
pub bpf_jit: bool,
pub dev_halt_at_slot: Option<Slot>,
pub compute_budget: Option<ComputeBudget>,
}