Execution Trace Diffing for Fast Software Fault Isolation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Identifying and resolving undesired software behaviors, such as execution crashes and performance issues, is challenging due to their rarity and difficulty in reproduction, requiring extensive time and resources for analysis.

Innovation Solution

The method involves diffing prior executions of an executable program based on replayable execution traces, using entity weighting, search space partitioning, and replacement restriction techniques to efficiently calculate edit distances between ordered sets of entities, reducing computational resources needed for analysis.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Loss of time

If conventional debugging and analysis methods are used on replayable execution traces, then diagnostic capability is maintained, but analysis time becomes excessively long (days) due to the vast amount of trace data generated by modern processors

Engineering Contradiction:
Improveanalysis timeVSAvoidtrace analysis throughput
Core Design Contradiction:
Loss of timeVSProductivity

Solution Approach 1:

The execution trace is divided into multiple segments based on function call boundaries. Each segment contains a subset of entities (function calls, instructions, etc.) that can be independently processed. This segmentation allows the diffing algorithm to work on smaller, manageable portions of the trace data rather than the entire trace at once, significantly reducing computation time while maintaining analysis accuracy.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent extracts only the essential entities from the execution trace that are relevant to identifying software faults, such as function calls, kernel calls, and telemetry datapoints. By filtering out redundant information and focusing on critical entities, the analysis process operates on a reduced dataset, thereby decreasing analysis time without sacrificing diagnostic capability.

Inventive Principle:
Principle #2Taking out (Extraction)

2Measurement precision

If detailed replayable execution traces are captured to enable precise fault identification, then measurement precision is improved, but the quantity of data to be analyzed increases significantly, requiring excessive computational resources

Engineering Contradiction:
Improvefault identification accuracyVSAvoidtrace data volume
Core Design Contradiction:
Measurement precisionVSQuantity of substance

Solution Approach 1:

The patent extracts and retains only the most relevant entities from the execution trace, such as function calls, kernel calls, and telemetry datapoints, while discarding redundant information. This selective extraction maintains the precision needed for fault identification by preserving critical diagnostic information while reducing the overall data volume that requires computational analysis.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

By segmenting the trace into function-call-based units, the patent organizes detailed trace data into structured, manageable sections. This segmentation allows the system to process and analyze only the relevant portions of the trace associated with potential faults, rather than processing the entire voluminous trace data set, thus reducing computational resource requirements while maintaining analysis precision.

Inventive Principle:
Principle #1Segmentation

3Reliability

If traditional edit distance algorithms are applied to compare execution traces, then comprehensive comparison is achieved, but computational complexity increases, requiring excessive processing power and time

Engineering Contradiction:
Improvetrace comparison accuracyVSAvoidcomputational complexity
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent applies segmentation to divide the execution traces into smaller segments based on function calls before performing edit distance comparison. This segmentation transforms the complex problem of comparing entire traces into multiple simpler comparisons of smaller segments, significantly reducing computational complexity while maintaining the reliability of the comparison through systematic analysis of all relevant segments.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent applies different weighting schemes to different types of entities within the traces based on their relative importance for fault detection. Critical entities such as function calls and kernel calls are assigned higher weights, while less important entities receive lower weights. This local quality approach allows the edit distance algorithm to focus computational effort on the most diagnostically valuable parts of the trace, improving reliability while reducing overall computational complexity.

Inventive Principle:
Principle #3Local quality

Data Source

PatentUS12596631B2Diffing prior executions of an executable program
Publication Date: 2026.04.07 MICROSOFT TECHNOLOGY LICENSING LLC
  • US12596631B2 patent drawing
  • US12596631B2 patent drawing
  • US12596631B2 patent drawing

AI summary

Diffing prior executions of an executable program. A computer system assigns a weighting to each entity type in a first ordered set of a first plurality of entities and a second ordered set of a second plurality of entities, including assigning different weightings to different entity types. The computer system calculates an edit distance between the first and second ordered sets based on calculating a minimal cost path through a diffing structure. Calculating the minimal cost path includes partitioning the diffing structure around intersecting entries that are identified based on (i) only permitting replacements between entities that have a common entity type, and (ii) utilizing the different weightings to identify single-entity replacements that have higher cost than adjoining multi-entity replacements. Calculating the minimal cost path also includes applying a differencing algorithm to these partitions, in order to identify corresponding segments of the minimal cost path.