Read-Only Buffer Mapping for OpenCL Data Loading Efficiency

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

In OpenCL environments, the inefficient mapping of read-only buffers into ordinary memory buffers leads to suboptimal performance due to the abandonment of more efficient data loading solutions.

Innovation Solution

A method and apparatus for loading task data that analyzes buffers after task initiation to determine read-only buffers, maps them into matched read-only storage spaces, and loads task data based on obtained mapping information, thereby improving data loading efficiency.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If read-only buffers are mapped into ordinary memory buffers, then the system can handle both read-only and read-write buffers uniformly, but data loading efficiency deteriorates due to abandonment of efficient fetching instructions

Engineering Contradiction:
Improvebuffer mapping flexibilityVSAvoiddata loading efficiency
Core Design Contradiction:
Adaptability or versatilityVSProductivity

Solution Approach 1:

The patent segments the memory space into distinct read-only storage spaces and ordinary memory buffers. The compiler analyzes buffer access patterns and selectively maps read-only buffers to read-only storage spaces while mapping read-write buffers to ordinary memory buffers, thereby resolving the contradiction between uniform handling flexibility and optimized data loading efficiency

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent applies local quality by providing different storage space characteristics for different buffer types. Read-only buffers receive specialized read-only storage spaces with efficient fetching instructions, while read-write buffers use ordinary memory buffers, allowing each buffer type to utilize the most appropriate storage characteristics for its specific access patterns

Inventive Principle:
Principle #3Local quality

2Ease of manufacture

If the compiler uses ordinary memory buffer mapping for all buffers, then the implementation is simplified, but performance deteriorates by abandoning efficient fetching instructions for read-only buffers

Engineering Contradiction:
Improveimplementation simplicityVSAvoidprogram performance
Core Design Contradiction:
Ease of manufactureVSProductivity

Solution Approach 1:

The patent applies preliminary action by having the compiler perform static analysis during the compilation phase to identify read-only buffers and generate appropriate mapping instructions. This preliminary classification allows the system to automatically select optimal storage spaces without runtime complexity, maintaining implementation simplicity while achieving performance optimization

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent changes the mapping parameter from a uniform ordinary memory buffer mapping to a differentiated mapping strategy based on buffer access characteristics. The compiler modifies the mapping behavior by detecting read-only qualifiers and adjusting the storage space selection accordingly, thereby improving performance without significantly complicating the implementation

Inventive Principle:
Principle #35Parameter changes

3Productivity

If read-only buffers are identified and mapped to specialized storage spaces, then data loading efficiency is improved, but the system complexity increases due to additional analysis and mapping steps

Engineering Contradiction:
Improvedata loading efficiencyVSAvoidcompiler complexity
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent applies universality by designing a compiler analysis mechanism that handles both read-only and read-write buffers through a unified process. The same compiler infrastructure performs analysis and mapping for all buffers, automatically adapting the mapping strategy based on buffer characteristics, thereby limiting the increase in system complexity while achieving optimized data loading efficiency

Inventive Principle:
Principle #6Universality (Multi-functionality)

Data Source

PatentUS12307125B2Method and apparatus for loading task data, and computer device
Publication Date: 2025.05.20 GLENFLY TECH CO LTD
  • US12307125B2 patent drawing
  • US12307125B2 patent drawing
  • US12307125B2 patent drawing

AI summary

Disclosed are method and apparatus for loading task data, a computer device, a storage medium, and a computer program product. The method includes: analyzing various types of buffers involved in a task after the task is initiated, and determining whether each of the buffers satisfies a preset read-only buffer condition; determining a buffer satisfying the read-only buffer condition as a read-only buffer; mapping the read-only buffer into a matched read-only storage space based on space information of the read-only storage space and size information of the read-only buffer, and obtaining corresponding read-only mapping information; and loading task data in the read-only buffer into the matched read-only storage space based on the read-only mapping information. With the method, the loading efficiency of task data can be improved.