Structured Program State Collection for Debugging

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Traditional debugging tools fail to provide sufficiently detailed information for programmers to interact with specific portions of executed program code, lacking the ability to capture complete program states, which hinders debugging efficiency and analysis.

Innovation Solution

A client device collects structured output information associated with events and state transitions during program execution, enabling programmers to reconstruct and analyze program states, re-execute code from specific points, and perform operations based on variable values, even if they change subsequently.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Measurement precision

If traditional debugging tools are used to receive and record program outputs, then basic execution monitoring is achieved, but the tools fail to generate sufficiently detailed debugging information and cannot capture complete program states

Engineering Contradiction:
Improvedebugging information detailVSAvoidprogram state capture
Core Design Contradiction:
Measurement precisionVSLoss of information

Solution Approach 1:

The patent segments the program execution into discrete events with associated states. Each event captures a specific moment in program execution along with the complete program state at that moment. This segmentation allows detailed analysis of individual execution points without requiring continuous monitoring of the entire program, thereby improving measurement precision while managing information complexity.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system performs preliminary actions by collecting and storing complete program states at specific events during execution. These pre-collected states enable programmers to reconstruct program behavior at any point without re-executing the entire program, providing detailed debugging information advance of time and improving measurement precision.

Inventive Principle:
Principle #10Preliminary action

2Ease of operation

If programmers want to interact with specific portions of executed program code and reconstruct execution at particular points, then detailed program analysis is enabled, but traditional tools lack the capability to provide such interaction and reconstruction

Engineering Contradiction:
Improveprogrammer interaction capabilityVSAvoiddebugging system functionality
Core Design Contradiction:
Ease of operationVSDevice complexity

Solution Approach 1:

The patent creates copies of program states at various execution points. These state copies are stored and can be retrieved to reconstruct program execution at specific moments. Programmers can interact with these state copies to analyze variable values, control flow, and program behavior at any point, enabling detailed interaction without modifying the original program execution, thus improving ease of operation.

Inventive Principle:
Principle #26Copying

Solution Approach 2:

The system dynamically collects program states at events during execution, then enables static analysis of these captured states. Programmers can dynamically reconstruct execution paths by selecting different event points and states, creating an interactive debugging experience that adapts to their analysis needs while maintaining a relatively simple underlying architecture.

Inventive Principle:
Principle #15Dynamics

3Measurement precision

If complete program states are collected at all execution points, then detailed program state reconstruction is achieved, but processor resources and time for analysis increase

Engineering Contradiction:
Improveprogram state completenessVSAvoiddebugging time
Core Design Contradiction:
Measurement precisionVSProductivity

Solution Approach 1:

Instead of uniformly collecting program states at all execution points, the system collects states selectively at significant events (function calls, returns, assignments, etc.). Each collected state includes only the necessary program information relevant to that event, providing local quality detail where needed while avoiding unnecessary data collection elsewhere, thus balancing measurement precision with productivity.

Inventive Principle:
Principle #3Local quality

Data Source

PatentUS9880925B1Collecting structured program code output
Publication Date: 2018.01.30 MATHWORKS INC
  • US9880925B1 patent drawing
  • US9880925B1 patent drawing
  • US9880925B1 patent drawing

AI summary

A system may obtain an executable code segment of program code. The executable code segment may be associated with an emitter, and the program code, when executed, may be associated with a plurality of execution states. Each execution state, of the plurality of execution states, may correspond to a state of execution at a point in the execution of the program code that causes an event, of the plurality of events. The system may execute the executable code segment. The system may receive, from the emitter and based on executing the executable code segment, a program state corresponding to the particular execution state. The emitter may emit the information based on a particular event caused by executing the executable code segment. The system may collect the program state and information describing the particular event.