Open L-as opened 4 years ago
Isn't it the filesystem's job to handle writes in a high-latency mount point?
@lenormf I don't think it is. Isn't this why we have things like io_uring now?
I just noticed that besides this being a source of latency, kakoune just seems extremely slow at writing to files compared to e.g. echo > $file
.
I just noticed that besides this being a source of latency, kakoune just seems extremely slow at writing to files compared to e.g. echo > $file.
Do you have a simple reproducer that shows the difference?
@krobelus No, unfortunately. It may honestly just be sshfs's fault or it doing some odd things, so I might very well be wrong. (I just compared it with my eyes, so it may also be some mental trickery)
Feature
When writing to many files mounted somewhere with high latency (e.g. over the network), the latency compounds even though :write-all should take almost exactly the same time as :write in high latency situations. A fix would be to write to each buffer in parallel, although I am not sure on how easily this can be implemented. I suppose it would be best if :write itself was done asynchronously, but then it would still be editable while sending it, which doesn't seem wise.