Skip to content

Commit

Permalink
support rocm>=6
Browse files Browse the repository at this point in the history
  • Loading branch information
vicentebolea committed Jun 27, 2024
1 parent 43dd72c commit b8661a6
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/everything.yml
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ jobs:
compiler: gcc8
shared: static
parallel: serial
- os: ubuntu20.04
- os: ubuntu22.04
compiler: rocm
parallel: serial
constrains: build_only
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
set(ENV{CC} gcc)
set(ENV{CXX} g++)
set(ENV{FC} gfortran)
set(ENV{FC} )

execute_process(
COMMAND "python3-config" "--prefix"
OUTPUT_VARIABLE PY_ROOT
OUTPUT_STRIP_TRAILING_WHITESPACE)

set(dashboard_cache "
BUILD_TESTING:BOOL=ON
BUILD_TESTING:BOOL=OFF
ADIOS2_BUILD_EXAMPLES:BOOL=ON
ADIOS2_USE_BZip2:BOOL=ON
Expand All @@ -34,6 +35,8 @@ CMAKE_CXX_COMPILER_LAUNCHER=ccache
CMAKE_C_FLAGS:STRING=-Wall
CMAKE_CXX_FLAGS:STRING=-Wall
CMAKE_Fortran_FLAGS:STRING=-Wall
OpenMP_gomp_LIBRARY:FILEPATH=/spack/var/spack/environments/adios2-ci-serial/.spack-env/view/lib/libgomp.so.1
AMDGPU_TARGETS=gfx906
")

set(CTEST_CMAKE_GENERATOR "Ninja")
Expand Down
File renamed without changes.
4 changes: 4 additions & 0 deletions source/adios2/helper/kokkos/adiosKokkos.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,11 @@ bool IsGPUbuffer(const void *ptr)
hipError_t ret;
hipPointerAttribute_t attr;
ret = hipPointerGetAttributes(&attr, ptr);
#if defined(ROCM_VERSION_MAJOR) && ROCM_VERSION_MAJOR < 6
if (ret == hipSuccess && attr.memoryType == hipMemoryTypeDevice)
#else
if (ret == hipSuccess && attr.type == hipMemoryTypeDevice)
#endif
{
return true;
}
Expand Down

0 comments on commit b8661a6

Please sign in to comment.