Skip to content

[Build] ORT can't build with cuda 12.9 #24731

Open
@yf711

Description

@yf711

Describe the issue

/onnxruntime/onnxruntime/contrib_ops/cuda/bert/embed_layer_norm_impl.cu(42): error #1444-D: type "cub::CUB_200802_SM_800::Min" was declared deprecated ("use cuda::minimum instead")
    cub::Min min;
             ^
/usr/local/cuda/targets/x86_64-linux/include/cub/thread/thread_operators.cuh(99): note #3287-D: because of a "deprecated" attribute
  using Min [[deprecated("use cuda::minimum instead")]] = ::cuda::minimum<>;
              ^

Remark: The warnings can be suppressed with "-diag-suppress <warning-number>"

Deprecated apis were used and need to be updated/suppressed when using cuda>=12.9

Urgency

Necessary to support cuda 12.9

Target platform

All

Build script

./build.sh --config Release --use_cuda --cuda_home /usr/local/cuda --cudnn_home /usr/lib/x86_64-linux-gnu --use_tensorrt --tensorrt_home /usr/lib/x86_64-linux-gnu --build_shared_lib --parallel --skip_tests --allow_running_as_root --cmake_extra_defines 'CMAKE_CUDA_ARCHITECTURES=80-real'

Error / output

/onnxruntime/onnxruntime/contrib_ops/cuda/bert/embed_layer_norm_impl.cu(42): error #1444-D: type "cub::CUB_200802_SM_800::Min" was declared deprecated ("use cuda::minimum instead")
    cub::Min min;
             ^
/usr/local/cuda/targets/x86_64-linux/include/cub/thread/thread_operators.cuh(99): note #3287-D: because of a "deprecated" attribute
  using Min [[deprecated("use cuda::minimum instead")]] = ::cuda::minimum<>;
              ^

Remark: The warnings can be suppressed with "-diag-suppress <warning-number>"

Visual Studio Version

No response

GCC / Compiler Version

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    buildbuild issues; typically submitted using templateep:CUDAissues related to the CUDA execution provider

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions