Skip to content

Add missing Thrust includes#4597

Closed
bdice wants to merge 3 commits intofacebookresearch:mainfrom
bdice:fix-missing-thrust-includes
Closed

Add missing Thrust includes#4597
bdice wants to merge 3 commits intofacebookresearch:mainfrom
bdice:fix-missing-thrust-includes

Conversation

@bdice
Copy link
Copy Markdown
Contributor

@bdice bdice commented Sep 30, 2025

While testing cuVS with a prerelease build of CCCL 3.1.x, I encountered compilation errors. There were some missing Thrust headers needed for thrust::copy and thrust::device_ptr.

This is being patched in cuVS as a workaround for now: rapidsai/cuvs#1398

This PR upstreams the patch.

Errors look like this:

FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o 
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(102): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(258): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(300): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu".
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o 
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(126): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(292): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(324): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu".

rapids-bot Bot pushed a commit to rapidsai/cuvs that referenced this pull request Sep 30, 2025
This PR patches FAISS for some missing Thrust includes. This is needed to support building with CCCL 3.1.x. RAPIDS 25.10 will still use CCCL 3.0.x but we want to make it possible to build with 3.1.x in 25.10.

xref: #1329 (This backports a fix from that testing PR, which is targeting 25.12)

I am upstreaming the patch here: facebookresearch/faiss#4597

