weechat.el icon indicating copy to clipboard operation
weechat.el copied to clipboard

weechat-get-more-lines is really slow

Open fjl opened this issue 8 years ago • 1 comments

When I'm disconnected from my relay for a couple of days and want to catch up, I use weechat-get-more-lines. Loading more than a few lines is really slow though and seems to reinitialise the buffer completely.

Can you help me figure out how it could be made faster? Ideally there would be a function that loads lines asynchronously up to the unread marker line.

fjl avatar Jan 10 '17 19:01 fjl

I'm sorry that weechat.el is as slow as it is - I hardly have the time to do a sophisticated refactoring that is so urgently needed.

One thing that's quite slow is weechat-print-line and the function it calls into. Another thing that's contributing to the slowness is the binary-parsing done in weechat-relay.el. I spent some time trying to figure out what's really slow there (mostly via Emacs' profiling capabilities) but haven't gotten anywhere.

As I said: I think weechat.el could benefit from a new architecture: Doing less buffer updates, batching more stuff, and generally a more pull-driven approach (compared to the eager-rendering done from weechat-relay-process-sentinel.

the-kenny avatar Jan 23 '17 09:01 the-kenny