Scheduling for multiple memory controllers
AssigneeAdvanced Micro Devices, Inc.
InventorsJaewoong Chung, Debarshi Chatterjee
Life of this patent
Estimating the term…
Abstract
Some embodiments of a multi processor system implement a virtual-time-based quality-of-service scheduling technique. In at least one embodiment of the invention, a method includes scheduling a memory request to a memory from a memory request queue in response to expiration of a virtual finish time of the memory request. The virtual finish time is based on a share of system memory bandwidth associated with the memory request. The method includes scheduling the memory request to the memory from the memory request queue before the expiration of the virtual finish time of the memory request if a virtual finish time of each other memory request in the memory request queue has not expired and based on at least one other scheduling rule.
Claims23
A method comprising:
- calculating a virtual finish time of a memory request from a first thread of a plurality of threads executing on a plurality of processors, the virtual finish time being calculated based on a virtual clock for the first thread, the virtual clock for the first thread progressing slower than a memory clock according to a share of memory bandwidth allocated to the first thread;
- scheduling the memory request to a memory from a memory request queue in response to expiration of the virtual finish time of the memory request, expiration of the virtual finish time including the virtual clock for the first thread at least reaching the virtual finish time of the memory request;
- and
- scheduling the memory request to the memory from the memory request queue before the expiration of the virtual finish time of the memory request if a virtual finish time of each other memory request in the memory request queue has not expired and based on at least one other scheduling rule.
An apparatus comprising:
- a memory controller comprising:
- control logic configured to calculate a virtual finish time corresponding to a memory request requested by a first thread of a plurality of threads executing on a plurality of processors, the virtual finish time being determined according to a virtual clock for the first thread, the virtual clock for the first thread progressing slower than a memory clock according to a share of memory bandwidth allocated to the first thread;
- a memory request buffer operative to store the memory request and the virtual finish time;
- and
- a scheduler operative to schedule the memory request to memory in response to expiration of the virtual finish time, expiration of the virtual finish time including the virtual clock for the first thread at least reaching the virtual finish time, and operative to schedule the memory request to memory before the expiration of the virtual finish time if a virtual finish time of each other memory request in the memory request queue has not expired and based on at least one other scheduling rule.
An apparatus comprising:
- a memory controller comprising:
- a memory request buffer operative to store a memory request and a corresponding virtual finish time;
- a scheduler operative to schedule the memory request to memory in response to expiration of the corresponding virtual finish time, the corresponding virtual finish time being based on a share of system memory bandwidth associated with the memory request and operative to schedule the memory request to memory before the expiration of the corresponding virtual finish time if a virtual finish time of each other memory request in the memory request queue has not expired and based on at least one other scheduling rule;
- and
- a plurality of storage elements per thread context supported by the memory controller, wherein the plurality of storage elements comprises, for each thread context:
- a virtual finish time storage element per memory bank, operative to store a virtual finish time of a last memory request from a thread associated with the thread context processed at the memory bank;
- a physical address storage element per memory bank operative to store a physical address of the last memory request from the thread processed at the memory bank;
- and
- a resource share storage element, operative to store the system memory bandwidth allocation of the thread.
Dependencies are inferred from the claim text.