Compiler Training System for Software Performance Portability
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional methods for maintaining performance portability in software programs across different hardware systems are limited due to incomplete knowledge of target hardware, leading to inefficient compiler transformations.
Innovation Solution
A compiler training system that utilizes machine learning techniques, analytical cost models, and profiled hardware performance data to automatically optimize software programs by generating and selecting optimal code transformations, storing them in a database for self-tuning capabilities.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If conventional compiler transformation methods are used, then software programs can be compiled, but performance portability across different hardware systems deteriorates due to incomplete knowledge of target hardware
Solution Approach 1:
The system performs preliminary actions by training the machine learning model in advance with extensive hardware performance data before actual compilation. The model learns optimal transformation strategies beforehand, enabling it to make accurate predictions even with limited target hardware knowledge during compilation.
Solution Approach 2:
The patent replaces conventional deterministic compiler transformation methods with a machine learning-based probabilistic system. The ML model substitutes traditional static analysis and heuristics, enabling adaptive transformation selection based on learned patterns from diverse hardware architectures.
2Productivity
If machine learning techniques are used to optimize code transformations, then software program efficiency improves, but device complexity increases due to the training system and database requirements
Solution Approach 1:
The system creates a copy of hardware performance characteristics in the form of training data and learned models. Instead of directly accessing complex hardware details during compilation, the compiler uses copied performance patterns from the training phase, simplifying the compilation process while maintaining optimization quality.
Solution Approach 2:
The complex work of learning hardware characteristics and optimal transformations is performed in advance during the training phase. This preliminary action separates the complex learning process from the compilation process, allowing the compiler to use pre-learned knowledge without bearing the full complexity burden during actual use.
3Manufacturing precision
If comprehensive hardware profiling is performed to improve transformation accuracy, then manufacturing precision of optimized code increases, but loss of time occurs during the profiling and training process
Solution Approach 1:
The system performs comprehensive hardware profiling and data collection in advance during the training phase. By moving this time-consuming activity to the training stage, the patent enables fast, accurate transformations during actual compilation without repeating the extensive profiling process.
Solution Approach 2:
The system uses feedback from performance measurements during training to continuously improve transformation accuracy. The ML model learns from measured performance data and adjusts its predictions, achieving high precision through iterative feedback rather than requiring exhaustive profiling at compilation time.
Data Source
AI summary
An example apparatus comprises a transformation generator to generate a population of code variants corresponding to an input code, the population of code variants to include transformation sequences of the input code, a dependence analyzer to analyze the population of code variants for dependence vectors, a profile controller to profile the population of code variants to determine performance metrics of hardware during an execution of respective ones of the transformation sequences, and a hash code generator to generate hash codes for storing in a database, the hash codes (a) corresponding to a combination of the dependence vectors and respective performance metrics and (b) mapped to respective transformation sequences.


