[Openmp-commits] [PATCH] D89974: [driver][CUDA] Use CMake's FindCUDA as default --cuda-path.

Artem Belevich via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Thu Oct 22 11:00:37 PDT 2020


tra added a comment.

In D89974#2347979 <https://reviews.llvm.org/D89974#2347979>, @Hahnfeld wrote:

> In D89974#2347938 <https://reviews.llvm.org/D89974#2347938>, @tra wrote:
>
>> One concern I have is that the path we configure during clang's build is not necessarily the right choice for the user of clang we build. It's likely that the clang in the end will be used on a completely different machine.
>> E.g. official clang builds can not ever provide the same CUDA path for *all* users who end up using them. Requiring the rest to use a special option to make clang work again looks like an overall usability regression to me.
>
> Not quite, as far as I understand the change it's only one of the searched paths.

Right. My mistake. I misread the code and the excess of `--cuda-path-ignore-cmake` in the tests convinced me that it replaced the default search paths.

The point about the path unlikely to be a good default guess still stands. It will also introduce surprising behavior when clang built on a machine with CUDA installed will behave differently compared to clang built on a machine w/o CUDA. IMO clang built from the same sources with the same build configuration options should behave the same way, regardless of what's been installed on the build host during the build.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D89974



More information about the Openmp-commits mailing list