요약·해설과 원문, 전문 번역을 서로 분리했습니다. API 이름, symbol, source path는 원문 표기를 사용합니다.
1. 요약·해설
원문의 핵심 논리와 kernel programming 관점의 보충 설명입니다. 아래의 전문 번역과는 별도로 작성했습니다.
2. 영어 원문 전체
번역 기준이 된 Linux v6.18.37 원문입니다. 줄 번호는 이 버전의 파일 좌표입니다.
원문 전체 펼치기
.. _amdgpu-gc:
========================================
drm/amdgpu - Graphics and Compute (GC)
========================================
The relationship between the CPU and GPU can be described as the
producer-consumer problem, where the CPU fills out a buffer with operations
(producer) to be executed by the GPU (consumer). The requested operations in
the buffer are called Command Packets, which can be summarized as a compressed
way of transmitting command information to the graphics controller.
The component that acts as the front end between the CPU and the GPU is called
the Command Processor (CP). This component is responsible for providing greater
flexibility to the GC since CP makes it possible to program various aspects of
the GPU pipeline. CP also coordinates the communication between the CPU and GPU
via a mechanism named **Ring Buffers**, where the CPU appends information to
the buffer while the GPU removes operations. It is relevant to highlight that a
CPU can add a pointer to the Ring Buffer that points to another region of
memory outside the Ring Buffer, and CP can handle it; this mechanism is called
**Indirect Buffer (IB)**. CP receives and parses the Command Streams (CS), and
writes the operations to the correct hardware blocks.
Graphics (GFX) and Compute Microcontrollers
-------------------------------------------
GC is a large block, and as a result, it has multiple firmware associated with
it. Some of them are:
CP (Command Processor)
The name for the hardware block that encompasses the front end of the
GFX/Compute pipeline. Consists mainly of a bunch of microcontrollers
(PFP, ME, CE, MEC). The firmware that runs on these microcontrollers
provides the driver interface to interact with the GFX/Compute engine.
MEC (MicroEngine Compute)
This is the microcontroller that controls the compute queues on the
GFX/compute engine.
MES (MicroEngine Scheduler)
This is the engine for managing queues. For more details check
:ref:`MicroEngine Scheduler (MES) <amdgpu-mes>`.
RLC (RunList Controller)
This is another microcontroller in the GFX/Compute engine. It handles
power management related functionality within the GFX/Compute engine.
The name is a vestige of old hardware where it was originally added
and doesn't really have much relation to what the engine does now.
.. toctree::
mes.rst
3. 한국어 전문 번역
영어 원문의 문단 순서와 의미를 유지한 전체 번역입니다. 코드, 함수명, symbol과 URL은 원문 표기를 유지합니다.
CPU와 GPU 사이의 명령 흐름
1-22CPU와 GPU의 관계는 생산자-소비자 문제로 설명할 수 있습니다. 생산자인 CPU가 실행할 연산으로 버퍼를 채우면 소비자인 GPU가 그 연산을 실행합니다. 버퍼에 담긴 요청 연산은 Command Packet이라 부르며, 그래픽 컨트롤러로 명령 정보를 압축해 전달하는 방식으로 요약할 수 있습니다.
CPU와 GPU 사이의 프런트엔드는 Command Processor(CP)입니다. CP는 GPU 파이프라인의 여러 측면을 프로그래밍할 수 있게 하여 Graphics and Compute(GC) 블록의 유연성을 높입니다. 또한 CPU가 정보를 추가하고 GPU가 연산을 제거하는 Ring Buffer 메커니즘을 통해 두 장치의 통신을 조정합니다.
CPU는 Ring Buffer 바깥의 다른 메모리 영역을 가리키는 포인터를 Ring Buffer에 추가할 수 있고 CP는 이를 처리할 수 있습니다. 이 메커니즘을 Indirect Buffer(IB)라고 합니다. CP는 Command Stream(CS)을 받아 파싱한 뒤 연산을 올바른 하드웨어 블록에 기록합니다.
생산자인 CPU가 만든 명령이 CP를 거쳐 GPU 하드웨어 블록으로 전달되는 관계입니다.
원문에서 사용하는 용어와 역할을 대응시킵니다.
.. _amdgpu-gc:
========================================
drm/amdgpu - Graphics and Compute (GC)
========================================
The relationship between the CPU and GPU can be described as the
producer-consumer problem, where the CPU fills out a buffer with operations
(producer) to be executed by the GPU (consumer). The requested operations in
the buffer are called Command Packets, which can be summarized as a compressed
way of transmitting command information to the graphics controller.
The component that acts as the front end between the CPU and the GPU is called
the Command Processor (CP). This component is responsible for providing greater
flexibility to the GC since CP makes it possible to program various aspects of
the GPU pipeline. CP also coordinates the communication between the CPU and GPU
via a mechanism named **Ring Buffers**, where the CPU appends information to
the buffer while the GPU removes operations. It is relevant to highlight that a
CPU can add a pointer to the Ring Buffer that points to another region of
memory outside the Ring Buffer, and CP can handle it; this mechanism is called
**Indirect Buffer (IB)**. CP receives and parses the Command Streams (CS), and
writes the operations to the correct hardware blocks.
Graphics와 Compute 마이크로컨트롤러
23-48GC는 큰 하드웨어 블록이므로 여러 firmware가 연결됩니다. CP는 GFX/Compute 파이프라인의 프런트엔드를 포괄하는 하드웨어 블록의 이름입니다. 주로 PFP, ME, CE, MEC 마이크로컨트롤러로 구성되며, 이들에서 실행되는 firmware가 드라이버와 GFX/Compute 엔진이 상호작용할 인터페이스를 제공합니다.
MEC(MicroEngine Compute)는 GFX/Compute 엔진의 compute queue를 제어합니다. MES(MicroEngine Scheduler)는 queue를 관리하는 엔진이며, 자세한 설명은 `MicroEngine Scheduler (MES) <amdgpu-mes>` 참조에서 이어집니다.
RLC(RunList Controller)는 GFX/Compute 엔진의 또 다른 마이크로컨트롤러이며, 그 엔진 안에서 power management 관련 기능을 처리합니다. RLC라는 이름은 처음 추가됐던 오래된 하드웨어의 흔적으로, 현재 엔진이 수행하는 작업과는 실제로 큰 관련이 없습니다.
각 약어가 가리키는 범위와 원문에 명시된 역할입니다.
문서가 설명하는 큰 블록과 세부 제어 구성요소의 관계를 정리합니다.
Graphics (GFX) and Compute Microcontrollers
-------------------------------------------
GC is a large block, and as a result, it has multiple firmware associated with
it. Some of them are:
CP (Command Processor)
The name for the hardware block that encompasses the front end of the
GFX/Compute pipeline. Consists mainly of a bunch of microcontrollers
(PFP, ME, CE, MEC). The firmware that runs on these microcontrollers
provides the driver interface to interact with the GFX/Compute engine.
MEC (MicroEngine Compute)
This is the microcontroller that controls the compute queues on the
GFX/compute engine.
MES (MicroEngine Scheduler)
This is the engine for managing queues. For more details check
:ref:`MicroEngine Scheduler (MES) <amdgpu-mes>`.
RLC (RunList Controller)
This is another microcontroller in the GFX/Compute engine. It handles
power management related functionality within the GFX/Compute engine.
The name is a vestige of old hardware where it was originally added
and doesn't really have much relation to what the engine does now.
MES 하위 문서 연결
49-52이 색인의 toctree는 `mes.rst`를 하위 문서로 포함합니다. 본문의 `amdgpu-mes` 참조는 해당 문서 첫 줄의 anchor와 연결되며, MES의 상세한 queue 관리 설명으로 이동합니다.
anchor, 내부 참조, 하위 문서가 같은 문서 계층을 구성합니다.
.. toctree::
mes.rst
요약·해설
index.rst:1-52AMDGPU의 Graphics and Compute(GC) 문서는 CPU가 명령을 생산하고 GPU가 소비하는 구조를 설명합니다. CP가 Ring Buffer와 IB를 통해 전달된 CS를 파싱하여 올바른 하드웨어 블록으로 보내며, CP를 구성하는 여러 마이크로컨트롤러와 별도의 MES·RLC가 queue 및 power management 기능을 담당합니다.
명령 경로와 제어 firmware를 두 축으로 읽을 수 있습니다.