The one machine this toolchain is written for, and the memory map the GPU sees.
The design of redbluegreen targets a machine where
the CPU and the GPU share a single unified pool of memory. The two
reach a buffer through the same virtual address. The pool is system
RAM, so the machine is capacity-rich and bandwidth-poor. This lets the
machine host large models in memory, but then run slowly, because
each weight arrives at memory speed. This bottleneck is also true for
training.
The machine is abundant in compute, but its pathway to the memory is narrow.
On boot, the driver gives the GPU a GTT window into the unified memory pool. The CPU owns the rest of the pool. Firmware carves out a small amount of VRAM. On this chip the kernel puts the GPU page tables in that carve-out, because amdgpu_vm_pt.c uses system memory for them only on app APUs, and this part is not one.
The desktop keeps the carve-out near full. A new mapping made while another process runs on the GPU can evict that process's buffer, and that ends in a reset. The reset page gives the full chain.
| Quantity | Value |
|---|---|
| System RAM, unified | 125 GiB |
| GTT window the GPU may map | 96 GiB |
| VRAM carve-out | 512 MiB |
| Carve-out held by the desktop | about 90 percent |
| Bandwidth, theoretical | 256 GB/s |
| Bandwidth, measured on a streaming load | 225 GB/s |
| CPU threads | 32 |
| Compute units, wave32 | 40, with 80 SIMDs |
So, our approach to training falls into three rules so far:
docs/birdseye.mddocs/lessons.mddrivers/gpu/drm/amd/amdgpu/amdgpu_vm_pt.c, for the
page-table placement