mbox series

[v4,0/2] one way barrier for split vring idx

Message ID 20200424033909.1893-1-joyce.kong@arm.com (mailing list archive)
Headers
Series one way barrier for split vring idx |

Message

Joyce Kong April 24, 2020, 3:39 a.m. UTC
  This patchset replaces the two-way barriers with C11 one-way barriers
for split vring idx, when the frontend and backend are implemented
in software.

By doing PVP benchmarking, the test result of 2c1q showed the throughput
increased 20% with the 0.001% of acceptable loss rate on Thunderx2
platform.[1]

By doing vhost-user + virtio-user case benchmarking, 4% performance gain
was measured on Thunderx2 platform by 2c1q RFC2544 test of 0.001% loss,
and 4.7% performance was improved on Dell platform by 1c1q RFC2544 test
of zero packet loss.[2]

[1]https://doc.dpdk.org/guides/howto/pvp_reference_benchmark.html
[2]https://doc.dpdk.org/dts/test_plans/pvp_multi_paths_performance_test_plan.html
   PVP test with virtio 1.0 normal path

v4:
  Remove some duplicated code comment.

v3:
  Modify some style error.

v2:
  Add test performance statistics.

Joyce Kong (2):
  virtio: one way barrier for split vring used idx
  virtio: one way barrier for split vring avail idx

 drivers/net/virtio/virtio_ethdev.c            |  7 +--
 drivers/net/virtio/virtio_ring.h              |  2 +-
 drivers/net/virtio/virtio_rxtx.c              | 35 ++++-------
 drivers/net/virtio/virtio_rxtx_simple_neon.c  |  5 +-
 drivers/net/virtio/virtio_rxtx_simple_sse.c   |  4 +-
 .../net/virtio/virtio_user/virtio_user_dev.c  |  8 ++-
 drivers/net/virtio/virtqueue.c                |  2 +-
 drivers/net/virtio/virtqueue.h                | 58 ++++++++++++++++---
 lib/librte_vhost/virtio_net.c                 | 19 +++---
 9 files changed, 81 insertions(+), 59 deletions(-)
  

Comments

Maxime Coquelin April 28, 2020, 4:06 p.m. UTC | #1
On 4/24/20 5:39 AM, Joyce Kong wrote:
> This patchset replaces the two-way barriers with C11 one-way barriers
> for split vring idx, when the frontend and backend are implemented
> in software.
> 
> By doing PVP benchmarking, the test result of 2c1q showed the throughput
> increased 20% with the 0.001% of acceptable loss rate on Thunderx2
> platform.[1]
> 
> By doing vhost-user + virtio-user case benchmarking, 4% performance gain
> was measured on Thunderx2 platform by 2c1q RFC2544 test of 0.001% loss,
> and 4.7% performance was improved on Dell platform by 1c1q RFC2544 test
> of zero packet loss.[2]
> 
> [1]https://doc.dpdk.org/guides/howto/pvp_reference_benchmark.html
> [2]https://doc.dpdk.org/dts/test_plans/pvp_multi_paths_performance_test_plan.html
>    PVP test with virtio 1.0 normal path
> 
> v4:
>   Remove some duplicated code comment.
> 
> v3:
>   Modify some style error.
> 
> v2:
>   Add test performance statistics.
> 
> Joyce Kong (2):
>   virtio: one way barrier for split vring used idx
>   virtio: one way barrier for split vring avail idx
> 
>  drivers/net/virtio/virtio_ethdev.c            |  7 +--
>  drivers/net/virtio/virtio_ring.h              |  2 +-
>  drivers/net/virtio/virtio_rxtx.c              | 35 ++++-------
>  drivers/net/virtio/virtio_rxtx_simple_neon.c  |  5 +-
>  drivers/net/virtio/virtio_rxtx_simple_sse.c   |  4 +-
>  .../net/virtio/virtio_user/virtio_user_dev.c  |  8 ++-
>  drivers/net/virtio/virtqueue.c                |  2 +-
>  drivers/net/virtio/virtqueue.h                | 58 ++++++++++++++++---
>  lib/librte_vhost/virtio_net.c                 | 19 +++---
>  9 files changed, 81 insertions(+), 59 deletions(-)
> 

Applied to dpdk-next-virtio/master

Thanks,
Maxime
  
