Linux Power Management development
 help / color / mirror / Atom feed
From: Navon John Lukose <navonjohnlukose@gmail.com>
To: Christian Loehle <christian.loehle@arm.com>
Cc: "Rafael J. Wysocki" <rafael@kernel.org>,
	Daniel Lezcano <daniel.lezcano@kernel.org>,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] cpuidle: teo: Keep the tick when intercepts predict a short idle period
Date: Wed,  2 Dec 2026 20:25:53 +0530	[thread overview]
Message-ID: <20261202145553.33595-1-navonjohnlukose@gmail.com> (raw)
In-Reply-To: <6d47fcee-f243-419e-9326-788cc90eeb2c@arm.com>

On Wed, 2 Dec 2026 12:37:32 +0000, Christian Loehle wrote:
> thanks for the patch, I think it makes sense.
> Do you mind just dumping the state counts / duration deltas, IMO that
> would be more readable.

Sure. Stock -> patched, summed over all 16 CPUs per second of wall time.
Residency is the share of total CPU time spent in the state. above
counts stays shorter than the state's own target residency, below
counts stays long enough for the next deeper state's (381 us for C1,
3144 us for C2).

The machine has 16 CPUs without SMT: 6 P-cores, 8 E-cores and 2 LP
E-cores. The pipe and timer loads ran on the cores named below; all
other CPUs, the LP E-cores included, only saw background activity.

Idle, display off, 7 stock / 8 patched interleaved rounds of 100 s
(one noisy stock round was dropped), the same runs as the changelog
numbers:

         entries/s       residency %       above/s         below/s
POLL     0.3 ->    0.3   0.00 ->  0.00    0.0 ->   0.0    0.2 ->   0.2
C1     139.6 ->  110.8   3.06 ->  0.21    0.3 ->   0.3   43.1 ->  30.6
C2     121.5 ->  104.8   3.27 ->  2.57   11.4 ->   7.8   12.8 ->   8.6
C3     472.2 ->  501.8  92.99 -> 96.59  115.4 -> 118.2    0.0 ->   0.0

Periodic loads, 6 interleaved rounds of 45 s each.

Pipe wakeups every 1.5 ms, writer and reader on E-cores 7 and 9:

         entries/s       residency %       above/s         below/s
POLL     2.8 ->    5.0   0.00 ->  0.00    0.0 ->   0.0    2.2 ->   4.2
C1     117.3 ->  303.9   2.24 ->  0.88    3.0 ->   4.5   34.9 -> 140.3
C2    1490.2 -> 1452.4  13.52 -> 12.79   36.3 ->  60.7    2.7 ->   2.7
C3     286.2 ->  292.5  83.90 -> 85.98   57.0 ->  57.3    0.0 ->   0.0

Pipe wakeups every 2 ms, writer and reader on E-cores 7 and 9:

         entries/s       residency %       above/s         below/s
POLL     2.3 ->    3.3   0.00 ->  0.00    0.0 ->   0.0    2.0 ->   2.8
C1      81.4 ->  196.1   1.57 ->  0.59    2.1 ->   4.4   28.4 -> 108.3
C2    1060.7 -> 1041.9  13.14 -> 13.01   10.1 ->  10.1    2.1 ->   2.4
C3     285.4 ->  263.6  85.00 -> 86.11   59.5 ->  51.6    0.0 ->   0.0

Pipe wakeups every 2.5 ms, writer and reader on E-cores 7 and 9:

         entries/s       residency %       above/s         below/s
POLL     3.3 ->    3.9   0.00 ->  0.00    0.0 ->   0.0    3.1 ->   3.6
C1      90.6 ->  145.6   1.71 ->  0.41    3.2 ->   4.0   29.0 ->  66.2
C2     874.0 ->  871.8  13.32 -> 13.29   12.2 ->  11.4    2.5 ->   2.9
C3     303.9 ->  291.5  84.69 -> 86.02   62.7 ->  63.9    0.0 ->   0.0

Pipe wakeups every 3 ms, writer and reader on P-cores 2 and 4:

         entries/s       residency %       above/s         below/s
POLL     4.8 ->    3.3   0.00 ->  0.00    0.0 ->   0.0    3.6 ->   2.7
C1      93.0 ->  148.5   1.86 ->  0.48    3.7 ->   2.8   30.7 ->  80.2
C2     749.1 ->  731.3  13.31 -> 13.19   12.1 ->   8.8    3.0 ->   3.1
C3     293.1 ->  282.6  84.50 -> 86.01   63.6 ->  60.4    0.0 ->   0.0

Timer wakeups every 2 ms on P-core 3:

         entries/s       residency %       above/s         below/s
POLL     3.5 ->   10.5   0.00 ->  0.00    0.0 ->   0.0    2.8 ->  10.2
C1      87.2 ->  146.4   2.05 ->  0.45    4.0 ->   2.9   31.1 ->  70.4
C2     568.5 ->  550.2   7.42 ->  7.20    6.3 ->   7.4    3.5 ->   3.3
C3     295.0 ->  294.2  90.14 -> 91.95   61.3 ->  58.1    0.0 ->   0.0

Under the periodic loads C1 is entered more often and its below count
rises because a wrong C1 pick now ends at the next tick and teo selects
again, instead of lasting until the next timer. below counts stays
rather than time, and about half of the C1 stays reach C2's 381 us, so
the count goes up while C1 residency drops by a factor of 2.5 to 4.5
(mean C1 stay 3.0-3.8 ms -> 0.45-0.52 ms).

If any other measurements would help, I can run them.

Navon

      reply	other threads:[~2026-12-02 14:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-12-02  8:25 [PATCH] cpuidle: teo: Keep the tick when intercepts predict a short idle period Navon John Lukose
2026-12-02 12:37 ` Christian Loehle
2026-12-02 14:55   ` Navon John Lukose [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=20261202145553.33595-1-navonjohnlukose@gmail.com \
    --to=navonjohnlukose@gmail.com \
    --cc=christian.loehle@arm.com \
    --cc=daniel.lezcano@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=rafael@kernel.org \
    /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