Skip to content

CUDA: Throw error if user-specified architectures don't work

Raul Tambre requested to merge tambre/cmake:cuda_user_architectures into master

Previously if an user specified CMAKE_CUDA_ARCHITECTURES and they didn't work we would end up erroring during compiler testing. Instead check if the architectures we successfully compiled with are the same as the user-specified (if any). If they don't match, then throw a more helpful error than compiler testing would.

Additionally, to make this work corrrectly I made it try all user-specified architectures at once instead of each separately.

Implements #20756 (closed).

Edited by Raul Tambre

Merge request reports