>-----Original Message-----
>From: Honnappa Nagarahalli [mailto:honnappa.nagaraha...@arm.com]
>Sent: Wednesday, February 5, 2020 11:52 AM
>To: Wang, Yipeng1 <yipeng1.w...@intel.com>; David Marchand
><david.march...@redhat.com>
>Cc: Amit Gupta <agup...@marvell.com>; Gobriel, Sameh
><sameh.gobr...@intel.com>; tho...@monjalon.net; dev <dev@dpdk.org>;
>nd <n...@arm.com>; Honnappa Nagarahalli <honnappa.nagaraha...@arm.com>; nd
><n...@arm.com>
>Subject: RE: [PATCH v2 3/5] test/hash: add lock free reader writer functional
>tests
>
><snip>
>
>> >> > >
>> >> > > Add lock-free reader writer concurrency functional tests.
>> >> > > These tests will provide the same coverage that non lock-free
>> >> > > APIs have.
>> >> > >
>> >> > > Signed-off-by: Honnappa Nagarahalli
>> >> > > <honnappa.nagaraha...@arm.com>
>> >> > > ---
>> >> > > app/test/test_hash_readwrite.c | 58
>> >> > > +++++++++++++++++++++-------------
>> >> > > 1 file changed, 36 insertions(+), 22 deletions(-)
>> >> > >
>> >> > > diff --git a/app/test/test_hash_readwrite.c
>> >> > > b/app/test/test_hash_readwrite.c index 635ed5a9f..a9429091c
>> >> > > 100644
>> >> > > --- a/app/test/test_hash_readwrite.c
>> >> > > +++ b/app/test/test_hash_readwrite.c
>> >> > > @@ -121,7 +121,7 @@
>> >> > test_hash_readwrite_worker(__attribute__((unused))
>> >> > > void *arg) }
>> >> > >
>> >> > > static int
>> >> > > -init_params(int use_ext, int use_htm, int use_jhash)
>> >> > > +init_params(int use_ext, int use_htm, int rw_lf, int use_jhash)
>> >> > > {
>> >> > > unsigned int i;
>> >> > >
>> >> > > @@ -140,15 +140,16 @@ init_params(int use_ext, int use_htm, int
>> >> > use_jhash)
>> >> > > else
>> >> > > hash_params.hash_func = rte_hash_crc;
>> >> > >
>> >> > > + hash_params.extra_flag =
>> >> > > + RTE_HASH_EXTRA_FLAGS_MULTI_WRITER_ADD;
>> >> > > if (use_htm)
>> >> > > - hash_params.extra_flag =
>> >> > > - RTE_HASH_EXTRA_FLAGS_TRANS_MEM_SUPPORT |
>> >> > > - RTE_HASH_EXTRA_FLAGS_RW_CONCURRENCY |
>> >> > > - RTE_HASH_EXTRA_FLAGS_MULTI_WRITER_ADD;
>> >> > > + hash_params.extra_flag |=
>> >> > > + RTE_HASH_EXTRA_FLAGS_TRANS_MEM_SUPPORT;
>>
>> [Wang, Yipeng] Thanks for the patch Honnappa. Here I think we still need the
>> RTE_HASH_EXTRA_FLAGS_RW_CONCURRENCY
>> Flag even with HTM.
>I have made RTE_HASH_EXTRA_FLAGS_RW_CONCURRENCY depend on 'rw_lf' flag. The
>test case HTM +
>RTE_HASH_EXTRA_FLAGS_RW_CONCURRENCY will still run when 'rw_lf' is set to 0.
>
[Wang, Yipeng]
I see, thought was an "else if". It is correct then,
Thanks!