We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
isfinite
Compile-time Error
libcu++
Based on internal discussion, __builtin_isfinite does not exist in NVRTC 12.0-12.2.
__builtin_isfinite
conda create -n my_env -y python=3.12 cuda-core cuda-version=12.0 conda activate my_env
from cuda.core.experimental import Program, Device dev = Device(0) dev.set_current() code2 = r""" #include <cuda/std/cmath> __global__ void my_kernel(double* s) { unsigned int tid = threadIdx.x + blockIdx.x * blockDim.x; double y = s[1]; if (tid == 0) { auto k = isfinite(y); if (k) { s[0] += 1; } } } """ prog = Program(code2, code_type="c++") mod = prog.compile(target_type="cubin", options=("-std=c++17", "-I/path/to/local/cccl/libcudacxx/include/"))
conda install -y cuda-version=12.X # X=1,2,..., no 7
Everything should work on Linux/Windows.
No response
The text was updated successfully, but these errors were encountered:
(Fixed the issue title; I meant to say 2.7.0 works fine but not 2.8.0 or main)
Sorry, something went wrong.
Notes:
diff --git a/libcudacxx/include/cuda/std/__cccl/builtin.h b/libcudacxx/include/cuda/std/__cccl/builtin.h index 3a5fda2f0..e3683fc58 100644 --- a/libcudacxx/include/cuda/std/__cccl/builtin.h +++ b/libcudacxx/include/cuda/std/__cccl/builtin.h @@ -244,9 +244,9 @@ #endif // _CCCL_CHECK_BUILTIN(isfinite) // Below 11.7 nvcc treats the builtin as a host only function -#if _CCCL_CUDACC_BELOW(11, 7) +#if _CCCL_CUDACC_BELOW(12, 3) # undef _CCCL_BUILTIN_ISFINITE -#endif // _CCCL_CUDACC_BELOW(11, 7) +#endif // _CCCL_CUDACC_BELOW(12, 3) #if _CCCL_CHECK_BUILTIN(builtin_isinf) || _CCCL_COMPILER(GCC) # define _CCCL_BUILTIN_ISINF(...) __builtin_isinf(__VA_ARGS__)
miscco
Successfully merging a pull request may close this issue.
Is this a duplicate?
Type of Bug
Compile-time Error
Component
libcu++
Describe the bug
Based on internal discussion,
__builtin_isfinite
does not exist in NVRTC 12.0-12.2.How to Reproduce
conda install -y cuda-version=12.X # X=1,2,..., no 7
Expected behavior
Everything should work on Linux/Windows.
Reproduction link
No response
Operating System
No response
nvidia-smi output
No response
NVCC version
No response
The text was updated successfully, but these errors were encountered: