tracks erasure coding shreds' indices explicitly (#21822)

The indices for erasure coding shreds are tied to data shreds:
https://github.com/solana-labs/solana/blob/90f41fd9b/ledger/src/shred.rs#L921

However with the upcoming changes to erasure schema, there will be more
erasure coding shreds than data shreds and we can no longer infer coding
shreds indices from data shreds.

The commit adds constructs to track coding shreds indices explicitly.
This commit is contained in:
behzad nouri
2021-12-19 22:37:55 +00:00
committed by GitHub
parent df6a4930b9
commit 65d59f4ef0
14 changed files with 253 additions and 69 deletions

View File

@ -341,6 +341,7 @@ pub(crate) mod tests {
&entries,
true, // is_last_in_slot
next_shred_index,
next_shred_index, // next_code_index
);
data_shreds.swap_remove(0)
}