Repository navigation
Refactor thrust::pointer - #5478
Conversation
24ce024 to
04accea
Compare
🟩 CI finished in 1h 58m: Pass: 100%/140 | Total: 3d 16h | Avg: 37m 55s | Max: 1h 57m | Hits: 63%/152687
|
| Project | |
|---|---|
| CCCL Infrastructure | |
| CCCL Packaging | |
| libcu++ | |
| CUB | |
| +/- | Thrust |
| CUDA Experimental | |
| stdpar | |
| python | |
| CCCL C Parallel Library | |
| Catch2Helper |
Modifications in project or dependencies?
| Project | |
|---|---|
| CCCL Infrastructure | |
| +/- | CCCL Packaging |
| libcu++ | |
| +/- | CUB |
| +/- | Thrust |
| +/- | CUDA Experimental |
| +/- | stdpar |
| python | |
| +/- | CCCL C Parallel Library |
| +/- | Catch2Helper |
🏃 Runner counts (total jobs: 140)
| # | Runner |
|---|---|
| 91 | linux-amd64-cpu16 |
| 17 | windows-amd64-cpu16 |
| 10 | linux-arm64-cpu16 |
| 7 | linux-amd64-gpu-rtx2080-latest-1 |
| 6 | linux-amd64-gpu-rtxa6000-latest-1 |
| 5 | linux-amd64-gpu-h100-latest-1 |
| 3 | linux-amd64-gpu-rtx4090-latest-1 |
| 1 | linux-amd64-gpu-l4-latest-1 |
| using raw_pointer = typename super_t::base_type; | ||
|
|
||
| // constructors | ||
| _CCCL_HOST_DEVICE pointer() |
There was a problem hiding this comment.
I believe we should replace all _CCCL_HOST_DEVICE with _CCCL_API, its shorter and does more things
There was a problem hiding this comment.
Then that should be done in a dedicated PR for the entire codebase.
| template <typename OtherPointer, | ||
| typename detail::enable_if_pointer_is_convertible<OtherPointer, pointer>::type* = nullptr> |
There was a problem hiding this comment.
General question: Do we want to move thrust / cub towards _CCCL_TEMPLATE and use our concept emulation?
There was a problem hiding this comment.
I dislike the concept emulation, because it harms readability IMO. And also this should be discussed more broadly and then applied to the entire codebase.
| { | ||
| template <typename Element, typename Tag, typename Reference, typename Derived> | ||
| struct iterator_traits<THRUST_NS_QUALIFIER::pointer<Element, Tag, Reference, Derived>> | ||
| struct std::iterator_traits<THRUST_NS_QUALIFIER::pointer<Element, Tag, Reference, Derived>> |
There was a problem hiding this comment.
Should we specialize _CUDA_VSTD::iterator_traits
There was a problem hiding this comment.
Wouldn't this be a breaking change? What about users relying on the std::iterator_traits specializations?
There was a problem hiding this comment.
Yeah, but we also need to work around this for NVRTC when the time comes
There was a problem hiding this comment.
Let's revisit this when the time comes
f33efd8 to
e2327f2
Compare
🟩 CI finished in 1h 57m: Pass: 100%/140 | Total: 3d 16h | Avg: 38m 03s | Max: 1h 55m | Hits: 62%/152687
|
| Project | |
|---|---|
| CCCL Infrastructure | |
| CCCL Packaging | |
| libcu++ | |
| CUB | |
| +/- | Thrust |
| CUDA Experimental | |
| stdpar | |
| python | |
| CCCL C Parallel Library | |
| Catch2Helper |
Modifications in project or dependencies?
| Project | |
|---|---|
| CCCL Infrastructure | |
| +/- | CCCL Packaging |
| libcu++ | |
| +/- | CUB |
| +/- | Thrust |
| +/- | CUDA Experimental |
| +/- | stdpar |
| python | |
| +/- | CCCL C Parallel Library |
| +/- | Catch2Helper |
🏃 Runner counts (total jobs: 140)
| # | Runner |
|---|---|
| 91 | linux-amd64-cpu16 |
| 17 | windows-amd64-cpu16 |
| 10 | linux-arm64-cpu16 |
| 7 | linux-amd64-gpu-rtx2080-latest-1 |
| 6 | linux-amd64-gpu-rtxa6000-latest-1 |
| 5 | linux-amd64-gpu-h100-latest-1 |
| 3 | linux-amd64-gpu-rtx4090-latest-1 |
| 1 | linux-amd64-gpu-l4-latest-1 |
…IDIA/cccl#5478) Upstream: NVIDIA/cccl@30c02fd - Adaptation: pointer.inl folded into pointer.h per upstream; kept local `::internal::remove_cvref_t` shim (C++17 fallback) and moved the local hipcc-linkage `pointer(Element*)` constructor (THRUST_HAS_HIP_COMPILER) definition inline; `_CCCL_*` wrapper macros spelled `THRUST_*`. - HIP counterpart: none (system-independent pointer type; hip `pointer` derives from it). - test/ counterpart: none (no test changes). - Not compiled, tests not run (per human). Co-Authored-By: Claude <noreply@anthropic.com>
…e_cvref_t in pointer Related upstream commit: 30c02fd29dd Refactor thrust::pointer (NVIDIA/cccl#5478) Related local port commit: a3de492 libhipcxx is now mandatory, so thrust::pointer uses _THRUST_STD::remove_cvref_t (upstream ::cuda::std::remove_cvref_t) instead of the ::internal fallback alias. Not compiled, tests not run (per human) Co-Authored-By: Claude <noreply@anthropic.com>
…IDIA/cccl#5478) Upstream: NVIDIA/cccl@30c02fd - Adaptation: pointer.inl folded into pointer.h per upstream; kept local `::internal::remove_cvref_t` shim (C++17 fallback) and moved the local hipcc-linkage `pointer(Element*)` constructor (THRUST_HAS_HIP_COMPILER) definition inline; `_CCCL_*` wrapper macros spelled `THRUST_*`. - HIP counterpart: none (system-independent pointer type; hip `pointer` derives from it). - test/ counterpart: none (no test changes). - Not compiled, tests not run (per human). Co-Authored-By: Claude <noreply@anthropic.com>
…IDIA/cccl#5478) Upstream: NVIDIA/cccl@30c02fd - Adaptation: pointer.inl folded into pointer.h per upstream; kept local `::internal::remove_cvref_t` shim (C++17 fallback) and moved the local hipcc-linkage `pointer(Element*)` constructor (THRUST_HAS_HIP_COMPILER) definition inline; `_CCCL_*` wrapper macros spelled `THRUST_*`. - HIP counterpart: none (system-independent pointer type; hip `pointer` derives from it). - test/ counterpart: none (no test changes). - Not compiled, tests not run (per human). Co-Authored-By: Claude <noreply@anthropic.com>
…e_cvref_t in pointer Related upstream commit: 30c02fd29dd Refactor thrust::pointer (NVIDIA/cccl#5478) Related local port commit: a3de492 libhipcxx is now mandatory, so thrust::pointer uses _THRUST_STD::remove_cvref_t (upstream ::cuda::std::remove_cvref_t) instead of the ::internal fallback alias. Not compiled, tests not run (per human) Co-Authored-By: Claude <noreply@anthropic.com>
…IDIA/cccl#5478) Upstream: NVIDIA/cccl@30c02fd - Adaptation: pointer.inl folded into pointer.h per upstream; kept local `::internal::remove_cvref_t` shim (C++17 fallback) and moved the local hipcc-linkage `pointer(Element*)` constructor (THRUST_HAS_HIP_COMPILER) definition inline; `_CCCL_*` wrapper macros spelled `THRUST_*`. - HIP counterpart: none (system-independent pointer type; hip `pointer` derives from it). - test/ counterpart: none (no test changes). - Not compiled, tests not run (per human). Co-Authored-By: Claude <noreply@anthropic.com>
…IDIA/cccl#5478) Upstream: NVIDIA/cccl@30c02fd - Adaptation: pointer.inl folded into pointer.h per upstream; kept local `::internal::remove_cvref_t` shim (C++17 fallback) and moved the local hipcc-linkage `pointer(Element*)` constructor (THRUST_HAS_HIP_COMPILER) definition inline; `_CCCL_*` wrapper macros spelled `THRUST_*`. - HIP counterpart: none (system-independent pointer type; hip `pointer` derives from it). - test/ counterpart: none (no test changes). - Not compiled, tests not run (per human). Co-Authored-By: Claude <noreply@anthropic.com>
…e_cvref_t in pointer Related upstream commit: 30c02fd29dd Refactor thrust::pointer (NVIDIA/cccl#5478) Related local port commit: a3de492 libhipcxx is now mandatory, so thrust::pointer uses _THRUST_STD::remove_cvref_t (upstream ::cuda::std::remove_cvref_t) instead of the ::internal fallback alias. Not compiled, tests not run (per human) Co-Authored-By: Claude <noreply@anthropic.com>
No description provided.