Shader Pre-Compilation Cache for High-Refresh Rendering

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

The high refresh rates in mobile devices with Android platforms lead to time constraints in shader compilation, causing rendering delays and frame drops due to the time-consuming nature of shader compilation processes.

Innovation Solution

A pre-processing system and method that involves pre-compiling shaders using a generating module to create output files, which are then stored in persistent caches for quick retrieval during rendering, reducing the need for real-time compilation.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If shader compilation is performed during rendering, then visual effects can be generated, but rendering time is blocked and frame drops occur

Engineering Contradiction:
Improverendering continuityVSAvoidshader compilation time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent applies preliminary action by pre-compiling shaders before they are actually needed for rendering. The system intercepts shader compilation requests, compiles the shaders in advance, and stores the compiled results in a cache. This allows the rendering process to directly use pre-compiled shaders without being blocked by compilation operations, thereby ensuring rendering continuity while eliminating compilation time delays.

Inventive Principle:
Principle #10Preliminary action

2Speed

If high refresh rate is implemented, then screen smoothness is improved, but rendering time per frame is reduced to 8.3ms or less

Engineering Contradiction:
Improverefresh rateVSAvoidrendering time per frame
Core Design Contradiction:
SpeedVSDuration of action of moving object

Solution Approach 1:

To support high refresh rates with limited rendering time per frame, the patent uses preliminary action by pre-compiling shaders before the tight rendering deadline. The pre-compilation process occurs outside the critical rendering path, so when high refresh rate rendering needs to complete within 8.3ms or less, the shaders are already compiled and ready for immediate use, eliminating compilation time from the per-frame budget.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The patent extracts the shader compilation operation from the rendering process itself. By separating compilation from rendering and performing compilation in advance, the system removes the time-consuming compilation step from the critical rendering path. This extraction allows the rendering process to focus solely on generating visual output within the constrained time window required for high refresh rates.

Inventive Principle:
Principle #2Taking out (Extraction)

3Reliability

If shader code is compiled to executable instructions, then desired visual effects are achieved, but compilation process becomes a bottleneck

Engineering Contradiction:
Improvevisual effect qualityVSAvoidrendering throughput
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent resolves the bottleneck by applying preliminary action - compiling shaders in advance before they are needed for rendering. The system intercepts compilation requests, performs the compilation operation beforehand, and stores results in cache. This ensures that high-quality visual effects are achieved through proper shader compilation while preventing compilation from becoming a bottleneck in the rendering pipeline, as compiled shaders are readily available for immediate use.

Inventive Principle:
Principle #10Preliminary action

Data Source

PatentUS12555182B2Pre-processing system and method thereof
Publication Date: 2026.02.17 MEDIATEK SINGAPORE PTE LTD
  • US12555182B2 patent drawing
  • US12555182B2 patent drawing
  • US12555182B2 patent drawing

AI summary

A pre-processing system for pre-compiling a shader, includes the following elements. A first persistent cache, disposed in a render engine of surface-flinger. A second persistent cache, disposed in a HWUI (Hardware Accelerated Rendering Engine for UI). A generating module, used to generate a text file, a binary file and a describer associated with the shader, and the shader is used to render a plurality of pages for an application program (APP). An installing module, used to store the text file and the binary file into a scan file path of the first persistent cache and/or the second persistent cache based on the describer.