Skip to content

Retouch ccp executor example cmake to enable or not multi device building #4770

New issue

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

Open
WilliamTambellini opened this issue May 29, 2025 · 3 comments
Assignees

Comments

@WilliamTambellini
Copy link
Contributor

WilliamTambellini commented May 29, 2025

As of today
https://github.com/NVIDIA/TensorRT-LLM/blob/255779a91d6d3d137a792c3dd590a8284267bd35/examples/cpp/executor/CMakeLists.txt
hardcodes
-DENABLE_MULTI_DEVICE=1

set(CMAKE_CXX_FLAGS "-Wall -pthread -lstdc++ -DENABLE_MULTI_DEVICE=1")

and then tries to build multi device.

This is just a proposal for ENABLE_MULTI_DEVICE to be overridable by cmake: eg:

if (not ${ENABLE_MULTI_DEVICE})
  set(ENABLE_MULTI_DEVICE 1)
endif()

set(CMAKE_CXX_FLAGS "-Wall -pthread -lstdc++ -DENABLE_MULTI_DEVICE=${ENABLE_MULTI_DEVICE}")
...

@tongyuantongyu ?

@brb-nv
Copy link
Collaborator

brb-nv commented May 30, 2025

@tongyuantongyu do you think you can help with this?

@tongyuantongyu
Copy link
Member

Thanks for the suggestion. @WilliamTambellini Would you like to create a PR for this?

@WilliamTambellini
Copy link
Contributor Author

Sure, on it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants