solana-with-rpc-optimizations/ledger
behzad nouri 484ead01ed
optimizes and simplifies SlotMeta::completed_data_indexes ops (#21059)
SlotMeta::completed_data_indexes is defined as a Vec<u32>:
https://github.com/solana-labs/solana/blob/a8d78e89d/ledger/src/blockstore_meta.rs#L31-L32

which results in inefficient updates:
https://github.com/solana-labs/solana/blob/a8d78e89d/ledger/src/blockstore.rs#L3245-L3326

This commit changes the type to BTreeSet<u32> for efficient and simpler
updates and lookups.

The change should be backward compatible because Vec<T> and BTreeSet<T>
are both serialized as seq:
https://github.com/serde-rs/serde/blob/ce0844b9e/serde/src/ser/impls.rs#L207-L208
https://github.com/serde-rs/serde/blob/ce0844b9e/serde/src/ser/impls.rs#L216-L217
2021-10-31 12:56:25 +00:00
..
benches Refactor code to get block signatures in get_confirmed_signatures_for_address2 (#20575) 2021-10-13 09:55:19 +02:00
src optimizes and simplifies SlotMeta::completed_data_indexes ops (#21059) 2021-10-31 12:56:25 +00:00
tests Blockstore test cleanup (#19656) 2021-09-10 07:33:08 -05:00
.gitignore
Cargo.toml chore: bump tonic from 0.5.2 to 0.6.1 (#21035) 2021-10-28 06:59:36 +00:00
build.rs adds crds-value for broadcasting duplicate shreds through gossip (#14133) 2020-12-18 14:32:43 +00:00