Odd performance problems with Lenovo L15

From: Kevin Oberman <rkoberman_at_gmail.com>
Date: Mon, 10 Jan 2022 05:12:58 UTC
I continue to see odd performance issues and just noticed something I can
put my finger on that may explain it. It has gone from odd to totally off
the rails. Any ideas will be appreciated.

Normally, on an idle system I see all CPUs running at full speed.
dev.cpu.7.freq: 2101
dev.cpu.6.freq: 2101
dev.cpu.5.freq: 2101
dev.cpu.4.freq: 2101
dev.cpu.3.freq: 2101
dev.cpu.2.freq: 2101
dev.cpu.1.freq: 2101
dev.cpu.0.freq: 2101

But, during a large compile (e.g. llvm or firefox), things sometimes go
wonky. Everything slows to a crawl. And, I see:
dev.cpu.7.freq: 400
dev.cpu.6.freq: 400
dev.cpu.5.freq: 400
dev.cpu.4.freq: 400
dev.cpu.3.freq: 400
dev.cpu.2.freq: 400
dev.cpu.1.freq: 400
dev.cpu.0.freq: 2101

And, it never changes back to faster speeds. This is while the system is
idle and the temps  are all back as expected in an idle system (low 40s). I
suspect that the change occurs when the system is very warm. The cores
reach about 90C and then start to drop back to near idle temps (<50C).

This is a 4 core system, but cpu 0 and 1 are running at very different
speeds... 0 at max frequency and 1 at minimum. I don't think that it is
possible as that is different clock rates on the threads of a single core.
Everything seems messed up with super-slow IO and processes simply locking
up. They can't be killed and the system will not even shut down with the
inability to terminate the "stuck" process.

This is one of the Lenovo systems that will lock-up with P-States enabled,
so they are disabled. I suspect that running without P-States is not well
tested. As far as I know, no progress has been made as to why this happens
on FreeBSD, but not on Linux. It may or may not be related to this issue.
--
Kevin Oberman, Part time kid herder and retired Network Engineer
E-mail: rkoberman@gmail.com
PGP Fingerprint: D03FB98AFA78E3B78C1694B318AB39EF1B055683