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

[Enhancement] Some idling after executing the last layer in expert worker #45

Open
shawlleyw opened this issue Dec 26, 2024 · 5 comments

Comments

@shawlleyw
Copy link
Collaborator

Need to figure out and fix it. One possible reason is copying tensor from GPU to CPU and sending it to sampler via zmq.

@hogura99
Copy link
Collaborator

At what cases?

step_attn=2, DP=1, step_exp=1, EP=2?

@shawlleyw
Copy link
Collaborator Author

Almost every case as I remember

@hogura99
Copy link
Collaborator

Will use context recorder in #50 to check the details.

@hogura99 hogura99 changed the title Some idling after executing the last layer in expert worker [Enhancement] Some idling after executing the last layer in expert worker Dec 30, 2024
@hogura99
Copy link
Collaborator

image

ZMQ send took a long time that also influences other kernels like NCCLRecv and gather_tokens_cuda. It should be caused by device2host memcpy.

@hogura99
Copy link
Collaborator

hogura99 commented Jan 2, 2025

image

The overlapping of tensor copy and expert execution has been done. But the performance has not been improved a lot since the problem also exists in attn, as following.

image

Will be fixed later.

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

2 participants