mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-25 18:55:30 -06:00
Enable hipcc, works if other modules are compiled by clang++
Disable rocalution for hipcc/clang with rocm < 5.3
This commit is contained in:
parent
bec51c4471
commit
9708a96501
@ -259,17 +259,11 @@ macro (config_hook)
|
||||
|
||||
if(hip_FOUND)
|
||||
get_filename_component(CXX_COMPILER ${CMAKE_CXX_COMPILER} NAME)
|
||||
if(${CXX_COMPILER} STREQUAL "hipcc")
|
||||
message(FATAL_ERROR " hipcc does not work, use g++ or clang++")
|
||||
endif()
|
||||
if(hip_VERSION VERSION_LESS "5.3")
|
||||
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
message(WARNING " Cannot use g++ for rocsparse with rocm < 5.3\n Disabling rocsparseSolver")
|
||||
unset(HAVE_ROCSPARSE)
|
||||
endif()
|
||||
if(ROCALUTION_FOUND)
|
||||
set(HAVE_ROCALUTION 1)
|
||||
set(COMPILE_BDA_BRIDGE 1)
|
||||
if(ROCALUTION_FOUND AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
message(WARNING " Cannot use hipcc/clang for rocalution with rocm < 5.3\n Disabling rocalutionSolver")
|
||||
unset(ROCALUTION_FOUND)
|
||||
unset(HAVE_ROCALUTION)
|
||||
endif()
|
||||
else()
|
||||
if(rocsparse_FOUND AND rocblas_FOUND)
|
||||
@ -278,10 +272,10 @@ macro (config_hook)
|
||||
else()
|
||||
unset(HAVE_ROCSPARSE)
|
||||
endif()
|
||||
if(ROCALUTION_FOUND)
|
||||
set(HAVE_ROCALUTION 1)
|
||||
set(COMPILE_BDA_BRIDGE 1)
|
||||
endif()
|
||||
endif()
|
||||
if(ROCALUTION_FOUND)
|
||||
set(HAVE_ROCALUTION 1)
|
||||
set(COMPILE_BDA_BRIDGE 1)
|
||||
endif()
|
||||
endif()
|
||||
endmacro (config_hook)
|
||||
|
Loading…
Reference in New Issue
Block a user