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

zebra: reduce memory usage by streams when redistributing routes #17928

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fdumontet6WIND
Copy link
Contributor

Stream is first encoded in a local variable.
A new stream based on the encoded data size is allocated. Encoded Stream is copied in allocated memeory area.

@frrbot frrbot bot added the zebra label Jan 27, 2025
@fdumontet6WIND fdumontet6WIND force-pushed the mem_alloc_stream branch 3 times, most recently from 05a0b94 to 7d3279e Compare January 27, 2025 11:05
Stream is first encoded in a local variable.
A new stream based on the encoded data size is allocated.
Encoded Stream is copied in allocated memeory area.

Signed-off-by: Francois Dumontet <francois.dumontet@6wind.com>
@donaldsharp
Copy link
Member

Can we find a better way to solve this problem then to copy the stream data 2 times?

@donaldsharp
Copy link
Member

why not count the nexthops and just do a quick multiplication to get the size of the stream?

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

Successfully merging this pull request may close these issues.

2 participants