[dpdk-dev] [PATCH] eal/atomic: reimplement rte atomic APIs with atomic builtins

2019-01-03 Thread Phil Yang
'__sync' builtins are deprecated, enable '__atomic' builtins for generic atomic operations. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Tested-by: Phil Yang --- lib/librte_eal/common/include/generic/rte_atomic.h | 80 ++ 1 file changed, 80 inserti

[dpdk-dev] [PATCH] packet_ordering: replace sync builtins with atomic builtins

2019-01-03 Thread Phil Yang
'__sync' builtins are deprecated, use '__atomic' builtins instead for packet_ordering. Fixes: 850f373 ("examples/packet_ordering: new sample app") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Ruifeng Wang --- examples/packet_ordering/main.c | 27

[dpdk-dev] [PATCH v3 1/4] config: use one single config option for C11 memory model

2018-10-08 Thread Phil Yang
Keep only single config option RTE_USE_C11_MEM_MODEL for C11 memory model, so all modules can leverage C11 atomic extension by enable this option. Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu Acked-by: Jerin Jacob --- config/arm/meson.build

[dpdk-dev] [PATCH v3 2/4] kni: fix kni fifo synchronization

2018-10-08 Thread Phil Yang
the values being synced before updating fifo_write and fifo_read. Fixes: 3fc5ca2 ("kni: initial import") Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu Reviewed-by: Ola Liljedahl Reviewed-by: Jerin Jacob --- lib/librte_kni/rte_kni_f

[dpdk-dev] [PATCH v3 3/4] kni: fix kni kernel fifo synchronization

2018-10-08 Thread Phil Yang
Adding memory barrier to make sure the values being synced before updating fifo_write in kni_fifo_put and fifo_read in kni_fifo_get. Fixes: 3fc5ca2 ("kni: initial import") Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu --- kernel/linux/kni/

[dpdk-dev] [PATCH v3 4/4] kni: introduce c11 atomic into kni fifo synchronization

2018-10-08 Thread Phil Yang
Syncing the values by adding c11 atomic memory barriers to make sure the values being synced before updating fifo_write and fifo_read. Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu Reviewed-by: Ola Liljedahl --- .../linuxapp/eal/include/exec-env

[dpdk-dev] [PATCH] app/testpmd: fix vdev socket initialization

2018-10-12 Thread Phil Yang
iled Fix by allocate the devices port to the first available socket or the socket configured in port-numa-config. Fixes: 487f9a5 ("app/testpmd: fix NUMA structures initialization") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- app/test-pmd/testpmd.c | 29 +

[dpdk-dev] [PATCH] app/testpmd: fix physic port socket initialization

2018-10-16 Thread Phil Yang
Once the lcore list setting excluded the socket which physic device attached, it will cause failure. Meanwhile, it will disable Testpmd cross NUMA scenario. Fixes: dbfb8ec ("app/testpmd: optimize mbuf pool allocation") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- app/test-pmd

[dpdk-dev] [PATCH v2] app/testpmd: fix physic port socket initialization

2018-10-16 Thread Phil Yang
Once the lcore list setting excluded the socket which physic device attached, it will cause failure. Meanwhile, it will disable Testpmd cross NUMA scenario. Fixes: dbfb8ec ("app/testpmd: optimize mbuf pool allocation") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- app/test-pmd

[dpdk-dev] [PATCH] app/testpmd: reserve NUMA node per device port and per ring

2018-10-18 Thread Phil Yang
ggested-by: Yigit Ferruh Signed-off-by: Phil Yang --- app/test-pmd/parameters.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c index 4a4debb..38b4197 100644 --- a/app/test-pmd/parameters.c +++ b/ap

[dpdk-dev] [PATCH 1/2] test/pmd_ring_perf: release ring resources after test

2018-10-19 Thread Phil Yang
Need to release the port and the ring resources after test. Otherwise, it will cause failure to allocate memory when reentry the test. Fixes: ea764af ("app/test: add performance test for ring driver") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- test/test/test_pmd_ring_

[dpdk-dev] [PATCH 2/2] test/pmd_ring: release ring resources after test

2018-10-19 Thread Phil Yang
Need to release the port and the ring resources after test. Otherwise, it will cause failure to allocate memory when reentry the test. Fixes: 4ea3801 ("app/test: fix ring unit test") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- test/test/test_pmd_ri

[dpdk-dev] [PATCH v2] test/pmd_ring: release ring resources after test

2018-10-19 Thread Phil Yang
Need to release the port and the ring resources after test. Otherwise, it will cause failure to allocate memory when reentry the test. Fixes: 4ea3801 ("app/test: fix ring unit test") Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- test/test/test_pmd_ri

[dpdk-dev] [PATCH 2/2] test/link_bonding_rssconf: disable HW CRC strip by default

2018-07-02 Thread Phil Yang
Since the tested null device has no capacity of HW CRC offload, disable it for the link bonding rssconf test by default. Otherwise, it will cause test unexpected failure. Fixes: b219c8c("test: enable HW CRC strip by default") Signed-off-by: Phil Yang --- test/test/test_link_bonding

[dpdk-dev] [PATCH 1/2] test/link_bonding: disable HW CRC strip by default.

2018-07-02 Thread Phil Yang
Since the tested virtual device has no capacity of HW CRC offload, disable it for the link bonding test by default. Otherwise, it will cause test unexpected failure. Fixes: b219c8c("test: enable HW CRC strip by default") Signed-off-by: Phil Yang --- test/test/test_link_bond

