]> git.baikalelectronics.ru Git - kernel.git/commit
fuse: Use hash table to link processing request
authorKirill Tkhai <ktkhai@virtuozzo.com>
Tue, 11 Sep 2018 10:12:14 +0000 (13:12 +0300)
committerMiklos Szeredi <mszeredi@redhat.com>
Fri, 28 Sep 2018 14:43:23 +0000 (16:43 +0200)
commit2743f2d5925483fb602bc4a9a617bff9a30bf916
tree34d256dcf2c28957a3a1deefe42cd6658f0ff4a3
parentda4441e47e1e8ef0316ecdb8e9f009768407c258
fuse: Use hash table to link processing request

We noticed the performance bottleneck in FUSE running our Virtuozzo storage
over rdma. On some types of workload we observe 20% of times spent in
request_find() in profiler.  This function is iterating over long requests
list, and it scales bad.

The patch introduces hash table to reduce the number of iterations, we do
in this function. Hash generating algorithm is taken from hash_add()
function, while 256 lines table is used to store pending requests.  This
fixes problem and improves the performance.

Reported-by: Alexey Kuznetsov <kuznet@virtuozzo.com>
Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
fs/fuse/dev.c
fs/fuse/fuse_i.h
fs/fuse/inode.c