blk-mq: switch ctx pending map to the sparser blk_align_bitmap
authorJens Axboe <axboe@fb.com>
Wed, 25 Jun 2014 19:51:18 +0000 (13:51 -0600)
committerJens Axboe <axboe@fb.com>
Mon, 30 Mar 2015 18:54:48 +0000 (12:54 -0600)
commit1df7f5fc8012e3f2ce2842c9a00216b4a85a31f8
tree00403c3d9c52ba356edc675e0fed6dd87715d30e
parente2d2609063b7550fb29618244bcf52ac4f421130
blk-mq: switch ctx pending map to the sparser blk_align_bitmap

Each hardware queue has a bitmap of software queues with pending
requests. When new IO is queued on a software queue, the bit is
set, and when IO is pruned on a hardware queue run, the bit is
cleared. This causes a lot of traffic. Switch this from the regular
BITS_PER_LONG bitmap to a sparser layout, similarly to what was
done for blk-mq tagging.

20% performance increase was observed for single threaded IO, and
about 15% performanc increase on multiple threads driving the
same device.

Signed-off-by: Jens Axboe <axboe@fb.com>
block/blk-mq.c
include/linux/blk-mq.h