ROCm组件

文章来自微信公众号“科文路”,欢迎关注、互动。转发须注明出处。

本文介绍 ROCm 的主要组成组件。

Low-level

ROCk - Kernel driver

AMDgpu is AMD’s fully open source unified kernel driver for its GPUs on Linux.

ROCm - Device libraries

Support libraries implemented as LLVM bitcode. These provide various utilities and functions for math operations, atomics, queries for launch parameters, on-device kernel launch, etc.

ROCt - Thunk

The thunk is responsible for all the thinking and queuing that goes into the stack.

ROCr - Runtime

The ROC runtime is different from the ROC Common Language Runtime in that it is not the same thing.

ROCm - CompilerSupport

ROCm code object manager(Comgr) is in charge of interacting with LLVM intermediate representation.

Mid-level

ROCclr - Common Language Runtime

The common language runtime is an indirection layer adapting calls to ROCr on linux and PAL on windows. It used to be able to route between different compilers like the HSAIL-compiler. It is now being absorbed by the upper indirection layers (HIP, OpenCL).

OpenCL

ROCm ships its Installable Client Driver(ICD) loader and an OpenCL implementation bundled together. As of January 2022, ROCm 4.5.2 ships OpenCL 2.2, and is lagging behind competition.

HIP - Heterogeneous Interface for Portability

The AMD implementation for its GPUs is called HIPAMD. There is also a CPU implementation mostly for demonstration purposes. On the NVIDIA CUDA platform, HIP provides header file which translate from the HIP runtime APIs to CUDA runtime APIs. On the AMD ROCm platform, HIP provides a header and runtime library built on top of HIP-Clang compiler.

HIPCC

HIP builds a HIPCC compiler that either wraps Clang and compiles with LLVM open AMDGPU backend, or redirects to the NVIDIA compiler.

HIPIFY

HIPIFY is a source-to-source compiling tool, it translates CUDA to HIP and reverse, either using a clang-based tool, or a sed-like Perl script.

GPUFORT

Like HIPIFY, GPUFORT is a tool compiling source code into other third-generation-language sources, allowing users to migrate from CUDA Fortran to HIP Fortran. It is also in the repertoire of research projects, even more so.

High-level

ROCm high-level libraries are usually consumed directly by application software, such as machine learning frameworks. Most of the following libraries are in the General Matrix Multiply (GEMM) category, which GPU architecture excels at.

rocBLAS / hipBLAS

rocBLAS and hipBLAS are central in high-level libraries, it is the AMD implementation for Basic Linear Algebra Subprograms. It uses the library Tensile privately.

rocSOLVER / hipSOLVER

This pair of libraries constitutes the LAPACK implementation for ROCm and is strongly coupled to rocBLAS.

Utilities

ROCm developer tools

Debug, tracer, profiler, System Management Interface, Validation suite, Cluster management.

GPUOpen tools

GPU analyzer, memory visualizer…

External tools

radeontop (TUI overview)

都看到这儿了,不如关注每日推送的“科文路”、互动起来~

Author

xlindo

Posted on

2022-03-14

Updated on

2023-05-10

Licensed under

Comments