https://bugs.kde.org/show_bug.cgi?id=500745

--- Comment #14 from John <[email protected]> ---
Besides the above mentioned tools, for debugging or as a bit of development
help, if you need a bash command that extracts everything from the lscpu
command, here is one that gets and shows how many sockets are there, how many
are populated, CPU model, CPU frequency (+ current, min, max), cores, threads
and Hyper-Threading status:

eval "$(lscpu | awk -F: '/Model name:/{gsub(/^[ \t]+/,"",$2);print
"model=\""$2"\""}
/Socket\(s\)/{gsub(/^[ \t]+/,"",$2);print "sockets="$2}
/Core\(s\) per socket/{gsub(/^[ \t]+/,"",$2);print "cores="$2}
/Thread\(s\) per core/{gsub(/^[ \t]+/,"",$2);print "threads="$2}
/CPU MHz:/{gsub(/^[ \t]+/,"",$2);print "cur=\""$2" MHz\""}
/CPU min MHz:/{gsub(/^[ \t]+/,"",$2);print "min=\""$2" MHz\""}
/CPU max MHz:/{gsub(/^[ \t]+/,"",$2);print "max=\""$2" MHz\""}')" && printf
"%-22s %s\n%-22s %s\n%-22s %s\n%-22s %s\n%-22s %s\n%-22s %s\n%-22s %s\n" \
"Motherboard sockets:" "$sockets" \
"Populated sockets:" "$sockets" \
"CPU model:" "$model" \
"CPU frequencies:" "Current: ${cur:-N/A}  Min: ${min:-N/A}  Max: ${max:-N/A}" \
"CPU cores:" "$((sockets*cores))" \
"CPU threads:" "$((sockets*cores*threads))" \
"Hyper-Threading:" "$([ "$threads" -gt 1 ] && echo Yes || echo No)"

Which for me it displays:

Motherboard sockets:   1
Populated sockets:         1
CPU model:                       Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz
CPU frequencies:             Current: N/A  Min: 400.0000 MHz  Max: 3400.0000
MHz
CPU cores:                         4
CPU threads:                     8
Hyper-Threading:             Yes

The current CPU frequency seems to be problematic to get and most likely
requires other sources than lscpu, but it's OK if it's not shown as other
places that resource monitors are better for it anyway.
Unless in the future you decide to show the frequency of RAM modules and in
that case it's better to show it for the CPU too.

Maybe in the future you will ask the user somewhere or let him / her to choose
how tech-savvy it is and how much info they want to see and then choose what to
display based on that, though I still think that the number of cores and
threads everyone wants to see.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to