Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optimise Websocket #141

Merged
merged 5 commits into from
Jan 15, 2025
Merged

Optimise Websocket #141

merged 5 commits into from
Jan 15, 2025

Conversation

essen
Copy link
Member

@essen essen commented Jan 3, 2025

essen added 2 commits January 6, 2025 16:13
See comment within the commit for full details.

This results in improved Cowboy performance decoding text
messages of around 10 to 15% in all scenarios, except when
the message is small and it contains mostly non-ASCII (due
to the cost of trying ASCII first).

This brings decoding of text frames closer to decoding of
binary frames, with ASCII data taking approximately 1.1 times
longer to decode, mixed data 1.25 times longer and mostly
non-ASCII data 1.35 times longer to decode.
@essen essen force-pushed the optimise-websockets branch from aab6a35 to 921b1ff Compare January 6, 2025 15:15
essen added 3 commits January 7, 2025 12:50
By (un)masking 16 bytes at a time when possible
(instead of 4) we process frames roughly 10% faster
for all frame types.
This has no real impact on performance
but simplies the code a little.
Disable improper lists warnings in cow_qs/cow_uri since
we intentionally create them.
@essen essen merged commit 109ca9b into master Jan 15, 2025
38 checks passed
@essen
Copy link
Member Author

essen commented Jan 15, 2025

Merged!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant