[gmx-users] Building Gromacs on a MacBook Pro with AMD Radeon Pro 560
Michael Williams
michael.r.c.williams at gmail.com
Mon Feb 18 11:20:10 CET 2019
Hello, I’ve been having trouble building Gromacs 2018.3 on my MacBook Pro. I would like to be able to use OpenMP as well as the GPU (via OpenCL). I’ve searched for successful builds with similar systems described on this email list, but haven’t found anything that worked yet.
Based on what I’ve read on this email list and various searches elsewhere, I am trying to build Gromacs 2018.3 using the OS X (10.14.3, Mojave) system default clang compiler (so that there is no compiler mismatch with the system OpenCL libraries). Since it does not have OpenMP support by default, I compiled libomp using the system’s clang. (As a side note, I built static libomp libraries).
I installed the custom libomp with a prefix of $HOME/.local , which is mostly empty except for Cmake. When I built Gromacs, I used the following command:
cmake .. -DGMX_BUILD_OWN_FFTW=ON \
-DCMAKE_INSTALL_PREFIX=/Users/michael/.local/apps/gromacs-2018.3-apple-clang-omp-ocl \
-DCMAKE_PREFIX_PATH=/Users/michael/.local \
-DREGRESSIONTEST_PATH=/Users/michael/.local/source/regressiontests-2018.3 \
-DCMAKE_C_FLAGS="-Xpreprocessor -fopenmp -lomp -I/Users/michael/.local/include -L/Users/michael/.local/lib” \
-DCMAKE_CXX_FLAGS="-Xpreprocessor -fopenmp -lomp -I/Users/michael/.local/include -L/Users/michael/.local/lib” \
-DGMX_GPU=ON \
-DGMX_USE_OPENCL=ON
Next I ran "make -j 4" and I didn’t get any errors during building (although I got the following warnings many times: clang: warning: -lomp: 'linker' input unused [-Wunused-command-line-argument]
clang: warning: argument unused during compilation: '-L/Users/michael/.local/lib' [-Wunused-command-line-argument]).
However, when I ran "make check”, I got the errors pasted below. For the record, when I compiled the same version of Gromacs with the same configuration settings as above except with no GPU support, all of the tests passed.
Any help or suggestions would be very much appreciated. Thanks kindly!
Mike
Errors during tests:
….
Using 1 MPI thread
Using 1 OpenMP thread
1 GPU auto-selected for this run.
Mapping of GPU IDs to the 1 GPU task in the 1 rank on this node:
PP:0
Compilation of source file /Users/michael/.local/source/gromacs-2018.3/src/gromacs/mdlib/nbnxn_ocl/nbnxn_ocl_kernels.cl failed!
-- Used build options: -DWARP_SIZE_TEST=64 -D_AMD_SOURCE_ -DGMX_OCL_FASTGEN -DEL_CUTOFF -DEELNAME=_ElecCut -DLJ_COMB_GEOM -DVDWNAME=_VdwLJCombGeom -DCENTRAL=22 -DNBNXN_GPU_NCLUSTER_PER_SUPERCLUSTER=8 -DNBNXN_GPU_CLUSTER_SIZE=8 -DNBNXN_GPU_JGROUP_SIZE=4 -DGMX_NBNXN_PRUNE_KERNEL_J4_CONCURRENCY=4 -DNBNXN_MIN_RSQ=3.82e-07f -DIATYPE_SHMEM -cl-fast-relaxed-math -cl-denorms-are-zero -I/Users/michael/.local/source/gromacs-2018.3/src/gromacs/mdlib/nbnxn_ocl
--------------LOG START---------------
<program source>:80:10: fatal error: 'nbnxn_ocl_kernel_pruneonly.clh' file not found
#include "nbnxn_ocl_kernel_pruneonly.clh"
^
---------------LOG END----------------
-------------------------------------------------------
Program: mdrun-test, version 2018.3
Source file: src/gromacs/gpu_utils/ocl_compiler.cpp (line 507)
Function: cl_program gmx::ocl::compileProgram(FILE *, const std::string &, const std::string &, cl_context, cl_device_id, ocl_vendor_id_t)
Internal error (bug):
Failed to compile NBNXN kernels for GPU #AMD Radeon Pro 560 Compute Engine
Could not build OpenCL program, error was CL_BUILD_PROGRAM_FAILURE
Followed by:
Abnormal return value for ' gmx mdrun -ntmpi 12 -notunepme >mdrun.out 2>&1' was 1
Retrying mdrun with better settings...
Abnormal return value for ' gmx mdrun -ntmpi 12 -ntomp 1 -notunepme >mdrun.out 2>&1' was 1
Retrying mdrun with better settings...
Abnormal return value for ' gmx mdrun -ntmpi 12 -ntomp 1 -notunepme >mdrun.out 2>&1' was 1
Retrying mdrun with better settings...
FAILED. Check mdrun.out, md.log file(s) in dd121 for dd121
Abnormal return value for ' gmx mdrun -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in nbnxn_pme_order5 for nbnxn_pme_order5
Abnormal return value for ' gmx mdrun -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in nbnxn_rzero for nbnxn_rzero
Abnormal return value for ' gmx mdrun -ntmpi 6 -notunepme >mdrun.out 2>&1' was 1
Retrying mdrun with better settings...
Abnormal return value for ' gmx mdrun -ntmpi 6 -ntomp 1 -notunepme >mdrun.out 2>&1' was 1
Retrying mdrun with better settings...
Abnormal return value for ' gmx mdrun -ntmpi 1 -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in orientation-restraints for orientation-restraints
Abnormal return value for ' gmx mdrun -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in position-restraints for position-restraints
Abnormal return value for ' gmx mdrun -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in pull_geometry_angle for pull_geometry_angle
Abnormal return value for ' gmx mdrun -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in pull_geometry_angle-axis for pull_geometry_angle-axis
7 out of 51 complex tests FAILED
Start 36: regressiontests/kernel
36/39 Test #36: regressiontests/kernel ........... Passed 42.00 sec
Start 37: regressiontests/freeenergy
37/39 Test #37: regressiontests/freeenergy .......***Failed 8.50 sec
:-) GROMACS - gmx mdrun, 2018.3 (-:
GROMACS is written by:
Emile Apol Rossen Apostolov Paul Bauer Herman J.C. Berendsen
Par Bjelkmar Aldert van Buuren Rudi van Drunen Anton Feenstra
Gerrit Groenhof Aleksei Iupinov Christoph Junghans Anca Hamuraru
Vincent Hindriksen Dimitrios Karkoulis Peter Kasson Jiri Kraus
Carsten Kutzner Per Larsson Justin A. Lemkul Viveca Lindahl
Magnus Lundborg Pieter Meulenhoff Erik Marklund Teemu Murtola
Szilard Pall Sander Pronk Roland Schulz Alexey Shvetsov
Michael Shirts Alfons Sijbers Peter Tieleman Teemu Virolainen
Christian Wennberg Maarten Wolf
and the project leaders:
Mark Abraham, Berk Hess, Erik Lindahl, and David van der Spoel
Copyright (c) 1991-2000, University of Groningen, The Netherlands.
Copyright (c) 2001-2017, The GROMACS development team at
Uppsala University, Stockholm University and
the Royal Institute of Technology, Sweden.
check out http://www.gromacs.org <http://www.gromacs.org/> for more information.
GROMACS is free software; you can redistribute it and/or modify it
under the terms of the GNU Lesser General Public License
as published by the Free Software Foundation; either version 2.1
of the License, or (at your option) any later version.
GROMACS: gmx mdrun, version 2018.3
Executable: /Users/michael/.local/source/gromacs-2018.3/build-apple-clang-omp-ocl/bin/gmx
Data prefix: /Users/michael/.local/source/gromacs-2018.3 (source tree)
Working dir: /Users/michael/.local/source/regressiontests-2018.3
Command line:
gmx mdrun -h
Thanx for Using GROMACS - Have a Nice Day
Abnormal return value for ' gmx mdrun -notunepme >mdrun.out 2>&1' was -1
FAILED. Check mdrun.out, md.log file(s) in expanded for expanded
1 out of 10 freeenergy tests FAILED
Start 38: regressiontests/pdb2gmx
38/39 Test #38: regressiontests/pdb2gmx .......... Passed 12.44 sec
Start 39: regressiontests/rotation
39/39 Test #39: regressiontests/rotation ......... Passed 2.64 sec
92% tests passed, 3 tests failed out of 39
More information about the gromacs.org_gmx-users
mailing list