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

[bug] Fix race condition #460

Merged
merged 1 commit into from
Sep 26, 2023
Merged

Conversation

akhoroshev
Copy link
Contributor

@akhoroshev akhoroshev commented Sep 23, 2023

I encountered segfault when I started generating a lot of requests with tensor para > 1.

It happens because threads exit from method LlamaV2::forward and release input/output tensors. But at the same time threads from LlamaV2::internalThreadEntry with rank > 0 can access these tensors.

@akhoroshev akhoroshev changed the title fix race condition [bug] Fix race condition Sep 23, 2023
Copy link
Collaborator

@lzhangzz lzhangzz left a comment

Choose a reason for hiding this comment

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

LGTM

@hatrexltd hatrexltd mentioned this pull request Sep 25, 2023
2 tasks
@lvhan028 lvhan028 mentioned this pull request Sep 26, 2023
2 tasks
@lvhan028 lvhan028 merged commit a54e3e0 into InternLM:main Sep 26, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants