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

[QoS] Support dynamic headroom calculation for Barefoot platforms #11104

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

Conversation

mmysle
Copy link

@mmysle mmysle commented Jun 10, 2022

Signed-off-by: Michał Mysłek michal.myslek@intel.com

What I did
Adding the dynamic headroom calculation support for Barefoot platforms.

Why I did it
Enabling dynamic mode for barefoot case.

How I verified it
The community tests are adjusted and pass.

Details if related

Signed-off-by: Michał Mysłek <michal.myslek@intel.com>
@mmysle mmysle requested review from a team and lguohan as code owners June 10, 2022 13:15
@@ -14,12 +14,17 @@
{%- macro generate_buffer_pool_and_profiles() %}
"BUFFER_POOL": {
"ingress_lossless_pool": {
{%- if dynamic_mode is not defined %}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi
From this PR I see the buffer pool sizes (ingress_lossless_pool_size, ingress_lossy_pool_size, and egress_lossy_pool) are dynamically calculated and the shared headroom pool size (ingress_lossless_pool.xoff) is a fixed number.
But in PR sonic-net/sonic-swss#2317 and sonic-net/sonic-swss#2323, I see the buffer pool sizes are fixed and the shared headroom pool size is dynamically calculated.
These result in both the buffer pool sizes and the shared headroom pool size are static. Is this a mistake or by intention?
If you are going to have the buffer pool sizes static and the shared headroom pool size dynamic, I would like to suggest

  • always defining sizes in all pools regardless of whether dynamic_mode is defined
  • defining xoff in ingress_lossless_pool only if dynamic_mode is defined

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stephenxs, thank you for the great suggestions! We decided to push the basic version of the feature so far. But of course it should be ready for further improvements. I like your proposals. I would try to follow your second approach with defining XOFF when dynamic mode is enabled, but I believe it would be worth to verify the first one too. The work will be continued by other engineers on our side.

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.

2 participants