Dynamic buffer management in data-driven intelligent network
Systems and methods for dynamic buffer management in switches that facilitate a data-driven intelligent networking system are provided. The system can accommodate dynamic traffic with fast, effective congestion control while providing efficient use of internal input buffer space.
1. A method for facilitating dynamic buffer management in a switch, the method comprising:
reserving a fixed space of an input buffer for each virtual channel of a physical link;
determining a virtual channel and buffer class associated with a received packet on the physical link;
determining one or more active virtual channels;
determining a virtual channel space limit in a shared space of the input buffer corresponding to the virtual channel associated with the received packet by calculating a total amount of dynamic space in the input buffer available to the active virtual channels and a percentage each of the active virtual channels is allowed to take across all possible active virtual channel combinations;
determining one or more active buffer classes;
determining a buffer class space limit in the shared space of the input buffer corresponding to the buffer class associated with the received packet by calculating a total amount of dynamic space in the input buffer available to the active buffer classes and a percentage each of the active buffer classes is allowed to take across all possible active buffer classes combinations; and
storing the received packet in the input buffer subject to the virtual channel space limit and buffer class space limit, the determining of the one or more active virtual channels and the one or more active buffer classes being based on one of existence of a request in an age queue or having outstanding credits for link partner input buffer space.
2. The method of claim 1 , further comprising:
determining that storing the received packet in the input buffer meets a predetermined condition based on the determined virtual channel space limit; and
initiating credit based flow control with an upstream switch.
3. The method of claim 1 , further comprising:
determining that storing the received packet in the input buffer meets a predetermined condition based on the determined buffer class space limit; and
initiating credit based flow control with an upstream switch.
4. The method of claim 1 , wherein determining the virtual channel space limit comprises looking up a virtual channel space limit lookup table based on the active virtual channels; and
wherein determining the buffer class space limit comprises looking up a buffer class space limit lookup table based on the active buffer classes.
5. The method of claim 4 ,
wherein an entry in the virtual channel space limit lookup table indicates respective space limits for each active virtual channel; and
wherein an entry in the buffer class space limit lookup table indicates respective space limits for each active buffer class.
6. The method of claim 5 ,
wherein each entry in the virtual channel space limit lookup table indicates a first amount of the shared space that can be used by all active virtual channels; and
wherein each entry in the buffer class space limit lookup table indicates a second amount of the shared space that can be used by all active buffer classes.
7. The method of claim 1 ,
wherein the input buffer comprises a statically allocated space that is associated with the virtual channel and buffer class associated with the received packet; and
wherein the shared space in the input buffer is shared among a number of virtual channels or buffer classes.
8. A switch that facilitates dynamic buffer management, the switch comprising:
an input buffer; and
an input queues logic block coupled to the input buffer, and to:
reserve a fixed space of an input buffer for each virtual channel of a physical link;
determine a virtual channel and buffer class associated with a received packet on the physical link;
determine one or more active virtual channels;
determine a virtual channel space limit in a shared space of the input buffer corresponding to the virtual channel associated with the received packet by calculating a total amount of dynamic space in the input buffer available to the active virtual channels and a percentage each of the active virtual channels is allowed to take across all possible active buffer classes combinations;
determine one or more active buffer classes;
determine a buffer class space limit in the shared space of the input buffer corresponding to the buffer class associated with the received packet by calculating a total amount of dynamic space in the input buffer available to the active buffer classes and a percentage each of the active buffer classes is allowed to take across all possible active buffer classes combinations; and
store the received packet in the input buffer subject to the virtual channel space limit and buffer class space limit.
9. The switch of claim 8 , wherein the input queues logic block is further to:
determine that storing the received packet in the input buffer meets a predetermined condition based on the determined virtual channel space limit; and
initiate credit based flow control with an upstream switch.
10. The switch of claim 8 , wherein the input queues logic block is further to:
determine that storing the received packet in the input buffer meets a predetermined condition based on the determined buffer class space limit; and
initiate credit based flow control with an upstream switch.
11. The switch of claim 8 , further comprising a virtual channel space limit lookup table and a buffer class space limit table;
wherein while determining the virtual channel space limit, the input queues logic block is further to look up the virtual channel space limit lookup table based on the active virtual channels; and
wherein while determining the buffer class space limit, the input queues logic block is further to look up the buffer class space limit lookup table based on the active buffer classes.
12. The switch of claim 11 , wherein an entry in the virtual channel space limit lookup table indicates respective space limits for each active virtual channel; and
wherein an entry in the buffer class space limit lookup table indicates respective space limits for each active buffer class.
13. The switch of claim 12 ,
wherein each entry in the virtual channel space limit lookup table indicates a first amount of the shared space that can be used by all active virtual channels; and
wherein each entry in the buffer class space limit lookup table indicates a second amount of the shared space that can be used by all active buffer classes.
14. The switch of claim 8 , wherein the input buffer comprises a statically allocated space that is associated with the virtual channel and buffer class associated with the received packet; and
wherein the shared space in the input buffer is shared among a number of virtual channels or buffer classes.
15. A network system, comprising:
a number of interconnected switches, wherein a respective switch comprises:
an input buffer; and
an input queues logic block coupled to the input buffer, and to:
reserve a fixed space of the input buffer for each virtual channel of a physical link;
determine a virtual channel and buffer class associated with a received packet on the physical link;
determine one or more active virtual channels;
determine a virtual channel space limit in a shared space in the input buffer corresponding to the virtual channel associated with the received packet by calculating a total amount of dynamic space in the input buffer available to the active virtual channels and a percentage each of the active virtual channels is allowed to take across all possible active buffer classes combinations;
determine one or more active buffer classes;
determine a buffer class space limit in the shared space of the input buffer corresponding to the buffer class associated with the received packet by calculating a total amount of dynamic space in the input buffer available to the active buffer classes and a percentage each of the active buffer classes is allowed to take across all possible active buffer classes combinations; and
store the received packet in the input buffer subject to the virtual channel space limit and buffer class space limit, the determination of the one or more active virtual channels and the one or more active buffer classes being based on one of existence of a request in an age queue or having outstanding credits for link partner input buffer space.
16. The network system of claim 15 , wherein the input queues logic block is further to:
determine that storing the received packet in the input buffer meets a predetermined condition based on the determined virtual channel space limit; and
initiate credit based flow control with an upstream switch.
17. The network system of claim 15 , wherein the input queues logic block is further to:
determine that storing the received packet in the input buffer meets a predetermined condition based on the determined buffer class space limit; and
initiate credit based flow control with an upstream switch.
18. The network system of claim 15 , wherein the respective switch further comprises a virtual channel space limit lookup table and a buffer class space limit table;
wherein while determining the virtual channel space limit, the input queues logic block is further to look up the virtual channel space limit lookup table based on the active virtual channels; and
wherein while determining the buffer class space limit, the input queues logic block is further to look up the buffer class space limit lookup table based on the active buffer classes.
19. The network system of claim 18 , wherein an entry in the virtual channel space limit lookup table indicates respective space limits for each active virtual channel; and
wherein an entry in the buffer class space limit lookup table indicates respective space limits for each active buffer class.
20. The network system of claim 19 , wherein each entry in the virtual channel space limit lookup table indicates a first amount of the shared space that can be used by all active virtual channels; and
wherein each entry in the buffer class space limit lookup table indicates a second amount of the shared space that can be used by all active buffer classes.
21. The network system of claim 15 , wherein the input buffer comprises a statically allocated space that is associated with the virtual channel and buffer class associated with the received packet; and
wherein the shared space in the input buffer is shared among a number of virtual channels or buffer classes.