[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-21 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. So an alternative is to: - patch `openmp/runtime/cmake/LibompCheckLinkerFlag.cmake` to make the `libomp_check_linker_flag` function to ignore the "Unknown CUDA version" warning, AND - ask users to build with `-DCMAKE_CXX_FLAGS=-Wno-unknown-cuda-version -DCMAKE_C_FLAGS=

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-17 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. Summary - In order to avoid the bug in PR44587 , one needs to build with >9.0. - With CUDA toolkit 10.2, building the trunk will fail because 10.0.0 does not support it yet. CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D74571#1877000 , @kkwli0 wrote: > > I am not sure I understand. Do we need to modify stuff outside of > > `/openmp`? I was hoping it is our CMake that can be adjusted to make this > > work as described earlier. TBH, he warni

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. > I am not sure I understand. Do we need to modify stuff outside of `/openmp`? > I was hoping it is our CMake that can be adjusted to make this work as > described earlier. TBH, he warning is even not my biggest problem. As long as > we get a libomptarget.bc we should be

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D74571#1876952 , @kkwli0 wrote: > It turns out that having the warning message also affects the C_SUPPORTS_FPIC > test in `cmake/modules/HandleLLVMOptions.cmake`. As a result, `cmake` thinks > that `-fPIC` is not supported.

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. It turns out that having the warning message also affects the C_SUPPORTS_FPIC test in `cmake/modules/HandleLLVMOptions.cmake`. As a result, `cmake` thinks that `-fPIC` is not supported. Eventually, it leads to error in `libclang-cpp.so`. ../../lib/CodeGen/CMakeFiles

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D74571#1876647 , @jdoerfert wrote: > That sounds like the right approach for OpenMP. We require a minimal CUDA > version, based on what we use internally, but no maximal version if possible > since we don't use new features anyway

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D74571#1876617 , @kkwli0 wrote: > Thanks for all the comments. It makes sense to keep the warning there before > any ptx65 features are added. The warning should also apply to both the CUDA > and OpenMP compile paths. As

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-14 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. Thanks for all the comments. It makes sense to keep the warning there before any ptx65 features are added. The warning should also apply to both the CUDA and OpenMP compile paths. As a result, I will pursue to ignore the warning in the build of libomp (i.e. libomp_che

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. @tra that's great context, thank you very much for writing it up. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D74571/new/ https://reviews.llvm.org/D74571 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D74571#1875296 , @JonChesterfield wrote: > Interesting distinction. > > Should compiling without warning indicate comprehensive support, or merely > that we ran the tests and they passed? The test in LLVM do have very limited te

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. Interesting distinction. Should compiling without warning indicate comprehensive support, or merely that we ran the tests and they passed? I assumed the latter on the basis that we probably don't have comprehensive support for cuda 10.1 either. No preference ei

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D74571#1875022 , @kkwli0 wrote: > In D74571#1874950 , @jdoerfert wrote: > > > > in order to avoid bug 44587 which requires >9.0.1 to be the build > > > compiler? > > > > Do we already

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. In D74571#1875002 , @kkwli0 wrote: > In D74571#1874947 , @JonChesterfield > wrote: > > > Do the in tree tests all pass with the 10.2 toolchain? That's not exactly > > the same as whether it wo

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. In D74571#1874950 , @jdoerfert wrote: > > in order to avoid bug 44587 which requires >9.0.1 to be the build compiler? > > Do we already require CUDA 10 as part of the libomptarget cmake (with a nice > message) to avoid the errors y

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. In D74571#1874947 , @JonChesterfield wrote: > Do the in tree tests all pass with the 10.2 toolchain? That's not exactly the > same as whether it works but is the closest approximation we have available. > > Assuming yes, this patc

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Artem Belevich via Phabricator via cfe-commits
tra requested changes to this revision. tra added a comment. This revision now requires changes to proceed. It's a bit premature to call CUDA-10.2 supported. We can compile using it, but clang/llvm has no support for the new things introduced by CUDA-10.2. E.g. CUDA-10.2 introduces new PTX versi

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Jon Chesterfield via Phabricator via cfe-commits
JonChesterfield added a comment. Do the in tree tests all pass with the 10.2 toolchain? That's not exactly the same as whether it works but is the closest approximation we have available. Assuming yes, this patch seems uncontroversial. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D7457

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a reviewer: ye-luo. jdoerfert added a comment. > Do we also want to put this patch to 10.0.0 RC2 Yes, if there is nothing else needed to support 10.2 we should for sure do that. > in order to avoid bug 44587 which requires >9.0.1 to be the build compiler? Do we already require C

[PATCH] D74571: [OpenMP][CUDA] Add CUDA 10.2 support

2020-02-13 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 created this revision. kkwli0 added reviewers: jdoerfert, ABataev, JonChesterfield, tra. Herald added a subscriber: guansong. kkwli0 edited the summary of this revision. This patch is to add CUDA 10.2 support. It essentially removes the warning message regarding the CUDA 10.2 toolkit not