[dpdk-dev] cuckoo hash in dpdk

Pragash Vijayaragavan pxv3620 at rit.edu
Wed Aug 23 22:20:55 CEST 2017


Hi ,

The performance will depend on the time taken for calculating the hash1 and
hash2 values for each lookup.

Can i know which hash functions are used to calculate the hash values for
each incoming key. We use CRC32 which uses xxhash i guess.
I could not find the implementation of the hash functions.


Thanks,

Pragash Vijayaragavan
Grad Student at Rochester Institute of Technology
email : pxv3620 at rit.edu
ph : 585 764 4662


On Wed, Aug 23, 2017 at 2:28 PM, Dumitrescu, Cristian <
cristian.dumitrescu at intel.com> wrote:

>
>
> > -----Original Message-----
> > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Pragash
> > Vijayaragavan
> > Sent: Wednesday, August 23, 2017 3:16 PM
> > To: dev at dpdk.org
> > Cc: Minseok Kwon <mxkvcs at rit.edu>
> > Subject: [dpdk-dev] cuckoo hash in dpdk
> >
> > Hi,
> >
> > I got the chance to look at the cuckoo hash used in dpdk and have a
> query.
> >
> > would using division and modulo operations be slower than bitwise
> > operations on RTE_HASH_BUCKET_ENTRIES, specially since
> > RTE_HASH_BUCKET_ENTRIES is a power of 2.
> > For example, to do a modulo we can do a "AND" operation on
> > (RTE_HASH_BUCKET_ENTRIES - 1), which might be faster. We did a cuckoo
> > filter for VPP and doing this gave a slight improvement in speed.
> > Is there any particular reason its done this way.
> >
> > Sorry if i am being wrong in any way, i was just curious.
> >
> > Thanks,
> >
> > Pragash Vijayaragavan
> > Grad Student at Rochester Institute of Technology
> > email : pxv3620 at rit.edu
> > ph : 585 764 4662
>
> Bitwise AND typically takes 1 cycle on any CPU, while modulo takes dozens
> of cycles.
>


More information about the dev mailing list