[dpdk-dev] [PATCH] test/virtual_pmd: Add DEV_RX_OFFLOAD_CRC_STRIP to virtual driver

2018-07-03 Thread Phil Yang
Add DEV_RX_OFFLOAD_CRC_STRIP to virtual drivers since they don't use CRC at all, when an application requires this offload virtual PMDs should not return error. Fixes: b219c8c("test: enable HW CRC strip by default") Signed-off-by: Phil Yang --- test/test/virtual_pmd.c | 1 + 1

Re: [dpdk-dev] [PATCH 1/2] test/link_bonding: disable HW CRC strip by default.

2018-07-03 Thread Phil Yang
Hi Ferruh, Thanks for you patch. > -Original Message- > From: Ferruh Yigit > Sent: Monday, July 2, 2018 6:00 PM > To: dev-boun...@dpdk.org; dev@dpdk.org > Cc: nd ; Phil Yang > Subject: Re: [dpdk-dev] [PATCH 1/2] test/link_bonding: disable HW CRC strip by > defaul

[dpdk-dev] [PATCH] app/testpmd: Optimize membuf pool allocation

2018-08-27 Thread Phil Yang
on by socket id") Signed-off-by: Phil Yang --- app/test-pmd/testpmd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index ee48db2..a56af2b 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -47

Re: [dpdk-dev] [PATCH] test/eal_flags: Optimize memory flags test

2018-04-25 Thread Phil Yang
TRLEN]; char buf[SOCKET_MEM_STRLEN];> /* to avoid copying string onto itself */ Thanks, Phil Yang > -Original Message- > From: Thomas Monjalon > Sent: Thursday, April 26, 2018 1:07 AM > To: Phil Yang > Cc: dev@dpdk.org; nd ; anatoly.bura...@intel.com; Herbert >

[dpdk-dev] [PATCH v2] app/testpmd: optimize membuf pool allocation

2018-09-11 Thread Phil Yang
on by socket id") Signed-off-by: Phil Yang Acked-by: Gavin Hu --- app/test-pmd/testpmd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index ee48db2..a56af2b 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd

[dpdk-dev] [PATCH v2 2/3] kni: fix kni fifo synchronization

2018-09-19 Thread Phil Yang
to make sure the values being synced before updating fifo_write and fifo_read. Fixes: 3fc5ca2 ("kni: initial import") Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu --- .../linuxapp/eal/include/exec-env/rte_kni_common.h | 5 lib/librte_kni/rte_

[dpdk-dev] [PATCH v2 1/3] config: use one single config option for C11 memory model

2018-09-19 Thread Phil Yang
Keep only single config option RTE_USE_C11_MEM_MODEL for C11 memory model, so all modules can leverage C11 atomic extension by enable this option. Fixes: 39368eb ("ring: introduce C11 memory model barrier option") Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by

[dpdk-dev] [PATCH v2 3/3] kni: fix kni kernel fifo synchronization

2018-09-19 Thread Phil Yang
Adding memory barrier to make sure the values being synced before updating fifo_write in kni_fifo_put and fifo_read in kni_fifo_get. Fixes: 3fc5ca2 ("kni: initial import") Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Gavin Hu --- kernel/linux/kni/

[dpdk-dev] [PATCH] build: add meson support for cortex a55 and a76 platforms

2019-01-31 Thread Phil Yang
Enable native/cross compiling for Cortex-A55 and Cortex-A76 on meson. Signed-off-by: Phil Yang Reviewed-by: Ola Liljedahl Reviewed-by: Gavin Hu --- config/arm/arm64_armv8_linuxapp_gcc | 2 ++ config/arm/meson.build | 2 ++ 2 files changed, 4 insertions(+) diff --git a/config/arm

[dpdk-dev] [PATCH] test/memzone: Fix test_memzone_basic & test_memzone_free issues.

2018-01-11 Thread Phil Yang
1. test_memzone_basic: No need to free a NULL memzone. It will cause test termination. 2. test_memzone_free: Out of mz[RTE_MAX_MEMZONE] memory bound while reserving memzone for mz. It will flush variable i. Fix by extend to mz[RTE_MAX_MEMZONE + 1]. Signed-off-by: Phil Yang --- test/test

[dpdk-dev] [PATCH 1/2] test/memzone: Fix test_memzone_basic issue

2018-01-14 Thread Phil Yang
No need to free a NULL memzone. It will cause test termination. Signed-off-by: Phil Yang --- test/test/test_memzone.c | 4 1 file changed, 4 deletions(-) diff --git a/test/test/test_memzone.c b/test/test/test_memzone.c index 6e80977..9c20172 100644 --- a/test/test/test_memzone.c +++ b

[dpdk-dev] [PATCH 0/2] Fix memzone autotest issues

2018-01-14 Thread Phil Yang
an the maximum test memzone_reserve flags 1GB Huge pages available Fail memzone free Test Failed Phil Yang (2): test/memzone: Fix test_memzone_basic issue test/memzone: Fix test_memzone_free issue test/test/test_memzone.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) -- 2.7.4

[dpdk-dev] [PATCH 2/2] test/memzone: Fix test_memzone_free issue

