read-process-output-max vs system pipe capacity #3561
fredericgiquel
started this conversation in
General
Replies: 1 comment
-
The pipe size is also limited to 64kb on macos. I used these scripts and dtruss to validate that. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The documentation suggests to set
read-process-output-max
to 1Mb to increase the amount of data read in one go from the language server. But the amount of data that actually transits also depends on system pipe capacity.On GNU/Linux, the pipe size is limited to 16 pages (64kb) by default unless using
fcntl
to increase the pipe capacity (see pipe(7) manpage). But Emacs does not increase the pipe capacity so values ofread-process-output-max
above 64k are not taken into account. This behavior can be highlighted doingstrace -e trace=write -p <pid_of_server>
and triggering a request for a "big" completion or using scripts detailed in the following link : https://debbugs.gnu.org/cgi/bugreport.cgi?bug=55737The patch that add the appropriate
fcntl
call has been merged in Emacs master branch last week (https://git.savannah.gnu.org/cgit/emacs.git/commit/?id=a947c10d9093b9f3a29b60a52bda8afa43b6fd29).I tested the system pipe capacity on VM with:
Not having access to the necessary hardware, I did not test on macOS. Can anyone test it?
Beta Was this translation helpful? Give feedback.
All reactions