Switch programs activation to whole-set based gating (#11750)

* Implement Debug for MessageProcessor

* Switch from delta-based gating to whole-set gating

* Remove dbg!

* Fix clippy

* Clippy

* Add test

* add loader to stable operating mode at proper epoch

* refresh_programs_and_inflation after ancestor setup

* Callback via snapshot; avoid account re-add; Debug

* Fix test

* Fix test and fix the past history

* Make callback management stricter and cleaner

* Fix test

* Test overwrite and frozen for native programs

* Test epoch callback with genesis-programs

* Add assertions for parent bank

* Add tests and some minor cleaning

* Remove unsteady assertion...

* Fix test...

* Fix DOS

* Skip ensuring account by dual (whole/delta) gating

* Fix frozen abi implementation...

* Move compute budget constatnt init back into bank

Co-authored-by: Ryo Onodera <ryoqun@gmail.com>
This commit is contained in:
Jack May
2020-08-25 09:49:15 -07:00
committed by GitHub
parent 2c5366f259
commit db4bbb3569
10 changed files with 761 additions and 176 deletions

View File

@ -172,8 +172,9 @@ impl LocalCluster {
match genesis_config.operating_mode {
OperatingMode::Stable | OperatingMode::Preview => {
genesis_config.native_instruction_processors =
solana_genesis_programs::get_native_programs(genesis_config.operating_mode, 0)
.unwrap_or_default()
solana_genesis_programs::get_native_programs_for_genesis(
genesis_config.operating_mode,
)
}
_ => (),
}