linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 00/11] VDUSE: Improve performance
@ 2022-12-05  8:41 Xie Yongji
  2022-12-05  8:41 ` [PATCH v2 01/11] genirq/affinity:: Export irq_create_affinity_masks() Xie Yongji
                   ` (6 more replies)
  0 siblings, 7 replies; 51+ messages in thread
From: Xie Yongji @ 2022-12-05  8:41 UTC (permalink / raw)
  To: mst, jasowang, tglx, hch; +Cc: virtualization, linux-kernel

Hi all,

This series introduces some ways to improve VDUSE performance.

Patch 1 ~ 7 brings current interrupt affinity spreading mechanism
to vduse device and make it possible for the virtio-blk driver
to build the blk-mq queues based on it. This would be useful to
mitigate the virtqueue lock contention in virtio-blk driver. In
our test, we could get ~50% improvement (600k iops -> 900k iops)
when using per-cpu virtqueue.

Patch 8 adds a sysfs interface for each vduse virtqueue to show
the affinity and effective affinity for IRQ callback. And the
effective affinity interface is also writable so that we can
do some performance tuning when the affinity mask contains more
than one CPU.

Patch 9 adds a sysfs interface for each virtqueues to control
whether use workqueue to inject irq or not. The vhost-vdpa case
can benefit from it.

Patch 10, 11 add a sysfs interface to support specifying bounce
buffer size in virtio-vdpa case. The high throughput workloads
can benefit from it. And we can also use it to reduce the memory
overhead for small throughput workloads.

Please review, thanks!

V1 to V2:
- Export irq_create_affinity_masks()
- Add set/get_vq_affinity and set_irq_affinity callbacks in vDPA
  framework
- Add automatic irq callback affinity support in VDUSE driver [Jason]
- Add more backgrounds information in commit log [Jason]
- Only support changing effective affinity when the value is a subset
  of the IRQ callback affinity mask.

Xie Yongji (11):
  genirq/affinity:: Export irq_create_affinity_masks()
  vdpa: Add set/get_vq_affinity callbacks in vdpa_config_ops
  vdpa: Add set_irq_affinity callback in vdpa_config_ops
  vduse: Refactor allocation for vduse virtqueues
  vduse: Introduce bound workqueue for irq injection
  vduse: Support automatic irq callback affinity
  vduse: Support set/get_vq_affinity callbacks
  vduse: Add sysfs interface for irq callback affinity
  vduse: Add enable_irq_wq sysfs interface for virtqueues
  vduse: Delay iova domain creation
  vduse: Support specifying bounce buffer size via sysfs

 drivers/vdpa/vdpa_user/vduse_dev.c | 497 +++++++++++++++++++++++++----
 drivers/virtio/virtio_vdpa.c       |  32 ++
 include/linux/vdpa.h               |  21 ++
 kernel/irq/affinity.c              |   1 +
 4 files changed, 488 insertions(+), 63 deletions(-)

-- 
2.20.1


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

end of thread, other threads:[~2023-02-14  2:39 UTC | newest]

Thread overview: 51+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-12-05  8:41 [PATCH v2 00/11] VDUSE: Improve performance Xie Yongji
2022-12-05  8:41 ` [PATCH v2 01/11] genirq/affinity:: Export irq_create_affinity_masks() Xie Yongji
2022-12-06  8:18   ` Christoph Hellwig
2022-12-06  8:40     ` Yongji Xie
2022-12-06  8:47       ` Christoph Hellwig
2022-12-06  9:28         ` Yongji Xie
2022-12-07  5:56           ` Jason Wang
2022-12-19  7:33   ` Michael S. Tsirkin
2022-12-19  9:36     ` Yongji Xie
2023-01-27  8:22       ` Michael S. Tsirkin
2023-01-30 11:53         ` Yongji Xie
2023-02-13 11:59           ` Michael S. Tsirkin
2023-02-13 14:50             ` Yongji Xie
2023-02-13 18:53               ` Thomas Gleixner
2023-02-14  2:38                 ` Yongji Xie
2022-12-05  8:41 ` [PATCH v2 02/11] vdpa: Add set/get_vq_affinity callbacks in vdpa_config_ops Xie Yongji
2022-12-16  3:52   ` Jason Wang
2022-12-05  8:41 ` [PATCH v2 03/11] vdpa: Add set_irq_affinity callback " Xie Yongji
2022-12-16  3:58   ` Jason Wang
2022-12-19  4:38     ` Yongji Xie
2022-12-19  6:06       ` Jason Wang
2022-12-19  7:12         ` Yongji Xie
2022-12-20  6:31           ` Jason Wang
2022-12-20 10:14             ` Yongji Xie
2022-12-21  3:20               ` Jason Wang
2022-12-05  8:41 ` [PATCH v2 04/11] vduse: Refactor allocation for vduse virtqueues Xie Yongji
2022-12-16  3:59   ` Jason Wang
2022-12-05  8:41 ` [PATCH v2 05/11] vduse: Introduce bound workqueue for irq injection Xie Yongji
2022-12-16  4:02   ` Jason Wang
2022-12-19  5:04     ` Yongji Xie
2022-12-20  6:27       ` Jason Wang
2022-12-20 10:01         ` Yongji Xie
2022-12-21  3:19           ` Jason Wang
2022-12-05  8:58 ` [PATCH v2 06/11] vduse: Support automatic irq callback affinity Xie Yongji
2022-12-16  5:30   ` Jason Wang
2022-12-19  4:56     ` Yongji Xie
2022-12-20  6:32       ` Jason Wang
2022-12-20  8:21         ` Yongji Xie
2022-12-05  9:02 ` [PATCH v2 07/11] vduse: Support set/get_vq_affinity callbacks Xie Yongji
2022-12-05  9:02   ` [PATCH v2 08/11] vduse: Add sysfs interface for irq callback affinity Xie Yongji
2022-12-16  5:35     ` Jason Wang
2022-12-19  5:16       ` Yongji Xie
2022-12-20  6:29         ` Jason Wang
2022-12-20  8:24           ` Yongji Xie
2022-12-05  9:02   ` [PATCH v2 09/11] vduse: Add enable_irq_wq sysfs interface for virtqueues Xie Yongji
2022-12-16  5:43     ` Jason Wang
2022-12-19  6:39       ` Yongji Xie
2022-12-05  9:02   ` [PATCH v2 10/11] vduse: Delay iova domain creation Xie Yongji
2022-12-16  5:49     ` Jason Wang
2022-12-05  9:02   ` [PATCH v2 11/11] vduse: Support specifying bounce buffer size via sysfs Xie Yongji
2022-12-16  6:02     ` Jason Wang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).