-
Notifications
You must be signed in to change notification settings - Fork 761
Add libcu++ dependency; initial round of NV_IF_TARGET ports.
#1605
Conversation
|
run tests |
fc0846e to
b771cda
Compare
|
run tests |
058166e to
9065dda
Compare
|
run tests |
17cfee7 to
e12b463
Compare
|
run tests |
e12b463 to
d51b751
Compare
|
run tests |
d51b751 to
2f2d141
Compare
|
run tests |
2f2d141 to
bbc43d0
Compare
|
run tests |
bbc43d0 to
193be7c
Compare
|
run tests |
193be7c to
42c32ad
Compare
|
run tests |
NV_IF_TARGET ports.
|
run tests |
42c32ad to
3710ed4
Compare
|
run tests |
|
run tests |
1a65974 to
e398841
Compare
|
run tests |
1 similar comment
|
run tests |
e9953c8 to
50316c7
Compare
|
Rebased. Now that the version has been bumped to 2.0.0 we can start to seriously think about merging this. run tests |
gevtushenko
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are a few comments that I consider critical, but the source of the issue isn't caused by this PR. So the comments shouldn't block it. The rest of the comments are quite optional.
| #include <thrust/system/detail/bad_alloc.h> | ||
| #include <thrust/detail/malloc_and_free.h> | ||
|
|
||
| #ifdef THRUST_CACHING_DEVICE_MALLOC |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see any documentation on this macro, is it still in use?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No idea.
50316c7 to
c9fe022
Compare
|
run tests |
There's no way for a user to meaningfully use this, since libcudacxx is a required dependency. It is checked during the initial `find_package(Thrust)` call, before the user would have access to Thrust's CMake API. Updated the CMake README.md with instructions for using an explicit libcudacxx target.
- The `g_state` flag wasn't reset between executions. - The `destroy` method was being invoke in the current host system, not the system that owned the allocated memory (always cpp). This broke on MSVC's OpenMP implementation, where it seemed to be asserting the `g_state` flag before it was updated by `destroy`. This only happened on MSVC when host system = OMP, and appears to be a bug/miscompile in MSVC (repro'd on 2019). Fixed by explicitly tagging the allocator system to cpp. - Added check that `destroy` is not invoked on empty vectors.
c9fe022 to
4cdf6de
Compare
|
run tests |
Requires NVIDIA/cub#448.
This PR contains an initial set of changes necessary to migrate Thrust and CUB to NV_IF_TARGET and remove dependence on
__CUDA_ARCH__. It does not fully remove all usages of__CUDA_ARCH__, but rather focuses on the following:#ifdef __CUDA_ARCH__to useNV_IF_TARGET.This also includes various bug fixes for issues exposed by the above.
Future PRs will address the remaining usages of
__CUDA_ARCH__in the CDP macros and the kernel dispatch infrastructure.Pre-written Release Notes
Breaking Changes
NV_IF_TARGETports. #1605: Add libcu++ dependency.NV_IF_TARGETports. #1605: The following macros are no longer defined by default. They can be re-enabled by definingTHRUST_PROVIDE_LEGACY_ARCH_MACROS. These will be removed completely in a future release.THRUST_IS_HOST_CODE: Replace withNV_IF_TARGET.THRUST_IS_DEVICE_CODE: Replace withNV_IF_TARGET.THRUST_INCLUDE_HOST_CODE: Replace withNV_IF_TARGET.THRUST_INCLUDE_DEVICE_CODE: Replace withNV_IF_TARGET.THRUST_DEVICE_CODE: Replace withNV_IF_TARGET.Other Enhancements
NV_IF_TARGETports. #1605: Removed special case code for unsupported CUDA architectures.NV_IF_TARGETports. #1605: Replace several usages of__CUDA_ARCH__with<nv/target>to handle host/device code divergence.Bug Fixes
NV_IF_TARGETports. #1605: Fix some execution space warnings in the allocator library.