From f75b8e168845952958b006fee2d362aa59a3192b Mon Sep 17 00:00:00 2001 From: Vsevak Date: Thu, 18 Jun 2020 00:33:46 +0300 Subject: [PATCH] Fix Makefile for GPU ROCm 3.5 backend --- lib/gpu/Makefile.hip | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/lib/gpu/Makefile.hip b/lib/gpu/Makefile.hip index 62d34592d1..833aa34933 100644 --- a/lib/gpu/Makefile.hip +++ b/lib/gpu/Makefile.hip @@ -36,7 +36,7 @@ MPI_LINK_OPTS = $(shell mpicxx --showme:link) #MPI_COMP_OPTS += -I/usr/include/mpi -DMPICH_IGNORE_CXX_SEEK -DOMPI_SKIP_MPICXX=1 HIP_PATH ?= $(wildcard /opt/rocm/hip) -HIP_PLATFORM=$(shell $(HIP_PATH)/bin/hipconfig --compiler) +#HIP_PLATFORM=$(shell $(HIP_PATH)/bin/hipconfig --compiler) ifeq (hcc,$(HIP_PLATFORM)) HIP_OPTS += -ffast-math @@ -48,8 +48,6 @@ else ifeq (nvcc,$(HIP_PLATFORM)) -gencode arch=compute_50,code=[sm_50,compute_50] -gencode arch=compute_52,code=[sm_52,compute_52] -gencode arch=compute_53,code=[sm_53,compute_53]\ -gencode arch=compute_60,code=[sm_60,compute_60] -gencode arch=compute_61,code=[sm_61,compute_61] -gencode arch=compute_62,code=[sm_62,compute_62]\ -gencode arch=compute_70,code=[sm_70,compute_70] -gencode arch=compute_72,code=[sm_72,compute_72] -gencode arch=compute_75,code=[sm_75,compute_75] -else - $(error Specify HIP platform using 'export HIP_PLATFORM=(hcc,nvcc)') endif BIN_DIR = . @@ -69,8 +67,8 @@ HIP_GPU_OPTS += $(HIP_OPTS) -I./ ifeq (hcc,$(HIP_PLATFORM)) HIP_HOST_OPTS += -fPIC HIP_GPU_CC = $(HIP_PATH)/bin/hipcc --genco - HIP_GPU_OPTS_S = -t="$(HIP_ARCH)" -f=\" - HIP_GPU_OPTS_E = \" + HIP_GPU_OPTS_S = --offload-arch=$(HIP_ARCH) + HIP_GPU_OPTS_E = HIP_KERNEL_SUFFIX = .cpp HIP_LIBS_TARGET = export HCC_AMDGPU_TARGET := $(HIP_ARCH) export HCC_AMDGPU_TARGET := $(HIP_ARCH)