feat: a repaired hole keeps a fainter band, so a report is not a false accusation
This commit is contained in:
1 parent
4666b807fc
commit
3859d2ca79
5 files changed
+48
-11
No files matched your search
+8
-2
@@ -875,8 +875,8 @@ void Acquisition::backfill_from(const udps_frame_t* frame, const Partition& part
|
||||
// and resequencing are one design. A stamp could not answer it -- the packet's own stamps
|
||||
// are a claim about a timeline the ring has moved past -- but the counter indexes the
|
||||
// reservation table directly.
|
||||
const Hole* hole = nullptr;
|
||||
for (const Hole& h : model_.holes()) {
|
||||
Hole* hole = nullptr;
|
||||
for (Hole& h : model_.holes()) {
|
||||
if (frame->counter >= h.counter_first && frame->counter < h.counter_first + h.packets) {
|
||||
hole = &h;
|
||||
break;
|
||||
@@ -928,6 +928,12 @@ void Acquisition::backfill_from(const udps_frame_t* frame, const Partition& part
|
||||
}
|
||||
}
|
||||
}
|
||||
// This packet's share of the hole has been delivered, whatever the ring still retains of it.
|
||||
// Marked on *arrival* and not on `filled`: a decimation coarse enough that no whole slot lies
|
||||
// inside one packet repairs no slot at all, and keying off `filled` would leave such a hole
|
||||
// permanently unrepairable -- a solid band over data that is all there, which is the exact
|
||||
// defect this task closes.
|
||||
++hole->filled_packets;
|
||||
model_.stats().backfilled.fetch_add(filled, std::memory_order_relaxed);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user