summaryrefslogtreecommitdiffstats
path: root/block/partitions
diff options
context:
space:
mode:
authorPaolo Valente <paolo.valente@linaro.org>2018-01-13 12:05:17 +0100
committerJens Axboe <axboe@kernel.dk>2018-01-18 16:21:35 +0100
commita52a69ea89dc12e6f4572f554940789c1ab23c7a (patch)
tree0406e05cbef505c74494c817069e13fa7ad83e83 /block/partitions
parentblk-mq: don't dispatch request in blk_mq_request_direct_issue if queue is busy (diff)
downloadlinux-a52a69ea89dc12e6f4572f554940789c1ab23c7a.tar.xz
linux-a52a69ea89dc12e6f4572f554940789c1ab23c7a.zip
block, bfq: limit tags for writes and async I/O
Asynchronous I/O can easily starve synchronous I/O (both sync reads and sync writes), by consuming all request tags. Similarly, storms of synchronous writes, such as those that sync(2) may trigger, can starve synchronous reads. In their turn, these two problems may also cause BFQ to loose control on latency for interactive and soft real-time applications. For example, on a PLEXTOR PX-256M5S SSD, LibreOffice Writer takes 0.6 seconds to start if the device is idle, but it takes more than 45 seconds (!) if there are sequential writes in the background. This commit addresses this issue by limiting the maximum percentage of tags that asynchronous I/O requests and synchronous write requests can consume. In particular, this commit grants a higher threshold to synchronous writes, to prevent the latter from being starved by asynchronous I/O. According to the above test, LibreOffice Writer now starts in about 1.2 seconds on average, regardless of the background workload, and apart from some rare outlier. To check this improvement, run, e.g., sudo ./comm_startup_lat.sh bfq 5 5 seq 10 "lowriter --terminate_after_init" for the comm_startup_lat benchmark in the S suite [1]. [1] https://github.com/Algodev-github/S Tested-by: Oleksandr Natalenko <oleksandr@natalenko.name> Tested-by: Holger Hoffstätte <holger@applied-asynchrony.com> Signed-off-by: Paolo Valente <paolo.valente@linaro.org> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/partitions')
0 files changed, 0 insertions, 0 deletions