Compiler Buffer Analysis for Heterogeneous Memory Allocation

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current computing systems with heterogeneous memory technologies face challenges in allocating and managing memory resources efficiently, as different applications have varying resource needs, and existing compiler technologies lack effective methods to map code blocks to suitable memory types based on specific memory attributes.

Innovation Solution

A compiler analysis method that identifies buffer access characteristics in code blocks, maps these characteristics to physical memory attributes, and generates system calls for optimal memory allocation, selecting the most suitable memory type for each application based on latency, bandwidth, power consumption, and other attributes.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If compiler performs basic code generation without memory analysis, then compilation speed is maintained, but memory allocation efficiency deteriorates

Engineering Contradiction:
Improvememory allocation efficiencyVSAvoidcompiler complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The compiler performs preliminary analysis of buffer access characteristics (access frequency, interleave value, size) during the compilation process before code generation. This preliminary action enables the compiler to predict physical memory attributes and generate optimized system calls for memory allocation, improving memory allocation efficiency without requiring runtime analysis overhead.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent introduces an intermediary layer between source code and executable code that analyzes buffer access patterns and maps them to physical memory attributes. This intermediary analysis phase acts as a mediator that translates high-level code characteristics into low-level memory allocation decisions, enabling efficient memory placement without exposing complexity to the programmer.

Inventive Principle:
Principle #24Intermediary (Mediator)

2Measurement precision

If compiler analyzes buffer access characteristics to predict memory attributes, then memory placement accuracy is improved, but compilation time increases

Engineering Contradiction:
Improvememory attribute prediction accuracyVSAvoidcompilation time
Core Design Contradiction:
Measurement precisionVSLoss of time

Solution Approach 1:

The compiler applies partial analysis by focusing only on identifying buffer access characteristics (frequency, interleave, size) that are most critical for memory placement decisions. Rather than performing exhaustive analysis of all code attributes, the patent selectively analyzes relevant buffer properties, achieving sufficient prediction accuracy while minimizing compilation time overhead.

Inventive Principle:
Principle #16Partial or excessive action

3Productivity

If system uses heterogeneous memory technologies, then system performance is improved, but memory management complexity increases

Engineering Contradiction:
Improvesystem performanceVSAvoidmemory management ease
Core Design Contradiction:
ProductivityVSEase of operation

Solution Approach 1:

The patent enables memory to essentially self-allocate by having the compiler automatically analyze code buffer access characteristics and generate appropriate system calls for memory allocation. This self-service approach eliminates the need for programmers to manually manage heterogeneous memory resources, reducing memory management complexity while maintaining performance optimizations.

Inventive Principle:
Principle #25Self-service

Solution Approach 2:

The compiler dynamically changes memory allocation parameters (such as memory type, placement location) based on analyzed buffer access characteristics. By automatically adjusting these parameters according to code-specific requirements, the system manages heterogeneous memory efficiently without requiring complex manual configuration or programmer intervention.

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS10802809B2Predicting physical memory attributes by compiler analysis of code blocks
Publication Date: 2020.10.13 INTERNATIONAL BUSINESS MACHINE CORPORATION
  • US10802809B2 patent drawing
  • US10802809B2 patent drawing
  • US10802809B2 patent drawing

AI summary

Predicting physical memory attributes by compiler analysis of code blocks includes receiving source code including at least one code block, and identifying a buffer associated with the at least one code block. Buffer access characteristics associated with the buffer are determined from the at least one code block. The buffer access characteristics are mapped to physical memory attributes associated with one or more physical memories of a computing system. Executable program code including a system call associated with memory allocation is generated based upon the physical memory attribute values.