CUDA_ARCH_ := $(GPU_TARGET)
ifneq ($(findstring Kepler, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_30
CUDA_ARCH_ += sm_35
endif
ifneq ($(findstring Maxwell, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_50
endif
ifneq ($(findstring Pascal, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_60
endif
ifneq ($(findstring Volta, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_70
endif
ifneq ($(findstring Turing, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_75
endif
ifneq ($(findstring Ampere, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_80
endif
ifneq ($(findstring Hopper, $(GPU_TARGET)),)
CUDA_ARCH_ += sm_90
endif
We see the first thing we do is set CUDA_ARCH_ := $(GPU_TARGET). If GPU_TARGET is sm_89 (or whatever number), it won't match any of the names, but that's ok, because
we already have the information we *really* need (the number). The Makefile then goes on to strip out the relevant sm numbers to create the argument to pass on to the CUDA compiler.
The error message if this process goes wrong indicates that sm_XX is a valid option for GPU_TARGET:
$(error ERROR: unknown `GPU_TARGET=$(GPU_TARGET)`. Set cuda_arch to one or more of Kepler, Maxwell, Pascal, Volta, Turing, Ampere, Hopper, or valid sm_XX from nvcc -h)
I don't know if anyone has tested on Ada specifically; we don't have access to one here at the moment, so I can't say anything officially. But the current list of names that are
recognized is not meant to be a definitive list of all architectures that can run MAGMA.
Natalie