Skip to content

RFC bfq: Waker logic tweaks for dbench performance

Jan Kara linux-block 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest2 patches 7 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2bfq: Fix check detecting whether waker queue should be selectedblock/bfq-iosched.c+1 -13 replies
2/2bfq: Allow short_ttime queues to have wakerblock/bfq-iosched.c+0 -12 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/2 RFC] bfq: Waker logic tweaks for dbench performance

Hello,

I was investigating why dbench performance (even for single dbench client) with BFQ is significantly worse than it used to be CFQ. The culprit is the idling logic in BFQ. The dbench workload is very fsync(2) heavy. In practice the time to complete fsync(2) calls is what determines the overall performance. For filesystems with a journal such as xfs or ext4 it is common that fsync(2) involves writing data from the process runningg fsync(2) - dbench in this case
- and then waiting for the journalling machinery to flush out metadata from a separate process (jbd2 process in ext4 case, worker thread in xfs case). CFQ's heuristic was able to determine that it isn't worth to idle waiting for either dbench or jbd2 IO. BFQ's heuristic is not able to determine this and thus jbd2 process is often blocked waiting for idle timer of dbench queue to trigger.

The first patch in the series is an obvious bugfix but is not enough to improve performance. The second patch does improve dbench performance from ~80 MB/s to ~200 MB/s on my test machine but I'm aware that it is probably way too aggressive and probably a different solution is needed. So I just wrote that patch to see the results and spark some discussion :). Any idea how to improve the waker logic so that dbench performance doesn't drop so dramatically?

Honza