mirror of
https://github.com/OPM/opm-simulators.git
synced 2026-10-24 14:47:44 -05:00
hipify: suppress warnings
This commit is contained in:
1 parent
b5c39c89d4
commit
abc8a9b50b
3 files changed
+9
-1
No files matched your search
@@ -29,6 +29,7 @@ option(BUILD_FLOW_ALU_GRID "Build flow blackoil with alu grid" OFF)
|
||||
option(USE_DAMARIS_LIB "Use the Damaris library for asynchronous I/O?" OFF)
|
||||
option(USE_GPU_BRIDGE "Enable the GPU bridge (GPU/AMGCL solvers)" ON)
|
||||
option(CONVERT_CUDA_TO_HIP "Convert CUDA code to HIP (to run on AMD cards)" OFF)
|
||||
option(SUPPRESS_HIPIFY_WARNINGS "Suppress warnings in hipify?" ON)
|
||||
option(USE_AMGX "Enable AMGX support?" OFF)
|
||||
option(USE_HYPRE "Use the Hypre library for linear solvers?" OFF)
|
||||
set(OPM_COMPILE_COMPONENTS "2;3;4;5;6;7" CACHE STRING "The components to compile support for")
|
||||
|
||||
@@ -48,6 +48,7 @@ macro (ADD_CUDA_OR_HIP_FILE LIST DIR FILE)
|
||||
${cuda_file_path}
|
||||
${hip_file_path}
|
||||
$<TARGET_FILE:hipify-perl>
|
||||
${SUPPRESS_HIPIFY_WARNINGS}
|
||||
DEPENDS
|
||||
${cuda_file_path}
|
||||
COMMENT
|
||||
|
||||
+7
-1
@@ -6,12 +6,18 @@ set -e # Make sure the script fails if a command fails
|
||||
input_file=$1
|
||||
output_file=$2
|
||||
hipify_command=$3
|
||||
suppress=$4
|
||||
|
||||
# make sure the output folder exists
|
||||
mkdir -p $(dirname $output_file)
|
||||
|
||||
# hipify out-of-place
|
||||
$hipify_command $input_file > $output_file
|
||||
if [ "$suppress" == "1" ] || [ "$suppress" == "ON" ]
|
||||
then
|
||||
$hipify_command -o $output_file $input_file 2> /dev/null
|
||||
else
|
||||
$hipify_command -o $output_file $input_file
|
||||
fi
|
||||
|
||||
# expand includes so we only need include_directories (path to hip)
|
||||
sed -i 's/^#include <hipblas\.h>/#include <hipblas\/hipblas.h>/g' $output_file
|
||||
|
||||
Reference in new issue
Block a user