mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-23 22:13:38 +00:00
ROCm header path updates (#14170)
ROCm reorganized header file locations. Use the new locations to avoid warnings.
This commit is contained in:
parent
9c0c49900e
commit
fe052e603b
3 changed files with 8 additions and 3 deletions
|
|
@ -262,7 +262,7 @@ if (onnxruntime_USE_ROCM)
|
|||
endif()
|
||||
|
||||
if (NOT CMAKE_HIP_ARCHITECTURES)
|
||||
set(CMAKE_HIP_ARCHITECTURES "gfx906;gfx908;gfx90a;gfx1030")
|
||||
set(CMAKE_HIP_ARCHITECTURES "gfx906;gfx908;gfx90a")
|
||||
endif()
|
||||
|
||||
file(GLOB rocm_cmake_components ${onnxruntime_ROCM_HOME}/lib/cmake/*)
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ limitations under the License.
|
|||
#pragma once
|
||||
|
||||
#include <hip/hip_fp16.h>
|
||||
#include <hipblas.h>
|
||||
#include <hipblas/hipblas.h>
|
||||
#include <hipcub/hipcub.hpp>
|
||||
#include "core/providers/rocm/rocm_common.h"
|
||||
#include "core/providers/rocm/cu_inc/common.cuh"
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ def hipify(hipify_perl_path, src_file_path, dst_file_path):
|
|||
|
||||
# NCCL -> RCCL
|
||||
# s = s.replace('NCCL_CALL', 'RCCL_CALL')
|
||||
s = s.replace("#include <nccl.h>", "#include <rccl.h>")
|
||||
s = s.replace("#include <nccl.h>", "#include <rccl/rccl.h>")
|
||||
|
||||
# CUDNN -> MIOpen
|
||||
s = s.replace("CUDNN", "MIOPEN")
|
||||
|
|
@ -161,6 +161,11 @@ def hipify(hipify_perl_path, src_file_path, dst_file_path):
|
|||
# Deletions
|
||||
s = s.replace('#include "device_atomic_functions.h"', "") # HIP atomics in main hip header already
|
||||
|
||||
# Fix warnings due to incorrect header paths, intentionally after all other hipify steps.
|
||||
s = s.replace("#include <hiprand_kernel.h>", "#include <hiprand/hiprand_kernel.h>")
|
||||
s = s.replace("#include <rocblas.h>", "#include <rocblas/rocblas.h>")
|
||||
s = s.replace("#include <hipblas.h>", "#include <hipblas/hipblas.h>")
|
||||
|
||||
with open(dst_file_path, "w") as f:
|
||||
f.write(s)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue