public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCHv2 0/2] blk-mq: add CPU latency limit control
@ 2024-10-18  7:30 Tero Kristo
  2024-10-18  7:30 ` [PATCHv2 1/2] block/genhd: add sysfs knobs for the CPU latency PM QoS settings Tero Kristo
                   ` (2 more replies)
  0 siblings, 3 replies; 7+ messages in thread
From: Tero Kristo @ 2024-10-18  7:30 UTC (permalink / raw)
  To: axboe; +Cc: hch, linux-block, linux-kernel

Hello,

Try #2 of the patches here. I sent earlier an RFC version against block/bio
[1], and then an isolated patch for NVMe driver only [2].

After feedback from maintainers, I've reworked the patches again to block
layer, this time to multiqueue support only. Once a blk-mq request is about
to be dispatched to the driver layer, the PM QoS variables for active CPUs
are tweaked based on configuration, and a timeout is launched as a delayed
work that drops the PM QoS limits once the queue is idle. The mechanism is
disabled by default, and only enabled once user activates it via the
provided sysfs knobs.

Some measurement data provided below as a reference for the
results, measured with 'fio' on an Intel Icelake Xeon platform, with an
extra NVMe card on the system. Both latency and bandwidth values are
provided, to showcase that the latency is reduced and bandwidth is not
impacted negatively due to overhead. C6 residency measurement is not
very accurate in my test leading to somewhat glitchy result on its
value (c6%).

key:
  slat: start latency max, in us
  clat: completion latency max, in us
  lat: overall latency max, in us
  bw: min-avg-max bandwidth values
  c6%: c6 (deep idle) residency for the active CPU during the test

cpu_lat_limit_us=10 (enabled)
  slat: 63, clat: 107, lat: 115, bw: 1177-1367-1397, c6%: 11.9
  slat: 30, clat: 129, lat: 137, bw: 1196-1380-1409, c6%: 0.9
  slat: 60, clat: 101, lat: 109, bw: 1193-1372-1407, c6%: 0.9
  slat: 29, clat: 135, lat: 143, bw: 1184-1369-1398, c6%: 1.0
  slat: 29, clat: 112, lat: 120, bw: 1188-1368-1397, c6%: 1.0
cpu_lat_limit_us=-1 (disabled)
  slat: 106, clat: 281, lat: 353, bw: 1183-1363-1403, c6%: 79.9
  slat: 107, clat: 270, lat: 319, bw: 1192-1370-1406, c6%: 79.8
  slat: 156, clat: 269, lat: 323, bw: 1187-1363-1398, c6%: 80.4
  slat: 106, clat: 267, lat: 316, bw: 1183-1367-1402, c6%: 80.5
  slat: 108, clat: 247, lat: 313, bw: 1186-1368-1404, c6%: 80.0
  slat: 107, clat: 274, lat: 323, bw: 1188-1361-1399, c6%: 80.0

-Tero

[1] https://lore.kernel.org/lkml/ZtHWkn2FJhAa+Vvo@fedora/T/
[2] https://lore.kernel.org/lkml/20241004101014.3716006-1-tero.kristo@linux.intel.com/


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-10-23 14:07 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-18  7:30 [PATCHv2 0/2] blk-mq: add CPU latency limit control Tero Kristo
2024-10-18  7:30 ` [PATCHv2 1/2] block/genhd: add sysfs knobs for the CPU latency PM QoS settings Tero Kristo
2024-10-18  7:30 ` [PATCHv2 2/2] blk-mq: add support for CPU latency limits Tero Kristo
2024-10-18 14:21   ` Jens Axboe
2024-10-23 13:26     ` Tero Kristo
2024-10-23 13:48       ` Jens Axboe
2024-10-23 14:06 ` [PATCH v3 " Tero Kristo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox