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

长input下coredump #746

Closed
frankxyy opened this issue Nov 23, 2023 · 11 comments
Closed

长input下coredump #746

frankxyy opened this issue Nov 23, 2023 · 11 comments
Assignees

Comments

@frankxyy
Copy link

frankxyy commented Nov 23, 2023

你好,我使用main分支较新的代码,#715 ,同时cherrypick了一个更新的commit #738 。 起了1个http client串行请求,prompt长度1k-8k。

出现coredump:
ebfee77b2e405f57bb0464ae4146f796

看起来不是OOM。

gdb core file结果:
8958558965536869787d2c436d8a38ea

对应现在github main分支代码这一行: https://github.com/InternLM/lmdeploy/blob/main/src/turbomind/models/llama/LlamaBatch.cc#L488C2-L488C2

@frankxyy frankxyy changed the title 并发下coredump 长input下coredump Nov 23, 2023
@frankxyy
Copy link
Author

@lzhangzz hi,你这能复现吗? 如果复现不了,我可以把prompt发你哈

@frankxyy
Copy link
Author

frankxyy commented Nov 23, 2023

image

coredump时,desc.size() 我打印出来,是0

@lzhangzz
Copy link
Collaborator

应该是有个request太长被reject了导致出现了空batch,可以试试 #747

@frankxyy
Copy link
Author

@lzhangzz 目前不再复现了

@frankxyy
Copy link
Author

@lzhangzz
出现了新的问题,长input返回空:

image

@frankxyy
Copy link
Author

frankxyy commented Nov 23, 2023

@lzhangzz
感觉不是 #747 的修改造成的, 像是我合了 #738 后,就出现这个问题了

@lzhangzz
Copy link
Collaborator

这看起来是history+prompt长度超过session_len,直接reject了

@frankxyy
Copy link
Author

frankxyy commented Nov 23, 2023

@lzhangzz
image

直接reject,finish_reason应该填length吧,但实际返回的finish_reason是none

@frankxyy
Copy link
Author

@lzhangzz 应该不是你这修改的原因,我回滚了还是有报错,可能是我哪边改错了。。。

@lzhangzz
Copy link
Collaborator

lzhangzz commented Nov 23, 2023

具体还要看turbomind的log,里面算的可能会有点不同。

还有种情况是在特别长的context下模型可能会直接输出eoa,这还要看你现在NTK alpha是怎么算的

@frankxyy
Copy link
Author

具体还要看turbomind的log,里面算的可能会有点不同。

还有种情况是在特别长的context下模型可能会直接输出eoa,这还要看你现在NTK alpha是怎么算的

查到原因了。。 我把kv cache占比调低,导致session_len被截短了

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