[PATCH 00/15] export/fuse: Use coroutines and multi-threading

Hanna Czenczek posted 15 patches 6 days, 15 hours ago
qapi/block-export.json     |    8 +-
block/export/fuse.c        | 1227 ++++++++++++++++++++++++++++--------
tests/qemu-iotests/308     |    4 +-
tests/qemu-iotests/308.out |    5 +-
4 files changed, 965 insertions(+), 279 deletions(-)
[PATCH 00/15] export/fuse: Use coroutines and multi-threading
Posted by Hanna Czenczek 6 days, 15 hours ago
Hi,

This series first contains some two bug fix patches (one more than the
other), then a couple of small modifications to prepare for the big
ones:

We remove libfuse from the request processing path, only using it for
mounting.  This does not really have a performance impact (but see the
benchmark results on that patch’s commit message), but it allows me to
sleep easier when it comes to concurrency, because I don’t know what
guarantees libfuse makes for coroutine concurrency.

In general, I just don’t feel that libfuse is really the best choice for
us: It seems primarily designed for projects that only provide a
filesystem, and nothing else, i.e. it provides a variety of main loops
and you’re supposed to use them.  QEMU however has its own main loop and
event processing, so the opacity of libfuse’s request processing makes
me uneasy.  Also, FUSE request parsing is not that hard.

Then, this series makes request processing run in coroutines.

Finally, it adds FUSE multi-threading (i.e. one FUSE FD per I/O thread).


Hanna Czenczek (15):
  fuse: Copy write buffer content before polling
  fuse: Ensure init clean-up even with error_fatal
  fuse: Remove superfluous empty line
  fuse: Explicitly set inode ID to 1
  fuse: Change setup_... to mount_fuse_export()
  fuse: Fix mount options
  fuse: Set direct_io and parallel_direct_writes
  fuse: Introduce fuse_{at,de}tach_handlers()
  fuse: Introduce fuse_{inc,dec}_in_flight()
  fuse: Add halted flag
  fuse: Manually process requests (without libfuse)
  fuse: Reduce max read size
  fuse: Process requests in coroutines
  fuse: Implement multi-threading
  fuse: Increase MAX_WRITE_SIZE with a second buffer

 qapi/block-export.json     |    8 +-
 block/export/fuse.c        | 1227 ++++++++++++++++++++++++++++--------
 tests/qemu-iotests/308     |    4 +-
 tests/qemu-iotests/308.out |    5 +-
 4 files changed, 965 insertions(+), 279 deletions(-)

-- 
2.48.1