mbox series

[for-4.20,0/6] xen: Rework for_each_set_bit()

Message ID 20240625190719.788643-1-andrew.cooper3@citrix.com (mailing list archive)
Headers show
Series xen: Rework for_each_set_bit() | expand

Message

Andrew Cooper June 25, 2024, 7:07 p.m. UTC
for_each_set_bit() is currently horribly inefficient for how we commonly use
it.  See patch 4 for details.

Andrew Cooper (6):
  x86/vmx: Rewrite vmx_sync_pir_to_irr() to be more efficient
  xen/bitops: Rename for_each_set_bit() to bitmap_for_each()
  xen/macros: Introduce BUILD_ERROR()
  xen/bitops: Introduce for_each_set_bit()
  ARM/vgic: Use for_each_set_bit() in vgic_set_irqs_pending()
  x86/xstate: Switch back to for_each_set_bit()

 xen/arch/arm/gic-vgic.c          |  2 +-
 xen/arch/arm/vgic.c              |  8 ++---
 xen/arch/arm/vgic/vgic-mmio-v2.c |  2 +-
 xen/arch/arm/vgic/vgic-mmio.c    | 12 +++----
 xen/arch/x86/cpu-policy.c        | 10 +++---
 xen/arch/x86/hvm/vmx/vmx.c       | 61 +++++++++++++++++++++++++++-----
 xen/arch/x86/xstate.c            |  8 ++---
 xen/common/bitops.c              | 29 +++++++++++++++
 xen/include/xen/bitmap.h         | 12 +++++++
 xen/include/xen/bitops.h         | 35 ++++++++++++------
 xen/include/xen/macros.h         |  2 ++
 xen/include/xen/self-tests.h     |  4 +--
 12 files changed, 142 insertions(+), 43 deletions(-)