Fail to complie HPL for CUDA in PowerPC


I am trying to compile hpl for cuda in Power8 PC.
The package is “hpl-2.0_FERMI_v15.tgz” that I found from this link “”.
I have installed MPICH-3.2 and OpenBLAS for Power8 in my PowerPC.
CUDA version is 8.0.

I modified those parameters in Make.CUDA.

  1. TOPdir = /root/hpl-2.0_FERMI_v15
  2. MPdir = /root/mpich-install
  3. LAdir = /root/openblas-install
  4. LAlib = -L (TOPdir)/src/cuda -ldgemm -L /usr/local/cuda/lib64 -lcuda -lcudart -lcublas -L (LAdir)/lib

When I ran “make arch=CUDA” there were some errors about “undefined reference”.

/root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_idamax.o): In function HPL_idamax': HPL_idamax.c:(.text+0x2c): undefined reference to idamax_’
/root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_dgemv.o): In function HPL_dgemv': HPL_dgemv.c:(.text+0x90): undefined reference to dgemv_’
HPL_dgemv.c:(.text+0xfc): undefined reference to dgemv_' /root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_dcopy.o): In function HPL_dcopy’:
HPL_dcopy.c:(.text+0x2c): undefined reference to dcopy_' /root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_daxpy.o): In function HPL_daxpy’:
HPL_daxpy.c:(.text+0x34): undefined reference to daxpy_' /root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_dscal.o): In function HPL_dscal’:
HPL_dscal.c:(.text+0x2c): undefined reference to dscal_' /root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_dtrsv.o): In function HPL_dtrsv’:
HPL_dtrsv.c:(.text+0x8c): undefined reference to dtrsv_' /root/hpl-2.0_FERMI_v15/lib/CUDA/libhpl.a(HPL_dger.o): In function HPL_dger’:
HPL_dger.c:(.text+0x64): undefined reference to dger_' HPL_dger.c:(.text+0xa8): undefined reference to dger_’
collect2: error: ld returned 1 exit status
make[2]: *** [dexe.grd] Error 1
make[2]: Leaving directory /root/hpl-2.0_FERMI_v15/testing/ptest/CUDA' make[1]: *** [build_tst] Error 2 make[1]: Leaving directory /root/hpl-2.0_FERMI_v15’
make: *** [build] Error 2

Please help to guide me if there is something missing that I should add.


I came across the same issue as you did, have you fixed this?

Yes, I came accross the same problem, because src/cuda/cuda_dgemm.c is expecting MKL, not OpenBLAS.

What I did is changed the following:
#ifdef GOTO
handle2 = dlopen (“”, RTLD_LAZY);
#ifdef ACML
handle2 = dlopen (“”, RTLD_LAZY);
handle2 = dlopen (“”, RTLD_LAZY);

#ifdef GOTO
mkl_dtrsm = (void()())dlsym(handle2, “dtrsm_”);
#ifdef ACML
mkl_dtrsm = (void(
)())dlsym(handle2, “dtrsm_”);
mkl_dtrsm = (void(*)())dlsym(handle2, “dtrsm_”);