Branch Trace Compression via Hash Fingerprinting

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Saving entire stack traces or branch traces in log messages is inefficient due to brevity loss and high memory and execution costs, making them impractical for debugging and diagnostics.

Innovation Solution

Generating metadata files for possible stack and branch traces, updating run-time trace values using mathematical operations, and matching these values to compress and represent the calling context efficiently, allowing for concise logging without performance sacrifices.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Loss of information

If entire stack traces or branch traces are saved in log messages, then debugging information is complete and detailed, but log message brevity is lost and memory and execution costs increase

Engineering Contradiction:
Improvedebugging information completenessVSAvoidlogging efficiency
Core Design Contradiction:
Loss of informationVSProductivity

Solution Approach 1:

The patent extracts only the essential identifying information from stack traces and branch traces, rather than saving the entire trace data. It uses hash functions to compute compact representations (fingerprints) of the trace data, extracting only the critical debugging information while discarding redundant details. This resolves the contradiction by maintaining debugging information completeness through hash-based identification while dramatically improving logging efficiency.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent transforms the stack trace and branch trace data from its original detailed form into a compressed parameter representation using hash functions. By changing the parameter representation from full trace data to compact hash values, the system maintains the ability to identify and debug issues while significantly reducing memory usage and execution overhead. This parameter transformation resolves the contradiction between information completeness and logging efficiency.

Inventive Principle:
Principle #35Parameter changes

2Loss of information

If entire stack traces or branch traces are saved in log messages, then calling context is fully captured, but memory usage increases significantly

Engineering Contradiction:
Improvecalling context accuracyVSAvoidmemory consumption
Core Design Contradiction:
Loss of informationVSQuantity of substance

Solution Approach 1:

The patent extracts only the essential identifying features of calling context from complete stack traces and branch traces. By using hash functions to compute compact representations of the trace data, it extracts the critical context information needed for debugging while removing redundant data. This resolves the contradiction by maintaining calling context accuracy through hash-based identification while dramatically reducing memory consumption.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent creates compact hash-based copies of the stack trace and branch trace data rather than storing the original detailed traces. These hash copies serve as efficient proxies that maintain the essential calling context information while occupying minimal memory space. This copying approach resolves the contradiction between calling context accuracy and memory consumption by using space-efficient hash representations.

Inventive Principle:
Principle #26Copying

3Loss of information

If entire stack traces or branch traces are saved in log messages, then execution details are fully recorded, but execution speed decreases

Engineering Contradiction:
Improveexecution trace completenessVSAvoidlogging operation time
Core Design Contradiction:
Loss of informationVSLoss of time

Solution Approach 1:

The patent extracts only the essential execution trace information needed for debugging by computing hash values from the complete traces. This extraction process captures the critical execution details while avoiding the overhead of storing and processing full trace data. The hash computation is performed efficiently during log generation, resolving the contradiction between execution trace completeness and logging operation time.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent performs hash computation as a preliminary action during log message generation, before the actual logging operation. By pre-computing the compact trace representations and storing them in efficient data structures, the system minimizes the time required for logging operations. This preliminary action approach resolves the contradiction between execution trace completeness and logging operation time.

Inventive Principle:
Principle #10Preliminary action

Data Source

PatentUS9104402B2Branch trace compression
Publication Date: 2015.08.11 VMWARE INC
  • US9104402B2 patent drawing
  • US9104402B2 patent drawing
  • US9104402B2 patent drawing

AI summary

Exemplary methods, apparatuses, and systems generate a plurality of possible branch traces for a computer program. Each possible branch trace represents different sequences of branch instructions that may be executed while the computer program is running. Each branch instruction has a corresponding identifier. A branch trace value is generated for at least one of the plurality of possible branch traces. Generating the branch trace value includes performing a mathematical or logical operation between a first identifier and each subsequent identifier of the possible branch trace to obtain the branch trace value. An output including a branch trace is generated based upon a match between a run-time branch trace value and the at least one generated branch trace value.