PlatformLab / Homa

Low-Latency Data Center Network Transport
ISC License
195 stars 27 forks source link

Sender::sendMessage() incorrectly sets DataHeader::unscheduledIndexLimit #7

Open cstlee opened 4 years ago

cstlee commented 4 years ago

The documentation states that the DataHeader::unscheduledIndexLimit is the number of packets that "will be sent" without a grant. However, Sender::sendMessage() sets this value to be the max number of packets that "might" be sent. This mismatch can lead the Receiver to expect more unscheduled packets than there are packets in the message which in turn may cause RESEND requests for nonexistent packets. The current implementation ignores these "inconsistent" RESEND request with a warning message and thus the issue doesn't result in an application visible error.

The implementation should be fixed so that both the Sender and Receiver use a consistent definition of unscheduledIndexLimit.