From: Joanne Koong <joannekoong@fb.com>
To: Alexei Starovoitov <alexei.starovoitov@gmail.com>,
Andrii Nakryiko <andrii.nakryiko@gmail.com>
Cc: Martin KaFai Lau <kafai@fb.com>, bpf <bpf@vger.kernel.org>,
Kernel Team <Kernel-team@fb.com>
Subject: Re: [PATCH v3 bpf-next 1/5] bpf: Add bloom filter map implementation
Date: Tue, 28 Sep 2021 20:38:45 -0700 [thread overview]
Message-ID: <c74f5df1-4953-29ca-2217-e63c3f112463@fb.com> (raw)
In-Reply-To: <20210929031715.wvicuaf6iixm7xsb@ast-mbp.dhcp.thefacebook.com>
On 9/28/21 8:17 PM, Alexei Starovoitov wrote:
> On Tue, Sep 28, 2021 at 05:14:55PM -0700, Andrii Nakryiko wrote:
>> So for Bloom filter you get performance advantage from a dedicated map
>> (due to having just 1 helper call to do N hashing operations). For
>> pure bitset, there seems to be little benefit at all because it is
>> basically ARRAY.
> I brought up bitset only as an idea to make bloomfilter map a bit more
> generic and was looking for feedback whether to call the new map
> "bitset that allows bloomfilter operations" or call it
> "bloomfilter that simplifies to bitset" with nr_hashes=0.
>
> It sounds that using bloomfilter as a base name fits better.
I am in favor of calling the new map "bitset that allows bloom filter
operations"
and having the map be BPF_MAP_TYPE_BITSET everywhere.
To me that is more intuitive since the bloom filter is based on top of a
bitset.
And I think more people will generally be using bitsets than the bloom
filter.
Additionally, for users who don't know or care what a bloom filter is, they
might skip this map type altogether and not realize it also can be used as
a bitset.
>> I haven't found SPDX header or any mention of GPL in
>> include/linux/jhash.h, so I assumed someone can just copy paste the
>> code (given the references to public domain). Seems like that's not
>> the case? Just curious about implications, license-wise, if there is
>> no SPDX? Is it still considered GPL?
> I believe so. Every project that copy pasted jhash from the kernel
> add SPDX gpl-2 to its source.
next prev parent reply other threads:[~2021-09-29 3:38 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-21 21:02 [PATCH v3 bpf-next 0/5] Implement bloom filter map Joanne Koong
2021-09-21 21:02 ` [PATCH v3 bpf-next 1/5] bpf: Add bloom filter map implementation Joanne Koong
2021-09-21 23:44 ` Andrii Nakryiko
2021-09-22 19:06 ` Joanne Koong
2021-09-22 19:38 ` Martin KaFai Lau
2021-09-22 20:52 ` Andrii Nakryiko
2021-09-22 22:08 ` Martin KaFai Lau
2021-09-22 23:07 ` Andrii Nakryiko
2021-09-23 1:28 ` Martin KaFai Lau
2021-09-23 18:42 ` Andrii Nakryiko
2021-09-23 19:42 ` Martin KaFai Lau
2021-09-23 20:30 ` Alexei Starovoitov
2021-09-23 21:12 ` Andrii Nakryiko
2021-09-23 22:28 ` Joanne Koong
2021-09-23 23:46 ` Martin KaFai Lau
2021-09-24 2:23 ` Andrii Nakryiko
2021-09-24 16:32 ` Joanne Koong
2021-09-24 23:12 ` Andrii Nakryiko
2021-09-27 16:41 ` Alexei Starovoitov
2021-09-27 21:14 ` Andrii Nakryiko
2021-09-27 23:51 ` Alexei Starovoitov
2021-09-28 0:36 ` Andrii Nakryiko
2021-09-28 16:21 ` Alexei Starovoitov
[not found] ` <aa967ed2-a958-f995-3a09-bbd6b6e775d4@fb.com>
2021-09-28 23:54 ` Andrii Nakryiko
2021-09-29 1:54 ` Joanne Koong
2021-09-29 0:14 ` Andrii Nakryiko
2021-09-29 3:17 ` Alexei Starovoitov
2021-09-29 3:38 ` Joanne Koong [this message]
2021-09-28 1:09 ` Martin KaFai Lau
2021-09-22 20:44 ` Andrii Nakryiko
2021-09-21 21:02 ` [PATCH v3 bpf-next 2/5] libbpf: Allow the number of hashes in bloom filter maps to be configurable Joanne Koong
2021-09-21 22:24 ` Joanne Koong
2021-09-22 23:14 ` Andrii Nakryiko
2021-09-21 23:57 ` Andrii Nakryiko
2021-09-21 21:02 ` [PATCH v3 bpf-next 3/5] selftests/bpf: Add bloom filter map test cases Joanne Koong
2021-09-21 21:02 ` [PATCH v3 bpf-next 4/5] bpf/benchs: Add benchmark test for bloom filter maps Joanne Koong
2021-09-21 21:02 ` [PATCH v3 bpf-next 5/5] bpf/benchs: Add benchmarks for comparing hashmap lookups with vs. without bloom filter Joanne Koong
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c74f5df1-4953-29ca-2217-e63c3f112463@fb.com \
--to=joannekoong@fb.com \
--cc=Kernel-team@fb.com \
--cc=alexei.starovoitov@gmail.com \
--cc=andrii.nakryiko@gmail.com \
--cc=bpf@vger.kernel.org \
--cc=kafai@fb.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;
as well as URLs for NNTP newsgroup(s).