Virtual Machine Branch Count Logging for Replay

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Conventional execution logging and replay systems in virtual machines are slow due to software tracing overhead and require expensive specialized hardware, making them inefficient for debugging and fault tolerance applications.

Innovation Solution

A method for logging non-deterministic events in a virtual machine by tracking execution points, specifically using a tuple {eip, brCnt, ecx} to identify instructions, and recording information about branch counts and execution points, allowing for efficient logging and replay of execution sequences without the need for expensive tracing hardware.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If conventional trace collection techniques using specialized hardware are used, then execution logging and replay can be performed, but the system becomes slow due to software tracing overhead and expensive hardware requirements

Engineering Contradiction:
Improveexecution logging accuracyVSAvoidexecution speed
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent extracts only the essential information needed for replay (branch instruction counts and non-deterministic events) from the complete execution trace, rather than logging every instruction. This selective extraction reduces the logging overhead and storage requirements while maintaining sufficient information for accurate replay.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

Instead of logging all instructions and filtering during replay, the patent inverts the approach by using branch counts to directly identify and log only the critical non-deterministic events that affect replay accuracy. This inversion reduces the volume of logged data and improves both speed and efficiency.

Inventive Principle:
Principle #13The other way round (Inversion)

2Loss of information

If specialized tracing hardware is used to monitor and log every instruction, then complete execution traces can be captured, but the system becomes expensive and complex

Engineering Contradiction:
Improveexecution trace completenessVSAvoidtracing hardware complexity
Core Design Contradiction:
Loss of informationVSDevice complexity

Solution Approach 1:

The patent uses software-based copying of branch count information and event data instead of specialized hardware tracing. The virtual machine monitor software captures branch instruction counts and non-deterministic events, creating a simplified copy of the essential execution information without requiring complex hardware trace buffers or monitoring circuits.

Inventive Principle:
Principle #26Copying

Solution Approach 2:

The patent changes the parameter being tracked from complete instruction addresses to branch instruction counts. This parameter transformation simplifies the tracing mechanism by using a compact counter that can be maintained in software, eliminating the need for complex hardware address capture and comparison logic.

Inventive Principle:
Principle #35Parameter changes

3Measurement precision

If every instruction is logged for replay purposes, then accurate replay can be achieved, but storage requirements and processing overhead increase significantly

Engineering Contradiction:
Improvereplay accuracyVSAvoidlog data volume
Core Design Contradiction:
Measurement precisionVSQuantity of substance

Solution Approach 1:

The patent extracts only the critical subset of execution information needed for replay - specifically branch instruction counts and non-deterministic events - rather than logging all instructions. This extraction reduces log data volume from potentially millions of instructions to a manageable number of branch points and events.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

Instead of logging all instructions and selecting during replay, the patent inverts by using branch counts to directly identify where non-deterministic events occurred. This approach captures only the essential replay information, minimizing storage requirements while maintaining replay accuracy.

Inventive Principle:
Principle #13The other way round (Inversion)

Data Source

PatentUS7844954B2Using branch instruction counts to facilitate replay of virtual machine instruction execution
Publication Date: 2010.11.30 VMWARE INC
  • US7844954B2 patent drawing
  • US7844954B2 patent drawing
  • US7844954B2 patent drawing

AI summary

A method and computer program product for logging non-deterministic events of a virtual machine executing a sequence guest instructions, the method including tracking an execution point in the sequence of executing guest instructions, the tracking of the execution point including determining a branch count of executed branch instructions; and detecting an occurrence of a non-deterministic event directed to the virtual machine during execution of the sequence of guest instructions, and recording information which includes an identifier of a current execution point, wherein the identifier includes the branch count.