Unified Memory Architecture for CPU-GPU Data Coherence
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Current operating systems manage GPUs as I/O devices, leading to separate physical and virtual address domains, which results in inefficiencies when offloading computational tasks to GPUs due to data copying, restructuring, and pointer chasing.
Innovation Solution
Implementing a unified memory architecture (UMA) that provides shared virtual memory between the CPU and GPU, allowing both to access the same physical memory without copying data or restructuring, by creating equivalent virtual address spaces and pinning the shared surface to ensure data coherence.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Device complexity
If separate physical and virtual address domains are used for CPU and GPU, then device complexity is reduced and ease of operation is improved, but data copying time increases and productivity decreases
Solution Approach 1:
The patent merges the separate virtual address spaces of CPU and GPU into a unified virtual address space. This allows both processors to access the same virtual memory addresses without data copying, directly resolving the contradiction by eliminating the productivity penalty while maintaining manageable complexity through unified memory management.
Solution Approach 2:
The unified memory architecture provides universal access to memory resources across both CPU and GPU through a common virtual address space. This multi-functional memory system serves both processors simultaneously, improving productivity by eliminating data transfer overhead while maintaining operational simplicity through a single memory management mechanism.
2Reliability
If data copying is performed between CPU and GPU memory, then data integrity is maintained, but time consumption increases and productivity decreases
Solution Approach 1:
By merging the virtual address spaces of CPU and GPU, the system eliminates the need for data copying while maintaining data integrity through unified memory access. Both processors access the same physical memory through their respective virtual addresses, ensuring data consistency without the time overhead of copying operations.
3Ease of operation
If separate virtual addressing schemes are used for CPU and GPU, then ease of operation is improved, but data copying requirements increase and productivity decreases
Solution Approach 1:
The unified virtual address space merges the separate addressing schemes into a single coherent memory model. This maintains ease of operation through simplified memory access patterns while dramatically improving productivity by eliminating the data copying overhead that would otherwise be required between the CPU and GPU.
Data Source
AI summary
A method and system for shared virtual memory between a central processing unit (CPU) and a graphics processing unit (GPU) of a computing device are disclosed herein. The method includes allocating a surface within a system memory. A CPU virtual address space may be created, and the surface may be mapped to the CPU virtual address space within a CPU page table. The method also includes creating a GPU virtual address space equivalent to the CPU virtual address space, mapping the surface to the GPU virtual address space within a GPU page table, and pinning the surface.


