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

执行目录内搜索时总会卡死 #45

Closed
heheda123123 opened this issue Jul 5, 2023 · 18 comments
Closed

执行目录内搜索时总会卡死 #45

heheda123123 opened this issue Jul 5, 2023 · 18 comments

Comments

@heheda123123
Copy link

有点奇怪,这种分离架构,在emacs没有计算为啥会卡住
image

@heheda123123
Copy link
Author

而且有时候是能出一点东西,然后才卡死
image

@manateelazycat
Copy link
Owner

你看看 *blink-search* 是不是有啥报错?

@heheda123123
Copy link
Author

卡死了看不了

@manateelazycat
Copy link
Owner

strace 追踪一下Emacs, 看看Emacs卡死的时候, 挂到什么地方了。

@heheda123123
Copy link
Author

heheda123123 commented Jul 5, 2023

人麻了,刚刚卡得电脑动不了,晚点我再试下,好像emacs相关的进程把30g内存都跑满了
我发现我在论坛发那个mimalloc的东西在这种情况下还真有用,用了mimalloc至少能动,只是emacs进程卡死。
刚才我复现的时候没有用带mimalloc的版本,直接卡得动不了。

@heheda123123
Copy link
Author

strace 追踪一下Emacs, 看看Emacs卡死的时候, 挂到什么地方了。

windows上的strace看不出来
image

@heheda123123
Copy link
Author

不过卡死貌似不是blink-search特有的问题,刚刚用consult-ripgrep也卡死了,奇怪
image

@heheda123123
Copy link
Author

heheda123123 commented Jul 5, 2023

而且好奇怪,在其他目录就没事,只要在我的emacs配置目录下用emacs中的ripgrep就会卡死

@heheda123123
Copy link
Author

heheda123123 commented Jul 5, 2023

好像和emacs版本有关系,我换成emacs29就没卡过了

更新:
还是卡了

@manateelazycat
Copy link
Owner

rg 遇到一些不认识的二进制文件会发生卡死的问题

@heheda123123
Copy link
Author

不过这不是启动了子进程嘛,rg卡死了为啥会导致emacs也动不了

@manateelazycat
Copy link
Owner

不知道

@manateelazycat
Copy link
Owner

如果方便的话, 可以看看是不是特定目录? 这些文件如果没有秘密, 可以上传一个压缩包, 我帮忙测试一下, 看看是不是我也会卡死。

@heheda123123
Copy link
Author

heheda123123 commented Jul 7, 2023

如果方便的话, 可以看看是不是特定目录? 这些文件如果没有秘密, 可以上传一个压缩包, 我帮忙测试一下, 看看是不是我也会卡死。

谢谢猫哥,文件有六十几m,我压缩发你邮箱了
我这边的复现步骤是,切换到这个目录,打开blink-search ,然后输出 !use-package
一般在输入前几个字符的时候就会卡死

@manateelazycat
Copy link
Owner

我通过反复删除文件, 发现是 projectile.cache 这个文件引起的卡顿

@heheda123123
Copy link
Author

500k的长单行文件,太长返回预览的时候卡死了吗,在python服务器端就判断一下,太长的行就截断只返回开头,或者显示个这一行太长了,consult-ripgrep好像就是这样处理的。但是consult-ripgrep时灵时不灵的,有时候也会卡死不知道为啥了

@manateelazycat
Copy link
Owner

blink-search 的架构是不会卡死的, 估计是rg找到这个超长行的字符串, 直接喂给 Emacs, 把 Emacs 喂挂了。

@manateelazycat
Copy link
Owner

已经被 01d0de7 补丁修复了, 因为超长行会直接把Emacs卡死, 所以直接不显示吧。

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