Modify CMake config to work with HIP #489
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR generalizes the GPU-related cmake bits and bobs so that it can handle being configured for HIP/AMD GPUs.
Haero built and passed tests for me on one of caraway's MI200 node, using
amdclangv17.0.0 andhipcc/rocmv6.0Note
HAERO_DEVICE_ARCH, that is set automatically ifDEVICE_ARCHis set.${haero_root}/CMakeLists.txt:176and seemed necessary because the name of the kokkos device flag,KOKKOS_ARCH_$DEVICE_ARCH, is not known ahead of time.AMD_GFX<N>architecture flags are preferred, so I added the current ones to thesetupscript.@bartgol I haven't taken a close look at EAMxx's strategy for building Haero, but with any luck, adding the
HAERO_DEVICE_ARCHshould have you off to the races.Closes #488