|
From: | Herman |
Subject: | bug#44007: 26.3; Strange shell mode performance |
Date: | Mon, 06 Nov 2023 13:28:15 +0100 |
User-agent: | mu4e 1.11.19; emacs 30.0.50 |
Eli Zaretskii <eliz@gnu.org> writes:
I'm not sure what exactly are we trying to do here. AFAIU, at least 2 variables were discovered that can speed up this example, so what else has to be done? Is there any bug here, and if so, what is the bug?
The bug is that if echo is enabled, emacs 'shell' gives a much worse performance. And it has no apparent reason why it should be the case.
Also, there is weird behavior around event handling (why does a RET speed up I/O?). I think that this behavior suggests that there is some bug in Emacs. At least I don't consider this a normal behavior.
I don't think that the solution is that zsh users should set these variables. It makes much more sense to fix Emacs so this doesn't happen in the first place.
I'd like to also mention that my hacky solution not just fixes the problem, but also improves shell's performance, even with the mentioned variables set. As far as I know POSIX programming, read() should always be called in a loop, if one wants to read N bytes (even in the successful case). Emacs doesn't have this in emacs_intr_read, that causes the problem.
[Prev in Thread] | Current Thread | [Next in Thread] |