Skip to content

Build failure with CUDA 13.3: CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED not declared #68

Description

@cscrosati98

Description

Building nvbandwidth fails because CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED is not defined in the CUDA headers available in my Conda environment.

Build Error

testcase.cpp:61:60: error: ‘CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED’ was not declared in this scope; did you mean ‘CU_DEVICE_ATTRIBUTE_IPC_EVENT_SUPPORTED’?
   61 |         CU_ASSERT(cuDeviceGetAttribute(&supportsMulticast, CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED, dev));
      |                                                            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/ghidora/bandwidth/nvbandwidth/error_handling.h:49:26: note: in definition of macro ‘CU_ASSERT’
   49 |     CUresult cuResult = (x); \
      |                          ^
make[2]: *** [CMakeFiles/nvbandwidth.dir/build.make:90: CMakeFiles/nvbandwidth.dir/testcase.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/nvbandwidth.dir/all] Error 2
make: *** [Makefile:91: all] Error 2

Environment

  • CUDA Toolkit: 13.3, installed through Conda
  • GPU: NVIDIA L40S
  • NVIDIA Driver Version: 595.71.05
  • Compiler: g++ 12
  • Build system: CMake / Make

Steps to Reproduce

  1. Create or activate a Conda environment containing CUDA 13.3.
  2. Configure the nvbandwidth build with CMake.
  3. Run make.
  4. The build fails while compiling testcase.cpp.

Expected Behavior

nvbandwidth should build successfully with CUDA 13.3 installed through Conda.

Actual Behavior

The build fails because CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED is not declared in the CUDA headers used during compilation.

Temporary Workaround

Commenting out the following line in testcase.cpp allows the build to complete:

CU_ASSERT(cuDeviceGetAttribute(
    &supportsMulticast,
    CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED,
    dev
));

This is only a temporary workaround because it disables multicast capability detection.

Suggested Fix

Please consider guarding the multicast capability query with an appropriate CUDA version or feature check so that the project can still compile when CU_DEVICE_ATTRIBUTE_MULTICAST_SUPPORTED is unavailable in the installed CUDA headers.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions