Virtual Priority Module for APIC Virtualization Overhead

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing virtualization methods face significant overhead in virtualizing processor and interrupt priorities, particularly in APIC architectures, which hinders high-performance virtualization of computer systems.

Innovation Solution

A method is introduced that efficiently handles processor and interrupt priorities by detecting changes in priority values and conditionally dispatching interrupts, using a virtual priority module to compare old and new priority values with a maximum pending priority value, thereby avoiding unnecessary APIC state recalculations and reducing virtualization overhead.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If complete APIC state recalculation is performed for every priority change, then correctness of interrupt handling is ensured, but virtualization overhead increases significantly

Engineering Contradiction:
Improvecorrectness of interrupt handlingVSAvoidvirtualization overhead
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

Instead of performing complete APIC state recalculation for every priority change, the patent applies partial action by only recalculating the necessary portion (maximum pending priority) when needed. The system determines whether recalculation is required by comparing old and new priority values against the current maximum pending priority, avoiding unnecessary complete state recalculation while maintaining correctness.

Inventive Principle:
Principle #16Partial or excessive action

Solution Approach 2:

The patent performs preliminary action by pre-establishing the maximum pending priority value and using it as a threshold for decision-making. Before performing complete APIC state recalculation, the system first compares priority changes against this pre-established threshold to determine if recalculation is necessary, thereby avoiding unnecessary computations.

Inventive Principle:
Principle #10Preliminary action

2Reliability

If APIC virtualization is implemented with full state management, then interrupt protection is ensured, but system performance deteriorates

Engineering Contradiction:
Improveinterrupt protectionVSAvoidsystem performance
Core Design Contradiction:
ReliabilityVSSpeed

Solution Approach 1:

The patent applies partial action by implementing selective APIC state management. Instead of fully managing and recalculating the entire APIC state for every interrupt or priority change, the system only performs necessary calculations (comparing priority values against maximum pending priority) and avoids unnecessary complete state recalculation, thereby maintaining interrupt protection while improving system performance.

Inventive Principle:
Principle #16Partial or excessive action

Solution Approach 2:

The patent utilizes parameter changes by dynamically adjusting the maximum pending priority value based on current system state and priority changes. This allows the system to optimize its behavior by changing the threshold parameter for determining when full APIC state recalculation is necessary, thereby balancing interrupt protection with system performance.

Inventive Principle:
Principle #35Parameter changes

3Adaptability or versatility

If binary translation is used for guest code, then compatibility is improved, but translation overhead increases

Engineering Contradiction:
Improveguest code compatibilityVSAvoidtranslation overhead
Core Design Contradiction:
Adaptability or versatilityVSProductivity

Solution Approach 1:

The patent applies preliminary action in the context of binary translation by pre-translating and pre-optimizing priority handling code sequences. The system prepares translation tables and optimization rules in advance for common priority change scenarios, allowing faster execution during actual guest code translation without requiring complete retranslation for each operation.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent utilizes parameter changes by optimizing the translation process dynamically based on the specific priority values and contexts involved. The binary translator adjusts its behavior based on parameters such as the magnitude of priority changes and the current maximum pending priority, applying different translation strategies to minimize overhead while maintaining compatibility.

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS7590982B1System and method for virtualizing processor and interrupt priorities
Publication Date: 2009.09.15 VMWARE INC
  • US7590982B1 patent drawing
  • US7590982B1 patent drawing
  • US7590982B1 patent drawing

AI summary

Dispatching of interrupts to a processor is conditionally suppressed, that is, only if an old priority value and a new priority value are either both less than or both greater than a maximum pending priority value. This conditional avoidance of dispatching is preferably implemented by a virtual priority module within a binary translator in a virtualized computer system and relates to interrupts directed to a virtualized processor by a virtualized local APIC.