You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
HIP is a better name in this case as it is the API the plugin is
actually built on rather than ROCm which is more of a framework.
As discussed this patch renames the ROCm plugin to HIP, it is thus very large but doesn't have any functional changes.
I tested it on both AMD and NVIDIA with `check-sycl-hip` and `check-sycl-hip-on-device`, and the results were the same than before this patch with `check-sycl-rocm` and `check-sycl-rocm-on-device`.
@@ -108,8 +108,8 @@ flags can be found by launching the script with `--help`):
108
108
*`--system-ocl` -> Don't download OpenCL headers and library via CMake but use the system ones
109
109
*`--no-werror` -> Don't treat warnings as errors when compiling llvm
110
110
*`--cuda` -> use the cuda backend (see [Nvidia CUDA](#build-dpc-toolchain-with-support-for-nvidia-cuda))
111
-
*`--rocm` -> use the rocm backend (see [AMD ROCm](#build-dpc-toolchain-with-support-for-amd-rocm))
112
-
*`--rocm-platform` -> select the platform used by the rocm backend, `AMD` or `NVIDIA` (see [AMD ROCm](#build-dpc-toolchain-with-support-for-amd-rocm) or see [NVIDIA ROCm](#build-dpc-toolchain-with-support-for-nvidia-rocm))
111
+
*`--hip` -> use the HIP backend (see [HIP](#build-dpc-toolchain-with-support-for-hip-amd))
112
+
*`--hip-platform` -> select the platform used by the hip backend, `AMD` or `NVIDIA` (see [HIP AMD](#build-dpc-toolchain-with-support-for-hip-amd) or see [HIP NVIDIA](#build-dpc-toolchain-with-support-for-hip-nvidia))
113
113
* '--enable-esimd-cpu-emulation' -> enable ESIMD CPU emulation (see [ESIMD CPU emulation](#build-dpc-toolchain-with-support-for-esimd-cpu))
114
114
*`--shared-libs` -> Build shared libraries
115
115
*`-t` -> Build type (debug or release)
@@ -161,11 +161,12 @@ a Titan RTX GPU (SM 71), but it should work on any GPU compatible with SM 50 or
161
161
above. The default SM for the NVIDIA CUDA backend is 5.0. Users can specify
162
162
lower values, but some features may not be supported.
163
163
164
-
### Build DPC++ toolchain with support for AMD ROCm
165
-
There is experimental support for DPC++ for ROCm devices.
164
+
### Build DPC++ toolchain with support for HIP AMD
166
165
167
-
To enable support for ROCm devices, follow the instructions for the Linux
168
-
DPC++ toolchain, but add the `--rocm` flag to `configure.py`
166
+
There is experimental support for DPC++ for HIP devices.
167
+
168
+
To enable support for HIP devices, follow the instructions for the Linux
169
+
DPC++ toolchain, but add the `--hip` flag to `configure.py`
169
170
170
171
Enabling this flag requires an installation of
171
172
ROCm 4.2.0 on the system, refer to
@@ -176,31 +177,31 @@ Currently, the only combination tested is Ubuntu 18.04 with ROCm 4.2.0 using a V
176
177
[LLD](https://llvm.org/docs/AMDGPUUsage.html) is necessary for the AMD GPU compilation chain.
177
178
The AMDGPU backend generates a standard ELF [ELF] relocatable code object that can be linked by lld to
178
179
produce a standard ELF shared code object which can be loaded and executed on an AMDGPU target.
179
-
So if you want to support AMD ROCm, you should also build the lld project.
180
+
So if you want to support HIP AMD, you should also build the lld project.
180
181
[LLD Build Guide](https://lld.llvm.org/)
181
182
182
183
The following CMake variables can be updated to change where CMake is looking
183
-
for the ROCm installation:
184
+
for the HIP installation:
184
185
185
-
*`SYCL_BUILD_PI_ROCM_INCLUDE_DIR`: Path to HIP include directory (default
186
+
*`SYCL_BUILD_PI_HIP_INCLUDE_DIR`: Path to HIP include directory (default
186
187
`/opt/rocm/hip/include`).
187
-
*`SYCL_BUILD_PI_ROCM_HSA_INCLUDE_DIR`: Path to HSA include directory (default
188
+
*`SYCL_BUILD_PI_HIP_HSA_INCLUDE_DIR`: Path to HSA include directory (default
188
189
`/opt/rocm/hsa/include`).
189
-
*`SYCL_BUILD_PI_ROCM_AMD_LIBRARY`: Path to HIP runtime library (default
190
+
*`SYCL_BUILD_PI_HIP_AMD_LIBRARY`: Path to HIP runtime library (default
190
191
`/opt/rocm/hip/lib/libamdhip64.so`).
191
192
192
-
### Build DPC++ toolchain with support for NVIDIA ROCm
193
+
### Build DPC++ toolchain with support for HIP NVIDIA
193
194
194
-
There is experimental support for DPC++ for using ROCm on NVIDIA devices.
195
+
There is experimental support for DPC++ for using HIP on NVIDIA devices.
195
196
196
197
This is a compatibility feature and the [CUDA backend](#build-dpc-toolchain-with-support-for-nvidia-cuda)
197
198
should be preferred to run on NVIDIA GPUs.
198
199
199
-
To enable support for NVIDIA ROCm devices, follow the instructions for the Linux
200
-
DPC++ toolchain, but add the `--rocm` and `--rocm-platform NVIDIA` flags to
200
+
To enable support for HIP NVIDIA devices, follow the instructions for the Linux
201
+
DPC++ toolchain, but add the `--hip` and `--hip-platform NVIDIA` flags to
201
202
`configure.py`.
202
203
203
-
Enabling this flag requires ROCm to be installed, more specifically
204
+
Enabling this flag requires HIP to be installed, more specifically
When building forROCm, use the ROCm target triple and specify the
600
+
When building forHIP AMD, use the AMD target triple and specify the
600
601
target architecture with `-Xsycl-target-backend --offload-arch=<arch>`
601
602
as follows:
602
603
@@ -638,8 +639,8 @@ execution, so SYCL runtime will use `default_selector` logic to select one
638
639
of accelerators available in the system or SYCL host device.
639
640
In this case, the behavior of the `default_selector` can be altered
640
641
using the `SYCL_BE` environment variable, setting `PI_CUDA` forces
641
-
the usage of the CUDA backend (if available), `PI_ROCM` forces
642
-
the usage of the ROCm backend (if available), `PI_OPENCL` will
642
+
the usage of the CUDA backend (if available), `PI_HIP` forces
643
+
the usage of the HIP backend (if available), `PI_OPENCL` will
643
644
force the usage of the OpenCL backend.
644
645
645
646
```bash
@@ -783,15 +784,15 @@ which contains all the symbols required.
783
784
* The NVIDIA OpenCL headers conflict with the OpenCL headers required for this
784
785
project and may cause compilation issues on some platforms
785
786
786
-
### ROCm back-end limitations
787
+
### HIP back-end limitations
787
788
788
789
* For supported Operating Systems, please refer to the [Supported Operating Systems](https://github.com/RadeonOpenCompute/ROCm#supported-operating-systems)
789
790
* The only combination tested is Ubuntu 18.04 with ROCm 4.2 using a Vega20 gfx906.
790
791
* Judging from the current [test](https://github.com/zjin-lcf/oneAPI-DirectProgramming) results,
791
-
there is still a lot of room forimprovementinROCm back-end support. The current problems include three aspects.
792
+
there is still a lot of room forimprovementinHIP back-end support. The current problems include three aspects.
792
793
The first one is at compile time: the `barrier` and `atomic` keywords are not supported.
793
-
The second is at runtime: when calling `hipMemcpyDtoHAsync`ROCm API, the program will cause an exception if the input data size is too large.
794
-
The third is calculation accuracy: the ROCm backend has obvious errors in the calculation results of some float type operators
794
+
The second is at runtime: when calling `hipMemcpyDtoHAsync`HIP API, the program will cause an exception if the input data size is too large.
795
+
The third is calculation accuracy: the HIP backend has obvious errors in the calculation results of some float type operators
0 commit comments