Design a round-robin arbiter to ensure that each request has an equal chance of being granted access to shared resources
-
In this design of the round-robin arbiter, two fixed priority arbiters are utilized to manage requests for a shared resource.
-
The first arbiter, the unmasked arbiter, processes the original request. The second arbiter, the masked arbiter, processes the request ANDed with a mask.
-
The masked arbiter takes priority over the unmasked one. If there is no masked request, the unmasked arbiter's result is used.
-
However, if there is a masked request, the masked arbiter's result takes precedence. The mask determines which request has priority.
-
The maskedRequest ensures that only requests with priority (i.e., those with a set mask bit) are processed by the masked arbiter.
-
The grant output checks whether the maskedRequest expression is 0. If it is, the unmasked arbiter's result is used.
-
The mask update ensures that requests are processed in a circular fashion, promoting statistical fairness and preventing starvation.
-
When the N-th bit is granted, the subsequent bits above N must have priority in the next cycle. That is, the MSB:N+1 bits are set to 1, while the remaining bits are set to 0. For example, if the grant vector is 00001000, the mask will be 11110000 in the next cycle.
-
Requests in the MSB 4 bits are granted access, but if there are no requests in these bits, the unmasked arbiter's result is used. If no grant occurs during the cycle, the mask remains unchanged.
Distributed under the MIT License. See LICENSE
for more information.
吳華楨 Trista Wu - [email protected]
Project Link: https://github.com/trista-csee/Round_Robin_Arbiter