-
Notifications
You must be signed in to change notification settings - Fork 82
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
decrease the memory footprint of request/reply procedure #262
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Vlado Lavor <[email protected]>
Providing test results using the API memory benchmark (GoVPP + borrowed from Frouter). The API RPS tends to fluctuate but seems to be improved in most measurements. The memory footprint is decreased as demonstrated by example results below. Full results can be found in attached files: Simple API: Current code
Patched
Frouter2 configuration: Current code
Patched
|
See issue #254
Instead of allocating new temporary request/reply objects for each message call and then leaving them for GC to collect, put them into
sync.Pool
instead. The follow-up call can pick previously allocated request/reply from the pool.This approach is supposed to decrease the total number of allocations and STWs due to the GC runs.
Signed-off-by: Vladimir Lavor [email protected]