Skip to content

Drop thrust::counting_iterator in favor of cuda::counting_iterator - #2958

Merged
rapids-bot[bot] merged 2 commits into
NVIDIA:mainfrom
miscco:drop_thrust_counting_iterator
Feb 19, 2026
Merged

Drop thrust::counting_iterator in favor of cuda::counting_iterator#2958
rapids-bot[bot] merged 2 commits into
NVIDIA:mainfrom
miscco:drop_thrust_counting_iterator

Conversation

@miscco

@miscco miscco commented Feb 18, 2026

Copy link
Copy Markdown
Contributor

No description provided.

@aamijar aamijar added non-breaking Non-breaking change improvement Improvement / enhancement to an existing function labels Feb 18, 2026
@aamijar

aamijar commented Feb 19, 2026

Copy link
Copy Markdown
Member

/merge

@rapids-bot
rapids-bot Bot merged commit 1beb059 into NVIDIA:main Feb 19, 2026
79 checks passed
rapids-bot Bot pushed a commit to NVIDIA/cuvs that referenced this pull request Feb 20, 2026
rapids-bot Bot pushed a commit to NVIDIA/cuvs that referenced this pull request Feb 23, 2026
…unting_iterator` (#1826)

This commit moves the use of `thrust::make_counting_iterator` to `cuda::make_counting_iterator`, much like in NVIDIA/raft#2958.

This change was initally done to fix the compile error one saw because of the use of `thrust::make_counting_iterator`:
```
 │ │ $SRC_DIR/cpp/tests/neighbors/all_neighbors/../../../src/neighbors/detail/knn_brute_force.cuh(230): error: namespace "thrust" has no member "make_counting_iterator"
 │ │         auto count = thrust::make_counting_iterator<IndexType>(0);
 │ │                              ^
 │ │ $SRC_DIR/cpp/tests/neighbors/all_neighbors/../../../src/neighbors/detail/knn_brute_force.cuh(230): error: type name is not allowed
 │ │         auto count = thrust::make_counting_iterator<IndexType>(0);
```

The RAPIDS projects seem to be moving away from using the thrust function, and switching to the cuda version of the same. (Refer to NVIDIA/raft#2958.) This change moves cuVS in that direction.

Authors:
  - MithunR (https://github.com/mythrocks)

Approvers:
  - Jinsol Park (https://github.com/jinsolp)
  - Divye Gala (https://github.com/divyegala)

URL: #1826
tfeher pushed a commit to Stardust-SJF/cuvs_rabitq that referenced this pull request Mar 3, 2026
…unting_iterator` (NVIDIA#1826)

This commit moves the use of `thrust::make_counting_iterator` to `cuda::make_counting_iterator`, much like in NVIDIA/raft#2958.

This change was initally done to fix the compile error one saw because of the use of `thrust::make_counting_iterator`:
```
 │ │ $SRC_DIR/cpp/tests/neighbors/all_neighbors/../../../src/neighbors/detail/knn_brute_force.cuh(230): error: namespace "thrust" has no member "make_counting_iterator"
 │ │         auto count = thrust::make_counting_iterator<IndexType>(0);
 │ │                              ^
 │ │ $SRC_DIR/cpp/tests/neighbors/all_neighbors/../../../src/neighbors/detail/knn_brute_force.cuh(230): error: type name is not allowed
 │ │         auto count = thrust::make_counting_iterator<IndexType>(0);
```

The RAPIDS projects seem to be moving away from using the thrust function, and switching to the cuda version of the same. (Refer to NVIDIA/raft#2958.) This change moves cuVS in that direction.

Authors:
  - MithunR (https://github.com/mythrocks)

Approvers:
  - Jinsol Park (https://github.com/jinsolp)
  - Divye Gala (https://github.com/divyegala)

URL: NVIDIA#1826
landrumb pushed a commit to landrumb/cuvs that referenced this pull request Jul 8, 2026
landrumb pushed a commit to landrumb/cuvs that referenced this pull request Jul 8, 2026
…unting_iterator` (NVIDIA#1826)

This commit moves the use of `thrust::make_counting_iterator` to `cuda::make_counting_iterator`, much like in NVIDIA/raft#2958.

This change was initally done to fix the compile error one saw because of the use of `thrust::make_counting_iterator`:
```
 │ │ $SRC_DIR/cpp/tests/neighbors/all_neighbors/../../../src/neighbors/detail/knn_brute_force.cuh(230): error: namespace "thrust" has no member "make_counting_iterator"
 │ │         auto count = thrust::make_counting_iterator<IndexType>(0);
 │ │                              ^
 │ │ $SRC_DIR/cpp/tests/neighbors/all_neighbors/../../../src/neighbors/detail/knn_brute_force.cuh(230): error: type name is not allowed
 │ │         auto count = thrust::make_counting_iterator<IndexType>(0);
```

The RAPIDS projects seem to be moving away from using the thrust function, and switching to the cuda version of the same. (Refer to NVIDIA/raft#2958.) This change moves cuVS in that direction.

Authors:
  - MithunR (https://github.com/mythrocks)

Approvers:
  - Jinsol Park (https://github.com/jinsolp)
  - Divye Gala (https://github.com/divyegala)

URL: NVIDIA#1826
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

improvement Improvement / enhancement to an existing function non-breaking Non-breaking change

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants