Re: [vpp-dev] Question of worker thread handoff

2018-04-23 Thread Kingwel Xie
pp-dev] Question of worker thread handoff Dear Kingwel, What would you expect from us to do if A waits for B to take stuff from the queue and on the same time B waits for A for the same reason beside what we already do in NAT code, and that is to drop instead of wait. -- Damjan On 23 Apr 20

Re: [vpp-dev] Question of worker thread handoff

2018-04-23 Thread Damjan Marion
:damar...@cisco.com] Sent: Monday, April 23, 2018 6:25 PM To: Ole Troan mailto:otr...@employees.org>>; Kingwel Xie mailto:kingwel@ericsson.com>> Cc: vpp-dev mailto:vpp-dev@lists.fd.io>>; Lollita Liu mailto:lollita@ericsson.com>> Subject: Re: [vpp-dev] Question of work

Re: [vpp-dev] Question of worker thread handoff

2018-04-23 Thread Kingwel Xie
, April 23, 2018 6:25 PM To: Ole Troan ; Kingwel Xie Cc: vpp-dev ; Lollita Liu Subject: Re: [vpp-dev] Question of worker thread handoff Yes, there are 2 options when handoff queue is full, drop or wait. Wait gives you nice back-pressure mechanism as it will slow down input worker, but it will

Re: [vpp-dev] Question of worker thread handoff

2018-04-23 Thread Damjan Marion
Yes, there are 2 options when handoff queue is full, drop or wait. Wait gives you nice back-pressure mechanism as it will slow down input worker, but it will not work in case when A handoffs to B and B handoffs to A. -- Damjan On 23 Apr 2018, at 10:50, Ole Troan mailto:otr...@employees.org>> wr

Re: [vpp-dev] Question of worker thread handoff

2018-04-23 Thread Ole Troan
Kingwei, Yes, it's possible to dead lock in this case. We had a similar issue with the NAT implementation. While testing I think we ended up dropping when the queue was full. Best regards, Ole > On 23 Apr 2018, at 10:33, Kingwel Xie wrote: > > Hi Damjan and all, > > We are currently thinking

[vpp-dev] Question of worker thread handoff

2018-04-23 Thread Kingwel Xie
Hi Damjan and all, We are currently thinking of how to utilize the handoff mechanism to serve our application logic – to run a packet re-ordering and re-transmit queue in the same worker context to avoid any lock between threads. We come across with a question when looking into the implementati