2018-01-14 Thread Phil Yang
When reserving memzone for mz[], it will out of mz[RTE_MAX_MEMZONE] memory bound after the counter reached to RTE_MAX_MEMZONE. It will flush the counter's memory and lead to mz[] memory cannot be freed. Fixd by extend to mz[RTE_MAX_MEMZONE + 1]. Signed-off-by: Phil Yang --- test

[dpdk-dev] [PATCH v2 1/2] test/memzone: Fix test_memzone_basic issue

2018-01-14 Thread Phil Yang
No need to free a NULL memzone. It will cause test termination. Signed-off-by: Phil Yang --- test/test/test_memzone.c | 4 1 file changed, 4 deletions(-) diff --git a/test/test/test_memzone.c b/test/test/test_memzone.c index 6e80977..9c20172 100644 --- a/test/test/test_memzone.c +++ b

[dpdk-dev] [PATCH v2 2/2] test/memzone: Fix test_memzone_free issue

2018-01-14 Thread Phil Yang
When reserving memzone for mz[], it will out of mz[RTE_MAX_MEMZONE] memory bound after the counter reached to RTE_MAX_MEMZONE. It will flush the counter's memory and lead to mz[] memory cannot be freed. Fixd by extend to mz[RTE_MAX_MEMZONE + 1]. Signed-off-by: Phil Yang --- test

[dpdk-dev] [PATCH v2 0/2] Fix memzone autotest issues

2018-01-14 Thread Phil Yang
an the maximum test memzone_reserve flags 1GB Huge pages available Fail memzone free Test Failed Phil Yang (2): test/memzone: Fix test_memzone_basic issue test/memzone: Fix test_memzone_free issue test/test/test_memzone.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) -- 2.7.4

Re: [dpdk-dev] [PATCH] test/memzone: Fix test_memzone_basic & test_memzone_free issues.

2018-01-14 Thread Phil Yang
Hi Anatoly, Thanks for your comments. Updated. Please review the version 2. Thanks, Phil Yang > -Original Message- > From: Burakov, Anatoly [mailto:anatoly.bura...@intel.com] > Sent: Saturday, January 13, 2018 1:44 AM > To: Phil Yang ; dev@dpdk.org > Cc: nd ; Jianbo Liu

[dpdk-dev] [PATCH] app/testpmd: fix stats period can't quit normally in container

2017-09-17 Thread Phil Yang
While running testpmd in container with stats-period option, it can't quit normally after received SIGINT. Signed-off-by: Phil Yang --- app/test-pmd/testpmd.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index e0

[dpdk-dev] [PATCH] app/testpmd: fix stats period can't quit normally in container

2017-09-17 Thread Phil Yang
While running testpmd in container with stats-period option, it can't quit normally after received SIGINT. Signed-off-by: Phil Yang --- app/test-pmd/testpmd.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index e0

[dpdk-dev] [PATCH] app/testpmd: fix stats period can't quit normally in container

2017-09-17 Thread Phil Yang
While running testpmd in container with stats-period option, it can't quit normally after received SIGINT. Signed-off-by: Phil Yang --- app/test-pmd/testpmd.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index e0

[dpdk-dev] [PATCH v2] app/testpmd: fix stats period can't quit normally in container

2017-09-21 Thread Phil Yang
In container, the process cannot be terminated by SIGINT/SIGTERM when execute with 'stats-period' option. Fixed by adding a flag to exit stats period loop after received SIGINT/SIGTERM. Signed-off-by: Phil Yang --- app/test-pmd/testpmd.c | 13 - 1 file changed, 12 insert

[dpdk-dev] [PATCH v2] app/testpmd: fix stats period can't quit normally in container

2017-09-21 Thread Phil Yang
In container, the process cannot be terminated by SIGINT/SIGTERM when execute with 'stats-period' option. Fixed by adding a flag to exit stats period loop after received either SIGINT or SIGTERM. Signed-off-by: Phil Yang --- app/test-pmd/testpmd.c | 13 - 1 file c

[dpdk-dev] [PATCH] fix memzone unit test defect in verify process.

2018-01-28 Thread Phil Yang
eal/linuxapp/eal/eal.c:957 #12 0xaab1e004 in main (argc=5, argv=0xfb58) at test.c:86 ... Phil Yang (1): test/memzone: fix incorrect result judging criteria test/test/test_memzone.c | 141 +-- 1 file changed, 74 insertions(+), 67 deletions(-) -- 2.7.4

[dpdk-dev] [PATCH] test/memzone: fix incorrect result judging criteria

2018-01-28 Thread Phil Yang
remained at the end. Fixes: 71330483a193 ("test/memzone: fix memory leak") Signed-off-by: Phil Yang --- test/test/test_memzone.c | 141 +-- 1 file changed, 74 insertions(+), 67 deletions(-) diff --git a/test/test/test_memzone.c b

Re: [dpdk-dev] [PATCH] lpm: fix allocation of an existing object

2018-01-30 Thread Phil Yang
on in the header file. > > Fixes: 134975073af3 ("lib: remove unnecessary pointer cast") > > Signed-off-by: Pavan Nikhilesh Acked-by: Phil Yang > --- > > This was already fixed in a previous patch by Olivier commit id > f82f705b635d31a63446a16bc4526dbebf29

Re: [dpdk-dev] [PATCH 2/2] test/memzone: handle previously allocated memzones

2018-01-30 Thread Phil Yang
about the memzone used in memzone autotest. It is rough but it seems more reliable. 😊 Thanks, Phil Yang > -Original Message- > From: dev [mailto:dev-boun...@dpdk.org] On Behalf Of Anatoly Burakov > Sent: Saturday, January 27, 2018 1:41 AM > To: dev@dpdk.org > Cc: radoslaw.

Re: [dpdk-dev] [PATCH 2/2] test/memzone: handle previously allocated memzones

2018-01-31 Thread Phil Yang
That is OK for me. Thanks for your comments. Thanks, Phil Yang > -Original Message- > From: Burakov, Anatoly [mailto:anatoly.bura...@intel.com] > Sent: Wednesday, January 31, 2018 6:05 PM > To: Phil Yang ; dev@dpdk.org > Cc: radoslaw.bierna...@linaro.org; sta...@dpdk.org

[dpdk-dev] [PATCH] test/eal_flags: Optimize memory flags test

2018-02-05 Thread Phil Yang
Since RTE_MAX_NUMA_NODES is configurable, the existing socket number could greater than RTE_MAX_NUMA_NODES. Optimize test case to cover this situation.(i.e RTE_MAX_NUMA_NODES=1) Fixes: 45f1b6e8680a ('app: add new tests on eal flags') Signed-off-by: Phil Yang --- test/test/test_eal_f

[dpdk-dev] [PATCH v2 1/3] packet_ordering: add statistics for each worker thread

2019-03-29 Thread Phil Yang
- Ro Pkts tx failed: 0 - Pkts transmitted w/o reorder:0 - Pkts tx failed w/o reorder: 0 Suggested-by: Honnappa Nagarahalli Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- doc/guides/sample_app_ug/packet_ordering.rst | 4 ++- examples/packet_ordering/main

[dpdk-dev] [PATCH v2 0/3] example and test cases optimizations

2019-03-29 Thread Phil Yang
C11_MEM_MODEL is enabled. Phil Yang (3): packet_ordering: add statistics for each worker thread test/distributor: replace sync builtins with atomic builtins test/ring_perf: replace sync builtins with atomic builtins app/test/test_distributor.c | 18 +- app/test

[dpdk-dev] [PATCH v2 2/3] test/distributor: replace sync builtins with atomic builtins

2019-03-29 Thread Phil Yang
f_autotest with this patch *** Cache line switch test === Time for 33554432 iterations = 1251715496 ticks Ticks per iteration = 37 Less ticks needed for the cache line switch test. It got 17% of performance improvement. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Ruifeng Wan

[dpdk-dev] [PATCH v2 3/3] test/ring_perf: replace sync builtins with atomic builtins

2019-03-29 Thread Phil Yang
ing operations performance. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Joyce Kong Reviewed-by: Dharmik Thakkar --- app/test/test_ring_perf.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/app/test/test_ring_perf.c b/app/test/test_ring_per

[dpdk-dev] [PATCH v3 1/3] packet_ordering: add statistics for each worker thread

2019-04-03 Thread Phil Yang
Honnappa Nagarahalli Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- doc/guides/sample_app_ug/packet_ordering.rst | 4 ++- examples/packet_ordering/main.c | 50 +--- 2 files changed, 48 insertions(+), 6 deletions(-) diff --git a/doc/guides/sample_app_ug/packet

[dpdk-dev] [PATCH v3 2/3] test/distributor: replace sync builtins with atomic builtins

2019-04-03 Thread Phil Yang
f_autotest with this patch *** Cache line switch test === Time for 33554432 iterations = 1251715496 ticks Ticks per iteration = 37 Less ticks needed for the cache line switch test. It got 17% of performance improvement. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Ruifeng Wan

[dpdk-dev] [PATCH v3 0/3] example and test cases optimizations

2019-04-03 Thread Phil Yang
. Reimplement test_ring_perf with atomic one-way barrier, if C11_MEM_MODEL is enabled. v1: Reimplement packet_ordering with __atomic one-way barrier. Phil Yang (3): packet_ordering: add statistics for each worker thread test/distributor: replace sync builtins with atomic builtins test/ring_perf

[dpdk-dev] [PATCH v3 3/3] test/ring_perf: replace sync builtins with atomic builtins

2019-04-03 Thread Phil Yang
ing operations performance. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Joyce Kong Reviewed-by: Dharmik Thakkar --- app/test/test_ring_perf.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/app/test/test_ring_perf.c b/app/test/test_ring_per

[dpdk-dev] [PATCH v4 1/3] packet_ordering: add statistics for each worker thread

2019-04-07 Thread Phil Yang
Honnappa Nagarahalli Signed-off-by: Phil Yang Reviewed-by: Gavin Hu --- doc/guides/sample_app_ug/packet_ordering.rst | 4 ++- examples/packet_ordering/main.c | 50 +--- 2 files changed, 48 insertions(+), 6 deletions(-) diff --git a/doc/guides/sample_app_ug/packet

[dpdk-dev] [PATCH v4 0/3] example and test cases optimizations

2019-04-07 Thread Phil Yang
. Reimplement test_distributor with atomic one-way barrier, if C11_MEM_MODEL is enabled. 3. Reimplement test_ring_perf with atomic one-way barrier, if C11_MEM_MODEL is enabled. v1: Reimplement packet_ordering with __atomic one-way barrier. Phil Yang (3): packet_ordering: add statistics for each worker

[dpdk-dev] [PATCH v4 3/3] test/ring_perf: replace sync builtins with atomic builtins

