Patent ID: 7290260

Claim:
An apparatus comprising: at least one processor; a memory coupled to the at least one processor; two or more logical partitions defined on the apparatus, wherein each of the two or more logical partitions owns portions of a shared processing resource; and a dynamic processor allocation mechanism residing in the memory and executed by the at least one processor, wherein the dynamic processor allocation mechanism reallocates the shared processing resource among the two or more logical partitions and wherein the amount of shared processing resource eligible to be reallocated is calculated on-the-fly by the dynamic processor allocation mechanism prior to the reallocation, the calculation comprising the steps of: determining a current utilization of the shared processing resource for each of the two or more logical partitions; determining a current utilization of the shared processing resource for the apparatus as a whole; constructing, for each of the two or more logical partitions, a bid determined by dividing the current utilization of the partition by the utilization of the apparatus as a whole, wherein any partition having a bid less than 1 is classified as potential donating partition, and any partition having a bid greater than 1 is classified as a potential recipient partition; calculating, for each potential recipient partition, an amount of resource desired to be received by multiplying the bid by a number of processing units currently assigned to the potential recipient partition, then subtracting the number of processing units currently assigned to the potential recipient partition; and calculating, for each potential donating partition, an amount of resource available for donation by subtracting the bid from 1, then multiplying the result by the number of processing units currently assigned to the potential donating partition.