Help with building HOOMD v3.0 from source

119 views
Skip to first unread message

Trung Nguyen

unread,
Jan 19, 2022, 3:47:50 PM1/19/22
to hoomd...@googlegroups.com
Hi HOOMD developers,I am trying to build HOOMD v3.0.0-beta.13-1-g0251d032b on a linux box following the online documentation. The build is successful with ENABLE_GPU=OFF. The compiler is g++ 11.2.1 20211203 (Red Hat 11.2.1-7).However, with ENABLE_GPU=ON, I got the errors such as:/usr/include/c++/11/bits/std_function.h:435:145: error: parameter packs not expanded with ...:I am using nvcc cuda_11.6.r11.6/compiler.30794723_0.Maybe I need to pass some extra flags from the host compiler to nvcc in this case? Or is there any restriction from the CUDA 11.6 nvcc to the host compiler that I missed? Any suggestion is appreciated.Thanks,-Trung

Joshua Anderson

unread,
Jan 20, 2022, 8:15:08 AM1/20/22
to hoomd...@googlegroups.com
Trung,

I successfully built HOOMD-blue v3.0.0-beta.13 in the nvidia/cuda:11.6.0-devel-ubuntu20.04 docker image with ENABLE_GPU=on. I will update the CI tests to ensure future releases are also compatible with CUDA 11.6.

As far as I know, NVIDIA added support for gcc11 in CUDA 11.5. You would have to check with NVIDIA support on whether additional flags are needed. You could always try building with an older host compiler (i.e. gcc9) and see if that works.
------
Joshua A. Anderson, Ph.D.
Research Area Specialist, Chemical Engineering, University of Michigan
> --
> You received this message because you are subscribed to the Google Groups "hoomd-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to hoomd-users...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/hoomd-users/CALHVP1aMkGx_SmvWgke34x9LnEzX0bas3yeqU6Prr_S50NaHCg%40mail.gmail.com.

Trung Nguyen

unread,
Jan 21, 2022, 12:23:51 PM1/21/22
to hoomd-users
Hi Josh,

thanks for the info and suggestions. Older gcc compilers (gcc6 and gcc8) work fine as expected.

My build was on Fedora 35. When I downgraded gcc to 11.2.1-1, the parameter packs errors disappear, but others come up, likely a mismatch of c++17 vs c++14. For instance, it throws an error "qualified name is not allowed" at  /hoomd/md/NeighborListGPUTree.cuh:95, which is

std::shared_ptr<neighbor::LBVH> get()

Maybe it's just how the gcc11 compiler shipped with Fedora is different from other distros.

Best,
-Trung

Joshua Anderson

unread,
Jan 21, 2022, 12:55:00 PM1/21/22
to hoomd...@googlegroups.com
Trung,

I was able to reproduce "qualified name is not allowed" at /hoomd/md/NeighborListGPUTree.cuh:95" with CUDA 11.5 and gcc 11.1. I pushed a fix for that to the master branch this morning.
------
Joshua A. Anderson, Ph.D.
Research Area Specialist, Chemical Engineering, University of Michigan

> To view this discussion on the web visit https://groups.google.com/d/msgid/hoomd-users/debb45e6-5682-412e-a72c-bc845cab97een%40googlegroups.com.

Trung Nguyen

unread,
Jan 21, 2022, 3:18:02 PM1/21/22
to hoomd...@googlegroups.com
I confirm that the fix resolved the compiling error for CUDA 11.6 and gcc 11.2.1 20210728. Thanks for the quick fix Josh!

-Trung

Reply all
Reply to author
Forward
0 new messages