# US 2024/0004772 A1 · Central processing unit utilization determination

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2024/0004772 A1
- Document ID: US20240004772A1
- Status: Published application
- Kind: A1
- Application number: 17/810,154
- Filed: 2022-06-30
- Published: 2024-01-04
- Earliest claimed: 2022-06-30
- Assignees: Microsoft Technology Licensing, LLC
- Applicants: Microsoft Technology Licensing, LLC
- Inventors: Khoa A. TO; Omar CARDONA; Dmitry MALLOY; Narcisa Ana Maria VASILE; Robert Tyler RETZLAFF
- Web page: https://patentgrep.com/patent/US20240004772A1

## CPC

- G06F 9/4893: {taking into account power or heat criteria (power management in computers in general G06F1/3203; thermal management in computers in general G06F1/206)}
- G06F 11/3419: {by assessing time}
- G06F 11/3024: {where the computing system component is a central processing unit [CPU]}
- Y02D 10/00: Energy efficient computing, e.g. low power processors, power management or thermal management
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- Y02D: CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE

## Abstract

Systems and methods for determining and reporting actual utilization of a core of a central processing unit (CPU) of a host. Prior to implementation of aspects of the present disclosure, running a poll querying endpoints of a process for work appears to the host's operating system as busy work (e.g., taking full use of the core for the poll duration). However, only a percentage of the duration of the poll is used to process a task of the process, where the remaining duration of the poll is spent querying the endpoints (idle time) and the core is not performing a task. Accordingly, a core utilization reporting system and method automatically detects the processing time of the tasks of a process, determines actual CPU utilization of the core based on a percentage of the time the core is busy polling (doing effectively no work) versus doing actual work (processing a task).

## Claims

### Claim 1

A computer-implemented method, comprising:
initiating a poll querying a plurality of endpoints of a process on a core of a central processing unit (CPU);
recording a timestamp corresponding to initiation of the poll;
for each endpoint of the plurality of endpoints that indicates it has work:
recording a timestamp corresponding to initiation of processing the work; and
recording a timestamp corresponding to completion of processing the work;
recording a timestamp corresponding to completion of the poll;
determining a total poll time using a first time delta between the timestamp corresponding to initiation of the poll and the timestamp corresponding to completion of the poll;
determining a total processing time using a sum of second time deltas between the timestamp corresponding to initiation of processing the work and the timestamp corresponding to completion of processing the work for each endpoint of the plurality of endpoints that indicates it has work;
determining a total idle time of the core during the poll by subtracting the sum of second time deltas from the first time delta; and
determining actual CPU utilization of the core using the total idle time.

### Claim 2 (depends on 1)

The method of claim 1, wherein recording the timestamp corresponding to initiation of processing the work comprises recording a timestamp when a thread of the process is hard-affinitized to the core.

### Claim 3 (depends on 1)

The method of claim 1, further comprising determining an idle time rate of the core by determining a ratio between the total idle time and the first time delta.

### Claim 4 (depends on 1)

The method of claim 1, wherein determining the actual CPU utilization of the core comprises determining a ratio between the sum of second time deltas and the first time delta.

### Claim 5 (depends on 1)

The method of claim 1, further comprising reporting metrics associated with the actual CPU utilization of the core.

### Claim 6 (depends on 1)

The method of claim 1, further comprising:
determining that the actual CPU utilization of the core is not within a utilization threshold;
determining an action that improves utilization of the core; and
causing the action to be performed.

### Claim 7 (depends on 6)

The method of claim 6, wherein determining the action comprises at least one of:
transitioning the process to a lower power core;
collapsing the process to fewer cores;
expanding the process to a core on a threshold;
ceding work to a scheduler; and
performing queue balancing.

### Claim 8 (depends on 1)

The method of claim 1, where initiating the poll comprises querying the plurality of endpoints in a sequence.

### Claim 9

