Thread (20 messages) 20 messages, 7 authors, 2025-07-30

Re: [PATCH v3] memcg: expose socket memory pressure in a cgroup

From: Daniel Sedlak <hidden>
Date: 2025-07-24 08:43:37
Also in: cgroups, linux-mm

On 7/23/25 7:54 PM, Shakeel Butt wrote:
quoted
To me, introducing the new PSI for sockets (like for CPU, IO, memory), would
be slightly better than cumulative counter because PSI can have the timing
information without frequent periodic scrapes. So it may help with live
debugs.
How would this PSI for sockets work? What would be the entry and exit
points?
Currently, we know the following information:

- we know when the pressure starts
- and we know when the pressure ends if not rearmed (start time + HZ)

 From that, we should be able to calculate a similar triplet to the 
pressure endpoints in the cgroups (cpu|io|memory|irq).pressure. That is, 
how much % of time on average was spent under pressure for avg10, avg60, 
avg300 i.e. average pressure over the past 10 seconds, 60 seconds, and 
300 seconds, respectively. (+ total time spent under pressure)

For example, if we had pressure for 5 seconds straight, then the output 
of socket.pressure could be:

	full avg10=50.00 avg60=8.33 avg300=1.66 total=77777

Do you think this would be feasible? If so, I can try to send it as v4.

Thanks!
Daniel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help