2019-04-07 Thread Phil Yang
ing operations performance. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Joyce Kong Reviewed-by: Dharmik Thakkar --- app/test/test_ring_perf.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/app/test/test_ring_perf.c b/app/test/test_ring_per

[dpdk-dev] [PATCH v4 2/3] test/distributor: replace sync builtins with atomic builtins

2019-04-07 Thread Phil Yang
f_autotest with this patch *** Cache line switch test === Time for 33554432 iterations = 1251715496 ticks Ticks per iteration = 37 Less ticks needed for the cache line switch test. It got 17% of performance improvement. Signed-off-by: Phil Yang Reviewed-by: Gavin Hu Reviewed-by: Ruifeng Wan

Re: [dpdk-dev] [PATCH 1/3] eventdev: fix race condition on timer list counter

2020-07-01 Thread Phil Yang
> -Original Message- > From: Honnappa Nagarahalli > Sent: Friday, June 19, 2020 2:26 AM > To: Carrillo, Erik G ; Phil Yang > ; dev@dpdk.org > Cc: d...@linux.vnet.ibm.com; Ruifeng Wang ; > Dharmik Thakkar ; nd ; > sta...@dpdk.org; Honnappa Nagarahalli ; > nd

Re: [dpdk-dev] [PATCH 1/3] eventdev: fix race condition on timer list counter

2020-07-01 Thread Phil Yang
> -Original Message- > From: Jerin Jacob > Sent: Wednesday, July 1, 2020 7:22 PM > To: Phil Yang > Cc: Honnappa Nagarahalli ; Carrillo, Erik G > ; dev@dpdk.org; d...@linux.vnet.ibm.com; > Ruifeng Wang ; Dharmik Thakkar > ; nd ; sta...@dpdk.org > Subject

[dpdk-dev] [PATCH v2 1/4] eventdev: fix race condition on timer list counter

2020-07-01 Thread Phil Yang
c11 atomics with RELAXED ordering to prevent confliction. Fixes: cc7b73ea9e3b ("eventdev: add new software timer adapter") Cc: erik.g.carri...@intel.com Cc: sta...@dpdk.org Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel Carril

[dpdk-dev] [PATCH v2 3/4] eventdev: remove redundant code

2020-07-01 Thread Phil Yang
There is no thread will access these impl_opaque data after timer canceled. When new timer armed, it got refilled. So the cleanup process is unnecessary. Signed-off-by: Phil Yang --- lib/librte_eventdev/rte_event_timer_adapter.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/lib

[dpdk-dev] [PATCH v2 2/4] eventdev: use c11 atomics for lcore timer armed flag

2020-07-01 Thread Phil Yang
threads. Then the atomic CAS operation is needed. Use the c11 atomic CAS instead of the generic rte_atomic operations to avoid the unnecessary barrier on aarch64. Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang --- v2: 1. Make the code comments more accurate. (Erik) 2

[dpdk-dev] [PATCH v2 4/4] eventdev: relax smp barriers with c11 atomics

2020-07-01 Thread Phil Yang
synchronize the opaque data between timer arm and cancel threads. Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang --- v2: 1. Removed implementation-specific opaque data cleanup code. 2. Replaced thread fence with atomic ACQURE/RELEASE ordering on state access. lib

Re: [dpdk-dev] [PATCH 2/2] doc: add aarch32 build guidance

2020-07-01 Thread Phil Yang
Hi Jerin, Your insight would be much appreciated. Thanks, Phil > -Original Message- > From: Ruifeng Wang > Sent: Wednesday, May 27, 2020 4:29 PM > To: Phil Yang ; dev@dpdk.org > Cc: tho...@monjalon.net; david.march...@redhat.com; > jer...@marvell.com; Honnappa Nag

Re: [dpdk-dev] [PATCH v2] app/testpmd: fix missing set for current forward engine

