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

Add bisection test #203

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

Conversation

x41lakazam
Copy link

@x41lakazam x41lakazam commented Apr 4, 2024

In a bisection, each rank is paired with one other rank called 'peer', they both send and receive N messages, this number is bound to the agg_iters parameter.

The selection of this 'peer' rank is defined by the getPeer function:
https://github.com/x41lakazam/nccl-tests/blob/bisection_test/src/bisection.cu#L19

@sjeaugey
Copy link
Member

sjeaugey commented Apr 4, 2024

Can't you already do that running the sendrecv_perf test, and setting NCCL_TESTS_SPLIT_MASK=(nranks/2)-1?

Sure, that only works with nranks being a power of two; maybe your code is more generic.

@x41lakazam
Copy link
Author

Being able to run this test when nranks is not a power of two is actually important to us

src/bisection.cu Outdated Show resolved Hide resolved
@x41lakazam x41lakazam force-pushed the bisection_test branch 3 times, most recently from 52ebfc6 to 42a079f Compare April 14, 2024 06:47
Add bisection to makefile

Add bisection doc in performance.md
Add bisection to makefile

Add bisection doc in performance.md
@x41lakazam
Copy link
Author

x41lakazam commented Apr 14, 2024

@AddyLaddy @sjeaugey

The code is ready to merge from our side
Please let me know what you think about it, thanks

src/bisection.cu Outdated
}

int getPeer(int rank, int n_ranks){
if (n_ranks % 4 == 0)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is n_ranks % 4 == 0 a special case?

Copy link
Author

@x41lakazam x41lakazam Jun 2, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This allow cross rail bisection for rail-optimized topology

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

Successfully merging this pull request may close these issues.

3 participants