diff options
author | Kim Alvefur <zash@zash.se> | 2024-11-09 00:37:15 +0100 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2024-11-09 00:37:15 +0100 |
commit | 693079c619ef4d33c90a20979ac5d97b0c2712ec (patch) | |
tree | edc821da1fb38afc1021d526ceb633b4b5ece13f /teal-src | |
parent | 3b079188006e47fdea16e267492033c56bdc6391 (diff) | |
download | prosody-693079c619ef4d33c90a20979ac5d97b0c2712ec.tar.gz prosody-693079c619ef4d33c90a20979ac5d97b0c2712ec.zip |
net.server_epoll: Improve efficiency of sending much buffered data
Problem: The string slice operations when a lot of data gets buffered
ends up being expensive and memory-consuming. We have util.dbuffer for
precisely this kind of thing.
I want to keep the behavior of writebuffer being upgraded from nil to a
string to full buffer since the last step involves three table
allocations, where the previous buffer method only used one. Avoiding
those allocations for simple writes like white space keep alive feels
like it would keep memory churn down.
This work was started in 2020
Diffstat (limited to 'teal-src')
0 files changed, 0 insertions, 0 deletions