Dynamic Software Pipelining Rollback Recovery

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Software pipelining techniques face significant roll-back overhead when speculative iterations result in exceptions, leading to the costly discarding of all previous results and re-execution of loops, which is inefficient in terms of computational resources and time.

Innovation Solution

Implementing a code generation technique that allows recovery of the last non-speculative iteration's results and delayed store operations by keeping extra copies of 'live-out' values and extending the lifetime of registers, enabling partial recovery and resuming execution from a committed point rather than rolling back to the beginning of the loop.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If speculative iterations are executed in software pipelining to increase throughput, then loop execution speed is improved, but exception handling overhead increases due to roll-back requirements

Engineering Contradiction:
Improveloop execution throughputVSAvoidroll-back overhead time
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The patent applies preliminary action by saving iteration results to a stack data structure before speculative execution begins. This pre-prepared storage mechanism allows the system to quickly restore previous states without performing expensive roll-back operations when exceptions occur, thus reducing the time loss while maintaining high throughput.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent implements discarding and recovering by using a stack to preserve valid iteration results before speculative execution. When an exception occurs, the system can discard the invalid speculative results and recover the previously saved valid results from the stack, avoiding the need to re-execute entire loop iterations and significantly reducing roll-back overhead.

Inventive Principle:
Principle #34Discarding and recovering

2Reliability

If roll-back is implemented to correct invalid results from speculative iterations, then correctness is maintained, but computational resources are wasted

Engineering Contradiction:
Improveiteration result correctnessVSAvoidcomputational resource waste
Core Design Contradiction:
ReliabilityVSLoss of energy

Solution Approach 1:

The patent uses preliminary action by pre-saving valid iteration results in a stack before speculative execution. This ensures that when exceptions occur, the system can immediately restore correct results without wasting computational resources on re-execution, thus maintaining reliability while minimizing energy waste.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent applies copying by creating a duplicate copy of valid iteration results and storing them in a stack data structure. This copy serves as a backup that can be quickly restored when speculative execution fails, ensuring correctness without the need to re-compute the results, thereby reducing computational resource consumption.

Inventive Principle:
Principle #26Copying

3Adaptability or versatility

If aggressive speculation is performed in atomic regions, then optimization effectiveness is improved, but roll-back overhead increases when exceptions occur

Engineering Contradiction:
Improveoptimization scopeVSAvoidroll-back overhead
Core Design Contradiction:
Adaptability or versatilityVSLoss of time

Solution Approach 1:

The patent applies preliminary action by saving the state at the beginning of atomic regions to a stack before aggressive speculation is performed. This pre-saved state enables quick recovery when exceptions occur, allowing the system to maintain broad optimization scope while minimizing the time loss from roll-back operations.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent implements discarding and recovering by using a stack to preserve valid states before speculative execution in atomic regions. When exceptions occur, the system can discard invalid speculative results and recover the previously saved valid states, thus maintaining optimization versatility while reducing roll-back overhead time.

Inventive Principle:
Principle #34Discarding and recovering

Data Source

PatentEP2997462B1Dynamic optimization of pipelined software
Publication Date: 2020.03.11 INTEL CORP
  • EP2997462B1 patent drawingFigure 1
  • EP2997462B1 patent drawingFigure 2
  • EP2997462B1 patent drawingFigure 3

AI summary

In an embodiment, a system includes a processor including at least one core to execute operations of a loop that includes S stages. The system also includes stage insertion means for adding a delay stage to the loop to increase a lifetime of a corresponding register associated with a first variable of the loop and to delay storage of contents of the register. The system also includes a dynamic random access memory (DRAM). Other embodiments are described and claimed.