Ferruh Yigit April 29, 2020, 5:45 p.m. UTC | #2
On 4/24/2020 4:39 AM, Joyce Kong wrote:
> This patchset replaces the two-way barriers with C11 one-way barriers
> for split vring idx, when the frontend and backend are implemented
> in software.
> 
> By doing PVP benchmarking, the test result of 2c1q showed the throughput
> increased 20% with the 0.001% of acceptable loss rate on Thunderx2
> platform.[1]
> 
> By doing vhost-user + virtio-user case benchmarking, 4% performance gain
> was measured on Thunderx2 platform by 2c1q RFC2544 test of 0.001% loss,
> and 4.7% performance was improved on Dell platform by 1c1q RFC2544 test
> of zero packet loss.[2]
> 
> [1]https://doc.dpdk.org/guides/howto/pvp_reference_benchmark.html
> [2]https://doc.dpdk.org/dts/test_plans/pvp_multi_paths_performance_test_plan.html
>    PVP test with virtio 1.0 normal path
> 
> v4:
>   Remove some duplicated code comment.
> 
> v3:
>   Modify some style error.
> 
> v2:
>   Add test performance statistics.
> 
> Joyce Kong (2):
>   virtio: one way barrier for split vring used idx
>   virtio: one way barrier for split vring avail idx
> 

Hi Joyce,

When 'CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DUMP=y' enabled, build fails. Can you
please check it?

Thanks,
ferruh
  
Maxime Coquelin April 30, 2020, 9:09 a.m. UTC | #3
On 4/29/20 7:45 PM, Ferruh Yigit wrote:
> On 4/24/2020 4:39 AM, Joyce Kong wrote:
>> This patchset replaces the two-way barriers with C11 one-way barriers
>> for split vring idx, when the frontend and backend are implemented
>> in software.
>>
>> By doing PVP benchmarking, the test result of 2c1q showed the throughput
>> increased 20% with the 0.001% of acceptable loss rate on Thunderx2
>> platform.[1]
>>
>> By doing vhost-user + virtio-user case benchmarking, 4% performance gain
>> was measured on Thunderx2 platform by 2c1q RFC2544 test of 0.001% loss,
>> and 4.7% performance was improved on Dell platform by 1c1q RFC2544 test
>> of zero packet loss.[2]
>>
>> [1]https://doc.dpdk.org/guides/howto/pvp_reference_benchmark.html
>> [2]https://doc.dpdk.org/dts/test_plans/pvp_multi_paths_performance_test_plan.html
>>    PVP test with virtio 1.0 normal path
>>
>> v4:
>>   Remove some duplicated code comment.
>>
>> v3:
>>   Modify some style error.
>>
>> v2:
>>   Add test performance statistics.
>>
>> Joyce Kong (2):
>>   virtio: one way barrier for split vring used idx
>>   virtio: one way barrier for split vring avail idx
>>
> 
> Hi Joyce,
> 
> When 'CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DUMP=y' enabled, build fails. Can you
> please check it?

Hi Joyce,

I will need the fix today, just send a v5 for the series.
If not possible to do it today, please let me know.

Maxime


> Thanks,
> ferruh
>
  
Joyce Kong April 30, 2020, 9:16 a.m. UTC | #4
> -----Original Message-----
> From: Maxime Coquelin <maxime.coquelin@redhat.com>
> Sent: Thursday, April 30, 2020 5:09 PM
> To: Ferruh Yigit <ferruh.yigit@intel.com>; Joyce Kong
> <Joyce.Kong@arm.com>; stephen@networkplumber.org;
> xiaolong.ye@intel.com; tiwei.bie@intel.com; zhihong.wang@intel.com;
> thomas@monjalon.net; jerinj@marvell.com; yinan.wang@intel.com;
> Honnappa Nagarahalli <Honnappa.Nagarahalli@arm.com>; Gavin Hu
> <Gavin.Hu@arm.com>
> Cc: nd <nd@arm.com>; dev@dpdk.org
> Subject: Re: [dpdk-dev] [PATCH v4 0/2] one way barrier for split vring idx
> 
> 
> 
> On 4/29/20 7:45 PM, Ferruh Yigit wrote:
> > On 4/24/2020 4:39 AM, Joyce Kong wrote:
> >> This patchset replaces the two-way barriers with C11 one-way barriers
> >> for split vring idx, when the frontend and backend are implemented in
> >> software.
> >>
> >> By doing PVP benchmarking, the test result of 2c1q showed the
> >> throughput increased 20% with the 0.001% of acceptable loss rate on
> >> Thunderx2 platform.[1]
> >>
> >> By doing vhost-user + virtio-user case benchmarking, 4% performance
> >> gain was measured on Thunderx2 platform by 2c1q RFC2544 test of
> >> 0.001% loss, and 4.7% performance was improved on Dell platform by
> >> 1c1q RFC2544 test of zero packet loss.[2]
> >>
> >> [1]https://doc.dpdk.org/guides/howto/pvp_reference_benchmark.html
> >>
> [2]https://doc.dpdk.org/dts/test_plans/pvp_multi_paths_performance_test
> _plan.html
> >>    PVP test with virtio 1.0 normal path
> >>
> >> v4:
> >>   Remove some duplicated code comment.
> >>
> >> v3:
> >>   Modify some style error.
> >>
> >> v2:
> >>   Add test performance statistics.
> >>
> >> Joyce Kong (2):
> >>   virtio: one way barrier for split vring used idx
> >>   virtio: one way barrier for split vring avail idx
> >>
> >
> > Hi Joyce,
> >
> > When 'CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DUMP=y' enabled, build fails.
> Can
> > you please check it?
> 
> Hi Joyce,
> 
> I will need the fix today, just send a v5 for the series.
> If not possible to do it today, please let me know.
> 
> Maxime
> 
Hi Maxime,
I have just fixed the issue and sent out the v5, please have a review.
Thanks. 
> 
> > Thanks,
> > ferruh
> >
  