2020-07-02 Thread Phil Yang
Hi Lijun, Some comments inline. > -Original Message- > From: dev On Behalf Of Lijun Ou > Sent: Wednesday, July 1, 2020 3:43 PM > To: wenzhuo...@intel.com; beilei.x...@intel.com; > bernard.iremon...@intel.com; ferruh.yi...@intel.com > Cc: dev@dpdk.org; linux...@huawei.com > Subject: [dpdk

Re: [dpdk-dev] [PATCH v2] app/testpmd: fix missing set for current forward engine

2020-07-02 Thread Phil Yang
> > IMPORTANT NOTICE: The contents of this email and any attachments are > confidential and may also be privileged. If you are not the intended > recipient, > please notify the sender immediately and do not disclose the contents to any > other person, use it for any purpose, or store or copy the

Re: [dpdk-dev] [PATCH] mbuf: use c11 atomics for refcnt operations

2020-07-06 Thread Phil Yang
> -Original Message- > From: David Marchand > Sent: Friday, July 3, 2020 11:39 PM > To: Phil Yang > Cc: dev ; Olivier Matz ; David > Christensen ; Honnappa Nagarahalli > ; Ruifeng Wang > ; nd > Subject: Re: [dpdk-dev] [PATCH] mbuf: use c11 atomics for refcnt

Re: [dpdk-dev] [PATCH v2 4/4] eventdev: relax smp barriers with c11 atomics

2020-07-06 Thread Phil Yang
> -Original Message- > From: Thomas Monjalon > Sent: Monday, July 6, 2020 6:04 PM > To: Phil Yang > Cc: erik.g.carri...@intel.com; dev@dpdk.org; jer...@marvell.com; Honnappa > Nagarahalli ; d...@linux.vnet.ibm.com; > Ruifeng Wang ; Dharmik Thakkar > ; nd ; > d

Re: [dpdk-dev] [PATCH v2 1/6] lib/eal: add a common wrapper for restricted pointers

2020-07-06 Thread Phil Yang
llanox.com; > shah...@mellanox.com; viachesl...@mellanox.com; Honnappa Nagarahalli > ; Phil Yang ; > Ruifeng Wang > Cc: dev@dpdk.org; nd > Subject: [PATCH v2 1/6] lib/eal: add a common wrapper for restricted > pointers > > The 'restrict' keyword is recognized in C99, while ty

Re: [dpdk-dev] [PATCH v2 4/6] net/i40e: replace restrict with rte restrict

2020-07-06 Thread Phil Yang
llanox.com; > shah...@mellanox.com; viachesl...@mellanox.com; Honnappa Nagarahalli > ; Phil Yang ; > Ruifeng Wang > Cc: dev@dpdk.org; nd > Subject: [PATCH v2 4/6] net/i40e: replace restrict with rte restrict > > '__rte_restrict' is a common wrapper for restricted pointe

Re: [dpdk-dev] [PATCH v2 5/6] examples/performance-thread: replace restrict with wrapper

2020-07-06 Thread Phil Yang
llanox.com; > shah...@mellanox.com; viachesl...@mellanox.com; Honnappa Nagarahalli > ; Phil Yang ; > Ruifeng Wang > Cc: dev@dpdk.org; nd > Subject: [PATCH v2 5/6] examples/performance-thread: replace restrict with > wrapper > > '__rte_restrict' is a common wrapper for

Re: [dpdk-dev] [PATCH v2 6/6] net/mlx5: replace restrict keyword with rte restrict

2020-07-06 Thread Phil Yang
llanox.com; > shah...@mellanox.com; viachesl...@mellanox.com; Honnappa Nagarahalli > ; Phil Yang ; > Ruifeng Wang > Cc: dev@dpdk.org; nd > Subject: [PATCH v2 6/6] net/mlx5: replace restrict keyword with rte restrict > > The 'restrict' keyword is recognized in C99, which might ha

[dpdk-dev] [PATCH v6 0/4] generic rte atomic APIs deprecate proposal

2020-07-07 Thread Phil Yang
style. 4. flag __sync_xxx built-ins in new patches. 5. wraps up compiler atomic built-ins 6. move the changes of libraries which make use of c11 atomic APIs out of this patchset. v3: add libatomic dependency for 32-bit clang v2: 1. fix Clang '-Wincompatible-pointer-types' WARNING. 2. fix ty

[dpdk-dev] [PATCH v6 3/4] devtools: prevent use of rte atomic APIs in future patches

2020-07-07 Thread Phil Yang
__atomic_thread_fence(__ATOMIC_SEQ_CST) is quite expensive for SMP case. Flag the new code which use __atomic_thread_fence API. Signed-off-by: Phil Yang Reviewed-by: Ruifeng Wang --- devtools/checkpatches.sh | 40 1 file changed, 40 insertions(+) diff --git a/devtools

[dpdk-dev] [PATCH v6 1/4] doc: add generic atomic deprecation section

2020-07-07 Thread Phil Yang
Add deprecating the generic rte_atomic_xx APIs to c11 atomic built-ins guide and examples. Signed-off-by: Phil Yang Signed-off-by: Honnappa Nagarahalli --- doc/guides/prog_guide/writing_efficient_code.rst | 139 ++- 1 file changed, 138 insertions(+), 1 deletion(-) diff

[dpdk-dev] [PATCH v6 4/4] eal/atomic: add wrapper for C11 atomic thread fence

2020-07-07 Thread Phil Yang
Provide a wrapper for __atomic_thread_fence built-in to support optimized code for __ATOMIC_SEQ_CST memory order for x86 platforms. Suggested-by: Honnappa Nagarahalli Signed-off-by: Phil Yang Reviewed-by: Ola Liljedahl Acked-by: Konstantin Ananyev --- lib/librte_eal/arm/include/rte_atomic_32

[dpdk-dev] [PATCH v6 2/4] maintainers: claim maintainers of C11 atomics

2020-07-07 Thread Phil Yang
Add the maintainership of C11 atomics code. Different maintainers focus on different platforms C11 atomics. Signed-off-by: Phil Yang Reviewed-by: Honnappa Nagarahalli --- MAINTAINERS | 4 1 file changed, 4 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 27fcd6d..3682d2a 100644

[dpdk-dev] [PATCH v2] mbuf: use C11 atomics for refcnt operations

2020-07-07 Thread Phil Yang
Use C11 atomics with explicit ordering instead of rte_atomic ops which enforce unnecessary barriers on aarch64. Signed-off-by: Phil Yang Reviewed-by: Ruifeng Wang --- v2: Fix ABI issue: revert the rte_mbuf_ext_shared_info struct refcnt field to refcnt_atomic. lib/librte_mbuf/rte_mbuf.c

[dpdk-dev] [PATCH v3 1/4] eventdev: fix race condition on timer list counter

2020-07-07 Thread Phil Yang
c11 atomics with RELAXED ordering to prevent confliction. Fixes: cc7b73ea9e3b ("eventdev: add new software timer adapter") Cc: erik.g.carri...@intel.com Cc: sta...@dpdk.org Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel Carril

[dpdk-dev] [PATCH v3 3/4] eventdev: remove redundant code

2020-07-07 Thread Phil Yang
There is no thread will access these impl_opaque data after timer canceled. When new timer armed, it got refilled. So the cleanup process is unnecessary. Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar --- lib/librte_eventdev/rte_event_timer_adapter.c | 2 -- 1 file changed, 2 deletions

[dpdk-dev] [PATCH v3 2/4] eventdev: use C11 atomics for lcore timer armed flag

2020-07-07 Thread Phil Yang
threads. Then the atomic CAS operation is needed. Use the C11 atomic CAS instead of the generic rte_atomic operations to avoid the unnecessary barrier on aarch64. Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel Carrillo --- v2: 1. Make the code

[dpdk-dev] [PATCH v3 4/4] eventdev: relax smp barriers with C11 atomics

2020-07-07 Thread Phil Yang
. Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel Carrillo --- v3: Fix ABI issue: revert to 'volatile enum rte_event_timer_state type state'. v2: 1. Removed implementation-specific opaque data cleanup code. 2. Replaced thread

[dpdk-dev] [PATCH v4 1/4] eventdev: fix race condition on timer list counter

2020-07-07 Thread Phil Yang
c11 atomics with RELAXED ordering to prevent confliction. Fixes: cc7b73ea9e3b ("eventdev: add new software timer adapter") Cc: erik.g.carri...@intel.com Cc: sta...@dpdk.org Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel Carril

[dpdk-dev] [PATCH v4 4/4] eventdev: relax smp barriers with C11 atomics

2020-07-07 Thread Phil Yang
. Cc: sta...@dpdk.org Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel Carrillo --- v4: 1. Fix typo. 2. Cc to stable release. (Honnappa) v3: Fix ABI issue: revert to 'volatile enum rte_event_timer_state type state'. v2:

[dpdk-dev] [PATCH v4 2/4] eventdev: use C11 atomics for lcore timer armed flag

2020-07-07 Thread Phil Yang
threads. Then the atomic compare-and-swap operation is needed. Use the C11 atomics instead of the generic rte_atomic operations to avoid the unnecessary barrier on aarch64. Cc: sta...@dpdk.org Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar Reviewed-by: Ruifeng Wang Acked-by: Erik Gabriel

[dpdk-dev] [PATCH v4 3/4] eventdev: remove redundant code

2020-07-07 Thread Phil Yang
There is no thread will access these impl_opaque data after timer canceled. When new timer armed, it got refilled. So the cleanup process is unnecessary. Cc: sta...@dpdk.org Signed-off-by: Phil Yang Reviewed-by: Dharmik Thakkar --- v4: Cc to stable release. (Honnappa) lib/librte_eventdev

Re: [dpdk-dev] [PATCH v3 4/4] eventdev: relax smp barriers with C11 atomics

2020-07-07 Thread Phil Yang
> -Original Message- > From: Jerin Jacob > Sent: Tuesday, July 7, 2020 10:30 PM > To: Phil Yang > Cc: tho...@monjalon.net; Erik Gabriel Carrillo ; > dpdk-dev ; jer...@marvell.com; Honnappa Nagarahalli > ; David Christensen > ; Ruifeng Wang ; > Dharmik Thak

Re: [dpdk-dev] [PATCH v2] mbuf: use C11 atomics for refcnt operations

2020-07-07 Thread Phil Yang
> -Original Message- > From: Stephen Hemminger > Sent: Wednesday, July 8, 2020 1:13 AM > To: Phil Yang > Cc: david.march...@redhat.com; dev@dpdk.org; d...@linux.vnet.ibm.com; > Honnappa Nagarahalli ; > olivier.m...@6wind.com; Ruifeng Wang ; nd > > Subject: Re:

Re: [dpdk-dev] [PATCH v2] mbuf: use C11 atomics for refcnt operations

2020-07-07 Thread Phil Yang
> -Original Message- > From: dev On Behalf Of Phil Yang > Sent: Tuesday, July 7, 2020 6:11 PM > To: david.march...@redhat.com; dev@dpdk.org > Cc: d...@linux.vnet.ibm.com; Honnappa Nagarahalli > ; olivier.m...@6wind.com; Ruifeng Wang > ; nd > Subject: [dpdk-dev]

Re: [dpdk-dev] [PATCH 1/2] eal: remove redundant code

2020-07-07 Thread Phil Yang
> -Original Message- > From: Honnappa Nagarahalli > Sent: Wednesday, July 8, 2020 1:15 PM > To: Phil Yang ; dev@dpdk.org > Cc: d...@linux.vnet.ibm.com; Ruifeng Wang ; nd > ; shah...@mellanox.com; sta...@dpdk.org; Honnappa > Nagarahalli ; nd > Subject: RE:

Re: [dpdk-dev] [PATCH 2/2] eal: use c11 atomics for interrupt status

2020-07-08 Thread Phil Yang
> -Original Message- > From: Harman Kalra > Sent: Wednesday, July 8, 2020 7:41 PM > To: Phil Yang > Cc: dev@dpdk.org; d...@linux.vnet.ibm.com; Honnappa Nagarahalli > ; Ruifeng Wang > ; nd > Subject: Re: [dpdk-dev] [PATCH 2/2] eal: use c11 atomics for interrupt st

Re: [dpdk-dev] [PATCH 2/2] eal: use c11 atomics for interrupt status

2020-07-08 Thread Phil Yang
> -Original Message- > From: Kinsella, Ray > Sent: Wednesday, July 8, 2020 11:05 PM > To: David Marchand ; Phil Yang > ; Aaron Conole > Cc: dev ; David Christensen ; > Honnappa Nagarahalli ; Ruifeng Wang > ; nd ; Dodji Seketeli > ; Neil Horman ; Harman > K

[dpdk-dev] [PATCH v2] eal: use c11 atomic built-ins for interrupt status

2020-07-08 Thread Phil Yang
data, so there is no need to set it to invalid after that. Signed-off-by: Phil Yang Reviewed-by: Ruifeng Wang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Harman Kalra --- v2: 1. Fixed typo. 2. Updated libabigail.abignore to pass ABI check. 3. Merged v1 two patches into one patch. devtools

[dpdk-dev] [PATCH] devtools: fix ninja break under default DESTDIR path

2020-07-08 Thread Phil Yang
If DPDK_ABI_REF_DIR is not set, the default DESTDIR is a relative path. This will break ninja in the ABI check test. Fixes: 777014e56d07 ("devtools: add ABI checks") Signed-off-by: Phil Yang --- devtools/test-meson-builds.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) di

Re: [dpdk-dev] [PATCH v2] eal: use c11 atomic built-ins for interrupt status

2020-07-09 Thread Phil Yang
> -Original Message- > From: Stefan Puiu > Sent: Thursday, July 9, 2020 4:02 PM > To: Phil Yang > Cc: david.march...@redhat.com; dev@dpdk.org; m...@ashroe.eu; > acon...@redhat.com; d...@linux.vnet.ibm.com; Honnappa Nagarahalli > ; Ruifeng Wang > ; nd ; do...@r

[dpdk-dev] [PATCH v3] eal: use c11 atomic built-ins for interrupt status

2020-07-09 Thread Phil Yang
data, so there is no need to set it to invalid after that. Signed-off-by: Phil Yang Reviewed-by: Ruifeng Wang Reviewed-by: Honnappa Nagarahalli Reviewed-by: Harman Kalra --- v3: Fixed typo. v2: 1. Fixed typo. 2. Updated libabigail.abignore to pass ABI check. 3. Merged v1 two patches into one

Re: [dpdk-dev] [PATCH v2] mbuf: use C11 atomics for refcnt operations

2020-07-09 Thread Phil Yang
> -Original Message- > From: Olivier Matz > Sent: Wednesday, July 8, 2020 7:43 PM > To: Phil Yang > Cc: Stephen Hemminger ; > david.march...@redhat.com; dev@dpdk.org; d...@linux.vnet.ibm.com; > Honnappa Nagarahalli ; Ruifeng Wang > ; nd > Subject: Re: [dpdk-de

Re: [dpdk-dev] [PATCH v2] mbuf: use C11 atomics for refcnt operations

2020-07-09 Thread Phil Yang
> -Original Message- > From: Olivier Matz > Sent: Wednesday, July 8, 2020 7:44 PM > To: Phil Yang > Cc: david.march...@redhat.com; dev@dpdk.org; d...@linux.vnet.ibm.com; > Honnappa Nagarahalli ; Ruifeng Wang > ; nd > Subject: Re: [PATCH v2] mbuf: use C11 atomi

[dpdk-dev] [PATCH v3] mbuf: use C11 atomic built-ins for refcnt operations

2020-07-09 Thread Phil Yang
Use C11 atomic built-ins with explicit ordering instead of rte_atomic ops which enforce unnecessary barriers on aarch64. Signed-off-by: Phil Yang Reviewed-by: Ruifeng Wang --- v3: 1.Fix ABI breakage. 2.Simplify data type cast. v2: Fix ABI issue: revert the rte_mbuf_ext_shared_info struct

Re: [dpdk-dev] [PATCH v3] mbuf: use C11 atomic built-ins for refcnt operations

2020-07-09 Thread Phil Yang
Hi Oliver, > -Original Message- > From: Olivier Matz > Sent: Thursday, July 9, 2020 7:04 PM > To: Phil Yang > Cc: dev@dpdk.org; step...@networkplumber.org; > david.march...@redhat.com; d...@linux.vnet.ibm.com; Honnappa > Nagarahalli ; Ruifeng Wang > ; nd > S

Re: [dpdk-dev] [PATCH v3] mbuf: use C11 atomic built-ins for refcnt operations

2020-07-09 Thread Phil Yang
> > > > > > > Hi Phil, > > > > > > On Thu, Jul 09, 2020 at 06:10:42PM +0800, Phil Yang wrote: > > > > Use C11 atomic built-ins with explicit ordering instead of > > > > rte_atomic ops which enforce unnecessary barriers on aarch64

[dpdk-dev] [PATCH v4 2/2] doc: announce deprecation of refcnt atomic member

2020-07-09 Thread Phil Yang
refcnt_atomic member in structures rte_mbuf and rte_mbuf_ext_shared_info will be deprecated in 20.11 release. Signed-off-by: Phil Yang --- doc/guides/rel_notes/deprecation.rst | 6 ++ 1 file changed, 6 insertions(+) diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes

  1   2   3   4   5   >