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

Improve memory usage #451

Merged
merged 9 commits into from
Jan 28, 2025
Merged

Improve memory usage #451

merged 9 commits into from
Jan 28, 2025

Conversation

Totodore
Copy link
Owner

Motivation

The PacketBuf smallvec defined for a engineio socket has a size of 10 packets on the stack. It is quite an improbable scenario that a user would send a packet encoded with the common parser with 9 binary attachments.
Therefore the number has been reduced to 2. If someone sends something with more than 1 binary attachments, it will simply be dynamically reallocated on the heap.

@Totodore Totodore added A-engineioxide Area related to engineioxide C-Performance Performance related issues and PRs labels Jan 28, 2025
@Totodore Totodore enabled auto-merge (squash) January 28, 2025 10:13
@Totodore Totodore merged commit 353bb80 into main Jan 28, 2025
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-engineioxide Area related to engineioxide C-Performance Performance related issues and PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant