lattice / quda

QUDA is a library for performing calculations in lattice QCD on GPUs.
https://lattice.github.io/quda
Other
289 stars 97 forks source link

HIP build broken... #1372

Closed bjoo closed 1 year ago

bjoo commented 1 year ago

From Carleton:

Hi Balint,

Yesterday afternoon I built QUDA/develop on Frontier (apparently)
successfully.  Steve reported compilation errors when he did that
later.  So I tried a new pull and got the same compilation error:

/ccs/home/detar/frontier/quda/quda/include/targets/hip/tunable_kernel.h:87:51:
error: no member named 'use_constant_memory_arg' in namespace
'quda::device'; did you mean 'use_constant_memory'?
      if (location == QUDA_CUDA_FIELD_LOCATION &&
device::use_constant_memory_arg<>::value) strcat(aux, "cmem,");

This looks like it is HIP related.  Does Jenkins check the HIP
backend?   When I did the pull, I noticed a ton of changed files. See
below.  The list includes the offending file above.

Best,

Carleton

-----------------------------------------------------------

 CMakeLists.txt                                |    1 +
 include/communicator_quda.h                   |   34 +-
 include/device.h                              |    7 +
 include/dslash.h                              |   25 +-
 include/eigen_helper.h                        |    2 +-
 include/eigensolve_quda.h                     |   19 +-
 include/gauge_field_order.h                   |   10 +-
 include/instantiate.h                         |   80 +++
 include/kernels/hisq_paths_force.cuh          | 1312
++++++++++++++++++++++++++++---------------
 include/kernels/multi_blas_core.cuh           |    2 -
 include/multi_blas_helper.cuh                 |   26 +-
 include/quda.h                                |    4 +
 include/quda_define.h.in                      |    8 +
 include/quda_matrix.h                         |   54 +-
 include/targets/cuda/constant_kernel_arg.h    |    7 +
 include/targets/cuda/target_device.h          |   14 +-
 include/targets/cuda/tunable_kernel.h         |   46 +-
 include/targets/hip/constant_kernel_arg.h     |    3 +
 include/targets/hip/tunable_kernel.h          |   39 +-
 include/tunable_block_reduction.h             |   10 +-
 include/tunable_nd.h                          |   13 +-
 include/tunable_reduction.h                   |   10 +-
 include/tune_quda.h                           |   18 +-
 include/unitarization_links.h                 |    2 +-
 lib/CMakeLists.txt                            |    4 +
 lib/blas_quda.cu                              |   18 +-
 lib/check_params.h                            |    6 +-
 lib/copy_gauge_helper.hpp                     |    9 +-
 lib/covDev.cu                                 |   22 +-
 lib/dslash_coarse.hpp                         |    2 -
 lib/dslash_domain_wall_4d_fused_m5.hpp        |    2 +-
 lib/dslash_policy.cuh                         |   29 +-
 lib/eig_block_trlm.cpp                        |   18 +-
 lib/eig_trlm.cpp                              |    2 +-
 lib/eigensolve_quda.cpp                       |   52 +-
 lib/gauge_fix_ovr.cu                          |    5 +-
 lib/hisq_paths_force_quda.cu                  |  895
++++++++++++++++++-----------
 lib/interface_quda.cpp                        |  244 +++++---
 lib/inv_cg_quda.cpp                           |    1 -
 lib/laplace.cu                                |   22 +-
 lib/milc_interface.cpp                        |   68 ++-
 lib/multi_blas_quda.cu                        |   26 +-
 lib/multi_reduce_quda.cu                      |   58 +-
 lib/pgauge_exchange.cu                        |    8 +-
 lib/reduce_quda.cu                            |   14 +-
 lib/staggered_quark_smearing.cu               |    8 +-
 lib/targets/cuda/device.cpp                   |   20 +
 lib/targets/cuda/quda_api.cpp                 |   12 +-
 lib/targets/cuda/target_cuda.cmake            |    4 +
 lib/targets/hip/device.cpp                    |   24 +
 lib/targets/hip/quda_api.cpp                  |   12 +-
 lib/util_quda.cpp                             |    3 +-
 tests/gauge_alg_test.cpp                      |   13 +-
 tests/gauge_path_test.cpp                     |    2 +
 tests/hisq_paths_force_test.cpp               |  643 ++++++++++++++-------
 tests/host_reference/hisq_force_reference.cpp |   97 ++--
 tests/host_reference/hisq_force_reference.h   |   58 +-
 tests/invert_test_gtest.hpp                   |    9 +-
 tests/utils/command_line_params.cpp           |   16 +
 tests/utils/command_line_params.h             |    4 +
 tests/utils/host_utils.cpp                    |  144 +++--
 tests/utils/host_utils.h                      |   51 +-
 tests/utils/set_params.cpp                    |    4 +
bjoo commented 1 year ago

More from Carleton

I see that the changes to the HIP version of tunable_kernel.h happened
in March.  So I must have been working with an earlier version of QUDA
when I got the successful compilation yesterday. Since Kate logged the
change to tunable_kernel.h, I'll ping her.
bjoo commented 1 year ago

Even more from Carleton

We are unable to compile the latest develop with the HIP back end
because of an undefined symbol in targets/hip/tunable_kernel.h, namely,
device::use_constant_memory_arg<>.  I don't see it in
targets/hip/constant_kernel_arg.h, where I thought it should be defined.
weinbe2 commented 1 year ago

Fixed in https://github.com/lattice/quda/pull/1369 ; we're working on getting it merged now.

weinbe2 commented 1 year ago

Specifically fixed in commit https://github.com/lattice/quda/pull/1369/commits/2e9845d38d4416f64003213a67200be308362d59

bjoo commented 1 year ago

Awesome! Thanks @weinbe2

maddyscientist commented 1 year ago

Closed by #1369