Commits
Pavel Tikhomirov authored and Konstantin Khorenko committed d478d513af0
blk-wbt: increase maximum queue depth to increase performance of writes With wbt patches on simple test: #!/bin/bash rm -rf /my/filetree echo 3 > /proc/sys/vm/drop_caches sync time tar -xzf /my/filetree.zip -C /my time sync we have a performance degradation of ~20-50% of last sync. That looks connected with the fact that SATA devices always have a small queue depth (request_queue->queue_depth == 31) and thus wbt is limiting the maximum number of inflight write requests depending on the prioryty with 8/16/23 (low to high), all extra writes just sleep waiting for previous writes to complete. But if more write requests given to the device driver, elevator algorithm should give a better performance than if we only give them by small portions, and before wbt we gave as much writes as we could. The whole point of wbt is in scaling these three limits making them bigger if we have only writes and making them lower if some reads want to be processed. So we increase the maximum from x3/4 of device queue size to x8. These should improve writes performance when where are no concurrent reads. These increase of "wb_..." limits makes reads latency decrease as now wbt should scale_down several times when detecting read requests. https://jira.sw.ru/browse/PSBM-96243 Signed-off-by: Pavel Tikhomirov <ptikhomirov@virtuozzo.com> ===================== Patchset description: block: backport writeback throttling We have a problem that if we run heavy write load on one cpu simultaneousely with short direct reads on other cpu, the latter will hang significantly. Writeback throttling looks like a sollution for these reads, as it will decrease the priority of long running writeback. Running simple dd experiment we see that reads latency decreased after wbt patches applied: https://docs.google.com/spreadsheets/d/1HLtepwFL_N5zm0JcTqMtJoYnf-b6Slwld8DDgL0gNDI We've ran vconsolidate on custom kernel with these patches, though it does not show any performance improvement (likely because this test does not produce high rate of writeback), it does not crash or fail the test. https://jira.sw.ru/browse/PSBM-96243 Jens Axboe (6): block: add REQ_BACKGROUND writeback: add wbc_to_write_flags() writeback: mark background writeback as such writeback: track if we're sleeping on progress in balance_dirty_pages() blk-wbt: add general throttling mechanism block: hook up writeback throttling Omar Sandoval (1): block: get rid of struct blk_issue_stat Pavel Tikhomirov (2): x86/asm: remove the unused get_limit() method block: enable CONFIG_BLK_WBT* blk-wbt: increase maximum queue depth to increase performance of writes