load_frozen_forks() finds new slots to process by creating new Banks for
the children of the current slot in process_next_slots(). Prior to this
change, we would then immediately check if we had reached the
halt_at_slot and correctly halt processing when appropriate. As such, it
would be possible for Banks to be created for slots beyond the
halt_at_slot.
While a potential child slot that is past halt_at_slot wouldn't be
replayed, the Bank being created still alters some universal state in
AccountsDb. So, this change moves the halt_at_slot check before we
create children Banks in process_next_slots().
* Moves CachedExecutors, related structs, consts and tests into the program-runtime crate.
* Moves TransactionExecutor, related enum and type defs into executor_cache mod.
#### Summary of Changes
This PR makes two FIFO-related validator arguments public:
--rocksdb_shred_compaction and --rocksdb_fifo_shred_storage_size.
#### Test Plan
* There're already ~26 validators running FIFO in mainnet-beta for more than 30 days,
no issues were reported so far.
* Ran a validator with FIFO for days and observed it's able to consistently catch up
and create new roots.
* Use infallible, unchecked methods to write into the serialization buffer
We serialize in two steps: first we compute the size of the buffer, then
we write into it. Therefore there's no need to check if each individual
write fits the buffer - we know it does we just computed the required
size.
* serialize_parameters: remove extra loop/borrows
Remove one extra loop over accounts to gather account lengths. Also
gather all accounts at once and avoid temporary borrows.
* Move creating MemoryRegions for serialized parameters from create_vm to serialize_parameters
This is in preparation of using multiple MemoryRegions once we land direct account mapping.
* bpf_loader: introduce internal API to build serialization buffer/regions
This is prep work for landing the direct_mapping feature, which maps account
data in their own memory regions.
* serialization: fix after API changes
* add epoch-boundary-stake-reward proposal
* 80 col
* clarify rewarding interval selection for skipping slots
* update proposal with reward credit based on jeff's comments
* Update docs/src/proposals/epoch-boundary-stake-reward.md
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
* Update docs/src/proposals/epoch-boundary-stake-reward.md
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
* rename
* update proposal with more feedbacks
* revise
* update with carl's feedback
* use mathmatic notation to clarify interval boundaries
* more feedbacks
* remove parenthesis
* update snapshot paragraph
* update with reward calc service
* more feedbacks
* update with more feedbacks
* more feedbacks from carllin
Co-authored-by: Trent Nelson <trent.a.b.nelson@gmail.com>
* Bumps solana_rbpf to 0.2.34
* Removes generic UserError from EbpfError.
* Uses ProgramResult for syscalls.
Removes use sites of the question_mark! macro by wrapping the call method of SyscallObjects.
* Uses InvokeContext as syscall context object directly.
* Replaces bind_syscall_context_object() by a parameter in the constructor.
* Inlines bind_syscall_context_objects() at its only call site.