# US 2021/0173684 A1 · Dynamic pause exiting

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

- Number: US 2021/0173684 A1
- Document ID: US20210173684A1
- Status: Published application
- Kind: A1
- Application number: 16/704,133
- Filed: 2019-12-05
- Published: 2021-06-10
- Earliest claimed: 2019-12-05
- Assignees: Red Hat, Inc.
- Applicants: Red Hat, Inc.
- Inventors: Andrea Arcangeli; Bandan Das
- Web page: https://patentgrep.com/patent/US20210173684A1

## CPC

- G06F 9/45558: {Hypervisor-specific management and integration aspects}
- G06F 9/45545: {Guest-host, i.e. hypervisor is an application program itself, e.g. VirtualBox}
- G06F 11/0757: {by exceeding a time limit, i.e. time-out, e.g. watchdogs}
- G06F 11/301: {where the computing system is a virtual computing platform, e.g. logically partitioned systems (virtual machines G06F9/45533; logical partitioning of resources G06F9/5077)}
- G06F 11/3065: {Monitoring arrangements determined by the means or processing involved in reporting the monitored data (error or fault reporting or logging G06F11/0766)}
- G06F 2009/45575: {Starting, stopping, suspending or resuming virtual machine instances}
- G06F 2009/45591: {Monitoring or debugging support}
- G06F 2201/81: Threshold
- G06F 2201/835: Timestamp
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A method performed by a physical computing system includes, with a hypervisor, determining a first time difference between when pause exiting was last enabled for the virtual machine and present time. The method further includes, with the hypervisor, in response to determining that the first time difference is greater than an enablement threshold, enabling pause exiting. The method further includes, with the hypervisor, with pause loop exiting enabled, determining a second time difference between when pause exiting was last disabled and the present time. The method further includes, with the hypervisor, disabling pause exiting in response to determining that the second time difference exceeds a disablement threshold.

## Claims

### Claim 1

A method comprising:
with a hypervisor, determining a first time difference between when pause exiting was last enabled for the virtual machine and present time;
with the hypervisor, in response to determining that the first time difference is greater than an enablement threshold, enabling pause exiting;
with the hypervisor, with pause loop exiting enabled, determining a second time difference between when pause exiting was last disabled and the present time; and
with the hypervisor, disabling pause exiting in response to determining that the second time difference exceeds a disablement threshold.

### Claim 2 (depends on 1)

The method of claim 1, wherein the hypervisor enables pause exiting in response to finding a pause instruction in an instruction stream of the virtual machine.

### Claim 3 (depends on 1)

The method of claim 1, wherein the hypervisor enables pause exiting in response to a pre-defined time-out.

### Claim 4 (depends on 1)

The method of claim 1, further comprising, while pause exiting is enabled, exiting a context of the virtual machine in response to executing a pause instruction for the virtual machine.

### Claim 5 (depends on 1)

The method of claim 1, wherein, while pause exiting is enabled, the determining the second time difference is done in response to determining that the CPL of software executing on the virtual machine is greater than zero.

### Claim 6 (depends on 1)

The method of claim 1, wherein the disablement threshold is smaller than the enablement threshold.

### Claim 7 (depends on 1)

The method of claim 1, wherein the disablement threshold is within a range of about 20 and 100 milliseconds.

### Claim 8 (depends on 1)

The method of claim 1, wherein the enablement threshold is within a range of about 50 and 200 milliseconds.

### Claim 9 (depends on 1)

The method of claim 1, wherein pause exiting is enabled or disabled by changing a value in an internal data structure managed by the hypervisor.

### Claim 10 (depends on 1)

The method of claim 1, wherein a pause instruction is executed while waiting on a spinlock.

### Claim 11

A method comprising:
with a hypervisor, enabling pause exiting in response to determining that a first time difference since pause exiting was last enabled and present time is greater than an enablement threshold; and
with the hypervisor, disabling pause exiting in response to determining that a second time difference since pause exiting was last disabled is greater than a disablement threshold;
wherein the disablement threshold is smaller than the enablement threshold.

### Claim 12 (depends on 11)

The method of claim 11, further comprising, while pause exiting is enabled, exiting a context of the virtual machine in response to executing a pause instruction for the virtual machine.

### Claim 13 (depends on 11)

The method of claim 11, further comprising, in response to determining that a Current Privilege Level (CPL) of software executing on the virtual machine is 0, using a hardware feature to cause an exit the virtual machine.

### Claim 14 (depends on 11)

The method of claim 11, wherein, while pause exiting is enabled, the determining the second time difference is done in response to determining that the CPL of software executing on the virtual machine is greater than zero.

### Claim 15 (depends on 11)

The method of claim 11, wherein the disablement threshold is within a range of about 20 and 100 milliseconds.

### Claim 16 (depends on 11)

The method of claim 11, wherein the enablement threshold is within a range of about 50 and 200 milliseconds.

### Claim 17 (depends on 11)

The method of claim 11, wherein pause exiting is enabled or disabled by changing a value in an internal data structure managed by the hypervisor.

### Claim 18

A computing system comprising:
a processor; and
a memory comprising machine readable instructions that when executed by the processor, cause the system to:
read an instruction stream for a virtual machine;
in response to finding a pause instruction in the instruction stream, determine a first time difference between when pause exiting was last enabled for the virtual machine and present time;
enable pause exiting in response to determining that the first time difference is greater than an enablement threshold;
with pause loop exiting enabled, determine a second time difference between when pause exiting was last disabled and the present time; and
disable pause exiting in response to determining that the second time difference exceeds a disablement threshold.

### Claim 19 (depends on 18)

The system of claim 18, wherein, while pause exiting is enabled, the system is further to defer pause exiting to a pause loop exiting hardware feature in response to determining that a Current Privilege Level (CPL) of software executing on the virtual machine is zero.

### Claim 20 (depends on 18)

The system of claim 18, wherein, while pause exiting is enabled, to determine the second time difference is done in response to determining that the CPL of software executing on the virtual machine is greater than zero.
