Processor Hardware Detecting Memory Aliasing for Register Promotion

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Modern computer compilers are unable to perform register promotion optimizations in regions of code where memory aliasing can occur, leading to suboptimal performance due to the risk of memory aliasing, which limits the execution time and efficiency of computer programs.

Innovation Solution

Incorporating processor hardware that detects and corrects memory aliasing, allowing compilers to use special store instructions and address tags to ensure proper operation even in regions with memory aliasing, enabling aggressive optimizations like register promotion.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Speed

If compilers perform register promotion optimizations in regions where memory aliasing can occur, then code execution speed improves, but functional correctness may be compromised due to undetected memory aliasing

Engineering Contradiction:
Improvecode execution speedVSAvoidfunctional correctness
Core Design Contradiction:
SpeedVSReliability

Solution Approach 1:

The patent introduces address tags as an intermediary mechanism between registers and memory addresses. These tags track the aliasing status of memory addresses, allowing the compiler to perform aggressive register promotion optimizations while the hardware monitoring system detects and handles any aliasing violations that occur, thus maintaining both performance and correctness.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The system implements feedback through hardware monitoring that detects memory aliasing conditions and triggers corrective actions. When aliasing is detected, the system flushes the instruction pipeline and re-executes instructions, providing feedback that ensures functional correctness while allowing optimized code to run in between corrections.

Inventive Principle:
Principle #23Feedback

2Reliability

If compilers avoid register promotion in regions where memory aliasing can occur, then functional correctness is maintained, but code execution speed deteriorates

Engineering Contradiction:
Improvefunctional correctnessVSAvoidcode execution speed
Core Design Contradiction:
ReliabilityVSSpeed

Solution Approach 1:

Address tags serve as an intermediary that enables the compiler to ignore potential aliasing issues during optimization and defer handling to hardware. This allows the compiler to generate fully optimized code with register promotion throughout, while the hardware tag system monitors and corrects any actual aliasing violations.

Inventive Principle:
Principle #24Intermediary (Mediator)

Solution Approach 2:

The hardware monitoring system provides self-service by automatically detecting memory aliasing conditions and correcting them through pipeline flushing and re-execution, without requiring compiler intervention or conservative optimization decisions. This allows the compiler to focus solely on performance optimization.

Inventive Principle:
Principle #25Self-service

3Adaptability or versatility

If hardware monitoring for memory aliasing is implemented, then code optimization freedom improves, but device complexity increases

Engineering Contradiction:
Improvecode optimization freedomVSAvoidhardware complexity
Core Design Contradiction:
Adaptability or versatilityVSDevice complexity

Solution Approach 1:

The patent segments the aliasing monitoring function into individual address tags associated with each register. Rather than a monolithic monitoring system, each register has its own tag that tracks the aliasing status of its associated memory address, distributing the complexity across multiple simple, identical structures.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The system changes the parameter tracking approach by adding address tags as an additional parameter to register operations. These tags store aliasing status information that can be monitored and corrected, transforming the hardware to provide monitoring capabilities through parameter extension rather than fundamental architectural changes.

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS10169009B2Processor that detects memory aliasing in hardware and assures correct operation when memory aliasing occurs
Publication Date: 2019.01.01 INTERNATIONAL BUSINESS MACHINE CORPORATION
  • US10169009B2 patent drawing
  • US10169009B2 patent drawing
  • US10169009B2 patent drawing

AI summary

Processor hardware detects when memory aliasing occurs, and assures proper operation of the code even in the presence of memory aliasing. Because the hardware can detect and correct for memory aliasing, this allows a compiler to make optimizations such as register promotion even in regions of the code where memory aliasing can occur. The result is code that is more optimized and therefore runs faster.