A system comprising memory storing instructions that, when executed, cause the system to:
initiate a poll querying a plurality of endpoints of a process on a core of a central processing unit (CPU);
record a timestamp corresponding to initiation of the poll;
for each endpoint of the plurality of endpoints that indicates it has work:
record a timestamp corresponding to initiation of processing the work; and
record a timestamp corresponding to completion of processing the work;
record a timestamp corresponding to completion of the poll;
determine a total poll time using a first time delta between the timestamp corresponding to initiation of the poll and the timestamp corresponding to completion of the poll;
determine a total processing time using a sum of second time deltas between the timestamp corresponding to initiation of processing the work and the timestamp corresponding to completion of processing the work for each of the plurality of endpoints indicating it has work;
determine a total idle time of the core by the sum of second time deltas from the first time delta; and
determine actual CPU utilization of the core using the total idle time.

### Claim 10 (depends on 9)

The system of claim 9, wherein the timestamp corresponding to initiation of processing the work comprises a timestamp corresponding to when a thread of the process is hard-affinitized to the core.

### Claim 11 (depends on 9)

The system of claim 9, wherein the instructions further cause the system to determine an idle time rate of the core by determining a ratio between the total idle time and the first time delta.

### Claim 12 (depends on 9)

The system of claim 9, wherein in determining the actual CPU utilization of the core, the instructions cause the system to determine a ratio between the sum of the second time deltas and the first time delta.

### Claim 13 (depends on 9)

The system of claim 9, wherein the instructions further cause the system to report metrics associated with the actual CPU utilization of the core.

### Claim 14 (depends on 13)

The system of claim 13, wherein the instructions further cause the system to determine the actual CPU utilization of the core is not within a utilization threshold;
determine an action that improves utilization of the core; and
issue a command to cause the action to be performed.

### Claim 15 (depends on 14)

The system of claim 14, the action comprises at least one of:
transitioning the process to a lower power core;
collapsing the process to fewer cores;
expanding the process to a core on a threshold;
ceding work to a scheduler; and
performing queue balancing.

### Claim 16 (depends on 9)

The system of claim 9, where the poll is performed in a loop.

### Claim 17

A computer-implemented method, comprising:
initiating a poll sequentially querying a plurality of endpoints of a process on a core of a central processing unit (CPU);
recording a timestamp corresponding to initiation of the poll;
for each endpoint of the plurality of endpoints that indicates it has work:
recording a timestamp corresponding to initiation of processing the work; and
recording a timestamp corresponding to completion of processing the work;
recording a timestamp corresponding to completion of the poll;
determining a total poll time using a first time delta between the timestamp corresponding to initiation of the poll and the timestamp corresponding to completion of the poll;
determining a total processing time using a sum of second time deltas between the timestamp corresponding to initiation of processing the work and the timestamp corresponding to completion of processing the work for each of the plurality of endpoints indicating it has work;
determining a total idle time of the core during the poll by subtracting the sum of second time deltas from the first time delta;
determining actual CPU utilization of the core using the total idle time; and
reporting metrics associated with the actual CPU utilization of the core.

### Claim 18 (depends on 17)

The computer-implemented method of claim 17, wherein recording the timestamp corresponding to initiation of processing the work comprises recording a timestamp when a thread of the process is hard-affinitized to the core.

### Claim 19 (depends on 17)

The computer-implemented method of claim 17, further comprising:
determining an idle time rate of the core by determining a ratio between the total idle time and the first time delta; and
wherein determining the actual CPU utilization of the core by determining a ratio between the sum of the second time deltas and the first time delta.

### Claim 20 (depends on 17)

The computer-implemented method of claim 17, further comprising:
determining that the actual CPU utilization of the core is not a utilization threshold;
determining an action that improves utilization of the core; and
causing the action to be performed, wherein the action comprises at least one of:
transitioning the process to a lower power core;
collapsing the process to fewer cores;
expanding the process to a core on a threshold;
ceding work to a scheduler; and
performing queue balancing.
