François Garillot
|
b08cff9e77
|
Simplify some pattern-matches (#16402)
When those match an exact combinator on Option / Result.
Tool-aided by [comby-rust](https://github.com/huitseeker/comby-rust).
|
2021-04-08 12:40:37 -06:00 |
behzad nouri
|
56923c91bf
|
limits number of unique pubkeys in the crds table (#15539)
|
2021-03-10 20:46:05 +00:00 |
behzad nouri
|
5a9896706c
|
indexes epoch slots in crds table (#15459)
ClusterInfo::get_epoch_slots_since scans the entire crds table to obtain
epoch-slots inserted since a timestamp:
https://github.com/solana-labs/solana/blob/013daa8f4/core/src/cluster_info.rs#L1245-L1262
The alternative is to index epoch-slots in crds table ordered by their
insert timestamp.
|
2021-02-26 14:12:04 +00:00 |
behzad nouri
|
f79c9d4094
|
adds an upper bound on cluster-slots size (#15300)
https://github.com/solana-labs/solana/issues/14366#issuecomment-769096305
|
2021-02-16 21:12:13 +00:00 |
behzad nouri
|
2758588ddd
|
uses btree-map instead of hash-map for cluster-slots (#15194)
retain traverses all values in the hashmap which is slow:
https://github.com/solana-labs/solana/blob/88f22c360/core/src/cluster_slots.rs#L45
btree-map instead allows more efficient prunning there.
In addition there is potential race condition here:
https://github.com/solana-labs/solana/blob/88f22c360/core/src/cluster_slots.rs#L68-L74
If another thread inserts a value at the same slot key between the read
and write lock, current thread will discard the inserted value.
|
2021-02-09 22:04:41 +00:00 |
behzad nouri
|
b6f231b60e
|
removes locked pubkey references (#15152)
|
2021-02-08 02:07:00 +00:00 |
behzad nouri
|
49019c6613
|
obtains staked-nodes from the root-bank (#14257)
... as opposed to the working bank
|
2020-12-27 13:28:05 +00:00 |
behzad nouri
|
c3048b451d
|
samples repair peers using WeightedIndex (#13919)
To output one random sample, weighted_best generates n random numbers:
https://github.com/solana-labs/solana/blob/f751a5d4e/core/src/weighted_shuffle.rs#L38-L63
WeightedIndex does so with only one random number:
https://github.com/rust-random/rand/blob/eb02f0e46/src/distributions/weighted_index.rs#L223-L240
Additionally, if the index is already constructed, it only does a total
of O(log(n)) amount of work; which can be achieved if RepairCache,
caches the weighted index:
https://github.com/solana-labs/solana/blob/f751a5d4e/core/src/serve_repair.rs#L83
Also, the repair-peers code can be reorganized to have fewer redundant
unlock-then-lock code.
|
2020-12-03 14:26:07 +00:00 |
Michael Vines
|
7bc073defe
|
Run `codemod --extensions rs Pubkey::new_rand solana_sdk::pubkey::new_rand`
|
2020-10-21 19:08:13 -07:00 |
Greg Fitzgerald
|
6ee222363e
|
Move BankForks to solana_runtime (#10637)
* Move BankForks to solana_runtime
* Update imports
|
2020-06-17 15:27:03 +00:00 |
carllin
|
42aaacf520
|
Factor out LockedPubkeyReferences (#10198)
Co-authored-by: Carl <carl@solana.com>
|
2020-05-22 23:23:17 -07:00 |
Kristofer Peterson
|
58ef02f02b
|
9951 clippy errors in the test suite (#10030)
automerge
|
2020-05-15 09:35:43 -07:00 |
carllin
|
3442f36f8a
|
Repair alternate versions of dead slots (#9805)
Co-authored-by: Carl <carl@solana.com>
|
2020-05-05 14:07:21 -07:00 |
carllin
|
bab3502260
|
Push down cluster_info lock (#9594)
* Push down cluster_info lock
* Rework budget decrement
Co-authored-by: Carl <carl@solana.com>
|
2020-04-21 12:54:45 -07:00 |
carllin
|
076fef5e57
|
Update Cluster Slots to support multiple threads (#9071)
Co-authored-by: Carl <carl@solana.com>
|
2020-03-25 18:09:19 -07:00 |
anatoly yakovenko
|
9a79be5ca0
|
Use cluster information about slots to prioritize repair (#8820)
automerge
|
2020-03-12 17:34:46 -07:00 |
anatoly yakovenko
|
f64ab49307
|
Cluster has no way to know which slots are available (#8732)
automerge
|
2020-03-11 21:31:50 -07:00 |