[PATCH] D114601: Read path to CUDA from env. variable CUDA_PATH on Windows

Artem Belevich via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 29 13:20:26 PST 2021


tra added inline comments.


================
Comment at: clang/lib/Driver/ToolChains/Cuda.cpp:137
   } else if (HostTriple.isOSWindows()) {
-    for (const char *Ver : Versions)
-      Candidates.emplace_back(
----------------
mojca wrote:
> tra wrote:
> > Do we want to keep this as the fall-back for cases when `CUDA_PATH` is not set?
> > 
> > Otherwise, we're risking to break existing users.
> That was going to be my question as well (for which I wanted your input).
> From the initial comments in the other review (D114326) I understood that eventually you wanted to get rid of the hardcoded list of versions (but I didn't fully understand the intent).
> 
> (Technically speaking this won't break existing users since they were only able to access CUDA versions up to 8.0 until now, and we would just remove support for anything older that CUDA 10.0.)
Good point. Then it's a good opportunity to decommission the auto-search by version magic and replace it with something more predictable.

I think this patch would obviate the D114326, too, and we should be able to remove the multi-version search everywhere.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D114601/new/

https://reviews.llvm.org/D114601



More information about the cfe-commits mailing list