Skip to content
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

nccl_max_nchannels dynamically set in the program #1572

Open
Rainlin007 opened this issue Jan 9, 2025 · 2 comments
Open

nccl_max_nchannels dynamically set in the program #1572

Rainlin007 opened this issue Jan 9, 2025 · 2 comments

Comments

@Rainlin007
Copy link

Rainlin007 commented Jan 9, 2025

I want to dynamically set nccl_max_nchannels in the program. hope allreduce uses different SM numbers under different conditions, is there any way to achieve this?

@gcongiu
Copy link
Contributor

gcongiu commented Jan 9, 2025

You can use ncclCommInitRankConfig and set maxCTAs in ncclConfig_t. This will allow you to set the number of max channels (CTAs) per communicator.

@sjeaugey
Copy link
Member

sjeaugey commented Jan 9, 2025

Note this property is per-communicator. If you want different allreduce operations to have different maxCTAs, then you'll need to create multiple communicators.

You can, however, use ncclCommSplit with config.splitShare=1 to create a new identical communicator with a different configuration but without using extra resources.

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