LinuxPPC-Dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] powerpc/irq: Use optimizations for /proc/interrupts
@ 2026-05-23 17:40 Shrikanth Hegde
  2026-05-23 17:40 ` [PATCH 1/3] powerpc/irq: Move __softirq_pending out of irq_stat Shrikanth Hegde
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Shrikanth Hegde @ 2026-05-23 17:40 UTC (permalink / raw)
  To: maddy, linuxppc-dev, tglx; +Cc: sshegde, christophe.leroy, linux-kernel

This series is based on work by Thomas Gleixner[1]. 

There are several optimization which helps to bring the time taken to
read /proc/interrupts. Though it is not in fastpaths, still many tools
read it often and this reduction in time will save meaningful amount of
cycle over the long duration.

[1]: https://lore.kernel.org/all/20260517194421.705253664@kernel.org/

Bulk of the design/code is copied from Thomas's work on x86. powerpc had
exact pattern which made it quite easy to port.

Using micro-loops[2] of reading /proc/interrupts shows real benefit of
the series. Bulk of the gain is already achieved using Thomas's
series[1]. This series on top provide some more benefits. As the system
size goes up, benefits could be more.

[2]: https://lore.kernel.org/all/87jysxw65f.ffs@tglx/

======== Performance Data ==================
Time taken to read /proc/interrupts 1000 times[2]
Base		:  103us 
v6		:   63us
v6+patch 1+2	:   57us
v6+patch 1+2+3	:   54us

Base: tip/master at c991e3897ead ("Merge branch into tip/master: 'x86/tdx'")
Depends on v6[1] to be applied first.

Shrikanth Hegde (3):
  powerpc/irq: Move __softirq_pending out of irq_stat
  powerpc/irq: Make irqstats array based
  powerpc/irq: Suppress unlikely interrupt stats by default

 arch/powerpc/include/asm/hardirq.h |  31 ++++---
 arch/powerpc/kernel/dbell.c        |   2 +-
 arch/powerpc/kernel/irq.c          | 131 +++++++++++++++--------------
 arch/powerpc/kernel/time.c         |   6 +-
 arch/powerpc/kernel/traps.c        |  11 +--
 arch/powerpc/kernel/watchdog.c     |   2 +-
 6 files changed, 95 insertions(+), 88 deletions(-)

-- 
2.47.3



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

end of thread, other threads:[~2026-05-29  8:09 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-23 17:40 [PATCH 0/3] powerpc/irq: Use optimizations for /proc/interrupts Shrikanth Hegde
2026-05-23 17:40 ` [PATCH 1/3] powerpc/irq: Move __softirq_pending out of irq_stat Shrikanth Hegde
2026-05-29  7:43   ` Christophe Leroy (CS GROUP)
2026-05-23 17:40 ` [PATCH 2/3] powerpc/irq: Make irqstats array based Shrikanth Hegde
2026-05-29  7:46   ` Christophe Leroy (CS GROUP)
2026-05-23 17:40 ` [PATCH 3/3] powerpc/irq: Suppress unlikely interrupt stats by default Shrikanth Hegde
2026-05-29  7:51   ` Christophe Leroy (CS GROUP)
2026-05-29  8:09     ` Shrikanth Hegde

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