Cake - FQ_codel the next generation
 help / color / mirror / Atom feed
From: Jonathan Morton <chromatix99@gmail.com>
To: Dave Acker <soldack@gmail.com>
Cc: cake@lists.bufferbloat.net
Subject: Re: [Cake] Fwd: curious about hashing comments on cake
Date: Fri, 8 Jan 2016 23:15:56 +0200	[thread overview]
Message-ID: <498376FB-98D0-4A71-9C50-24C0B5B6CDAD@gmail.com> (raw)
In-Reply-To: <CAA93jw5Zmmu7E8hfu4vCTR_ma=e8ynEbuJmaTsuz0Z=+V7anKA@mail.gmail.com>

> On http://www.bufferbloat.net/projects/codel/wiki/CakeTechnical, it
> says that the hash used by fq_codel had various issues and that "we
> have also found that the hash function fq_codel relies on is
> suboptimal."  I believe that fq_codel uses the Jenkins hash like many
> other parts of linux.  What was suboptimal about it?  The page notes
> the birthday problem but was there anything else?

In some tests, we were seeing a higher rate of collisions than even the birthday theorem would predict.  That generally points to a hash function insufficiently indistinguishable from white noise, at least when truncated for use in a small table.

I don’t think there’s anything fundamentally wrong with the Jenkins hash, but there are possibly limitations with the input conditioning, especially with IPv6 addresses.

Cake does still use the Jenkins hash directly when compiled for older kernels, but that’s a backwards compatibility measure.  For newer kernels, Cake uses whichever hash function is supplied as part of the new flow-dissection API.  It strikes me that this would probably be updated in future if a serious weakness was discovered, and probably uses better input conditioning than the old system.

The birthday paradox is the big one, though, and this is what the set-associative hash function addresses directly.

 - Jonathan Morton


      reply	other threads:[~2016-01-08 21:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAJts4a2fW-j3hw-gKhshrJ9O115jf_gWqsdOAb=XikVgqiXGUw@mail.gmail.com>
2016-01-08 20:58 ` Dave Taht
2016-01-08 21:15   ` Jonathan Morton [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://lists.bufferbloat.net/postorius/lists/cake.lists.bufferbloat.net/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=498376FB-98D0-4A71-9C50-24C0B5B6CDAD@gmail.com \
    --to=chromatix99@gmail.com \
    --cc=cake@lists.bufferbloat.net \
    --cc=soldack@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox