CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
93 lines
2.5 KiB
ReStructuredText
93 lines
2.5 KiB
ReStructuredText
.. meta::
|
||
:description: HSA runtime implementation
|
||
:keywords: ROCR, ROCm, library, tool, runtime
|
||
|
||
.. _contributing-to-rocr:
|
||
|
||
Contributing to ROCR
|
||
========================
|
||
|
||
This document contains useful information required to contribute to ROCR.
|
||
|
||
.. _runtime-design:
|
||
|
||
Runtime design
|
||
-----------------
|
||
|
||
ROCR consists of the following primary layers:
|
||
|
||
1. :ref:`C interface adaptors <c-interface-adaptors>`
|
||
|
||
2. C++ interface classes and common functions
|
||
|
||
3. Device-specific implementations
|
||
|
||
The first layer provides interfaces to make ROCR APIs available to the user applications.
|
||
The second and third layers comprise of the internal ROCR implementation, which is available for contribution.
|
||
|
||
Additionally, the runtime is dependent on a small utility library that provides simple common functions, limited operating system, compiler abstraction, and atomic operation interfaces.
|
||
|
||
The following sections list the important files present in the second and third layer.
|
||
|
||
C++ interface classes and common functions
|
||
----------------------------------------------
|
||
|
||
The C++ interface layer provides abstract interface classes encapsulating commands to HSA signals, agents, and queues. This layer also contains the implementation of device-independent commands, such as ``hsa_init``, ``hsa_system_get_info``, and a default signal and queue implementation.
|
||
|
||
Files present in this layer:
|
||
|
||
- ``runtime.h`` (cpp)
|
||
|
||
- ``agent.h``
|
||
|
||
- ``queue.h``
|
||
|
||
- ``signal.h``
|
||
|
||
- ``memory_region.h`` (cpp)
|
||
|
||
- ``checked.h``
|
||
|
||
- ``memory_database.h`` (cpp)
|
||
|
||
- ``default_signal.h`` (cpp)
|
||
|
||
Device-specific implementations
|
||
----------------------------------
|
||
|
||
The device-specific layer contains implementations of the C++ interface classes that implement HSA functionality for ROCm supported devices.
|
||
|
||
Files present in this layer:
|
||
|
||
- ``amd_cpu_agent.h`` (cpp)
|
||
|
||
- ``amd_gpu_agent.h`` (cpp)
|
||
|
||
- ``amd_hw_aql_command_processor.h`` (cpp)
|
||
|
||
- ``amd_memory_region.h`` (cpp)
|
||
|
||
- ``amd_memory_registration.h`` (cpp)
|
||
|
||
- ``amd_topology.h`` (cpp)
|
||
|
||
- ``host_queue.h`` (cpp)
|
||
|
||
- ``interrupt_signal.h`` (cpp)
|
||
|
||
- ``hsa_ext_private_amd.h`` (cpp)
|
||
|
||
Source and include directories
|
||
--------------------------------
|
||
|
||
- ``core``: Source code for AMD’s implementation of the core HSA Runtime API’s
|
||
|
||
- ``cmake_modules``: CMake support modules and files
|
||
|
||
- ``inc``: Public and AMD-specific header files exposing the HSA Runtime`s interfaces
|
||
|
||
- ``libamdhsacode``: Code object definitions and interfaces
|
||
|
||
- ``loader``: Loads code objects
|
||
|
||
- ``utils``: Utilities required to build the core runtime |