From: Alexei Starovoitov <ast@fb.com>
To: Omar Sandoval <osandov@osandov.com>, Jens Axboe <axboe@fb.com>,
<linux-block@vger.kernel.org>
Cc: <linux-kernel@vger.kernel.org>, <kernel-team@fb.com>
Subject: Re: [PATCH v2 1/5] blk-mq: abstract tag allocation out into scale_bitmap library
Date: Wed, 7 Sep 2016 17:01:56 -0700 [thread overview]
Message-ID: <57D0AA74.5010000@fb.com> (raw)
In-Reply-To: <de3d08bb7b2a2f20bd456112b97a9ab2fe6f1573.1473291702.git.osandov@fb.com>
On 9/7/16 4:46 PM, Omar Sandoval wrote:
> From: Omar Sandoval <osandov@fb.com>
>
> This is a generally useful data structure, so make it available to
> anyone else who might want to use it. It's also a nice cleanup
> separating the allocation logic from the rest of the tag handling logic.
>
> The code is behind a new Kconfig option, CONFIG_SCALE_BITMAP, which is
> only selected by CONFIG_BLOCK for now.
>
> This should be a complete noop functionality-wise.
>
> Signed-off-by: Omar Sandoval <osandov@fb.com>
> ---
> MAINTAINERS | 1 +
> block/Kconfig | 1 +
> block/blk-mq-tag.c | 469 ++++++++++---------------------------------
> block/blk-mq-tag.h | 37 +---
> block/blk-mq.c | 113 +++--------
> block/blk-mq.h | 9 -
> include/linux/blk-mq.h | 9 +-
> include/linux/scale_bitmap.h | 340 +++++++++++++++++++++++++++++++
> lib/Kconfig | 3 +
> lib/Makefile | 2 +
> lib/scale_bitmap.c | 305 ++++++++++++++++++++++++++++
...
> diff --git a/include/linux/scale_bitmap.h b/include/linux/scale_bitmap.h
> new file mode 100644
> index 0000000..63f712b
> --- /dev/null
> +++ b/include/linux/scale_bitmap.h
> @@ -0,0 +1,340 @@
> +/*
> + * Fast and scalable bitmaps.
...
> +/**
> + * struct scale_bitmap_word - Word in a &struct scale_bitmap.
> + */
> +struct scale_bitmap_word {
> +/**
> + * struct scale_bitmap - Scalable bitmap.
> + *
> + * A &struct scale_bitmap is spread over multiple cachelines to avoid ping-pong.
> + * This trades off higher memory usage for better scalability.
> + */
> +struct scale_bitmap {
scale_bitmap sounds odd, since 'scale' is also a verb.
We also have lib/rhashtable.c:
* Resizable, Scalable, Concurrent Hash Table
everything is 'scalable' nowadays.
May be resizable bitmap would be a better name?
'struct rbitmap'... lib/rbitmap.c ?
next prev parent reply other threads:[~2016-09-08 0:02 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-07 23:46 [PATCH v2 0/5] " Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 1/5] " Omar Sandoval
2016-09-08 0:01 ` Alexei Starovoitov [this message]
2016-09-08 0:38 ` Omar Sandoval
2016-09-08 1:12 ` Alexei Starovoitov
2016-09-08 16:11 ` Jens Axboe
2016-09-08 18:16 ` Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 2/5] scale_bitmap: allocate wait queues on a specific node Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 3/5] scale_bitmap: push per-cpu last_tag into scale_bitmap_queue Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 4/5] scale_bitmap: push alloc policy " Omar Sandoval
2016-09-07 23:46 ` [PATCH v2 5/5] scale_bitmap: randomize initial last_cache values Omar Sandoval
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=57D0AA74.5010000@fb.com \
--to=ast@fb.com \
--cc=axboe@fb.com \
--cc=kernel-team@fb.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=osandov@osandov.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
Powered by JetHome