[dpdk-dev] [PATCH v1 2/3] test/hash: change multiwriter test to use jhash
Bruce Richardson
bruce.richardson at intel.com
Thu Oct 11 13:27:36 CEST 2018
On Wed, Oct 10, 2018 at 02:48:04PM -0700, Yipeng Wang wrote:
> With sequential key, the test will cover more corner
> cases with jhash instead of crc hash, since jhash
> generates more random hash pattern on sequential key.
> It is useful for functional verification.
>
> Signed-off-by: Yipeng Wang <yipeng1.wang at intel.com>
> ---
> test/test/test_hash_multiwriter.c | 15 +++++++++++----
> 1 file changed, 11 insertions(+), 4 deletions(-)
>
Looking at the code in the patch, it appears the function is always now
called with use_jhash == 1. Why not just do a one-line change to switch the
hard-coded crc hash to jhash, rather than hardcoding that later in the file
and having a branch with a never-taken leg?
/Bruce
More information about the dev
mailing list