Difference GART/GTT and related questions

Peter Maucher bellosilicio at gmail.com
Fri Oct 7 15:49:48 UTC 2022


Hi dri-devel,

what is the difference between GTT and GART for AMD GPUs?
 From what I gathered when looking through the mailing list archives and 
the freedesktop docs [1] as well as wikipedia [2],
these terms seem to be synonymous, but that can not be the whole truth
(different sizes in dmesg log, different kernel parameters in 
amdgpu/radeon, ...).

As far as I understand it currently,
the size of the GART is depending on some HW/ASIC functionality [3].
On the other hand, I was successfully able to increase the size of the 
GART mapping(?) from 512MB to 1024MB by using amdgpu.gartsize=1024 on my 
RX 6600, and booting the system.

GTT, on the other hand, is the maximum amount of system memory visible 
to the GPU, shared between all processes connected to the GPU.
As I understand it, using GPUVM, each process can have one or more GARTs 
for mapping?
Apparently, there is also something called a GART table window,
what's up with that?

Also, according to what I found in the mailing list archives,
the GPUVM functionality "replaces" old GART with new GART features,
so what is the difference and what exactly is GPUVM?
If I understood correctly, GPUVM is a MMU using page tables on the GPU?

And, additionally, the addresses translated by the GART(s) are 
optionally translated once more by the PCIe IOMMU,
as the former is located on the GPU and the latter is in the CPU's PCIe 
root complex?
Wikipedia mentions something about (another?) GART in an AMD IOMMU...

Lastly, do any of these numbers influence what the longest contiguous 
mapping is for one buffer to the GPU?
As in: can I map 95% or so of the available (GART/GTT?) space into one 
buffer and have the GPU work on it?

Thanks, Peter

[1] https://dri.freedesktop.org/wiki/GART/
[2] https://en.wikipedia.org/wiki/Graphics_address_remapping_table
[3] https://www.kernel.org/doc/html/v6.0/gpu/amdgpu/module-parameters.html



More information about the dri-devel mailing list