The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Johannes Weiner <hannes@cmpxchg.org>
To: Pintu Kumar Agarwal <pintu.agarwal@oss.qualcomm.com>
Cc: linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	surenb@google.com, rostedt@goodmis.org, mhiramat@kernel.org,
	peterz@infradead.org, mathieu.desnoyers@efficios.com,
	mingo@redhat.com, juri.lelli@redhat.com,
	vincent.guittot@linaro.org, dietmar.eggemann@arm.com,
	bsegall@google.com, mgorman@suse.de, vschneid@redhat.com,
	kprateek.nayak@amd.com, pintu.ping@gmail.com, nathan@kernel.org,
	ojeda@kernel.org, nsc@kernel.org, gary@garyguo.net,
	tglx@kernel.org, thomas.weissschuh@linutronix.de,
	aliceryhl@google.com, dianders@chromium.org,
	linux.amoon@gmail.com, rdunlap@infradead.org,
	akpm@linux-foundation.org, shuah@kernel.org
Subject: Re: [RFC PATCH 0/1] psi: Introduce in-kernel PSI auto monitor feature
Date: Mon, 13 Jul 2026 07:59:36 -0400	[thread overview]
Message-ID: <20260713115936.GM276793@cmpxchg.org> (raw)
In-Reply-To: <20260702171606.527077-1-pintu.agarwal@oss.qualcomm.com>

On Thu, Jul 02, 2026 at 10:46:05PM +0530, Pintu Kumar Agarwal wrote:
> Hi all,
> 
> This RFC introduces an in-kernel PSI auto monitor aimed at improving
> root-cause visibility for resource pressure events in Linux systems.
> 
> Motivation:
> 
> PSI already provides an excellent mechanism to detect CPU, memory and
> I/O pressure and includes trigger-based notifications via pollable
> interfaces. However, it deliberately avoids attributing pressure to
> individual tasks.

Why is this necessary?

> In real-world systems, this creates a gap: when a PSI trigger fires,
> users still need to determine *which tasks caused the stall* by combining
> multiple tools (top, meminfo, vmstat, perf, tracing, etc.), often after
> the event has already passed.

I've never found myself needing to identify which specific task was
stalled. Tasks competing over a shared resource are interdependent.

Consider this scenario: Task A, B, C are allocating memory and
creating pressure together; B randomly becomes the sucker to hit
direct reclaim and making room for the other too as well. Why is it
meaningful to know that B stalled? It caused the resource contention
no more than the other two.

Then A and C refault: A is fast, but C happens to hit when the flash
drive is running garbage collection. Why is it meaningful to know C?
Again, C is no more the culprit in that situation than the others.

The meaningful thing you can say is that the domain as a whole is
under pressure. Who exactly becomes the lightning rod is noise.

That said, if you do need it, why not use delayacct? It already tracks
the reclaim, swap, thrashing time and events that also go into psi on
a per-task basis. It's not sampled, either.

      parent reply	other threads:[~2026-07-13 11:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-02 17:16 [RFC PATCH 0/1] psi: Introduce in-kernel PSI auto monitor feature Pintu Kumar Agarwal
2026-07-02 17:16 ` [RFC PATCH 1/1] " Pintu Kumar Agarwal
2026-07-02 19:51   ` K Prateek Nayak
2026-07-03 15:32     ` Pintu Kumar Agarwal
2026-07-10 16:01       ` Pintu Kumar Agarwal
2026-07-13  3:16         ` K Prateek Nayak
2026-07-13 11:59 ` Johannes Weiner [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260713115936.GM276793@cmpxchg.org \
    --to=hannes@cmpxchg.org \
    --cc=akpm@linux-foundation.org \
    --cc=aliceryhl@google.com \
    --cc=bsegall@google.com \
    --cc=dianders@chromium.org \
    --cc=dietmar.eggemann@arm.com \
    --cc=gary@garyguo.net \
    --cc=juri.lelli@redhat.com \
    --cc=kprateek.nayak@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=linux.amoon@gmail.com \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mgorman@suse.de \
    --cc=mhiramat@kernel.org \
    --cc=mingo@redhat.com \
    --cc=nathan@kernel.org \
    --cc=nsc@kernel.org \
    --cc=ojeda@kernel.org \
    --cc=peterz@infradead.org \
    --cc=pintu.agarwal@oss.qualcomm.com \
    --cc=pintu.ping@gmail.com \
    --cc=rdunlap@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=shuah@kernel.org \
    --cc=surenb@google.com \
    --cc=tglx@kernel.org \
    --cc=thomas.weissschuh@linutronix.de \
    --cc=vincent.guittot@linaro.org \
    --cc=vschneid@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox