Debugging Prefixed Code Using Trap Instructions

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

The debugging of code containing prefix instructions is challenging due to the limitations imposed by the size of directly addressable data ranges, which restricts the size of global data areas and complicates debugging processes.

Innovation Solution

A computer program product that uses traps to debug application code with prefix instructions, where a trap replaces the prefixed instruction, reports the presence of the prefix, and ignores it during execution, allowing for efficient debugging and code modification.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Volume of moving object

If prefix instructions are used to extend addressability, then the directly addressable data range is increased, but the debugging complexity increases due to prefix handling requirements

Engineering Contradiction:
Improvedirectly addressable data rangeVSAvoiddebugging complexity
Core Design Contradiction:
Volume of moving objectVSDevice complexity

Solution Approach 1:

The patent extracts the prefix handling logic from the normal instruction execution path by introducing a separate prefix storage facility and prefix detection mechanism. The trap instruction isolates prefix information in a dedicated register, separating it from the main execution flow and allowing independent handling of prefix and instruction debugging.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The prefix storage facility acts as an intermediary between the prefix instruction and the prefixed instruction. It stores prefix information (such as address extensions) and makes it available to the execution unit without requiring the debugging mechanism to directly interpret or handle the prefix-modified instruction semantics.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Reliability

If traps are inserted to debug prefixed instructions, then debugging capability is improved, but the trap execution may be incorrectly modified by the prefix

Engineering Contradiction:
Improvedebugging capabilityVSAvoidtrap execution accuracy
Core Design Contradiction:
ReliabilityVSManufacturing precision

Solution Approach 1:

The patent performs preliminary detection of prefix instructions before executing the trap. The system checks whether a prefix is present and, if so, prevents the prefix from modifying the trap instruction. This preliminary action ensures that the trap executes with its original semantics unchanged by any prefix.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent applies a counter-action to nullify the prefix effect on trap instructions. When a prefix is detected before a trap, the system actively prevents the prefix from taking effect on the trap instruction, thereby counteracting what would otherwise be a harmful modification to the trap's execution behavior.

Inventive Principle:
Principle #9Preliminary anti-action

3Quantity of substance

If breakpoints are set over prefix or prefixed instructions, then code coverage is improved, but the execution flow management becomes more complex

Engineering Contradiction:
Improvecode coverageVSAvoidexecution flow management
Core Design Contradiction:
Quantity of substanceVSDevice complexity

Solution Approach 1:

The patent segments the instruction stream into distinct prefix instructions and prefixed instructions. This segmentation allows the debugging system to independently track and manage breakpoints for each segment, simplifying execution flow management while maintaining comprehensive code coverage through separate handling of prefix and instruction portions.

Inventive Principle:
Principle #1Segmentation

Data Source

PatentUS10810104B2Debugging of prefixed code
Publication Date: 2020.10.20 INTERNATIONAL BUSINESS MACHINE CORPORATION
  • US10810104B2 patent drawing
  • US10810104B2 patent drawing
  • US10810104B2 patent drawing

AI summary

A debugging capability that enables the efficient debugging of code that has prefixes, referred to herein as prefixed code. To debug application code, in which the application code includes a prefixed instruction to be modified by a prefix, a trap is provided. The trap is configured to report a presence of the prefix, but to otherwise perform the trap functions absent the prefix; i.e., the prefix is otherwise ignored in the processing of the trap.