Skip to content

Conversation

@CBenoit
Copy link
Member

@CBenoit CBenoit commented Aug 14, 2024

We’re spending a lot of time dealing with Bytes and BytesMut in the JMUX sender task.

image

This patch is getting rid of the leftmost drop. We can actually reuse the BytesMut buffer between writes and greatly reduces allocation / de-allocation.

Performance is increased by ~26.3%.

Before this patch:

0.0000-19.0245 sec 25.2 GBytes 11.4 Gbits/sec

After this patch:

0.0000-17.1307 sec 28.8 GBytes 14.4 Gbits/sec

Performance is increased by ~26.3%.

Before this patch:

> 0.0000-19.0245 sec 25.2 GBytes 11.4 Gbits/sec

After this patch:

> 0.0000-17.1307 sec  28.8 GBytes  14.4 Gbits/sec
@CBenoit CBenoit enabled auto-merge (squash) August 14, 2024 17:06
@CBenoit CBenoit merged commit 8ebfd23 into master Aug 14, 2024
@CBenoit CBenoit deleted the perf/jmux-proxy-2 branch August 14, 2024 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants