Processor Control Register Virtualization via Shadow Locations

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In virtual machine environments, the overhead of Exit-Enter Time (EET) is substantial due to the need for the Virtual Machine Monitor (VMM) to save and restore processor state when handling privileged instructions, particularly when writing control flags, which can interfere with other guest virtual machines.

Innovation Solution

Implementing shadow locations for virtualized flags that are owned by a guest virtual machine, allowing writes and reads to be redirected within these shadow locations without incurring the EET overhead, and only requiring VMM intervention when necessary.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If the VMM saves and restores processor state when handling privileged instructions, then guest isolation and system security are maintained, but Exit-Enter Time overhead increases substantially

Engineering Contradiction:
Improveguest isolationVSAvoidExit-Enter Time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent segments processor state into two categories: shadowed state (stored in shadow structures) and real state (stored in actual processor registers). This segmentation allows the VMM to avoid saving and restoring entire processor state for every privileged instruction, instead only handling specific state changes, thereby reducing Exit-Enter Time while maintaining guest isolation through the shadowed state mechanism.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent creates shadow copies of processor state (shadow control registers, shadow segment descriptors, shadow descriptor tables) that mirror the real processor state. These shadow copies are maintained by the VMM and used to virtualize privileged instructions, allowing guests to execute instructions against shadow state without requiring full VMM intervention and state saving/restoring, thus reducing time overhead while preserving isolation.

Inventive Principle:
Principle #26Copying

2Reliability

If the VMM virtualizes all privileged instructions, then guest isolation is ensured, but processing overhead and system performance decrease

Engineering Contradiction:
Improveguest isolationVSAvoidsystem performance
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent enables guests to self-service by allowing them to execute privileged instructions directly against shadow state structures without requiring VMM interception and handling. The shadowed state mechanism allows guests to modify their own virtualized state (control flags, segment descriptors, etc.) without triggering VM exits, thereby improving system performance while maintaining isolation through the shadowing mechanism.

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The patent extracts the isolation-enforcing functionality from the VMM and places it into shadow state structures that can be manipulated directly by guests. By taking out the state management burden from the VMM and embedding it in shadow structures, the system reduces VMM intervention overhead while preserving guest isolation through the shadowed state architecture.

Inventive Principle:
Principle #2Taking out (Extraction)

3Manufacturing precision

If control flags are written to actual processor control registers, then instruction execution is accurate, but other guest virtual machines may be interfered with

Engineering Contradiction:
Improveinstruction execution accuracyVSAvoidinterference with other guests
Core Design Contradiction:
Manufacturing precisionVSObject-affected harmful factors

Solution Approach 1:

The patent introduces shadow control registers as intermediary structures between guest privileged instructions and actual processor control registers. When a guest writes to a control flag, the write is directed to the shadow control register instead of the actual register. The shadowed state acts as a mediator that allows accurate guest instruction execution while preventing direct interference with the actual processor state and other guests, as the VMM can control when and how shadow state is synchronized with real state.

Inventive Principle:
Principle #24Intermediary (Mediator)

Data Source

PatentUS7725895B2Processor control register virtualization to minimize virtual machine exits
Publication Date: 2010.05.25 TAHOE RES LTD
  • US7725895B2 patent drawing
  • US7725895B2 patent drawing
  • US7725895B2 patent drawing

AI summary

Writing a control flag in a processor control register by a guest virtual machine. Determine whether the control flag is owned by the guest virtual machine. Write the control flag to the processor control register if the control flag is owned by the guest virtual machine. Write the control flag to a shadow location if the control flag is not owned by the guest virtual machine.