Maxime Coquelin April 30, 2020, 9:24 a.m. UTC | #5
On 4/30/20 11:16 AM, Joyce Kong wrote:
>> -----Original Message-----
>> From: Maxime Coquelin <maxime.coquelin@redhat.com>
>> Sent: Thursday, April 30, 2020 5:09 PM
>> To: Ferruh Yigit <ferruh.yigit@intel.com>; Joyce Kong
>> <Joyce.Kong@arm.com>; stephen@networkplumber.org;
>> xiaolong.ye@intel.com; tiwei.bie@intel.com; zhihong.wang@intel.com;
>> thomas@monjalon.net; jerinj@marvell.com; yinan.wang@intel.com;
>> Honnappa Nagarahalli <Honnappa.Nagarahalli@arm.com>; Gavin Hu
>> <Gavin.Hu@arm.com>
>> Cc: nd <nd@arm.com>; dev@dpdk.org
>> Subject: Re: [dpdk-dev] [PATCH v4 0/2] one way barrier for split vring idx
>>
>>
>>
>> On 4/29/20 7:45 PM, Ferruh Yigit wrote:
>>> On 4/24/2020 4:39 AM, Joyce Kong wrote:
>>>> This patchset replaces the two-way barriers with C11 one-way barriers
>>>> for split vring idx, when the frontend and backend are implemented in
>>>> software.
>>>>
>>>> By doing PVP benchmarking, the test result of 2c1q showed the
>>>> throughput increased 20% with the 0.001% of acceptable loss rate on
>>>> Thunderx2 platform.[1]
>>>>
>>>> By doing vhost-user + virtio-user case benchmarking, 4% performance
>>>> gain was measured on Thunderx2 platform by 2c1q RFC2544 test of
>>>> 0.001% loss, and 4.7% performance was improved on Dell platform by
>>>> 1c1q RFC2544 test of zero packet loss.[2]
>>>>
>>>> [1]https://doc.dpdk.org/guides/howto/pvp_reference_benchmark.html
>>>>
>> [2]https://doc.dpdk.org/dts/test_plans/pvp_multi_paths_performance_test
>> _plan.html
>>>>    PVP test with virtio 1.0 normal path
>>>>
>>>> v4:
>>>>   Remove some duplicated code comment.
>>>>
>>>> v3:
>>>>   Modify some style error.
>>>>
>>>> v2:
>>>>   Add test performance statistics.
>>>>
>>>> Joyce Kong (2):
>>>>   virtio: one way barrier for split vring used idx
>>>>   virtio: one way barrier for split vring avail idx
>>>>
>>>
>>> Hi Joyce,
>>>
>>> When 'CONFIG_RTE_LIBRTE_VIRTIO_DEBUG_DUMP=y' enabled, build fails.
>> Can
>>> you please check it?
>>
>> Hi Joyce,
>>
>> I will need the fix today, just send a v5 for the series.
>> If not possible to do it today, please let me know.
>>
>> Maxime
>>
> Hi Maxime,
> I have just fixed the issue and sent out the v5, please have a review.
> Thanks. 

Thanks! That was fast :)

Maxime

>>
>>> Thanks,
>>> ferruh
>>>
>