Guest Memory Bitmap for Fast Virtual Page Eviction

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current processor architectures lack hardware or software support for optimizing memory management in virtualized environments, leading to inefficient memory eviction processes that result in significant delays due to disk I/O operations.

Innovation Solution

A method and system that utilize a memory bitmap maintained by guest memory managers to indicate the state of memory pages, allowing the host machine to determine whether content should be preserved or discarded, thereby reducing the time for memory eviction from milliseconds to nano-seconds by avoiding unnecessary I/O operations.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If the host machine pages out memory page contents to secondary storage during memory eviction, then the memory page contents are preserved for future access, but the memory eviction process experiences significant delay due to disk I/O operations

Engineering Contradiction:
Improvememory page contents preservationVSAvoidmemory eviction time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent extracts the decision-making process for memory eviction from the host machine and delegates it to the guest operating system through the memory bitmap mechanism. The guest OS maintains the bitmap that indicates which memory pages can be safely evicted without preserving contents, allowing the host to quickly identify and evict such pages without performing disk I/O operations.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The guest operating system performs preliminary action by maintaining the memory bitmap that pre-identifies which memory pages have their contents marked for non-preservation. This advance preparation allows the host machine to immediately determine during memory eviction which pages can be discarded without disk operations, eliminating the need for runtime analysis of page contents.

Inventive Principle:
Principle #10Preliminary action

2Adaptability or versatility

If the host machine performs disk I/O operations to store and retrieve memory page contents, then memory pages can be paged out and paged in, but the virtual machine experiences significant performance degradation

Engineering Contradiction:
Improvememory management flexibilityVSAvoidvirtual machine performance
Core Design Contradiction:
Adaptability or versatilityVSProductivity

Solution Approach 1:

The memory bitmap serves as an intermediary data structure that mediates between the guest operating system's memory management needs and the host machine's memory eviction decisions. This bitmap provides the host with quick information about which pages can be evicted without disk operations, eliminating the performance degradation caused by unnecessary I/O while maintaining the flexibility to handle both preserved and non-preserved pages.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The guest operating system performs self-service by maintaining its own memory bitmap that tracks which memory pages have contents that should not be preserved. This self-maintained information structure allows the guest OS to effectively communicate its memory management preferences to the host without requiring complex host-side analysis, thereby improving virtual machine performance by avoiding unnecessary disk operations.

Inventive Principle:
Principle #25Self-service

3Speed

If hardware support like ESSA instructions is provided for memory management optimization, then memory pages can be efficiently identified for eviction without disk I/O, but such hardware support is unavailable in other processor architectures like x86

Engineering Contradiction:
Improvememory eviction speedVSAvoidprocessor architecture compatibility
Core Design Contradiction:
SpeedVSAdaptability or versatility

Solution Approach 1:

The patent creates a software-based copy of the hardware ESSA functionality through the memory bitmap mechanism. Instead of relying on hardware instructions that identify pages for eviction, the guest OS maintains a bitmap that copies the essential information about which pages can be safely evicted. This software emulation achieves the same performance benefits as hardware support while being compatible with any processor architecture including x86.

Inventive Principle:
Principle #26Copying

Solution Approach 2:

The patent substitutes the mechanical hardware-based ESSA instruction system with a software-based memory bitmap mechanism. The bitmap data structure replaces the need for special hardware instructions, allowing the same memory eviction optimization to function across different processor architectures without requiring hardware modifications or architecture-specific instructions.

Inventive Principle:
Principle #28Mechanics substitution (Replace mechanical system)

Data Source

PatentUS9280486B2Managing memory pages based on free page hints
Publication Date: 2016.03.08 RED HAT INC
  • US9280486B2 patent drawing
  • US9280486B2 patent drawing
  • US9280486B2 patent drawing

AI summary

A host selects a memory page that has been allocated to a guest for eviction. The host may be a host machine that hosts a plurality of virtual machines. The host accesses a bitmap maintained by the guest to determine a state of a bit in the bitmap associated with the memory page. The host determines whether content of the memory page is to be preserved based on the state of the bit. In response to determining that the content of the memory page is not to be preserved, the host discards the content of the memory page.