Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

defines thrust::tuple_element consistently with std::tuple_element #1314

Merged
merged 1 commit into from
Oct 15, 2020

Conversation

andrewcorrigan
Copy link
Contributor

I propose changing the template arguments of thrust::tuple_element to match std::tuple_element:

template< std::size_t I, class T >
class tuple_element;

This is consistent with the implementation used by <cuda/std/tuple>

While I understand that thrust::tuple_element will likely be replaced alongside thrust::tuple pending resolution of NVIDIA/cccl#742, the motivation for this PR is that the overload of thrust::tuple_element for thrust::pair will also need to be replaced, since it still uses template<int, typename>. This PR enables branches such as my variadic tuple branch to BJHVT (bring-jared-hoberock's-variadic-tuple) while we await mainline variadic thrust::tuple support.

With -DTHRUST_DEVICE_SYSTEM=CPP:

100% tests passed, 0 tests failed out of 151

Total Test time (real) = 109.05 sec

@alliepiper
Copy link
Collaborator

LGTM. We'll have to change this anyway for NVIDIA/cccl#742, might as well get it out of the way now.

@alliepiper alliepiper added this to the 1.11.0 milestone Oct 13, 2020
@alliepiper
Copy link
Collaborator

DVS CL 29194450.

@alliepiper alliepiper added testing: internal ci in progress Currently testing on internal NVIDIA CI (DVS). testing: internal ci passed Passed internal NVIDIA CI (DVS). testing: gpuCI in progress Started gpuCI testing. and removed testing: internal ci in progress Currently testing on internal NVIDIA CI (DVS). labels Oct 13, 2020
@alliepiper alliepiper added testing: gpuCI passed Passed gpuCI testing. and removed testing: gpuCI in progress Started gpuCI testing. labels Oct 15, 2020
@alliepiper alliepiper merged commit c036413 into NVIDIA:main Oct 15, 2020
@andrewcorrigan andrewcorrigan deleted the tuple-element-size_t-class branch October 25, 2020 14:17
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
testing: gpuCI passed Passed gpuCI testing. testing: internal ci passed Passed internal NVIDIA CI (DVS).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants