TFHE-rs compiling error in version 1.2.0

Hello!

I’m trying to compile a code using TFHE-rs with GPU acceleration, but the following error occurs:

[ 31%] Building CUDA object src/CMakeFiles/tfhe_cuda_backend.dir/integer/abs.cu.o

— stderr
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
Compiling in Debug mode
CMake Warning:
Manually-specified variables were not used by the project:

  CMAKE_ASM_COMPILER
  CMAKE_ASM_FLAGS
  CMAKE_C_COMPILER
  CMAKE_C_FLAGS

nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
nvcc warning : Support for offline compilation for architectures prior to ‘<compute/sm/lto>_75’ will be removed in a future release (Use -Wno-deprecated-gpu-targets to suppress warning).
In file included from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/radix_ciphertext.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/compression/…/integer_utilities.h:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/compression/compression_utilities.h:4,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/compression/compression.cuh:9,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/compression/compression.cu:1:
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper_profile.cuh:3:10: fatal error: nvToolsExt.h: No such file or directory
3 | #include <nvToolsExt.h>
| ^~~~~~~~~~~~~~
compilation terminated.
In file included from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/radix_ciphertext.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/integer_utilities.h:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/integer.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/cmux.cuh:4,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/cmux.cu:1:
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper_profile.cuh:3:10: fatal error: nvToolsExt.h: No such file or directory
3 | #include <nvToolsExt.h>
| ^~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [src/CMakeFiles/tfhe_cuda_backend.dir/build.make:227: src/CMakeFiles/tfhe_cuda_backend.dir/integer/compression/compression.cu.o] Error 1
gmake[2]: *** Waiting for unfinished jobs…
gmake[2]: *** [src/CMakeFiles/tfhe_cuda_backend.dir/build.make:197: src/CMakeFiles/tfhe_cuda_backend.dir/integer/cmux.cu.o] Error 1
In file included from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/radix_ciphertext.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/integer_utilities.h:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/integer.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/bitwise_ops.cuh:6,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/abs.cuh:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/abs.cu:1:
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper_profile.cuh:3:10: fatal error: nvToolsExt.h: No such file or directory
3 | #include <nvToolsExt.h>
| ^~~~~~~~~~~~~~
compilation terminated.
In file included from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/radix_ciphertext.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/integer_utilities.h:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/integer.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/bitwise_ops.cuh:6,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/abs.cuh:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/div_rem.cuh:6,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/div_rem.cu:1:
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper_profile.cuh:3:10: fatal error: nvToolsExt.h: No such file or directory
3 | #include <nvToolsExt.h>
| ^~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [src/CMakeFiles/tfhe_cuda_backend.dir/build.make:167: src/CMakeFiles/tfhe_cuda_backend.dir/integer/abs.cu.o] Error 1
gmake[2]: *** [src/CMakeFiles/tfhe_cuda_backend.dir/build.make:242: src/CMakeFiles/tfhe_cuda_backend.dir/integer/div_rem.cu.o] Error 1
In file included from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/radix_ciphertext.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/integer_utilities.h:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/integer.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/comparison.cuh:6,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/comparison.cu:1:
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper_profile.cuh:3:10: fatal error: nvToolsExt.h: No such file or directory
3 | #include <nvToolsExt.h>
| ^~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [src/CMakeFiles/tfhe_cuda_backend.dir/build.make:212: src/CMakeFiles/tfhe_cuda_backend.dir/integer/comparison.cu.o] Error 1
In file included from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/radix_ciphertext.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/include/integer/integer_utilities.h:5,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/integer.cuh:7,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./integer/bitwise_ops.cuh:6,
from /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/integer/bitwise_ops.cu:1:
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper_profile.cuh:3:10: fatal error: nvToolsExt.h: No such file or directory
3 | #include <nvToolsExt.h>
| ^~~~~~~~~~~~~~
compilation terminated.
gmake[2]: *** [src/CMakeFiles/tfhe_cuda_backend.dir/build.make:182: src/CMakeFiles/tfhe_cuda_backend.dir/integer/bitwise_ops.cu.o] Error 1
/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper.cuh(27): warning #20050-D: inline qualifier ignored for “global” function
attribute((global)) inline void print_debug_kernel(const double2 *src, int N) {
^

Remark: The warnings can be suppressed with “-diag-suppress ”

/home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/tfhe-cuda-backend-0.10.0/cuda/src/./utils/helper.cuh(27): warning #20050-D: inline qualifier ignored for “global” function
attribute((global)) inline void print_debug_kernel(const double2 *src, int N) {
^

Remark: The warnings can be suppressed with “-diag-suppress ”

gmake[1]: *** [CMakeFiles/Makefile2:116: src/CMakeFiles/tfhe_cuda_backend.dir/all] Error 2
gmake: *** [Makefile:146: all] Error 2

thread ‘main’ panicked at /home/rkruger/.cargo/registry/src/index.crates.io-1949cf8c6b5b557f/cmake-0.1.54/src/lib.rs:1119:5:

command did not execute successfully, got: exit status: 2

build script failed, must exit now
note: run with RUST_BACKTRACE=1 environment variable to display a backtrace

The error only occurs if I set the version 1.2.0. In version 1.1.3 the compilation is fine.

Hello @Rodrigo_Kruger !

Thank you very much for reporting the issue, we have noticed it as well and a fix is incoming. I will let you know as soon as it’s integrated. :slightly_smiling_face:

1 Like

The fix is merged on main, I will make a release of the Cuda backend on Tuesday. Then this should work again for you after doing cargo update && cargo clean.

1 Like