Performance regression: resume_console takes 100ms longer in S2idle/S3 resume in v6.6-rc1
Hi,
I notice a regression report on Bugzilla [1]. Quoting from it:
Quoted 17 lines
Ever since 6.6.0-rc1 we've seen S3 and S2idle resume take 100ms longer because of
resume_comsole.resume_consoleordinarily takes only a few milliseconds, but now it's consistently 100ms. I've bisected the issue to this commit:commit
9e70a5e109a4a23367810de09be826c52d27ee2fAuthor: John Ogness <[email protected]> Date: Mon Jul 17 21:52:06 2023 +0206printk: Add per-console suspended state
Currently the global @console_suspended is used to determine if consoles are in a suspended state. Its primary purpose is to allow usage of the
console_lockwhen suspended without causing console printing. It is synchronized by theconsole_lock.Rather than relying on the
console_lockto determine suspended state, make it an official per-console state that is set withinconsole->flags. This allows the state to be queried via SRCU.
Quoted 5 lines
Remove @console_suspended. Console printing will still be avoided when suspended because
console_is_usable()returns false when the new suspended flag is set for that console.We are seeing this on roughly 2/3 of our machines, both on test systems and production systems.
Then,
Quoted 1 line
The effect is most pronounced in the GigaByte z170x UD5. It goes from 300ms to 400ms because of an msleep 100 in the
resume_consolecode. This might not seem like much but it's in series with everything else so it will always be there. Our goal is to keep both suspend and resume under 1 second if at all possible, so every bit counts.
See Bugzilla for the full thread and attached sleepgraph timelines (in html format).
Anyway, I'm adding this regression to be tracked by regzbot:
#regzbot introduced: 9e70a5e109a4a2 https://bugzilla.kernel.org/show_bug.cgi?id=217955
#regzbot title: resume_console performance regression due to per-console suspended state
Thanks.
[1]: https://bugzilla.kernel.org/show_bug.cgi?id=217955
Signature · 1 line
An old man doll... just what I always wanted! - Clara
Quoted 31 lines · Bagas Sanjaya
Hi,
I notice a regression report on Bugzilla [1]. Quoting from it:
Quoted 17 lines
Ever since 6.6.0-rc1 we've seen S3 and S2idle resume take 100ms longer because of
resume_comsole.resume_consoleordinarily takes only a few milliseconds, but now it's consistently 100ms. I've bisected the issue to this commit:commit
9e70a5e109a4a23367810de09be826c52d27ee2fAuthor: John Ogness <[email protected]> Date: Mon Jul 17 21:52:06 2023 +0206printk: Add per-console suspended state
Currently the global @console_suspended is used to determine if consoles are in a suspended state. Its primary purpose is to allow usage of the
console_lockwhen suspended without causing console printing. It is synchronized by theconsole_lock.Rather than relying on the
console_lockto determine suspended state, make it an official per-console state that is set withinconsole->flags. This allows the state to be queried via SRCU.Quoted 5 lines
Remove @console_suspended. Console printing will still be avoided when suspended because
console_is_usable()returns false when the new suspended flag is set for that console.We are seeing this on roughly 2/3 of our machines, both on test systems and production systems.
Then,
Quoted 1 line
The effect is most pronounced in the GigaByte z170x UD5. It goes from 300ms to 400ms because of an msleep 100 in the
resume_consolecode. This might not seem like much but it's in series with everything else so it will always be there. Our goal is to keep both suspend and resume under 1 second if at all possible, so every bit counts.
Quoted 8 lines
See Bugzilla for the full thread and attached sleepgraph timelines (in html format).
Anyway, I'm adding this regression to be tracked by regzbot:
#regzbot introduced:
9e70a5e109a4a2https://bugzilla.kernel.org/show_bug.cgi?id=217955
#regzbot title:resume_consoleperformance regression due to per-console suspended state
#regzbot fix: printk: flush consoles before checking progress
Signature · 1 line
An old man doll... just what I always wanted! - Clara