# Queuing\_Traffic Manager\_V1architecture

**URL:** https://forum.p4.org/t/queuing-traffic-manager-v1architecture/359
**Category:** Getting Started with P4
**Created:** [June 2, 2022, 3:06pm UTC](https://forum.p4.org/t/queuing-traffic-manager-v1architecture/359 "2022-06-02T15:06:27Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![ederollora](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.p4.org/ederollora/32/21_2.png) [@ederollora](https://forum.p4.org/u/ederollora)
#### Post date: [June 2, 2022, 8:25pm UTC](https://forum.p4.org/t/queuing-traffic-manager-v1architecture/359/2 "2022-06-02T20:25:40Z")

</div>

Hi,

This is not a question I can properly answer as I have never developed any part of bmv2 of the Simple Switch target. But I remember reading about similar questions compared to the one you made.

I will literally copy an answer from @antoninbas from the [first link posted below](https://github.com/p4lang/behavioral-model/issues/729#issuecomment-470213274), it might help with your question.

> I’ll answer this question specifically for bmv2 _simple\_switch_ (every bmv2 target is free to adopt a different queuing scheme). simple\_switch has an `input_buffer` queue ([https://github.com/p4lang/behavioral-model/blob/master/targets/simple\_switch/simple\_switch.h#L172](https://github.com/p4lang/behavioral-model/blob/master/targets/simple_switch/simple_switch.h#L172)). By default this queue can hold 1K packets and is blocking, meaning a write operation will block until there is an available slot. In particular this means that a resubmitted / recirculated packet can never be dropped. For incoming packets read though libpcap (for example) the write is blocking, so back-pressure will build at the Linux interface and I expect packets to be dropped there if there is more incoming traffic than simple\_switch can handle.
> 
> If this doesn’t work for you, feel free to use different settings for `input_buffer` or change the input queueing scheme altogether.
> 
> There isn’t really a notion of “line rate” here. The simple\_switch ingress pipeline will handle packets as fast as your CPU can handle.

I can provide you a few links that might help if you have not read them yet:

- [Is there an input queue in ingress port to storage packets arriving at line rate? #729](https://github.com/p4lang/behavioral-model/issues/729)
- [Priority Queueing with v1model.p4 #562](https://github.com/p4lang/behavioral-model/issues/562)
- [Priority Switching in V1model #401](https://github.com/p4lang/tutorials/issues/401#)
- [What is the queue management approach in P4?](https://forum.p4.org/t/what-is-the-queue-management-approach-in-p4/273)
- [Simple\_switch queue capacity #311](https://github.com/p4lang/behavioral-model/issues/311)
- [BMv2 Queues: independent from qdisc? #343](https://github.com/p4lang/tutorials/issues/343)
- See this code line from [`simple_switch.h`](https://github.com/p4lang/behavioral-model/blob/f16d0de3486aa7fb2e1fe554aac7d237cc1adc33/targets/simple_switch/simple_switch.h#L37).

If my answer does not work, you can ask again and @antonin or @andyfingerhut might be able to help if they pass by the thread.

Cheers,

---

_[View the full topic](https://forum.p4.org/t/queuing-traffic-manager-v1architecture/359)._