Authors:
  - Bradley Dice (https://github.com/bdice)
  - Corey J. Nolet (https://github.com/cjnolet)

Approvers:
  - Tarang Jain (https://github.com/tarang-jain)
  - Divye Gala (https://github.com/divyegala)

URL: #1398
@facebook-github-bot
Copy link
Copy Markdown
Contributor

@mnorris11 has imported this pull request. If you are a Meta employee, you can view this in D83686425.

@meta-codesync
Copy link
Copy Markdown
Contributor

meta-codesync Bot commented Oct 8, 2025

@mnorris11 has imported this pull request. If you are a Meta employee, you can view this in D83686425.

@meta-codesync
Copy link
Copy Markdown
Contributor

meta-codesync Bot commented Oct 9, 2025

@mnorris11 merged this pull request in 752832c.

AlSchlo pushed a commit to AlSchlo/faiss-panorama that referenced this pull request Oct 12, 2025
Summary:
While testing cuVS with a prerelease build of CCCL 3.1.x, I encountered compilation errors. There were some missing Thrust headers needed for `thrust::copy` and `thrust::device_ptr`.

This is being patched in cuVS as a workaround for now: rapidsai/cuvs#1398

This PR upstreams the patch.

Errors look like this:

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(102): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(258): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(300): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu".
```

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(126): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(292): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(324): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu".
```

Pull Request resolved: facebookresearch#4597

Reviewed By: junjieqi

Differential Revision: D83686425

Pulled By: mnorris11

fbshipit-source-id: 8adf8dacc64b582483ca78cb00ff5d380d616704
samanthawaters8882michaeldonovan added a commit to samanthawaters8882michaeldonovan/faiss that referenced this pull request Oct 12, 2025
Summary:
While testing cuVS with a prerelease build of CCCL 3.1.x, I encountered compilation errors. There were some missing Thrust headers needed for `thrust::copy` and `thrust::device_ptr`.

This is being patched in cuVS as a workaround for now: rapidsai/cuvs#1398

This PR upstreams the patch.

Errors look like this:

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(102): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(258): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(300): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu".
```

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(126): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(292): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(324): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu".
```

Pull Request resolved: facebookresearch/faiss#4597

Reviewed By: junjieqi

Differential Revision: D83686425

Pulled By: mnorris11

fbshipit-source-id: 8adf8dacc64b582483ca78cb00ff5d380d616704
AlSchlo pushed a commit to AlSchlo/faiss-panorama that referenced this pull request Oct 20, 2025
Summary:
While testing cuVS with a prerelease build of CCCL 3.1.x, I encountered compilation errors. There were some missing Thrust headers needed for `thrust::copy` and `thrust::device_ptr`.

This is being patched in cuVS as a workaround for now: rapidsai/cuvs#1398

This PR upstreams the patch.

Errors look like this:

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(102): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(258): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(300): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu".
```

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(126): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(292): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(324): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu".
```

Pull Request resolved: facebookresearch#4597

Reviewed By: junjieqi

Differential Revision: D83686425

Pulled By: mnorris11

fbshipit-source-id: 8adf8dacc64b582483ca78cb00ff5d380d616704
enp1s0 pushed a commit to enp1s0/cuvs that referenced this pull request Oct 22, 2025
This PR patches FAISS for some missing Thrust includes. This is needed to support building with CCCL 3.1.x. RAPIDS 25.10 will still use CCCL 3.0.x but we want to make it possible to build with 3.1.x in 25.10.

xref: rapidsai#1329 (This backports a fix from that testing PR, which is targeting 25.12)

I am upstreaming the patch here: facebookresearch/faiss#4597

Authors:
  - Bradley Dice (https://github.com/bdice)
  - Corey J. Nolet (https://github.com/cjnolet)

Approvers:
  - Tarang Jain (https://github.com/tarang-jain)
  - Divye Gala (https://github.com/divyegala)

URL: rapidsai#1398
dimitraseferiadi pushed a commit to dimitraseferiadi/SuCo that referenced this pull request Mar 8, 2026
Summary:
While testing cuVS with a prerelease build of CCCL 3.1.x, I encountered compilation errors. There were some missing Thrust headers needed for `thrust::copy` and `thrust::device_ptr`.

This is being patched in cuVS as a workaround for now: rapidsai/cuvs#1398

This PR upstreams the patch.

Errors look like this:

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(102): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(258): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(300): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu".
```

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(126): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(292): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(324): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu".
```

Pull Request resolved: facebookresearch#4597

Reviewed By: junjieqi

Differential Revision: D83686425

Pulled By: mnorris11

fbshipit-source-id: 8adf8dacc64b582483ca78cb00ff5d380d616704
dimitraseferiadi pushed a commit to dimitraseferiadi/SuCo that referenced this pull request Mar 16, 2026
Summary:
While testing cuVS with a prerelease build of CCCL 3.1.x, I encountered compilation errors. There were some missing Thrust headers needed for `thrust::copy` and `thrust::device_ptr`.

This is being patched in cuVS as a workaround for now: rapidsai/cuvs#1398

This PR upstreams the patch.

Errors look like this:

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/BinaryCuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(102): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(258): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu(300): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/BinaryCuvsCagra.cu".
```

```
FAILED: [code=2] _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
sccache $BUILD_PREFIX/bin/nvcc -forward-unknown-to-host-compiler -DCCCL_DISABLE_PDL -DCUB_DISABLE_NAMESPACE_MAGIC -DCUB_IGNORE_NAMESPACE_MAGIC_ERROR -DCUTLASS_NAMESPACE=raft_cutlass -DCUVS_BUILD_CAGRA_HNSWLIB -DLIBCUDACXX_ENABLE_EXPERIMENTAL_MEMORY_RESOURCE -DRAFT_LOG_ACTIVE_LEVEL=RAPIDS_LOGGER_LOG_LEVEL_INFO -DRAFT_SYSTEM_LITTLE_ENDIAN=1 -DTHRUST_DEVICE_SYSTEM=THRUST_DEVICE_SYSTEM_CUDA -DTHRUST_DISABLE_ABI_NAMESPACE -DTHRUST_HOST_SYSTEM=THRUST_HOST_SYSTEM_CPP -DTHRUST_IGNORE_ABI_NAMESPACE_ERROR -DUSE_NVIDIA_CUVS=1 -I$SRC_DIR/cpp/build/_deps/faiss-src -I$SRC_DIR/cpp/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/thrust/../../../thrust -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/libcudacxx/../../../libcudacxx/include -I$SRC_DIR/cpp/build/_deps/cccl-src/lib/cmake/cub/../../../cub -I$SRC_DIR/cpp/build/_deps/hnswlib-src -isystem $BUILD_PREFIX/targets/x86_64-linux/include -isystem $BUILD_PREFIX/targets/x86_64-linux/include/cccl -isystem $PREFIX/targets/x86_64-linux/include -isystem $PREFIX/include -isystem $BUILD_PREFIX/include -O3 -DNDEBUG "--generate-code=arch=compute_75,code=[sm_75]" "--generate-code=arch=compute_80,code=[sm_80]" "--generate-code=arch=compute_86,code=[sm_86]" "--generate-code=arch=compute_90a,code=[sm_90a]" "--generate-code=arch=compute_100f,code=[sm_100f]" "--generate-code=arch=compute_120a,code=[sm_120a]" "--generate-code=arch=compute_120,code=[compute_120,sm_120]" -Xcompiler=-fPIC -Xfatbin=-compress-all --expt-extended-lambda --expt-relaxed-constexpr -Xcompiler=-fopenmp -Xcompiler -pthread "-Xcompiler=-ffile-prefix-map=$PREFIX/=''" -MD -MT _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o -MF _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o.d -x cu -c $SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu -o _deps/faiss-build/faiss/gpu/CMakeFiles/faiss_gpu_objs.dir/impl/CuvsCagra.cu.o
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(126): error: namespace "thrust" has no member "copy"
          thrust::copy(
                  ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(292): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu(324): error: namespace "thrust" has no member "copy"
      thrust::copy(
              ^
3 errors detected in the compilation of "$SRC_DIR/cpp/build/_deps/faiss-src/faiss/gpu/impl/CuvsCagra.cu".
```

Pull Request resolved: facebookresearch#4597

Reviewed By: junjieqi

Differential Revision: D83686425

Pulled By: mnorris11

fbshipit-source-id: 8adf8dacc64b582483ca78cb00ff5d380d616704
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants